home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 9 Archive / 09-Archive.zip / zip201.zip / amiga / makefile.azt < prev    next >
Makefile  |  1993-09-01  |  2KB  |  88 lines

  1. # Makefile for Zip, ZipNote, ZipCloak, ZipSplit for Aztec C 5.2
  2. #   -- Paul Kienitz, July 1993
  3. # Wow, it even works with Manx's own broken mini-Make now.
  4.  
  5. # Make sure platform is defined correctly
  6. DOSFLAG = -d AMIGA
  7.  
  8. # NOTE:  Encryption requires separately available CRYPT.C
  9. # Define these two as blank for no-encryption version.
  10. CRYPTF = -d CRYPT
  11. CRYPTO = crypt.o
  12.  
  13. DEFINES = $(DOSFLAG) $(CRYPTF)
  14. CC = cc
  15. CFLAGS = $(DEFINES) -pl -mcd -sabfmnpu -wcr0u -r46
  16. # -pl means short ints, -mcd is large code & data, -r46 is use A4 and A6 like
  17. # regular regs, -sabfmnpu is various optimizations, -wcr0u adjusts type checking
  18.  
  19. LD = ln
  20. LDLIBS = -lcl
  21. LDFLAGS = -m +q
  22.  
  23. ###############################################
  24. # BASIC COMPILE INSTRUCTIONS AND DEPENDENCIES #
  25. ###############################################
  26.  
  27. # default C rules
  28. .c.o :
  29.     $(CC) $(CFLAGS) -o $@ $*.c
  30.  
  31. # rules for routines containing entries needed by utilities
  32. .c.oo :
  33.     $(CC) $(CFLAGS) -d UTIL -o $@ $*.c
  34.  
  35. # object file lists
  36.  
  37. HFILES = zip.h ziperr.h tailor.h revision.h crypt.h amiga/z-stat.h
  38.  
  39. OBJI = deflate.o trees.o bits.o
  40. OBJA = zipfile.o zipup.o util.o fileio.o globals.o amiga/amiga.o
  41. OBJU = zipfile.oo zipup.oo fileio.oo util.oo globals.o amiga/amiga.o
  42.  
  43. OBJZ = zip.o $(OBJA) $(OBJI) $(CRYPTO) amiga/match.o
  44.  
  45. OBJN = zipnote.o  $(OBJU)
  46. OBJC = zipcloak.o $(OBJU) crypt.oo
  47. OBJS = zipsplit.o $(OBJU)
  48.  
  49. ZIPS = zip zipnote zipcloak zipsplit
  50.  
  51. zip : $(OBJZ) $(HFILES)
  52.     $(LD) $(LDFLAGS) -o $@ $(OBJZ) $(LDLIBS)
  53.  
  54. zipnote : $(OBJN) $(HFILES)
  55.     $(LD) $(LDFLAGS) -o $@ $(OBJN) $(LDLIBS)
  56.  
  57. zipcloak : $(OBJC) $(HFILES)
  58.     $(LD) $(LDFLAGS) -o $@ $(OBJC) $(LDLIBS)
  59.  
  60. zipsplit : $(OBJS) $(HFILES)
  61.     $(LD) $(LDFLAGS) -o $@ $(OBJS) $(LDLIBS)
  62.  
  63. all :      $(ZIPS)
  64.  
  65. clean :
  66.        -delete $(OBJZ) >nil:
  67.        -delete $(OBJU) >nil:
  68.        -delete zipnote.o zipcloak.o zipsplit.o >nil:
  69.  
  70. # special cases:
  71.  
  72. trees.o : trees.c
  73.     $(CC) $(CFLAGS) -mr -o trees.o trees.c
  74.  
  75. deflate.o : deflate.c
  76.     $(CC) $(CFLAGS) -d ASMV -o deflate.o deflate.c
  77.  
  78. amiga/match.o : amiga/match_68.a
  79.     as -n -c -d -eCPUTEST -eAMIGA -o amiga/match.o amiga/match_68.a
  80. # -n -c -d means one pass, and large code & data; -e defines a symbol.
  81. # The SAS assembler should also define the symbol ATSIGN when assembling.
  82.  
  83. amiga/amiga.o : amiga/amiga.c amiga/filedate.c amiga/stat.c amiga/z-stat.h
  84.     $(CC) $(CFLAGS) -o amiga/amiga.o amiga/amiga.c
  85.  
  86. zip.o zipnote.o zipcloak.o crypt.o zipsplit.o deflate.o trees.o bits.o \
  87.    zipfile.o zipup.o fileio.o util.o globals.o : $(HFILES)
  88.