Makefile.in 4.58 KB
Newer Older
Tinderbox User's avatar
Tinderbox User committed
1
# Copyright (C) 2004-2013  Internet Systems Consortium, Inc. ("ISC")
Mark Andrews's avatar
Mark Andrews committed
2 3 4 5 6 7 8 9 10 11 12 13 14
# Copyright (C) 1998-2003  Internet Software Consortium.
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
# INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
# LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
Mark Andrews's avatar
Mark Andrews committed
15

Mark Andrews's avatar
Mark Andrews committed
16
# $Id$
David Lawrence's avatar
David Lawrence committed
17

Bob Halley's avatar
Bob Halley committed
18 19 20 21
srcdir =	@srcdir@
VPATH =		@srcdir@
top_srcdir =	@top_srcdir@

Bob Halley's avatar
Bob Halley committed
22 23
@BIND9_VERSION@

Bob Halley's avatar
Bob Halley committed
24 25
@LIBISC_API@

26
CINCLUDES =	-I${srcdir}/unix/include \
27
		-I${srcdir}/@ISC_THREAD_DIR@/include \
28
		-I${srcdir}/@ISC_ARCH_DIR@/include \
29
		-I./include \
Francis Dupont's avatar
Francis Dupont committed
30
		-I${srcdir}/include @ISC_OPENSSL_INC@
31
CDEFINES =	@USE_OPENSSL@
Bob Halley's avatar
Bob Halley committed
32 33
CWARNINGS =

34
# Alphabetically
Bob Halley's avatar
Bob Halley committed
35
UNIXOBJS =	@ISC_ISCIPV6_O@ \
Michael Graff's avatar
Michael Graff committed
36
		unix/app.@O@ unix/dir.@O@ unix/entropy.@O@ \
David Lawrence's avatar
David Lawrence committed
37
		unix/errno2result.@O@ unix/file.@O@ unix/fsaccess.@O@ \
Michael Graff's avatar
Michael Graff committed
38
		unix/interfaceiter.@O@ unix/keyboard.@O@ unix/net.@O@ \
39
		unix/os.@O@ unix/resource.@O@ unix/socket.@O@ unix/stdio.@O@ \
Mark Andrews's avatar
Mark Andrews committed
40
		unix/stdtime.@O@ unix/strerror.@O@ unix/syslog.@O@ unix/time.@O@
41

Bob Halley's avatar
Bob Halley committed
42
NLSOBJS =	nls/msgcat.@O@
Michael Graff's avatar
Michael Graff committed
43

Mark Andrews's avatar
CHANGES  
Mark Andrews committed
44 45 46
THREADOPTOBJS = @ISC_THREAD_DIR@/condition.@O@ @ISC_THREAD_DIR@/mutex.@O@

THREADOBJS =	@THREADOPTOBJS@ @ISC_THREAD_DIR@/thread.@O@
Michael Graff's avatar
Michael Graff committed
47

48
WIN32OBJS = 	win32/condition.@O@ win32/dir.@O@ win32/file.@O@ \
David Lawrence's avatar
David Lawrence committed
49 50
		win32/fsaccess.@O@ win32/once.@O@ win32/stdtime.@O@ \
		win32/thread.@O@ win32/time.@O@
David Lawrence's avatar
David Lawrence committed
51

52
# Alphabetically
Michael Graff's avatar
Michael Graff committed
53
OBJS =		@ISC_EXTRA_OBJS@ \
54
		assertions.@O@ backtrace.@O@ base32.@O@ base64.@O@ \
55
		bind9.@O@ bitstring.@O@ buffer.@O@ bufferlist.@O@ \
56
		commandline.@O@ crc64.@O@ error.@O@ event.@O@ \
57
		hash.@O@ heap.@O@ hex.@O@ hmacmd5.@O@ hmacsha.@O@ \
58
		httpd.@O@ inet_aton.@O@ iterated_hash.@O@ \
59
		lex.@O@ lfsr.@O@ lib.@O@ log.@O@ \
60
		md5.@O@ mem.@O@ mutexblock.@O@ \
61
		netaddr.@O@ netscope.@O@ pool.@O@ ondestroy.@O@ \
62
		parseint.@O@ portset.@O@ quota.@O@ radix.@O@ random.@O@ \
63 64
		ratelimiter.@O@ refcount.@O@ region.@O@ regex.@O@ result.@O@ \
		rwlock.@O@ \
Evan Hunt's avatar
Evan Hunt committed
65
		safe.@O@ serial.@O@ sha1.@O@ sha2.@O@ sockaddr.@O@ stats.@O@ \
66 67
		string.@O@ strtoul.@O@ symtab.@O@ task.@O@ taskpool.@O@ \
		timer.@O@ version.@O@ ${UNIXOBJS} ${NLSOBJS} ${THREADOBJS}
