home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 35 Internet / 35-Internet.zip / tcpdumpb.zip / Makefile < prev    next >
Makefile  |  1997-02-26  |  5KB  |  142 lines

  1. # Generated automatically from Makefile.in by configure.
  2. #  Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996
  3. #     The Regents of the University of California.  All rights reserved.
  4. #
  5. #  Redistribution and use in source and binary forms, with or without
  6. #  modification, are permitted provided that: (1) source code distributions
  7. #  retain the above copyright notice and this paragraph in its entirety, (2)
  8. #  distributions including binary code include the above copyright notice and
  9. #  this paragraph in its entirety in the documentation or other materials
  10. #  provided with the distribution, and (3) all advertising materials mentioning
  11. #  features or use of this software display the following acknowledgement:
  12. #  ``This product includes software developed by the University of California,
  13. #  Lawrence Berkeley Laboratory and its contributors.'' Neither the name of
  14. #  the University nor the names of its contributors may be used to endorse
  15. #  or promote products derived from this software without specific prior
  16. #  written permission.
  17. #  THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
  18. #  WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  19. #  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  20. #
  21. # @(#) $Header: Makefile.in,v 1.195 96/07/16 23:52:06 leres Exp $ (LBL)
  22.  
  23. #
  24. # Various configurable paths (remember to edit Makefile.in, not Makefile)
  25. #
  26.  
  27. # Top level hierarchy
  28. prefix = /usr/local
  29. exec_prefix = ${prefix}
  30. # Pathname of directory to install the binary
  31. BINDEST = ${exec_prefix}/sbin
  32. # Pathname of directory to install the man page
  33. MANDEST = ${prefix}/man
  34.  
  35. #
  36. # You shouldn't need to edit anything below here.
  37. #
  38.  
  39. CC = gcc
  40. CCOPT = -O4
  41. INCLS = -I. -Ilibpcap -include /emx/include/sys/types.h -include /emx/include/sys/so_ioctl.h
  42. DEFS =  -DHAVE_FCNTL_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_LIBSOCKET=1 -DSTDC_HEADERS=1 -Dint32_t=int -Du_int32_t=u_int -DRETSIGTYPE=void -DRETSIGVAL= -DHAVE_TIMEZONE=1 -DLBL_ALIGN=1 -DPPP -DHAVE_FDDI
  43.  
  44. # Standard CFLAGS
  45. CFLAGS = $(CCOPT) $(DEFS) $(INCLS)
  46.  
  47. # Standard LIBS
  48. LIBS = -llibpcap -lsocket -lipspy -lrpc
  49.  
  50. INSTALL = ./install-sh -c
  51.  
  52. # Explicitly define compilation rule since SunOS 4's make doesn't like gcc.
  53. # Also, gcc does not remove the .o before forking 'as', which can be a
  54. # problem if you don't own the file but can write to the directory.
  55. .c.o:
  56.     @rm -f $@
  57.     $(CC) $(CFLAGS) -c $*.c
  58.  
  59. CSRC =    tcpdump.c addrtoname.c \
  60.     print-ether.c print-ip.c print-arp.c print-tcp.c \
  61.     print-udp.c print-atalk.c print-domain.c print-tftp.c \
  62.     print-bootp.c print-nfs.c print-icmp.c print-igrp.c \
  63.     print-sl.c print-ppp.c print-rip.c print-snmp.c \
  64.     print-ntp.c print-null.c print-egp.c print-ospf.c \
  65.     print-fddi.c print-llc.c print-sunrpc.c print-wb.c \
  66.     print-decnet.c print-isoclns.c print-ipx.c \
  67.     print-atm.c print-dvmrp.c print-pim.c print-krb.c \
  68.     util.c machdep.c bpf_dump.c parsenfsfh.c print-smb.c smbutil.c
  69. LOCALSRC =
  70. GENSRC = version.c
  71.  
  72. SRC =    $(CSRC) $(GENSRC) $(LOCALSRC)
  73.  
  74. # We would like to say "OBJ = $(SRC:.c=.o)" but Ultrix's make cannot
  75. # hack the extra indirection
  76. OBJ =    $(CSRC:.c=.o) $(GENSRC:.c=.o) $(LOCALSRC:.c=.o)  strcasecmp.o
  77. HDR =   addrtoname.h appletalk.h bootp.h decnet.h \
  78.     ethertype.h extract.h fddi.h interface.h igrp.h ipx.h \
  79.     llc.h machdep.h mib.h nfsfh.h nfsv2.h ntp.h ospf.h
  80.  
  81. TAGHDR = \
  82.     /usr/include/arpa/tftp.h \
  83.     /usr/include/net/slip.h \
  84.     /usr/include/netinet/if_ether.h \
  85.     /usr/include/netinet/in.h \
  86.     /usr/include/netinet/ip_icmp.h \
  87.     /usr/include/netinet/tcp.h \
  88.     /usr/include/netinet/udp.h \
  89.     /usr/include/protocols/routed.h
  90.  
  91. TAGFILES = $(SRC) $(HDR) $(TAGHDR)
  92.  
  93. CLEANFILES = $(OBJ) tcpdump $(GENSRC)
  94.  
  95. tcpdump: $(OBJ) 
  96.     @rm -f $@
  97.     $(CC) -Zcrtdll $(CFLAGS) -o $@ $(OBJ) $(LIBS)
  98.  
  99. version.o: version.c
  100. version.c: VERSION
  101.     @rm -f $@
  102.     sed -e 's/.*/char version[] = "&";/' VERSION > $@
  103.  
  104. install: force
  105.     $(INSTALL) -m 550 -o bin -g 0 tcpdump $(DESTDIR)$(BINDEST)
  106.  
  107. install-man: force
  108.     $(INSTALL) -m 444 -o bin -g bin tcpdump.1 $(DESTDIR)$(MANDEST)/man1
  109.  
  110. lint:    $(GENSRC) force
  111.     lint -hbxn $(SRC) | \
  112.         grep -v 'struct/union .* never defined' | \
  113.         grep -v 'possible pointer alignment problem'
  114.  
  115. clean:
  116.     rm -f $(CLEANFILES)
  117.  
  118. distclean:
  119.     rm -f $(CLEANFILES) Makefile config.cache config.log config.status \
  120.         gnuc.h os-proto.h
  121.  
  122. tags:    $(TAGFILES)
  123.     ctags -wtd $(TAGFILES)
  124.  
  125. tar:    force
  126.     @cwd=`pwd` ; dir=`basename $$cwd` ; name=tcpdump-`cat VERSION` ; \
  127.         list="" ; tar="tar chFFf" ; \
  128.         for i in `cat FILES` ; do list="$$list $$name/$$i" ; done; \
  129.         echo \
  130.         "rm -f ../$$name; ln -s $$dir ../$$name" ; \
  131.          rm -f ../$$name; ln -s $$dir ../$$name ; \
  132.         echo \
  133.         "(cd .. ; $$tar - [lots of files]) | compress > /tmp/$$name.tar.Z" ; \
  134.          (cd .. ; $$tar - $$list) | compress > /tmp/$$name.tar.Z ; \
  135.         echo \
  136.         "rm -f ../$$name" ; \
  137.          rm -f ../$$name
  138.  
  139. force:    /tmp
  140. depend:    $(GENSRC) force
  141.     ./mkdep -c $(CC) $(DEFS) $(INCLS) $(SRC)
  142.