diff options
author | Mark Adler <madler@alumni.caltech.edu> | 2011-09-09 23:21:57 -0700 |
---|---|---|
committer | Mark Adler <madler@alumni.caltech.edu> | 2011-09-09 23:21:57 -0700 |
commit | 13a294f044ef0a89b2dcbfbb5d4d4c792673348e (patch) | |
tree | d9b377b4d8c00633c3da4e96659bfba9b08287f2 /win32/Makefile.gcc | |
parent | 7c2a874e50b871d04fbd19501f7b42cff55e5abc (diff) | |
download | zlib-1.2.0.1.tar.gz zlib-1.2.0.1.tar.bz2 zlib-1.2.0.1.zip |
zlib 1.2.0.1v1.2.0.1
Diffstat (limited to 'win32/Makefile.gcc')
-rw-r--r-- | win32/Makefile.gcc | 105 |
1 files changed, 105 insertions, 0 deletions
diff --git a/win32/Makefile.gcc b/win32/Makefile.gcc new file mode 100644 index 0000000..7f9973b --- /dev/null +++ b/win32/Makefile.gcc | |||
@@ -0,0 +1,105 @@ | |||
1 | # Makefile for zlib, derived from Makefile.dj2. | ||
2 | # Modified for mingw32 by C. Spieler, 6/16/98. | ||
3 | # Updated for zlib-1.2.x by Cosmin Truta, 11-Mar-2003. | ||
4 | # Tested under Cygwin and MinGW. | ||
5 | |||
6 | # Copyright (C) 1995-1998 Jean-loup Gailly. | ||
7 | # For conditions of distribution and use, see copyright notice in zlib.h | ||
8 | |||
9 | # To compile, or to compile and test, type: | ||
10 | # | ||
11 | # make -fmakefile.gcc; make test -fmakefile.gcc | ||
12 | # | ||
13 | # To install libz.a, zconf.h and zlib.h in the system directories, type: | ||
14 | # | ||
15 | # make install -fmakefile.gcc | ||
16 | # | ||
17 | |||
18 | LIB = libz.a | ||
19 | SHAREDLIB = libz.so | ||
20 | VER = 1.2.0 | ||
21 | |||
22 | CC = gcc | ||
23 | #CFLAGS = -DDEBUG -MMD -g | ||
24 | CFLAGS = $(LOC) -O3 -Wall | ||
25 | |||
26 | AS = $(CC) | ||
27 | ASFLAGS = $(LOC) -Wall | ||
28 | |||
29 | LD = $(CC) | ||
30 | LDFLAGS = $(LOC) -s | ||
31 | |||
32 | AR = ar | ||
33 | ARFLAGS = rcs | ||
34 | |||
35 | CP = cp -fp | ||
36 | # If GNU install is available, replace $(CP) with install. | ||
37 | INSTALL = $(CP) | ||
38 | RM = rm -f | ||
39 | |||
40 | prefix = /usr/local | ||
41 | exec_prefix = $(prefix) | ||
42 | |||
43 | OBJS = adler32.o compress.o crc32.o deflate.o gzio.o infback.o \ | ||
44 | inffast.o inflate.o inftrees.o trees.o uncompr.o zutil.o | ||
45 | |||
46 | # to use the asm code: make OBJA=match.o | ||
47 | OBJA = | ||
48 | |||
49 | TEST_OBJS = example.o minigzip.o | ||
50 | |||
51 | all: $(LIB) example minigzip | ||
52 | |||
53 | test: all | ||
54 | ./example | ||
55 | echo hello world | ./minigzip | ./minigzip -d | ||
56 | |||
57 | .c.o: | ||
58 | $(CC) $(CFLAGS) -c -o $@ $< | ||
59 | |||
60 | libz.a: $(OBJS) | ||
61 | $(AR) $(ARFLAGS) $@ $(OBJS) | ||
62 | |||
63 | example: example.o $(LIB) | ||
64 | $(LD) -o $@ $< $(LIB) | ||
65 | |||
66 | minigzip: minigzip.o $(LIB) | ||
67 | $(LD) -o $@ $< $(LIB) | ||
68 | |||
69 | |||
70 | # INCLUDE_PATH and LIBRARY_PATH were set for [make] in djgpp.env . | ||
71 | |||
72 | .PHONY : uninstall clean | ||
73 | |||
74 | install: zlib.h zconf.h $(LIB) | ||
75 | -@if not exist $(INCLUDE_PATH)/nul mkdir $(INCLUDE_PATH) | ||
76 | -@if not exist $(LIBRARY_PATH)/nul mkdir $(LIBRARY_PATH) | ||
77 | $(INSTALL) zlib.h $(INCLUDE_PATH) | ||
78 | $(INSTALL) zconf.h $(INCLUDE_PATH) | ||
79 | $(INSTALL) $(LIB) $(LIBRARY_PATH) | ||
80 | |||
81 | uninstall: | ||
82 | $(RM) $(INCLUDE_PATH)/zlib.h | ||
83 | $(RM) $(INCLUDE_PATH)/zconf.h | ||
84 | $(RM) $(LIBRARY_PATH)/libz.a | ||
85 | |||
86 | clean: | ||
87 | $(RM) *.o | ||
88 | $(RM) *.exe | ||
89 | $(RM) libz.a | ||
90 | $(RM) foo.gz | ||
91 | |||
92 | adler32.o: zlib.h zconf.h | ||
93 | compress.o: zlib.h zconf.h | ||
94 | crc32.o: crc32.h zlib.h zconf.h | ||
95 | deflate.o: deflate.h zutil.h zlib.h zconf.h | ||
96 | example.o: zlib.h zconf.h | ||
97 | gzio.o: zutil.h zlib.h zconf.h | ||
98 | inffast.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h | ||
99 | inflate.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h | ||
100 | infback.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h | ||
101 | inftrees.o: zutil.h zlib.h zconf.h inftrees.h | ||
102 | minigzip.o: zlib.h zconf.h | ||
103 | trees.o: deflate.h zutil.h zlib.h zconf.h trees.h | ||
104 | uncompr.o: zlib.h zconf.h | ||
105 | zutil.o: zutil.h zlib.h zconf.h | ||