~ubuntu-branches/ubuntu/precise/boinc/precise

« back to all changes in this revision

Viewing changes to zip/zip/win32/makefile.wat

Tags: 6.12.8+dfsg-1
* New upstream release.
* Simplified debian/rules

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# WMAKE makefile for Windows 95 and Windows NT (Intel only)
2
 
# using Watcom C/C++ v11.0+, by Paul Kienitz, last revised 13 Feb 99.
3
 
# Makes Zip.exe, ZipNote.exe, ZipCloak.exe, and ZipSplit.exe.
4
 
#
5
 
# Invoke from Zip source dir with "WMAKE -F WIN32\MAKEFILE.WAT [targets]"
6
 
# To build with debug info use "WMAKE DEBUG=1 ..."
7
 
# To build without any assembly modules use "WMAKE NOASM=1 ..."
8
 
#
9
 
# Other options to be fed to the compiler can be specified in an environment
10
 
# variable called LOCAL_ZIP.  One possibility "-DDYN_ALLOC", but currently
11
 
# this is not supported unless NOASM is also used.
12
 
 
13
 
variation = $(%LOCAL_ZIP)
14
 
 
15
 
# Stifle annoying "Delete this file?" questions when errors occur:
16
 
.ERASE
17
 
 
18
 
.EXTENSIONS:
19
 
.EXTENSIONS: .exe .obj .c .h .asm
20
 
 
21
 
# We maintain multiple sets of object files in different directories so that
22
 
# we can compile msdos, dos/4gw, and win32 versions of Zip without their
23
 
# object files interacting.  The following var must be a directory name
24
 
# ending with a backslash.  All object file names must include this macro
25
 
# at the beginning, for example "$(O)foo.obj".
26
 
 
27
 
!ifdef DEBUG
28
 
O = od32w\  # comment here so backslash won't continue the line
29
 
!else
30
 
O = ob32w\  # likewise
31
 
!endif
32
 
 
33
 
# The assembly hot-spot code in crc_i386.asm and match32.asm is optional.
34
 
# This section controls its usage.
35
 
 
36
 
!ifdef NOASM
37
 
asmob = $(O)crc32.obj           # C source
38
 
cvars = $+$(cvars)$- -DNO_ASM   # otherwise ASM_CRC might default on!
39
 
# "$+$(foo)$-" means expand foo as it has been defined up to now; normally,
40
 
# this make defers inner expansion until the outer macro is expanded.
41
 
!else  # !NOASM
42
 
asmob = $(O)match32.obj $(O)crc_i386.obj
43
 
cvars = $+$(cvars)$- -DASMV -DASM_CRC
44
 
!endif
45
 
 
46
 
# Our object files.  OBJZ is for Zip, OBJC is for ZipCloak, OBJN is for
47
 
# ZipNote, and OBJS is for ZipSplit:
48
 
 
49
 
OBJZ3 = $(O)zip.obj $(O)crypt.obj $(O)ttyio.obj $(O)trees.obj $(O)zipup.obj
50
 
OBJZ2 = $(OBJZ3) $(O)util.obj $(O)zipfile.obj $(O)fileio.obj $(O)deflate.obj
51
 
OBJZ1 = $(OBJZ2) $(O)globals.obj $(O)crctab.obj $(asmob)
52
 
OBJZ  = $(OBJZ1) $(O)win32zip.obj $(O)win32.obj $(O)nt.obj
53
 
 
54
 
OBJU1 = $(O)zipfile_.obj $(O)fileio_.obj $(O)util_.obj $(O)globals.obj
55
 
OBJ_U = $(OBJU1) $(O)win32_.obj
56
 
 
57
 
OBJC  = $(O)zipcloak.obj $(O)crctab.obj $(O)crypt_.obj $(O)ttyio.obj $(OBJ_U)
58
 
 
59
 
OBJN  = $(O)zipnote.obj $(OBJ_U)
60
 
 
61
 
OBJS  = $(O)zipsplit.obj $(OBJ_U)
62
 
 
63
 
# Common header files included by all C sources:
64
 
 
65
 
ZIP_H = zip.h ziperr.h tailor.h win32\osdep.h
66
 
 
67
 
# Now we have to pick out the proper compiler and options for it.
68
 
 
69
 
cc     = wcc386
70
 
link   = wlink
71
 
asm    = wasm
72
 
# Use Pentium Pro timings, register args, static strings in code:
73
 
cflags = -bt=NT -6r -zt -zq
74
 
aflags = -bt=NT -mf -3 -zq
75
 
lflags = sys NT
76
 
cvars  = $+$(cvars)$- -DWIN32 $(variation)
77
 
avars  = $+$(avars)$- $(variation)
78
 
 
79
 
# Specify optimizations, or a nonoptimized debugging version:
80
 
 
81
 
!ifdef DEBUG
82
 
cdebug = -od -d2
83
 
ldebug = d w all op symf
84
 
!else
85
 
cdebug = -s -obhikl+rt -oe=100 -zp8
86
 
# -oa helps slightly but might be dangerous.
87
 
ldebug = op el
88
 
!endif
89
 
 
90
 
# How to compile sources:
91
 
