home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 5 / FreshFish_July-August1994.bin / bbs / gnu / gzip-1.2.4-src.lha / src / amiga / gzip-1.2.4 / Makefile.in < prev    next >
Makefile  |  1994-02-23  |  12KB  |  387 lines

  1. # Makefile for gzip (GNU zip)    -*- Indented-Text -*-
  2. # Copyright (C) 1992-1993 Jean-loup Gailly and the Free Software Foundation
  3.  
  4. # This program is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2, or (at your option)
  7. # any later version.
  8.  
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12. # GNU General Public License for more details.
  13.  
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program; if not, write to the Free Software
  16. # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  17.  
  18. # $Id: Makefile.in,v 0.23 1993/06/24 11:51:47 jloup Exp $
  19.  
  20. #### Start of system configuration section. ####
  21.  
  22.  
  23. srcdir = @srcdir@
  24. VPATH = @srcdir@
  25.  
  26. CC = @CC@
  27. ASCPP = @ASCPP@
  28.  
  29. INSTALL = @INSTALL@
  30. INSTALL_PROGRAM = @INSTALL_PROGRAM@
  31. INSTALL_DATA = @INSTALL_DATA@
  32.  
  33. # Things you might add to DEFS (configure usually figures out what to do):
  34. # -DGNU_STANDARD        Behave as gzip even if invoked as gunzip (GNU standard)
  35. # -DDIRENT              Use <dirent.h>  for recursion (-r)
  36. # -DSYSDIR              Use <sys/dir.h> for recursion (-r)
  37. # -DSYSNDIR             Use <sys/ndir.h> for recursion (-r)
  38. # -DNDIR                Use <ndir.h> for recursion (-r)
  39. # -DSTDC_HEADERS        Use <stdlib.h>
  40. # -DHAVE_UNISTD_H    Use <unistd.h>
  41. # -DNO_FCNTL_H          Don't use <fcntl.h>
  42. # -DNO_UTIME_H        Don't use <utime.h>
  43. # -DHAVE_SYSUTIME_H    Use <sys/utime.h>
  44. # -DNO_MEMORY_H         Don't use <memory.h>. Not needed if STDC_HEADERS.
  45. # -DNO_STRING_H         Use strings.h, not string.h. Not needed if STDC_HEADERS
  46. # -DRETSIGTYPE=int      Define this if signal handlers must return an int.
  47. # -DNO_SYMLINK          OS defines S_IFLNK but does not support symbolic links
  48. # -DNO_MULTIPLE_DOTS    System does not allow file names with multiple dots
  49. # -DNO_UTIME        System does not support setting file modification time
  50. # -DNO_CHOWN        System does not support setting file owner
  51. # -DNO_DIR        System does not support readdir()
  52. # -DPROTO        Force function prototypes even if __STDC__ not defined
  53. # -DASMV        Use asm version match.S
  54. # -DMSDOS        MSDOS specific
  55. # -DOS2            OS/2 specific
  56. # -DVAXC        Vax/VMS with Vax C compiler
  57. # -DVMS            Vax/VMS with gcc
  58. # -DDEBUG        Debug code
  59. # -DDYN_ALLOC        Use dynamic allocation of large data structures
  60. # -DMAXSEG_64K        Maximum array size is 64K (for 16 bit system)
  61. # -DRECORD_IO           read() and write() are rounded to record sizes.
  62. # -DNO_STDIN_FSTAT      fstat() is not available on stdin
  63. # -DNO_FSTAT            fstat() is not available
  64. # -DNO_SIZE_CHECK       stat() does not give a reliable file size
  65.  
  66. DEFS = @DEFS@
  67. LIBS = @LIBS@
  68.  
  69. # additional assembly sources for particular systems may be required.
  70. OBJA = @OBJA@
  71.  
  72. SEDCMD = @SEDCMD@
  73.  
  74. CFLAGS = @CFLAGS@
  75. # If you want debug on by default, use: CFLAGS="-g" ./configure
  76. LDFLAGS = $(CFLAGS)
  77.  
  78. G=@G@
  79. # To install znew, zmore, etc... as gznew, gzmore... use: G=g
  80.  
  81. ZCAT=@ZCAT@
  82. # To install zcat executable and man page as gzcat, use: ZCAT=gzcat
  83.  
  84. X=
  85. # For OS/2 or MSDOS, use: X=.exe
  86.  
  87. O=.o
  88. # For OS/2 or MSDOS, use: O=.obj
  89.  
  90. prefix = /gnu
  91. exec_prefix = $(prefix)
  92.  
  93. bindir = $(exec_prefix)/bin
  94. scriptdir = $(bindir)
  95. # scriptdir is the directory in which shell scripts should be installed
  96. datadir = $(prefix)/lib
  97. libdir = $(prefix)/lib
  98. infodir = $(prefix)/info
  99.  
  100. # Extension (not including `.') for the installed manual page filenames.
  101. manext = 1
  102. # Where to install the manual pages.
  103. mandir = $(prefix)/man/man$(manext)
  104. # Use manlinks=so to use the .so method instead of hard links
  105. manlinks = ln
  106.  
  107. alldirs = $(bindir) $(scriptdir) $(datadir) $(libdir) $(infodir) $(mandir)
  108.  
  109. #### End of system configuration section. ####
  110.  
  111. SHELL = /bin/sh
  112.  
  113. LOADLIBES = $(LIBS)
  114.  
  115. TAR = tar
  116.  
  117. SRCS = gzip.c zip.c deflate.c trees.c bits.c unzip.c inflate.c util.c crypt.c\
  118.        lzw.c unlzw.c unpack.c unlzh.c getopt.c match.S
  119.  
  120. OBJS = gzip$O zip$O deflate$O trees$O bits$O unzip$O inflate$O util$O \
  121.        crypt$O lzw$O unlzw$O unpack$O unlzh$O getopt$O $(OBJA)
  122.  
  123. HDRS = gzip.h lzw.h tailor.h revision.h crypt.h getopt.h
  124.  
  125. GENFILES =  README NEWS INSTALL Makefile.in configure.in configure COPYING \
  126.   TODO THANKS ChangeLog $(SRCS) $(HDRS) zmore.in znew.in zdiff.in zgrep.in \
  127.   zforce.in gzexe.in gzip.1 zdiff.1 zgrep.1 zmore.1 znew.1 gzexe.1 zforce.1 \
  128.   gzip.doc algorithm.doc gzip.texi texinfo.tex gpl.texinfo gzip.info
  129.  
  130. sampleFILES =  sample/makecrc.c sample/zread.c sample/add.c sample/sub.c \
  131.        sample/ztouch sample/zfile
  132.  
  133. msdosFILES = msdos/tailor.c msdos/match.asm msdos/gzip.prj msdos/doturboc.bat \
  134.   msdos/Makefile.msc msdos/Makefile.bor msdos/Makefile.djg
  135.  
  136. os2FILES = os2/Makefile.os2 os2/gzip.def os2/gzip16.def
  137.  
  138. ntFILES = nt/Makefile.nt
  139.  
  140. vmsFILES = vms/Readme.vms vms/Makefile.vms vms/Makefile.gcc vms/makegzip.com \
  141.    vms/Makefile.mms vms/vms.c vms/gzip.hlp
  142.  
  143. amigaFILES = amiga/Makefile.sasc amiga/Makefile.gcc amiga/tailor.c \
  144.   amiga/utime.h amiga/match.a
  145.  
  146. atariFILES = atari/Makefile.st
  147.  
  148. primosFILES = primos/readme primos/primos.c primos/ci.opts \
  149.    primos/build.cpl primos/include/errno.h primos/include/fcntl.h \
  150.    primos/include/stdlib.h primos/include/sysStat.h primos/include/sysTypes.h
  151.  
  152. DISTFILES = $(GENFILES) $(sampleFILES) $(msdosFILES) $(os2FILES) $(ntFILES)\
  153.    $(vmsFILES) $(amigaFILES) $(atariFILES) $(primosFILES)
  154.  
  155. SCRIPTS = $(G)zdiff $(G)zgrep $(G)zmore $(G)znew $(G)zforce gzexe
  156.  
  157. .c$O:
  158.     $(CC) -c $(DEFS) $(CFLAGS) $<
  159.  
  160. #.PHONY: default all force test check
  161.  
  162. default:  gzip$X
  163. all:    gzip$X $(G)zdiff $(G)zgrep $(G)zmore $(G)znew $(G)zforce gzexe
  164. force:
  165.  
  166. #### Start of specific targets section. ####
  167. #
  168. # 'configure' works only on Unix systems. For other systems able to make
  169. # sense of this makefile, you can define target specific entries here.
  170. # For other systems such as MSDOS, separate Makefiles are
  171. # provided in subdirectories.
  172.  
  173. # NeXT 2.x, 3.0, 3.1 thin. For gcc, replace -bsd with -D__STRICT_BSD__.
  174. next:
  175.     $(MAKE) all CFLAGS="-O -bsd -DASMV" \
  176.     DEFS="-DNO_STDLIB_H -DNO_STRING_H -DNO_UTIME_H -DSYSDIR -DRETSIGTYPE=int"
  177.  
  178. # NeXT 3.1 fat (68k + 386). For gcc, replace -bsd with -D__STRICT_BSD__.
  179. next-fat:
  180.     $(MAKE) all OBJA=match-next.o \
  181.     CFLAGS="-O2 -bsd -DASMV -fno-builtin -arch m68k -arch i386" \
  182.     DEFS="-DNO_STDLIB_H -DNO_STRING_H -DNO_UTIME_H -DSYSDIR -DRETSIGTYPE=int"
  183.  
  184. match-next.o: match.S
  185.     cat $(srcdir)/match.S > match-next.s
  186.     $(CC) -arch m68k -arch i386 -c match-next.s
  187.     rm -f match-next.s
  188.  
  189. # gcc with emx 0.8f kit (use by preference os2/Makefile.os2)
  190. os2_gcc:
  191.     $(MAKE) all CC=gcc CFLAGS="-O -DOS2" X=".exe"
  192.  
  193. # Xenix 2.3.2 for 286:
  194. xenix_286:
  195.     $(MAKE) all CFLAGS="-LARGE -M2l"
  196.  
  197. # Coherent (with broken /bin/sh):
  198. coherent:
  199.     $(MAKE) all OBJA=match.o DEFS=\
  200.     "-DASMV -DSTDC_HEADERS=1 -DHAVE_UNISTD_H=1 -DDIRENT=1"
  201.  
  202. #### End of specific targets section. ####
  203.  
  204. install: installdirs installbin installman
  205.  
  206. installbin: all
  207.     $(INSTALL_PROGRAM) gzip$X $(bindir)/gzip$X
  208.     for f in $(SCRIPTS); do \
  209.       $(INSTALL_PROGRAM) $${f} $(scriptdir)/$${f}; done
  210.     rm -f $(scriptdir)/$(G)zcmp; \
  211.       ln $(scriptdir)/$(G)zdiff $(scriptdir)/$(G)zcmp
  212.     for f in gunzip$X ungzip$X $(ZCAT)$X ; do \
  213.       rm -f $(bindir)/$${f}; done
  214.     @if echo $(DEFS) | grep GNU_STANDARD > /dev/null; then \
  215.       echo 'exec gzip -d  $${1+"$$@"}' > $(bindir)/gunzip$X; \
  216.       echo 'exec gzip -dc $${1+"$$@"}' > $(bindir)/$(ZCAT)$X; \
  217.       chmod 755 $(bindir)/gunzip$X  $(bindir)/$(ZCAT)$X; \
  218.     else \
  219.       ln $(bindir)/gzip$X $(bindir)/gunzip$X; \
  220.       ln $(bindir)/gzip$X $(bindir)/$(ZCAT)$X; \
  221.     fi
  222.  
  223. installman: gzip.info
  224.     for f in gzip gunzip $(ZCAT) $(SCRIPTS) $(G)zcmp; do \
  225.       rm -f $(mandir)/$${f}.$(manext); done
  226.     -cd $(srcdir); for f in gzip gzexe; do \
  227.       $(INSTALL_DATA) $${f}.1 $(mandir)/$${f}.$(manext); done
  228.     -cd $(srcdir); for f in zdiff zgrep zmore znew zforce; do \
  229.       $(INSTALL_DATA) $${f}.1 $(mandir)/$(G)$${f}.$(manext); done
  230.     -cd $(mandir); if test $(manlinks) = so; then \
  231.       echo .so man$(manext)/gzip.$(manext)      > $(ZCAT).$(manext);\
  232.       echo .so man$(manext)/$(G)zdiff.$(manext) > $(G)zcmp.$(manext);\
  233.       echo .so man$(manext)/gzip.$(manext)      > gunzip.$(