home *** CD-ROM | disk | FTP | other *** search
/ Super Net 1 / SUPERNET_1.iso / PC / OTROS / UNIX / ARCHIE / CLIENTS / ARCHIE-1.2 / MAKEFILE < prev    next >
Encoding:
Text File  |  1992-04-14  |  5.2 KB  |  141 lines

  1. #
  2. # Last changed: 4/14/92, v1.3.2
  3. #
  4. # Makefile for the minimal build for an archie Prospero client.
  5.  
  6. # Your C compiler:
  7. CC=cc
  8.  
  9. # For most systems, these OPTIONS will suffice.  Exceptions:
  10. #
  11. #    * If you're on a Stardent, add  -43
  12. #    * If you're running EP/IX, you may need to add  -systype bsd43
  13. #      but try it without it first.
  14. OPTIONS= -O -I. -I/usr/netinclude -I/usr/ucbinclude
  15.  
  16. # For this, DEFINES is usually ok as-is.  Try it without any of these
  17. # first; if some stuff fails or shows up undefined, then come back and
  18. # add 'em.  Also please drop me a line if you had to add anything...ideally
  19. # things will reach a point where this whole section will be unnecessary.
  20. #
  21. #     * if you want to include the debugging code (so you
  22. #       can help with problem-solving if any crop up), add    -DDEBUG
  23. #     * if you're running Interactive Unix, add              -DISC
  24. #     * if you're running System V, add                  -DSYSV
  25. #     * if you're running a USG (System V.2) system, add      -DUSG
  26. #     * if you're running UTS, add                  -DUTS
  27. #     * if your system doesn't have the functions index(),
  28. #       rindex(), bcopy(), or bzero(), add                    -DFUNCS
  29. #     * if your system is missing the getenv(3) routine, add  -DGETENV
  30. #     * if your system doesn't have the re_comp/regcmp or re_exec/regex
  31. #       routines (no regex(3)/regcmp(3X) library), then add   -DNOREGEX
  32. #     * if your system is lacking strspn(), add               -DSTRSPN
  33. DEFINES= -DDEBUG
  34.  
  35. # The default Archie server; choose one of:
  36. #    archie.ans.net        (USA [NY])
  37. #    archie.rutgers.edu        (USA [NJ])
  38. #    archie.sura.net        (USA [MD])
  39. #    archie.unl.edu        (USA [NE])
  40. #    archie.mcgill.ca        (Canada)
  41. #    archie.funet.fi        (Finland/Mainland Europe)
  42. #    archie.au            (Australia)
  43. #    archie.doc.ic.ac.uk    (Great Britain/Ireland)
  44. #
  45. ARCHIE= archie.sura.net
  46.  
  47. #    Usually LDFLAGS is empty; if, after you build this, archie
  48. #     complains that it can't resolve ARCHIE.ANS.NET (or whatever
  49. #     you defined ARCHIE_HOST as), you need to add `-lresolv'.
  50. #    * If you need the PW library (e.g. A/UX), add -lPW
  51. #    * If you're using ISC, add -linet
  52. #    * If you're using Wollongong TCP/IP on an AT&T box, use the
  53. #      arguments -lnet -lnsl_s .
  54. #    * If you're using UTS, add -lsocket
  55. #    * If you're using System V Release 4, add -L/usr/ucblib etc.
  56. LDFLAGS=
  57. #LDFLAGS= -lresolv
  58. #LDFLAGS= -lnet -lnsl_s
  59. #LDFLAGS= -lsocket
  60. #LDFLAGS= -L/usr/ucblib -lucb -lsockdns -lnsl
  61.  
  62. # Change this if necessary.
  63. RM=/bin/rm
  64.  
  65. # =========================
  66. # Yer' done....make archie.
  67. # =========================
  68. #
  69. CFLAGS=$(OPTIONS) $(DEFINES) -DARCHIE_HOST=\"$(ARCHIE)\"
  70.  
  71. VERSION=1.3.2
  72. VMS_VERSION=`echo $(VERSION) | sed -e 's,\\.,_,g'`
  73.  
  74. OBJS=    aquery.o archie.o atalloc.o dirsend.o get_pauth.o get_vdir.o \
  75.     perrmesg.o procquery.o ptalloc.o regex.o stcopy.o support.o \
  76.     vlalloc.o vl_comp.o
  77.  
  78. all: archie
  79.  
  80. archie: $(OBJS)
  81.     $(CC) $(CFLAGS) -o $@ $(OBJS) $(LDFLAGS)
  82.  
  83. $(OBJS): archie.h pmachine.h pcompat.h Makefile
  84.  
  85. procquery.o: copyright.h
  86.  
  87. clean:
  88.     $(RM) -f *.o archie archie.doc
  89.  
  90. gclean: clean
  91.     $(RM) -f *~ archie.0* archie$(VMS_VERSION).com archie.tar* gmon.out archie.doc
  92.  
  93. unx-deadly:
  94.     unifdef -UXARCHIE xprocquery.c > procquery.c
  95.  
  96. udp: udp.o
  97.     $(CC) -o $@ udp.o
  98.  
  99. udptest: udp
  100.     @echo "This should print the date, if UDP's enabled, or hang if not:"
  101.     @./udp
  102.  
  103. FILES=    INSTALL Makefile Prospero README README.dos archie.c archie.h \
  104.     archie.lnk archie.doc archie.man aquery.c atalloc.c dirsend.c \
  105.     get_pauth.c get_vdir.c make.com makefile.cut makefile.dos makefile.os2 \
  106.     msdos/cutcp.h msdos/hostform.h msdos/netevent.h \
  107.     perrmesg.c patchlevel.h pauthent.h pcompat.h perrno.h pfs.h pmachine.h \
  108.     pprot.h procquery.c ptalloc.c rdgram.h regex.c regex.h stcopy.c \
  109.     support.c copyright.h udp.c vl_comp.c vlalloc.c vms.h vms_support.c \
  110.     vms/fd.h vms/in.h vms/pseudos.h vms/signal.h vms/socket.h vms/time.h \
  111.     vms/types.h vms/network.h vms/multi.opt vms/ucx.opt vms/woll.opt
  112.  
  113. BFILES= $(FILES) xprocquery.c
  114.  
  115. dist: tar shar dcl
  116.  
  117. shar: archie.doc
  118.     makekit -narchie-$(VERSION). `echo $(FILES) \
  119.         tr ' ' '\012' | sed -e "s/^/archie-$(VERSION)\//g"` \
  120.         vms msdos > Manifest
  121.  
  122. archie.doc: archie.man
  123.     nroff -man archie.man | tr '\010' _ | sed -e s/__//g > archie.doc
  124.  
  125. dcl: archie.doc
  126.     if [ ! -d archie$(VMS_VERSION)/ ]; then ln -s . archie$(VMS_VERSION); fi
  127.     echo '$$ write sys$$output "Unpacking..."' > archie$(VMS_VERSION).com
  128.     echo '$$ if f$$search("archie.dir") .eqs. "" then create/dir [.ARCHIE]' >> archie$(VMS_VERSION).com
  129.     echo '$$ if f$$search("[.ARCHIE]vms.dir") .eqs. "" then create/dir [.ARCHIE.VMS]' >> archie$(VMS_VERSION).com
  130.     echo '$$ if f$$search("[.ARCHIE]msdos.dir") .eqs. "" then create/dir [.ARCHIE.MSDOS]' >> archie$(VMS_VERSION).com
  131.     echo '$$ set noverify' >> archie$(VMS_VERSION).com
  132.     dclshar `echo "$(FILES)" | tr ' ' '\012' | \
  133.         sed -e "s/^/archie\//g"` >> archie$(VMS_VERSION).com
  134.     echo '$$ write sys$$output "Ok, now enter the ARCHIE directory, look at MAKE.COM, then type @MAKE ."' >> archie$(VMS_VERSION).com
  135.  
  136. tar: archie.doc
  137.     if [ ! -d archie-$(VERSION)/ ]; then ln -s . archie-$(VERSION); fi
  138.     tar cvf archie-$(VERSION).tar `echo $(FILES) |\
  139.      tr ' ' '\012' | sed -e "s/^/archie-$(VERSION)\//g"`
  140.     compress -f archie-$(VERSION).tar
  141.