Building DHCP server from sources/repository

Patrick Cervicek patrick at
Mon Jan 1 15:45:43 UTC 2018

just for the mail archive


"How to checkout, build and start DHCP server"

@ISC: It would be nice if you could provide some documentation on your
developer/git page. Please fix the dhcp configure/makefiles. Please also
check how to build and run ATF in dhcp.

# prepare environment on host

# create new linux build system (chroot) with debootstrap
sudo debootstrap --arch i386 --variant=minbase stretch
chroot $CHROOT/stretch_i386_root

# prepare environment in chroot
mkdir ${WORKSPACE}

# change to root
sudo chroot stretch_i386_root/

# install necessary packages
apt-get install build-essential git libssl-dev

# clone both repositories - dhcp dependends on bind libs!
git clone ${WORKSPACE}/bind
git clone  ${WORKSPACE}/dhcp

# change to bind directory
cd ${WORKSPACE}/bind

# run configure and name a directory where the bin/libs/includes should be
installed for dhcp
# consider taking "--with-atf" for unit tests
./configure --prefix=${WORKSPACE}/bind-output
make install

# change to dhcp directory
cd ${WORKSPACE}/dhcp

# run configure and name a directory where the bin/libs/includes should be
# important: you need now to name the output folder with the previously
built bind files
# --with-atf does not work :-(
./configure --prefix=${WORKSPACE}/dhcp-output

# change LIB variable in all Makefiles
sed -i 's/^LIBS =.*/LIBS = -lssl -lcrypto -lpthread/g' */Makefile
##  on ubuntu you need gssapi_krb5 (?)
##  sed -i 's/^LIBS =.*/LIBS = -lgssapi_krb5 -lssl -lcrypto -lpthread/g'

make install

# check if server was built
./server/dhcpd -v
Internet Systems Consortium DHCP Server 4.4.0a1

# finish

> Hi,
> I would like to join development on dhcp, but I fail building the sources.
> I would expect this to work:
> 1) git clone
> 2) cd dhcp
> 3)./configure
> 4) make
> Unfortunately it fails at step 3 "configure" with this error message:
> "
> ...
> checking for struct tpacket_auxdata.tp_vlan_tci... yes
> configure: error: Where to find or build bind includes and libraries must
> be specified
> "
> Why does dhcp require bind to be installed? Is there any documentation how
> to build dhcp from the repository? It would be helpful to demonstrate this
> on a clean new bootstraped linux like this:
> sudo debootstrap --arch i386 jessie /path/to/jessie_i386_root
> Regards,
> Patrick
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at

More information about the dhcp-users mailing list