68
SYMTBLOBJS =	backtrace-emptytbl.@O@
Bob Halley's avatar
Bob Halley committed
69

70
# Alphabetically
Bob Halley's avatar
Bob Halley committed
71
SRCS =		@ISC_EXTRA_SRCS@ \
72
		assertions.c backtrace.c base32.c base64.c bind9.c \
73
		bitstring.c buffer.c bufferlist.c commandline.c crc64.c \
74
		error.c event.c heap.c hex.c hmacmd5.c hmacsha.c \
75
		httpd.c inet_aton.c iterated_hash.c \
Michael Graff's avatar
Michael Graff committed
76
		lex.c lfsr.c lib.c log.c \
77
		md5.c mem.c mutexblock.c \
78
		netaddr.c netscope.c pool.c ondestroy.c \
79
		parseint.c portset.c quota.c radix.c random.c \
80
		ratelimiter.c refcount.c region.c regex.c result.c rwlock.c \
Evan Hunt's avatar
Evan Hunt committed
81 82 83
		safe.c serial.c sha1.c sha2.c sockaddr.c stats.c string.c \
		strtoul.c symtab.c symtbl-empty.c task.c taskpool.c timer.c \
		version.c
Bob Halley's avatar
Bob Halley committed
84

Bob Halley's avatar
Bob Halley committed
85 86
LIBS =		@LIBS@

Mark Andrews's avatar
Mark Andrews committed
87 88 89 90
# Note: the order of SUBDIRS is important.
# Attempt to disable parallel processing.
.NOTPARALLEL:
.NO_PARALLEL:
91
SUBDIRS =	include unix nls @ISC_THREAD_DIR@ @ISC_ARCH_DIR@
Bob Halley's avatar
Bob Halley committed
92
TARGETS =	timestamp
93
TESTDIRS =	@UNITTESTS@
Bob Halley's avatar
Bob Halley committed
94 95 96

@BIND9_MAKE_RULES@

Evan Hunt's avatar
Evan Hunt committed
97 98 99 100
safe.@O@: safe.c
	${LIBTOOL_MODE_COMPILE} ${CC} ${ALL_CFLAGS} @CCNOOPT@ \
		-c ${srcdir}/safe.c

Bob Halley's avatar
Bob Halley committed
101
version.@O@: version.c
102
	${LIBTOOL_MODE_COMPILE} ${CC} ${ALL_CFLAGS} \
Bob Halley's avatar
Bob Halley committed
103 104 105 106
		-DVERSION=\"${VERSION}\" \
		-DLIBINTERFACE=${LIBINTERFACE} \
		-DLIBREVISION=${LIBREVISION} \
		-DLIBAGE=${LIBAGE} \
107
		-c ${srcdir}/version.c
Bob Halley's avatar
Bob Halley committed
108

109 110 111 112 113
libisc.@SA@: ${OBJS} ${SYMTBLOBJS}
	${AR} ${ARFLAGS} $@ ${OBJS} ${SYMTBLOBJS}
	${RANLIB} $@

libisc-nosymtbl.@SA@: ${OBJS}
114 115
	${AR} ${ARFLAGS} $@ ${OBJS}
	${RANLIB} $@
Bob Halley's avatar
Bob Halley committed
116

117
libisc.la: ${OBJS} ${SYMTBLOBJS}
118
	${LIBTOOL_MODE_LINK} \
119
		${CC} ${ALL_CFLAGS} ${LDFLAGS} -o libisc.la -rpath ${libdir} \
Bob Halley's avatar
Bob Halley committed
120
		-version-info ${LIBINTERFACE}:${LIBREVISION}:${LIBAGE} \
121 122 123 124 125 126
		${OBJS} ${SYMTBLOBJS} ${LIBS}

libisc-nosymtbl.la: ${OBJS}
	${LIBTOOL_MODE_LINK} \
		${CC} ${ALL_CFLAGS} ${LDFLAGS} -o libisc-nosymtbl.la -rpath ${libdir} \
		-version-info ${LIBINTERFACE}:${LIBREVISION}:${LIBAGE} \
Bob Halley's avatar
Bob Halley committed
127 128
		${OBJS} ${LIBS}

129
timestamp: libisc.@A@ libisc-nosymtbl.@A@
Bob Halley's avatar
Bob Halley committed
130 131 132
	touch timestamp

installdirs:
133
	$(SHELL) ${top_srcdir}/mkinstalldirs ${DESTDIR}${libdir}
Bob Halley's avatar
Bob Halley committed
134 135

install:: timestamp installdirs
136
	${LIBTOOL_MODE_INSTALL} ${INSTALL_DATA} libisc.@A@ ${DESTDIR}${libdir}
Bob Halley's avatar
Bob Halley committed
137

138
clean distclean::
139 140
	rm -f libisc.@A@ libisc-nosymtbl.@A@ libisc.la \
	libisc-nosymtbl.la timestamp