home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 9 Archive / 09-Archive.zip / unzip532.zip / acorn / makefile < prev    next >
Makefile  |  1996-07-01  |  4KB  |  115 lines

  1. # Makefile for UnZip, UnZipSFX, ZipInfo and fUnZip (5.2 or later)
  2. # last modified:  18 Apr 96
  3.  
  4. # add -g to CC to debug
  5. # add -d to BIND to debug
  6. CC   = cc
  7. BIND = link
  8. AS   = $(CC) -c
  9. ASM  = objasm
  10. SQUEEZE = squeeze -v
  11. E    =
  12.  
  13. # flags
  14. #   CFLAGS    flags for C compile
  15. #   LFLAGS1   flags after output file spec, before obj file list
  16. #   LFLAGS2   flags after obj file list (libraries, etc)
  17. #
  18. LIB      =
  19. CFLAGS   = -throwback -wn
  20. CFLAGS   = $(CFLAGS) -IC:,@.
  21. ASMFLAGS = -Throwback -Stamp -NoCache -CloseExec -quit
  22. LFLAGS1  =
  23. LFLAGS2  = $(LIB) C:o.Stubs
  24.  
  25. # object file lists
  26. OBJS1 = unzip.o crc32.o crctab.o crypt.o envargs.o explode.o
  27. OBJS2 = extract.o fileio.o globals.o inflate.o list.o match.o
  28. OBJS3 = process.o ttyio.o unreduce.o unshrink.o zipinfo.o 
  29. OBJS  = $(OBJS1) $(OBJS2) $(OBJS3) riscos.o swiven.o acorn.o 
  30. OBJF  = funzip.o crc32.o crypt_.o globals_.o inflate_.o ttyio_.o \
  31.         riscos.o swiven.o
  32. OBJX  = unzipsfx.o crc32.o crctab.o crypt.o extract_.o fileio.o globals.o \
  33.         inflate.o match.o process_.o ttyio.o acorn_.o swiven.o riscos_.o
  34.  
  35. UNZIP_H = unzip.h unzpriv.h globals.h acorn/riscos.h acorn/swiven.h
  36.  
  37. all:      unzip funzip unzipsfx
  38.  
  39.  
  40. install:  unzip funzip unzipsfx
  41.         $(SQUEEZE) unzip %.unzip
  42.         $(SQUEEZE) funzip %.funzip
  43.         $(SQUEEZE) unzipsfx unzipsfx
  44.         copy %.unzip %.zipinfo ~CVF
  45.  
  46. # suffix rules
  47. .SUFFIXES:      .o .c
  48. .c.o:
  49.         $(CC) $(CFLAGS) -c $<
  50. .s.o:
  51.         $(ASM) $(ASMFLAGS) -from @*.s -to @*.o
  52.  
  53. # rules for unzip and funzip
  54. crc32.o:        crc32.c $(UNZIP_H) zip.h
  55. crctab.o:       crctab.c $(UNZIP_H) zip.h
  56. crypt.o:        crypt.c $(UNZIP_H) zip.h crypt.h ttyio.h
  57. envargs.o:      envargs.c $(UNZIP_H)
  58. explode.o:      explode.c $(UNZIP_H)
  59. extract.o:      extract.c $(UNZIP_H) crypt.h
  60. fileio.o:       fileio.c $(UNZIP_H) crypt.h ttyio.h ebcdic.h
  61. funzip.o:       funzip.c $(UNZIP_H) crypt.h ttyio.h tables.h
  62. globals.o:      globals.c $(UNZIP_H)
  63. inflate.o:      inflate.c inflate.h $(UNZIP_H)
  64. list.o:         list.c $(UNZIP_H)
  65. match.o:        match.c $(UNZIP_H)
  66. process.o:      process.c $(UNZIP_H)
  67. ttyio.o:        ttyio.c $(UNZIP_H) zip.h crypt.h ttyio.h
  68. unreduce.o:     unreduce.c $(UNZIP_H)
  69. unshrink.o:     unshrink.c $(UNZIP_H)
  70. unzip.o:        unzip.c $(UNZIP_H) crypt.h version.h consts.h
  71. zipinfo.o:      zipinfo.c $(UNZIP_H)
  72.  
  73. crypt_.o:       crypt.c $(UNZIP_H) zip.h crypt.h ttyio.h
  74.         $(CC) $(CFLAGS) -DFUNZIP -c c.crypt -o o.crypt_
  75. extract_.o:     extract.c $(UNZIP_H) crypt.h
  76.         $(CC) $(CFLAGS) -DSFX -c c.extract -o o.extract_
  77. globals_.o:     globals.c $(UNZIP_H)
  78.         $(CC) $(CFLAGS) -DFUNZIP -c c.globals -o o.globals_
  79. inflate_.o:     inflate.c inflate.h $(UNZIP_H) crypt.h
  80.         $(CC) $(CFLAGS) -DFUNZIP -c c.inflate -o o.inflate_
  81. process_.o:     process.c $(UNZIP_H)
  82.         $(CC) $(CFLAGS) -DSFX -c c.process -o o.process_
  83. ttyio_.o:       ttyio.c $(UNZIP_H) zip.h crypt.h ttyio.h
  84.         $(CC) $(CFLAGS) -DFUNZIP -c c.ttyio -o o.ttyio_
  85.  
  86. unzipsfx.o:     unzip.c $(UNZIP_H) crypt.h version.h consts.h
  87.         $(CC) $(CFLAGS) -DSFX -c c.unzip -o o.unzipsfx
  88.  
  89. acorn.o:       acorn/acorn.c $(UNZIP_H)
  90.         $(CC) $(CFLAGS) -c acorn/acorn.c
  91. acorn_.o:       acorn/acorn.c $(UNZIP_H)
  92.         $(CC) $(CFLAGS) -c -DSFX -DSFX_EXDIR -o acorn_.o acorn/acorn.c
  93.  
  94. riscos.o:       acorn/riscos.c $(UNZIP_H)
  95.         $(CC) $(CFLAGS) -c acorn/riscos.c
  96. riscos_.o:      acorn/riscos.c $(UNZIP_H)
  97.         $(CC) $(CFLAGS) -c -DSFX -DSFX_EXDIR -o riscos_.o acorn/riscos.c
  98.  
  99. swiven.o:       acorn/swiven.s
  100.         $(ASM) $(ASMFLAGS) -from acorn.s.swiven -to o.swiven
  101.  
  102. unzip:    $(OBJS)
  103.           $(BIND) -o unzip$(E) $(LFLAGS1) $(OBJS) $(LFLAGS2)
  104. funzip:   $(OBJF)
  105.           $(BIND) -o funzip$(E) $(LFLAGS1) $(OBJF) $(LFLAGS2)
  106. unzipsfx: $(OBJX)
  107.           $(BIND) -o unzipsfx$(E) $(LFLAGS1) $(OBJX) $(LFLAGS2)
  108.  
  109. clean:  ;remove unzip; remove funzip;
  110.         remove zipinfo; remove unzipsfx;
  111.         create o.!fake! 0
  112.         wipe o.* ~cf
  113.  
  114. # end of Makefile
  115.