]> git.ipfire.org Git - thirdparty/dhcp.git/blame - util/Makefile.bind.in
Add link/update address for dhcp-users mailing list
[thirdparty/dhcp.git] / util / Makefile.bind.in
CommitLineData
95bba8b6 1#
75de8eaf 2# Copyright (C) 2009-2019 Internet Systems Consortium, Inc. ("ISC")
95bba8b6
SR
3#
4# Permission to use, copy, modify, and/or distribute this software for any
5# purpose with or without fee is hereby granted, provided that the above
6# copyright notice and this permission notice appear in all copies.
7#
8# THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
9# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
10# AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
11# INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12# LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
13# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14# PERFORMANCE OF THIS SOFTWARE.
15
95bba8b6
SR
16# Configure and build the bind libraries for use by DHCP
17
e94e7f23
FD
18binddir=@BINDDIR@
19bindsrcdir=@BINDSRCDIR@
95bba8b6 20
f9e73c18
FD
21prefix = @prefix@
22exec_prefix = @exec_prefix@
23
ae91e4db 24bindconfig = --without-openssl --without-libxml2 --without-libjson \
ece2d9da 25 --without-gssapi --disable-threads --without-lmdb \
cc35f849 26 --includedir=@includedir@ --libdir=@libdir@ --without-python\
13e5cc6c 27 @BINDLT@ @BINDIOMUX@ @BINDCONFIG@ --enable-full-report
6913a589 28
f9e73c18
FD
29@BIND_ATF_FALSE@cleandirs = ./lib ./include
30@BIND_ATF_TRUE@cleandirs = ./lib ./include ./atf
6913a589
FD
31cleanfiles = ./configure.log ./build.log ./install.log
32
36d4e51a 33bindlibs = isc dns isccfg irs
f9e73c18 34installdirs = includedir=${binddir}/include libdir=${binddir}/lib
f8137a46 35
1b245c91
FD
36@BIND_ATF_FALSE@all: bind1 bind2
37@BIND_ATF_TRUE@all: bind1 atf bind2
38
39bind1:
95bba8b6 40# Extract the source from the tarball, if it hasn't been already.
f8137a46
FD
41 @if test -d ${bindsrcdir} ; then \
42 echo ${bindsrcdir} already unpacked... ; \
43 else \
44 gunzip -c bind.tar.gz | tar xf - ; \
95bba8b6
SR
45 fi
46
ae91e4db 47# Configure the libraries
6913a589
FD
48# Currently disable the epoll, devpoll and kqueue options as they
49# don't interact well with the DHCP code.
d81e9330
SR
50# If the top-level Bind Makefile exists we skip the configuration step
51# as we assume it's done and won't change. Doing a make clean will
52# reset things if necessary.
6913a589 53 @if test -f ${bindsrcdir}/Makefile ; then \
ae91e4db 54 echo Bind libraries already configured ; \
6913a589 55 else \
ae91e4db 56 echo Configuring BIND libraries for DHCP. ; \
6913a589
FD
57 rm -rf ${cleandirs} ${cleanfiles} ; \
58 (cd ${bindsrcdir} && \
59 ./configure ${bindconfig} > ${binddir}/configure.log); \
d81e9330 60 fi
95bba8b6 61
e31705ff 62atf: bind1
6913a589 63# Build and copy the ATF support if not yet installed.
f8137a46
FD
64 @if test -d ./atf ; then \
65 echo ATF support already installed ; \
66 else \
67 echo Building ATF support ; \
68 (cd ${bindsrcdir}/unit; \
69 $(MAKE) atf > ${binddir}/build.log ; \
70 cp -rp atf ${binddir}) ; \
1b245c91 71 fi
6913a589 72
e31705ff
TM
73@BIND_ATF_TRUE@bind2: atf
74bind2: bind1
ae91e4db 75# Build and install the libraries
d81e9330 76# No need to do anything if we already have something installed.
e4dcd805
FD
77 @if test -d ${binddir}/lib ; then \
78 echo Bind libraries already installed ; \
79 else \
80 echo Building BIND libraries - this takes some time. ; \
81 for libdir in ${bindlibs} ; do \
82 (cd ${bindsrcdir}/lib/$$libdir ; \
83 echo Building $$libdir library in `pwd` ; \
b94669fa 84 $(MAKE) all >> ${binddir}/build.log) ; \
e4dcd805
FD
85 done ; \
86 \
87 echo Installing BIND libraries to ${binddir}. ; \
88 for libdir in ${bindlibs} ; do \
89 (cd ${bindsrcdir}/lib/$$libdir ; \
90 MAKEDEFS="${installdirs}"; export MAKEDEFS; \
91 $(MAKE) ${installdirs} LIBTOOL_MODE_INSTALL= install >> \
92 ${binddir}/install.log) ; \
93 done ; \
d81e9330 94 fi
95bba8b6
SR
95
96clean:
ae91e4db 97 @echo Cleaning BIND library.
6913a589 98 rm -rf ${bindsrcdir} ${cleandirs} ${cleanfiles}
95bba8b6 99
f9741514
FD
100@INSTALL_BIND_FALSE@install:
101@INSTALL_BIND_TRUE@install: install-bind
f9741514
FD
102
103install-bind: all
104 @for libdir in ${bindlibs} ; do \
105 (cd ${bindsrcdir}/lib/$$libdir ; \
106 $(MAKE) install) ; \
107 done
108
36d4e51a
FD
109@INSTALL_BIND_FALSE@uninstall:
110@INSTALL_BIND_TRUE@uninstall: uninstall-bind
111
112uninstall-bind: all
113 @for libdir in ${bindlibs} ; do \
114 (cd ${bindsrcdir}/lib/$$libdir ; \
115 $(MAKE) uninstall) ; \
116 done
117
b3745bf5
SR
118# Include the following so that this Makefile is happy when the parent
119# tries to use them.
8d822e2c 120install-exec:
b3745bf5 121
36d4e51a 122check distdir distclean dvi installcheck: