ignore some files
[tridge/bind9.git] / bin / tests / sockaddr / Makefile
1 # Copyright (C) 2004, 2007  Internet Systems Consortium, Inc. ("ISC")
2 # Copyright (C) 1999-2002  Internet Software Consortium.
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
16 # $Id: Makefile.in,v 1.21 2007/06/19 23:47:00 tbox Exp $
17
18 srcdir =        .
19
20 top_srcdir =    ../../..
21
22 # Copyright (C) 2004, 2005, 2007  Internet Systems Consortium, Inc. ("ISC")
23 # Copyright (C) 1999-2001  Internet Software Consortium.
24 #
25 # Permission to use, copy, modify, and/or distribute this software for any
26 # purpose with or without fee is hereby granted, provided that the above
27 # copyright notice and this permission notice appear in all copies.
28 #
29 # THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
30 # REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
31 # AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
32 # INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
33 # LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
34 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
35 # PERFORMANCE OF THIS SOFTWARE.
36
37 # $Id: includes.in,v 1.21 2007/06/19 23:47:24 tbox Exp $
38
39 # Search for machine-generated header files in the build tree,
40 # and for normal headers in the source tree (${top_srcdir}).
41 # We only need to look in OS-specific subdirectories for the
42 # latter case, because there are no machine-generated OS-specific
43 # headers.
44
45 ISC_INCLUDES = -I/home/tridge/project/bind9/lib/isc/include \
46         -I${top_srcdir}/lib/isc \
47         -I${top_srcdir}/lib/isc/include \
48         -I${top_srcdir}/lib/isc/unix/include \
49         -I${top_srcdir}/lib/isc/pthreads/include \
50         -I${top_srcdir}/lib/isc/x86_32/include
51
52 ISCCC_INCLUDES = -I/home/tridge/project/bind9/lib/isccc/include \
53        -I${top_srcdir}/lib/isccc/include
54
55 ISCCFG_INCLUDES = -I/home/tridge/project/bind9/lib/isccfg/include \
56        -I${top_srcdir}/lib/isccfg/include
57
58 DNS_INCLUDES = -I/home/tridge/project/bind9/lib/dns/include \
59         -I${top_srcdir}/lib/dns/include
60
61 LWRES_INCLUDES = -I/home/tridge/project/bind9/lib/lwres/include \
62         -I${top_srcdir}/lib/lwres/unix/include \
63         -I${top_srcdir}/lib/lwres/include
64
65 BIND9_INCLUDES = -I/home/tridge/project/bind9/lib/bind9/include \
66         -I${top_srcdir}/lib/bind9/include
67
68 TEST_INCLUDES = \
69         -I${top_srcdir}/lib/tests/include
70
71 CINCLUDES =     ${TEST_INCLUDES} ${ISC_INCLUDES}
72
73 CDEFINES =
74 CWARNINGS =
75
76 ISCLIBS =       ../../../lib/isc/libisc.la
77 TAPIDEPLIBS =   ../../../lib/tests/libt_api.la
78
79 ISCDEPLIBS =    ../../../lib/isc/libisc.la
80 TAPILIBS =      ../../../lib/tests/libt_api.la
81
82 DEPLIBS =       ${TAPIDEPLIBS} ${ISCDEPLIBS}
83
84 LIBS =          ${TAPILIBS} ${ISCLIBS} -lcap -lpthread  -lxml2
85
86 TARGETS =       t_sockaddr
87
88 SRCS =          t_sockaddr.c
89
90 # Copyright (C) 2004-2009  Internet Systems Consortium, Inc. ("ISC")
91 # Copyright (C) 1998-2003  Internet Software Consortium.
92 #
93 # Permission to use, copy, modify, and/or distribute this software for any
94 # purpose with or without fee is hereby granted, provided that the above
95 # copyright notice and this permission notice appear in all copies.
96 #
97 # THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
98 # REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
99 # AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
100 # INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
101 # LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
102 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
103 # PERFORMANCE OF THIS SOFTWARE.
104
105 # $Id: rules.in,v 1.64.130.2 2009/01/10 23:46:57 tbox Exp $
106
107 ###
108 ### Common Makefile rules for BIND 9.
109 ###
110
111 ###
112 ### Paths
113 ###
114 ### Note: paths that vary by Makefile MUST NOT be listed
115 ### here, or they won't get expanded correctly.
116
117 prefix =        /home/tridge/project/bind9/prefix
118 exec_prefix =   ${prefix}
119 bindir =        ${exec_prefix}/bin
120 sbindir =       ${exec_prefix}/sbin
121 includedir =    ${prefix}/include
122 libdir =        ${exec_prefix}/lib
123 sysconfdir =    /etc/bind
124 localstatedir = /var
125 mandir =        $/share/man
126 datarootdir =   ${prefix}/share
127
128 DESTDIR =
129
130
131
132 top_builddir =  /home/tridge/project/bind9
133
134 ###
135 ### All
136 ###
137 ### Makefile may define:
138 ###     TARGETS
139
140 all: subdirs ${TARGETS}
141
142 ###
143 ### Subdirectories
144 ###
145 ### Makefile may define:
146 ###     SUBDIRS
147
148 ALL_SUBDIRS = ${SUBDIRS} nulldir
149
150 #
151 # We use a single-colon rule so that additional dependencies of
152 # subdirectories can be specified after the inclusion of this file.
153 # The "depend" target is treated the same way.
154 #
155 subdirs:
156         @for i in ${ALL_SUBDIRS}; do \
157                 if [ "$$i" != "nulldir" -a -d $$i ]; then \
158                         echo "making all in `pwd`/$$i"; \
159                         (cd $$i; ${MAKE} ${MAKEDEFS} DESTDIR="${DESTDIR}" all) || exit 1; \
160                 fi; \
161         done
162
163 install:: all
164
165 install clean distclean maintainer-clean doc docclean man manclean::
166         @for i in ${ALL_SUBDIRS}; do \
167                 if [ "$$i" != "nulldir" -a -d $$i ]; then \
168                         echo "making $@ in `pwd`/$$i"; \
169                         (cd $$i; ${MAKE} ${MAKEDEFS} DESTDIR="${DESTDIR}" $@) || exit 1; \
170                 fi; \
171         done
172
173 ###
174 ### C Programs
175 ###
176 ### Makefile must define
177 ###     CC
178 ### Makefile may define
179 ###     CFLAGS
180 ###     LDFLAGS
181 ###     CINCLUDES
182 ###     CDEFINES
183 ###     CWARNINGS
184 ### User may define externally
185 ###     EXT_CFLAGS
186
187 CC =            ccache gcc
188 CFLAGS =        -fno-strict-aliasing -DDIG_SIGCHASE -g -I/usr/include/libxml2
189 LDFLAGS =       
190 STD_CINCLUDES = 
191 STD_CDEFINES =   -D_GNU_SOURCE
192 STD_CWARNINGS =  -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith -fno-strict-aliasing
193
194 BUILD_CC = ccache gcc
195 BUILD_CFLAGS = -fno-strict-aliasing -DDIG_SIGCHASE -g -I/usr/include/libxml2
196 BUILD_CPPFLAGS =  -D_GNU_SOURCE 
197 BUILD_LDFLAGS = 
198 BUILD_LIBS = -lcap -lpthread  -lxml2
199
200 .SUFFIXES:
201 .SUFFIXES: .c .lo
202
203 ALWAYS_INCLUDES = -I${top_builddir}
204 ALWAYS_DEFINES = -D_REENTRANT -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
205 ALWAYS_WARNINGS =
206
207 ALL_CPPFLAGS = \
208         ${ALWAYS_INCLUDES} ${CINCLUDES} ${STD_CINCLUDES} \
209         ${ALWAYS_DEFINES} ${CDEFINES} ${STD_CDEFINES}
210
211 ALL_CFLAGS = ${EXT_CFLAGS} ${ALL_CPPFLAGS} ${CFLAGS} \
212         ${ALWAYS_WARNINGS} ${STD_CWARNINGS} ${CWARNINGS}
213
214 .c.lo:
215         ${LIBTOOL_MODE_COMPILE} ${CC} ${ALL_CFLAGS} -c $<
216
217 SHELL = /bin/bash
218 LIBTOOL = $(SHELL) $(top_builddir)/libtool
219 LIBTOOL_MODE_COMPILE = ${LIBTOOL} --mode=compile
220 LIBTOOL_MODE_INSTALL = ${LIBTOOL} --mode=install
221 LIBTOOL_MODE_LINK = ${LIBTOOL} --mode=link
222 PURIFY = 
223
224 MKDEP = ${SHELL} ${top_builddir}/make/mkdep
225
226 cleandir: distclean
227 superclean: maintainer-clean
228
229 clean distclean maintainer-clean::
230         rm -f *.lo *.o *.lo *.la core *.core .depend
231         rm -rf .libs
232
233 distclean maintainer-clean::
234         rm -f Makefile
235
236 depend:
237         @for i in ${ALL_SUBDIRS}; do \
238                 if [ "$$i" != "nulldir" -a -d $$i ]; then \
239                         echo "making depend in `pwd`/$$i"; \
240                         (cd $$i; ${MAKE} ${MAKEDEFS} DESTDIR="${DESTDIR}" $@) || exit 1; \
241                 fi; \
242         done
243         @if [ X"${VPATH}" != X ] ; then \
244                 if [ X"${SRCS}" != X -a X"${PSRCS}" != X ] ; then \
245                         echo ${MKDEP} -vpath ${VPATH} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
246                         ${MKDEP} -vpath ${VPATH} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
247                         echo ${MKDEP} -vpath ${VPATH} -ap ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
248                         ${MKDEP} -vpath ${VPATH} -ap ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
249                         ${DEPENDEXTRA} \
250                 elif [ X"${SRCS}" != X ] ; then \
251                         echo ${MKDEP} -vpath ${VPATH} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
252                         ${MKDEP} -vpath ${VPATH} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
253                         ${DEPENDEXTRA} \
254                 elif [ X"${PSRCS}" != X ] ; then \
255                         echo ${MKDEP} -vpath ${VPATH} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
256                         ${MKDEP} -vpath ${VPATH} -p ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
257                         ${DEPENDEXTRA} \
258                 fi \
259         else \
260                 if [ X"${SRCS}" != X -a X"${PSRCS}" != X ] ; then \
261                         echo ${MKDEP} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
262                         ${MKDEP} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
263                         echo ${MKDEP} -ap ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
264                         ${MKDEP} -ap ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
265                         ${DEPENDEXTRA} \
266                 elif [ X"${SRCS}" != X ] ; then \
267                         echo ${MKDEP} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
268                         ${MKDEP} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${SRCS}; \
269                         ${DEPENDEXTRA} \
270                 elif [ X"${PSRCS}" != X ] ; then \
271                         echo ${MKDEP} ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
272                         ${MKDEP} -p ${ALL_CPPFLAGS} ${ALL_CFLAGS} ${PSRCS}; \
273                         ${DEPENDEXTRA} \
274                 fi \
275         fi
276
277 FORCE:
278
279 ###
280 ### Libraries
281 ###
282
283 AR =            /usr/bin/ar
284 ARFLAGS =       cruv
285 RANLIB =        ranlib
286
287 ###
288 ### Installation
289 ###
290
291 INSTALL =               /usr/bin/install -c
292 INSTALL_PROGRAM =       ${INSTALL}
293 LINK_PROGRAM =          ln -s
294 INSTALL_SCRIPT =        ${INSTALL}
295 INSTALL_DATA =          ${INSTALL} -m 644
296
297 ###
298 ### Programs used when generating documentation.  It's ok for these
299 ### not to exist when not generating documentation.
300 ###
301
302 XSLTPROC =              /usr/bin/xsltproc --novalid --xinclude --nonet
303 PERL =                  /usr/bin/perl
304 LATEX =                 /usr/bin/latex
305 PDFLATEX =              /usr/bin/pdflatex
306 W3M =                   /usr/bin/w3m
307
308 ###
309 ### DocBook -> HTML
310 ### DocBook -> man page
311 ###
312
313 .SUFFIXES: .docbook .html .1 .2 .3 .4 .5 .6 .7 .8
314
315 .docbook.html:
316         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-docbook-html.xsl $<
317
318 .docbook.1:
319         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
320
321 .docbook.2:
322         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
323
324 .docbook.3:
325         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
326
327 .docbook.4:
328         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
329
330 .docbook.5:
331         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
332
333 .docbook.6:
334         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
335
336 .docbook.7:
337         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
338
339 .docbook.8:
340         ${XSLTPROC} -o $@ ${top_srcdir}/doc/xsl/isc-manpage.xsl $<
341
342 t_sockaddr: t_sockaddr.lo ${DEPLIBS}
343         ${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ t_sockaddr.lo ${LIBS}
344
345 test: t_sockaddr
346         -@./t_sockaddr -b . -a
347
348 testhelp:
349         @./t_sockaddr -h
350
351 clean distclean::
352         rm -f ${TARGETS}