1238104Sdes# Standard installation pathnames 2238104Sdes# See the file LICENSE for the license 3238104SdesSHELL = @SHELL@ 4238104SdesVERSION = @PACKAGE_VERSION@ 5238104Sdesbasesrcdir = $(shell basename `pwd`) 6238104Sdessrcdir = @srcdir@ 7238104Sdesprefix = @prefix@ 8238104Sdesexec_prefix = @exec_prefix@ 9238104Sdesbindir = @bindir@ 10238104Sdesmandir = @mandir@ 11238104Sdesincludedir = @includedir@ 12246854Sdesdatarootdir = @datarootdir@ 13238104Sdes 14238104SdesCC = @CC@ 15238104SdesCFLAGS = -I. @CFLAGS@ 16238104SdesCPPFLAGS = @CPPFLAGS@ 17238104SdesLDFLAGS = @LDFLAGS@ 18238104SdesLIBS = @LIBS@ 19238104SdesINSTALL = $(srcdir)/install-sh -c 20238104SdesINSTALL_PROGRAM = $(INSTALL) 21238104SdesLDNSDIR = @LDNSDIR@ 22238104SdesLIBS_STC = @LIBS_STC@ 23238104Sdes 24238104SdesCOMPILE = $(CC) $(CPPFLAGS) $(CFLAGS) -I. -I$(srcdir) 25238104SdesLINK = $(CC) $(CFLAGS) $(LDFLAGS) 26238104Sdes 27238104SdesLINT = splint 28238104SdesLINTFLAGS=+quiet -weak -warnposix -unrecog -Din_addr_t=uint32_t -Du_int=unsigned -Du_char=uint8_t -preproc -Drlimit=rlimit64 -D__gnuc_va_list=va_list 29238104Sdes#-Dglob64=glob -Dglobfree64=globfree 30238104Sdes# compat with openssl linux edition. 31238104SdesLINTFLAGS+="-DBN_ULONG=unsigned long" -Dkrb5_int32=int "-Dkrb5_ui_4=unsigned int" -DPQ_64BIT=uint64_t -DRC4_INT=unsigned -fixedformalarray -D"ENGINE=unsigned" -D"RSA=unsigned" -D"DSA=unsigned" -D"EVP_PKEY=unsigned" -D"EVP_MD=unsigned" -D"SSL=unsigned" -D"SSL_CTX=unsigned" -D"X509=unsigned" -D"RC4_KEY=unsigned" -D"EVP_MD_CTX=unsigned" 32238104Sdes# compat with NetBSD 33238104Sdesifeq "$(shell uname)" "NetBSD" 34238104SdesLINTFLAGS+="-D__RENAME(x)=" -D_NETINET_IN_H_ 35238104Sdesendif 36238104Sdes# compat with OpenBSD 37238104SdesLINTFLAGS+="-Dsigset_t=long" 38238104Sdes# FreeBSD8 39238104SdesLINTFLAGS+="-D__uint16_t=uint16_t" 40238104SdesLINTFLAGS+=-D__signed__=signed "-D__packed=" "-D__aligned(x)=" 41238104Sdes# Ubuntu Linux 11.04 42238104SdesLINTFLAGS+="-D__u16=struct __u16" "-D__u32=struct __u32" "-D__u64=struct __u64" 43238104Sdes 44238104SdesOBJ=drill.o drill_util.o error.o root.o work.o chasetrace.o dnssec.o securetrace.o 45238104SdesSRC=$(OBJ:.o=.c) 46238104Sdes 47238104SdesHEADER=drill.h $(srcdir)/drill_util.h 48238104Sdes 49238104Sdes.PHONY: all clean realclean docclean doc release tags install all-static 50238104Sdes 51238104Sdesall: drill 52238104Sdesall-static: drill-stc 53238104Sdes 54238104Sdestags: 55238104Sdes ctags *.[ch] 56238104Sdes 57238104Sdesdrill: $(OBJ) 58238104Sdes $(LINK) -o drill $(OBJ) $(LIBS) 59238104Sdes 60238104Sdesdrill-stc: $(OBJ) 61238104Sdes $(LINK) -o drill $(OBJ) $(LIBS_STC) 62238104Sdes 63238104Sdes## implicit rule 64238104Sdes%.o: $(srcdir)/%.c 65238104Sdes $(COMPILE) -c $< 66238104Sdes 67238104Sdesclean: 68238104Sdes rm -f ${OBJ} 69238104Sdes rm -f drill 70238104Sdes rm -f *core 71238104Sdes rm -f config.h.in~ 72238104Sdes rm -f config.log 73238104Sdes rm -f config.guess 74238104Sdes rm -f config.status 75238104Sdes 76238104Sdesdocclean: 77238104Sdes rm -rf doxydoc 78238104Sdes 79238104Sdesdistclean: clean docclean 80238104Sdes rm -f config.h 81238104Sdes 82238104Sdesrealclean: clean docclean 83238104Sdes rm -f tags 84238104Sdes rm -f config.log 85238104Sdes rm -f config.sub 86238104Sdes rm -f ltmain.sh 87238104Sdes rm -f config.status 88238104Sdes rm -rf autom4te.cache 89238104Sdes rm -f config.h 90238104Sdes rm -f config.h.in 91238104Sdes rm -f configure 92238104Sdes rm -f Makefile 93246854Sdes rm -f drill.1 94238104Sdes rm -f aclocal.m4 95238104Sdes 96238104Sdesdoc: 97238104Sdes doxygen drill.doxygen 98238104Sdes 99238104Sdesinstall: all 100238104Sdes $(INSTALL) -d $(DESTDIR)$(bindir) 101238104Sdes $(INSTALL) drill $(DESTDIR)$(bindir)/drill 102246854Sdes $(INSTALL) -m 644 drill.1 $(DESTDIR)$(mandir)/man1/drill.1 103238104Sdes 104238104Sdesuninstall: 105238104Sdes @echo 106238104Sdes rm -f -- $(DESTDIR)$(bindir)/drill 107238104Sdes rm -f -- $(DESTDIR)$(mandir)/man1/drill.1 108238104Sdes rmdir -p $(DESTDIR)$(bindir) 109238104Sdes rmdir -p $(DESTDIR)$(mandir)/man1 110238104Sdes @echo 111238104Sdes 112238104Sdeslint: 113238104Sdes @for i in $(SRC) ; do \ 114238104Sdes $(LINT) $(LINTFLAGS) $(CPPFLAGS) -I$(srcdir) $(srcdir)/$$i ; \ 115238104Sdes if [ $$? -ne 0 ] ; then exit 1 ; fi ; \ 116238104Sdes done 117238104Sdes 118238104Sdesconfclean: clean 119246854Sdes rm -rf config.log config.status config.h Makefile drill.1 120