Building ISC DHCP 4.X on Solaris hosts

I attempted to upgrade my ISC DHCP installation to dhcp-4.1.1b1 this past weekend, and ran into the following configure error:

$ ./configure --prefix=/bits/software/dhcp-4.1.1b1

checking for a BSD-compatible install... /bin/ginstall -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... unsupported
checking for style of include used by make... none
checking dependency style of gcc... none
checking how to run the C preprocessor... /lib/cpp
configure: error: C preprocessor "/lib/cpp" fails sanity check
See `config.log' for more details.

Th config.log had a number of errors similar to the following:

conftest.c:11:19: stdio.h: No such file or directory
conftest.c:12:23: sys/types.h: No such file or directory
conftest.c:13:22: sys/stat.h: No such file or directory

Which are due to missing system headers. I reviewed the list of packages that were installed, and sure enough SUNWhea (this package contains the various header files) was missing. I installed this package as well as a number of others:

$ pkgadd -d . SUNWhea SUNWbinutils SUNWarc SUNWgcc SUNWgccruntime

$ pkgadd -d . SUNWlibsigsegv SUNWgm4 SUNWgnu-automake-110 SUNWaconf

Any everything compiled and installed perfectly.

This article was posted by Matty on 2009-07-13 12:37:00 -0400 EDT