annotate zlib/Makefile.msc @ 3:5a977ccbc7a9 default tip

Empty changelog
author darius
date Sat, 06 Dec 1997 05:41:29 +0000
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
1 # Makefile for zlib
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
2 # Microsoft C 5.1 or later
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
3
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
4 # To use, do "make makefile.msc"
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
5
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
6 # WARNING: the small model is supported but only for small values of
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
7 # MAX_WBITS and MAX_MEM_LEVEL. If you wish to reduce the memory
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
8 # requirements (default 256K for big objects plus a few K), you can add
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
9 # to CFLAGS below: -DMAX_MEM_LEVEL=7 -DMAX_WBITS=14
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
10 # See zconf.h for details about the memory requirements.
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
11
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
12 # ------------- Microsoft C 5.1 and later -------------
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
13 MODEL=-AL
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
14 CFLAGS=-Oait -Gs -nologo -W3 $(MODEL)
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
15 #-Ox generates bad code with MSC 5.1
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
16 CC=cl
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
17 LD=link
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
18 LDFLAGS=/e/st:0x1000/noe
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
19 O=.obj
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
20
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
21 # variables
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
22 OBJ1 = adler32$(O) compress$(O) crc32$(O) gzio$(O) uncompr$(O) deflate$(O) \
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
23 trees$(O)
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
24 OBJP1 = adler32$(O)+compress$(O)+crc32$(O)+gzio$(O)+uncompr$(O)+deflate$(O)+\
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
25 trees$(O)
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
26 OBJ2 = zutil$(O) inflate$(O) infblock$(O) inftrees$(O) infcodes$(O) \
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
27 infutil$(O) inffast$(O)
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
28 OBJP2 = zutil$(O)+inflate$(O)+infblock$(O)+inftrees$(O)+infcodes$(O)+\
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
29 infutil$(O)+inffast$(O)
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
30
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
31 adler32.obj: adler32.c zutil.h zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
32 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
33
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
34 compress.obj: compress.c zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
35 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
36
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
37 crc32.obj: crc32.c zutil.h zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
38 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
39
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
40 deflate.obj: deflate.c deflate.h zutil.h zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
41 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
42
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
43 gzio.obj: gzio.c zutil.h zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
44 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
45
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
46 infblock.obj: infblock.c zutil.h zlib.h zconf.h infblock.h inftrees.h\
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
47 infcodes.h infutil.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
48 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
49
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
50 infcodes.obj: infcodes.c zutil.h zlib.h zconf.h inftrees.h infutil.h\
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
51 infcodes.h inffast.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
52 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
53
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
54 inflate.obj: inflate.c zutil.h zlib.h zconf.h infblock.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
55 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
56
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
57 inftrees.obj: inftrees.c zutil.h zlib.h zconf.h inftrees.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
58 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
59
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
60 infutil.obj: infutil.c zutil.h zlib.h zconf.h inftrees.h infutil.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
61 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
62
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
63 inffast.obj: inffast.c zutil.h zlib.h zconf.h inftrees.h infutil.h inffast.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
64 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
65
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
66 trees.obj: trees.c deflate.h zutil.h zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
67 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
68
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
69 uncompr.obj: uncompr.c zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
70 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
71
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
72 zutil.obj: zutil.c zutil.h zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
73 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
74
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
75 example.obj: example.c zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
76 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
77
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
78 minigzip.obj: minigzip.c zlib.h zconf.h
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
79 $(CC) -c $(CFLAGS) $*.c
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
80
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
81 # we must cut the command line to fit in the MS/DOS 128 byte limit:
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
82 zlib.lib: $(OBJ1) $(OBJ2)
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
83 lib zlib $(OBJ1);
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
84 lib zlib $(OBJ2);
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
85
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
86 example.exe: example.obj zlib.lib
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
87 $(LD) $(LDFLAGS) example.obj,,,zlib.lib;
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
88
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
89 minigzip.exe: minigzip.obj zlib.lib
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
90 $(LD) $(LDFLAGS) minigzip.obj,,,zlib.lib;
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
91
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
92 test: example.exe minigzip.exe
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
93 example
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
94 echo hello world | minigzip | minigzip -d
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
95
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
96 #clean:
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
97 # del *.obj
5a977ccbc7a9 Empty changelog
darius
parents:
diff changeset
98 # del *.exe