Makefile.in 2.2 KB
Newer Older
1
# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
Mark Andrews's avatar
Mark Andrews committed
2
#
3 4 5
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
6 7 8
#
# See the COPYRIGHT file distributed with this work for additional
# information regarding copyright ownership.
Bob Halley's avatar
Bob Halley committed
9

Bob Halley's avatar
Bob Halley committed
10 11 12 13
srcdir =	@srcdir@
VPATH =		@srcdir@
top_srcdir =	@top_srcdir@

14
@BIND9_MAKE_INCLUDES@
15

16
CINCLUDES =	${DNS_INCLUDES} ${ISC_INCLUDES} ${ISCCFG_INCLUDES} \
17
		@DST_OPENSSL_INC@
18

19
CDEFINES =	@CRYPTO@
Bob Halley's avatar
Bob Halley committed
20
CWARNINGS =
Mark Andrews's avatar
Mark Andrews committed
21
BACKTRACECFLAGS = @BACKTRACECFLAGS@
Bob Halley's avatar
Bob Halley committed
22

23
DNSLIBS =	../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
24 25
ISCLIBS =	../../lib/isc/libisc.@A@ @ISC_OPENSSL_LIBS@
ISCNOSYMLIBS =	../../lib/isc/libisc-nosymtbl.@A@ @ISC_OPENSSL_LIBS@
26
ISCCFGLIBS = 	../../lib/isccfg/libisccfg.@A@
27

Bob Halley's avatar
Bob Halley committed
28 29
DNSDEPLIBS =	../../lib/dns/libdns.@A@
ISCDEPLIBS =	../../lib/isc/libisc.@A@
30
ISCDEPNOSYMLIBS = ../../lib/isc/libisc-nosymtbl.@A@
31
ISCCFGDEPLIBS = ../../lib/isccfg/libisccfg.@A@
32 33

LIBS =		@LIBS@
Bob Halley's avatar
Bob Halley committed
34

35
SUBDIR =	atomic db dst names rbt resolver \
36
		tasks timers system @PKCS11_TOOLS@ optional
37

Evan Hunt's avatar
Evan Hunt committed
38 39
TESTDIRS =	system

40 41
# Test programs that are built by default:
# cfg_test is needed for regenerating doc/misc/options
42
# makejournal is needed by system tests
43 44
# wire_test is needed for fuzz testing
# other opptional test programs have been moved to ./optional
45

46
# Alphabetically
47
TARGETS =	cfg_test@EXEEXT@ makejournal@EXEEXT@ \
48
		wire_test@EXEEXT@
49

50
SRCS =		cfg_test.c makejournal.c wire_test.c
Bob Halley's avatar
Bob Halley committed
51

Bob Halley's avatar
Bob Halley committed
52 53
@BIND9_MAKE_RULES@

54
all_tests: subdirs
55

56 57
wire_test@EXEEXT@: wire_test.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
	${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ wire_test.@O@ \
58
		${DNSLIBS} ${ISCLIBS} ${LIBS}
59

60
cfg_test@EXEEXT@: cfg_test.@O@ ${ISCCFGDEPLIBS} ${ISCDEPLIBS}
61
	${LIBTOOL_MODE_LINK} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ cfg_test.@O@ \
62
		${ISCCFGLIBS} ${DNSLIBS} ${ISCLIBS} ${LIBS}
63

64 65
makejournal@EXEEXT@: makejournal.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
	${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ makejournal.@O@ \
66
		${DNSLIBS} ${ISCLIBS} ${LIBS}
67

68 69 70
distclean::
	rm -f headerdep_test.sh

71
clean distclean::
72
	rm -f ${TARGETS}
James Brister's avatar
James Brister committed
73

74 75
check: test

William King's avatar
William King committed
76
test:
Evan Hunt's avatar
Evan Hunt committed
77
	@for dir in $(TESTDIRS) ;\
William King's avatar
William King committed
78
	do \
79
		( cd $$dir; $(MAKE) test ) ;\
William King's avatar
William King committed
80
	done