.c.obj:
92
 
        $(cc) $(cdebug) $(cflags) $(cvars) $[@ -fo=$@
93
 
 
94
 
# Here we go!  By default, make all targets:
95
 
all: Zip.exe ZipNote.exe ZipCloak.exe ZipSplit.exe
96
 
 
97
 
# Convenient shorthand options for single targets:
98
 
z:   Zip.exe       .SYMBOLIC
99
 
n:   ZipNote.exe   .SYMBOLIC
100
 
c:   ZipCloak.exe  .SYMBOLIC
101
 
s:   ZipSplit.exe  .SYMBOLIC
102
 
 
103
 
Zip.exe:        $(OBJZ)
104
 
        $(link) $(lflags) $(ldebug) name $@ file {$(OBJZ)}
105
 
 
106
 
ZipNote.exe:    $(OBJN)
107
 
        $(link) $(lflags) $(ldebug) name $@ file {$(OBJN)}
108
 
 
109
 
ZipCloak.exe:   $(OBJC)
110
 
        $(link) $(lflags) $(ldebug) name $@ file {$(OBJC)}
111
 
 
112
 
ZipSplit.exe:   $(OBJS)
113
 
        $(link) $(lflags) $(ldebug) name $@ file {$(OBJS)}
114
 
 
115
 
# Source dependencies:
116
 
 
117
 
$(O)crctab.obj:   crctab.c $(ZIP_H)
118
 
$(O)crc32.obj:    crc32.c $(ZIP_H)          # only used if NOASM
119
 
$(O)crypt.obj:    crypt.c $(ZIP_H) crypt.h ttyio.h
120
 
$(O)deflate.obj:  deflate.c $(ZIP_H)
121
 
$(O)fileio.obj:   fileio.c $(ZIP_H)
122
 
$(O)globals.obj:  globals.c $(ZIP_H)
123
 
$(O)trees.obj:    trees.c $(ZIP_H)
124
 
$(O)ttyio.obj:    ttyio.c $(ZIP_H) crypt.h ttyio.h
125
 
$(O)util.obj:     util.c $(ZIP_H)
126
 
$(O)zip.obj:      zip.c $(ZIP_H) crypt.h revision.h ttyio.h
127
 
$(O)zipfile.obj:  zipfile.c $(ZIP_H)
128
 
$(O)zipup.obj:    zipup.c $(ZIP_H) revision.h crypt.h win32\zipup.h
129
 
$(O)zipnote.obj:  zipnote.c $(ZIP_H) revision.h
130
 
$(O)zipcloak.obj: zipcloak.c $(ZIP_H) revision.h crypt.h ttyio.h
131
 
$(O)zipsplit.obj: zipsplit.c $(ZIP_H) revision.h
132
 
 
133
 
# Special case object files:
134
 
 
135
 
$(O)win32.obj:    win32\win32.c $(ZIP_H) win32\win32zip.h
136
 
        $(cc) $(cdebug) $(cflags) $(cvars) win32\win32.c -fo=$@
137
 
 
138
 
$(O)win32zip.obj: win32\win32zip.c $(ZIP_H) win32\win32zip.h win32\nt.h
139
 
        $(cc) $(cdebug) $(cflags) $(cvars) win32\win32zip.c -fo=$@
140
 
 
141
 
$(O)nt.obj:       win32\nt.c $(ZIP_H) win32\nt.h
142
 
        $(cc) $(cdebug) $(cflags) $(cvars) win32\nt.c -fo=$@
143
 
 
144
 
$(O)match32.obj:  win32\match32.asm
145
 
        $(asm) $(aflags) $(avars) win32\match32.asm -fo=$@
146
 
 
147
 
$(O)crc_i386.obj: win32\crc_i386.asm
148
 
        $(asm) $(aflags) $(avars) win32\crc_i386.asm -fo=$@
149
 
 
150
 
# Variant object files for ZipNote, ZipCloak, and ZipSplit:
151
 
 
152
 
$(O)zipfile_.obj: zipfile.c $(ZIP_H)
153
 
        $(cc) $(cdebug) $(cflags) $(cvars) -DUTIL zipfile.c -fo=$@
154
 
 
155
 
$(O)fileio_.obj:  fileio.c $(ZIP_H)
156
 
        $(cc) $(cdebug) $(cflags) $(cvars) -DUTIL fileio.c -fo=$@
157
 
 
158
 
$(O)util_.obj:    util.c $(ZIP_H)
159
 
        $(cc) $(cdebug) $(cflags) $(cvars) -DUTIL util.c -fo=$@
160
 
 
161
 
$(O)crypt_.obj:   crypt.c $(ZIP_H) crypt.h ttyio.h
162
 
        $(cc) $(cdebug) $(cflags) $(cvars) -DUTIL crypt.c -fo=$@
163
 
 
164
 
$(O)win32_.obj:   win32\win32.c $(ZIP_H) win32\win32zip.h
165
 
        $(cc) $(cdebug) $(cflags) $(cvars) -DUTIL win32\win32.c -fo=$@
166
 
 
167
 
# Unwanted file removal:
168
 
 
169
 
clean:     .SYMBOLIC
170
 
        del $(O)*.obj
171
 
 
172
 
cleaner:   clean  .SYMBOLIC
173
 
        del Zip.exe
174
 
        del ZipNote.exe
175
 
        del ZipCloak.exe
176
 
        del ZipSplit.exe