source: trunk/essentials/app-arch/gzip/msdos/Makefile.bor

Last change on this file was 3325, checked in by bird, 18 years ago

gzip 1.3.11

File size: 2.9 KB
Line 
1# Makefile for gzip
2# Borland (Turbo) C++.
3# Warning: this file is not suitable for Turbo C 2.0. In this case, read
4# then invoke the file doturboc.bat.
5
6# To use, do "make -fmakefile.bor"
7
8# Turbo C++ 1.0 seems to have a buggy exit() function. You must add
9# to CFLAGS: -Dexit=_exit
10
11# WARNING: the small model is not supported. The compact model is used
12# here. If you want to use the large model, add -D__LARGE__ to ASFLAGS
13# Add -DSMALL_MEM to CFLAGS if you wish to reduce the memory
14# requirements. Add -DNO_ASM to CFLAGS and remove match.obj from OBJA if
15# you do not have tasm.
16
17# ------------- Turbo C++, Borland C++ -------------
18MODEL=-mc
19#CFLAGS=-w -w-eff -w-def -w-sig -w-cln -a -d -G -O -Z $(MODEL)
20CFLAGS=-O2 -Z $(MODEL)
21CC=bcc
22LD=bcc
23# replace bcc with tcc for Turbo C++ 1.0
24LDFLAGS=$(MODEL)
25AS=tasm
26ASFLAGS=-ml -t -DDYN_ALLOC -DSS_NEQ_DS
27LIB = c:\bcc\lib
28
29# ------------- Common declarations:
30STRIP=rem
31# If you don't have lzexe, get it (by ftp on wuarchive.wustl.edu
32# in /mirrors/msdos/filutl/lzexe91e.zip). Then define:
33#STRIP=lzexe
34# Or if you've registered PKLITE, then define:
35#STRIP=pklite
36# This makes a big difference in .exe size (and possibly load time)
37
38O=.obj
39OBJA=match$(O) tailor$(O) $(LIB)\wildargs.obj
40
41# ------------- Used by install rule
42# set BIN to the directory you want to install the executables to
43BIN = c:\bin
44
45# variables
46OBJ1 = gzip$(O) zip$(O) deflate$(O) trees$(O) bits$(O) unzip$(O) inflate$(O) \
47 util$(O)
48OBJ2 = crypt$(O) lzw$(O) unlzw$(O) unpack$(O) unlzh$(O) getopt$(O) $(OBJA)
49
50all: gzip.exe
51
52gzip.obj: gzip.c gzip.h tailor.h crypt.h revision.h lzw.h
53 $(CC) -c $(CFLAGS) $*.c
54
55zip.obj: zip.c gzip.h tailor.h crypt.h
56 $(CC) -c $(CFLAGS) $*.c
57
58deflate.obj: deflate.c gzip.h tailor.h
59 $(CC) -c $(CFLAGS) $*.c
60
61trees.obj: trees.c gzip.h tailor.h
62 $(CC) -c $(CFLAGS) $*.c
63
64bits.obj: bits.c gzip.h tailor.h crypt.h
65 $(CC) -c $(CFLAGS) $*.c
66
67unzip.obj: unzip.c gzip.h tailor.h crypt.h
68 $(CC) -c $(CFLAGS) $*.c
69
70inflate.obj: inflate.c gzip.h tailor.h
71 $(CC) -c $(CFLAGS) $*.c
72
73util.obj: util.c gzip.h tailor.h crypt.h
74 $(CC) -c $(CFLAGS) $*.c
75
76crypt.obj: crypt.c gzip.h tailor.h crypt.h
77 $(CC) -c $(CFLAGS) $*.c
78
79lzw.obj: lzw.c gzip.h tailor.h
80 $(CC) -c $(CFLAGS) $*.c
81
82unlzw.obj: unlzw.c gzip.h tailor.h lzw.h
83 $(CC) -c $(CFLAGS) $*.c
84
85unpack.obj: unpack.c gzip.h tailor.h
86 $(CC) -c $(CFLAGS) $*.c
87
88unlzh.obj: unlzh.c gzip.h tailor.h
89 $(CC) -c $(CFLAGS) $*.c
90
91tailor.obj: msdos\tailor.c gzip.h tailor.h
92 $(CC) -c $(CFLAGS) msdos\$*.c
93
94getopt.obj: getopt.c getopt.h
95 $(CC) -c $(CFLAGS) $*.c
96
97match.obj: msdos\match.asm
98 $(AS) $(ASFLAGS) msdos\match, match;
99
100# we must cut the command line to fit in the MS/DOS 128 byte limit:
101gzip.exe: $(OBJ1) $(OBJ2)
102 echo $(OBJ1) > gzip.rsp
103 echo $(OBJ2) >> gzip.rsp
104 $(LD) $(LDFLAGS) @gzip.rsp
105 del gzip.rsp
106 $(STRIP) gzip.exe
107# If you use Borland make, you can use instead:
108# $(LD) $(LDFLAGS) @&&|
109#$**
110#|
111
112install: gzip.exe
113 copy /b gzip.exe $(BIN)
114 copy /b gzip.exe $(BIN)\gunzip.exe
115
116clean:
117 del *.obj
118 del *.exe
Note: See TracBrowser for help on using the repository browser.