blob: b5133598b66bb019e48609cbb1583dd14064275c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
|
# Makefile for Zip, ZipCloak, ZipNote and ZipSplit for
# djgpp 1.x
VPATH=.;msdos
# ------------- djgpp -------------
CPPFLAGS=-I. -DDOS -DASM_CRC $(LOCAL_ZIP)
ASFLAGS=$(CPPFLAGS)
CFLAGS=-Wall -O2 -m486 $(CPPFLAGS)
UTILFLAGS=-c -DUTIL $(CFLAGS) -o
CC=gcc
LD=gcc
LDFLAGS=-s
STRIP=strip
# Change the STUBIFY definition to the upper version if you want to create
# executables which can be used without any external extender file.
# >>> NOTE: Either copy the go32 extender into your build directory, or
# >>> edit the STUBIFY macro and add the correct path to "go32.exe".
#STUBIFY=coff2exe -s go32.exe
STUBIFY=coff2exe
# variables
#set CRC32 to crc_gcc.o or crc32.o, depending on whether ASM_CRC is defined:
CRC32 = crc_gcc.o
OBJZ = zip.o crypt.o ttyio.o zipfile.o zipup.o fileio.o util.o \
$(CRC32) crctab.o globals.o
OBJI = deflate.o trees.o match.o msdos.o
OBJU = zipfile_.o fileio_.o util_.o globals.o msdos_.o
OBJN = zipnote.o $(OBJU)
OBJC = zipcloak.o crctab.o crypt_.o ttyio.o $(OBJU)
OBJS = zipsplit.o $(OBJU)
ZIP_H = zip.h ziperr.h tailor.h msdos/osdep.h
# rules
.SUFFIXES: # Delete make's default suffix list
.SUFFIXES: .exe .out .a .ln .o .c .cc .C .p .f .F .y .l .s .S .h
.c.o:
$(CC) -c $(CFLAGS) $< -o $@
zips: zip.exe zipnote.exe zipsplit.exe zipcloak.exe
zip.o: zip.c $(ZIP_H) revision.h crypt.h ttyio.h
zipfile.o: zipfile.c $(ZIP_H)
zipup.o: zipup.c $(ZIP_H) revision.h crypt.h msdos/zipup.h
fileio.o: fileio.c $(ZIP_H)
util.o: util.c $(ZIP_H)
globals.o: globals.c $(ZIP_H)
deflate.o: deflate.c $(ZIP_H)
trees.o: trees.c $(ZIP_H)
crc_gcc.o: crc_i386.S
$(CC) $(ASFLAGS) -x assembler-with-cpp -c -o $@ crc_i386.S
crc32.o: crc32.c $(ZIP_H)
crctab.o: crctab.c $(ZIP_H)
crypt.o: crypt.c $(ZIP_H) crypt.h ttyio.h
ttyio.o: ttyio.c $(ZIP_H) crypt.h ttyio.h
msdos.o: msdos/msdos.c $(ZIP_H)
zipcloak.o: zipcloak.c $(ZIP_H) revision.h crypt.h ttyio.h
zipnote.o: zipnote.c $(ZIP_H) revision.h
zipsplit.o: zipsplit.c $(ZIP_H) revision.h
zipfile_.o: zipfile.c $(ZIP_H)
$(CC) $(UTILFLAGS) $@ zipfile.c
fileio_.o: fileio.c $(ZIP_H)
$(CC) $(UTILFLAGS) $@ fileio.c
util_.o: util.c $(ZIP_H)
$(CC) $(UTILFLAGS) $@ util.c
crypt_.o: crypt.c $(ZIP_H) crypt.h ttyio.h
$(CC) $(UTILFLAGS) $@ crypt.c
msdos_.o: msdos/msdos.c $(ZIP_H)
$(CC) $(UTILFLAGS) $@ msdos/msdos.c
match.o: match.S
$(CC) $(ASFLAGS) -x assembler-with-cpp -c -o $@ match.S
zip.exe: $(OBJZ) $(OBJI)
echo $(OBJZ) > zip.rsp
echo $(OBJI) >> zip.rsp
$(LD) $(LDFLAGS) -o zip @zip.rsp
del zip.rsp
$(STRIP) zip
$(STUBIFY) zip
del zip
zipcloak.exe: $(OBJC)
$(LD) $(LDFLAGS) $(OBJC) -o zipcloak
$(STRIP) zipcloak
$(STUBIFY) zipcloak
del zipcloak
zipnote.exe: $(OBJN)
$(LD) $(LDFLAGS) $(OBJN) -o zipnote
$(STRIP) zipnote
$(STUBIFY) zipnote
del zipnote
zipsplit.exe: $(OBJS)
$(LD) $(LDFLAGS) $(OBJS) -o zipsplit
$(STRIP) zipsplit
$(STUBIFY) zipsplit
del zipsplit
|