Makefile.am 2.15 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14
SUBDIRS = . tests

AM_CPPFLAGS = -I$(top_srcdir)/src/lib -I$(top_builddir)/src/lib
AM_CPPFLAGS += -I$(top_srcdir)/src/bin -I$(top_builddir)/src/bin
AM_CPPFLAGS += $(BOOST_INCLUDES)

AM_CXXFLAGS = $(B10_CXXFLAGS)

if USE_STATIC_LINK
AM_LDFLAGS = -static
endif

pkglibexecdir = $(libexecdir)/@PACKAGE@

15
CLEANFILES  = *.gcno *.gcda spec_config.h dhcp4_messages.h dhcp4_messages.cc
16

17
man_MANS = b10-dhcp4.8
18
DISTCLEANFILES = $(man_MANS)
19
EXTRA_DIST = $(man_MANS) b10-dhcp4.xml dhcp4.spec
20

21
if GENERATE_DOCS
22
b10-dhcp4.8: b10-dhcp4.xml
23
	@XSLTPROC@ --novalid --xinclude --nonet -o $@ \
24 25
        http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl \
	$(srcdir)/b10-dhcp4.xml
26 27 28 29

else

$(man_MANS):
30 31
	@echo Man generation disabled.  Creating dummy $@.  Configure with --enable-generate-docs to enable it.
	@echo Man generation disabled.  Remove this file, configure with --enable-generate-docs, and rebuild BIND 10 > $@
32

33 34 35 36 37
endif

spec_config.h: spec_config.h.pre
	$(SED) -e "s|@@LOCALSTATEDIR@@|$(localstatedir)|" spec_config.h.pre >$@

38 39 40 41 42
dhcp4_messages.h dhcp4_messages.cc: dhcp4_messages.mes
	$(top_builddir)/src/lib/log/compiler/message $(top_srcdir)/src/bin/dhcp4/dhcp4_messages.mes

BUILT_SOURCES = spec_config.h dhcp4_messages.h dhcp4_messages.cc

43 44
pkglibexec_PROGRAMS = b10-dhcp4

45
b10_dhcp4_SOURCES  = main.cc
46
b10_dhcp4_SOURCES += ctrl_dhcp4_srv.cc ctrl_dhcp4_srv.h
47
b10_dhcp4_SOURCES += config_parser.cc config_parser.h
48 49 50 51 52
b10_dhcp4_SOURCES += dhcp4_log.cc dhcp4_log.h
b10_dhcp4_SOURCES += dhcp4_srv.cc dhcp4_srv.h

nodist_b10_dhcp4_SOURCES = dhcp4_messages.h dhcp4_messages.cc
EXTRA_DIST += dhcp4_messages.mes
53

54
b10_dhcp4_LDADD  = $(top_builddir)/src/lib/dhcp/libb10-dhcp++.la
55
b10_dhcp4_LDADD += $(top_builddir)/src/lib/util/libb10-util.la
56
b10_dhcp4_LDADD += $(top_builddir)/src/lib/dhcpsrv/libb10-dhcpsrv.la
57
b10_dhcp4_LDADD += $(top_builddir)/src/lib/exceptions/libb10-exceptions.la
58
b10_dhcp4_LDADD += $(top_builddir)/src/lib/asiolink/libb10-asiolink.la
59
b10_dhcp4_LDADD += $(top_builddir)/src/lib/log/libb10-log.la
60
b10_dhcp4_LDADD += $(top_builddir)/src/lib/config/libb10-cfgclient.la
61
b10_dhcp4_LDADD += $(top_builddir)/src/lib/cc/libb10-cc.la
62

63 64
b10_dhcp4dir = $(pkgdatadir)
b10_dhcp4_DATA = dhcp4.spec