]> 4ch.mooo.com Git - 16.git/blob - makefile
refresh wwww
[16.git] / makefile
1 #
2 #       Higanbana Project makefile
3 #
4 #
5 # Possible optimizations for 8088 class processors
6 #
7 # -oa   Relax alias checking
8 # -ob   Try to generate straight line code
9 # -oe - expand user functions inline (-oe=20 is default, adds lots of code)
10 # -oh   Enable repeated optimizations
11 # -oi   generate certain lib funcs inline
12 # -oi+  Set max inline depth (C++ only, use -oi for C)
13 # -ok   Flowing of register save into function flow graph
14 # -ol   loop optimizations
15 # -ol+  loop optimizations plus unrolling
16 # -or   Reorder for pipelined (486+ procs); not sure if good to use
17 # -os   Favor space over time
18 # -ot   Favor time over space
19 # -ei   Allocate an "int" for all enum types
20 # -zp2  Allow compiler to add padding to structs
21 # -zpw  Use with above; make sure you are warning free!
22 # -0    8088/8086 class code generation
23 # -s    disable stack overflow checking
24
25 # -zk0u translate kanji to unicode... wwww
26 # -zk0  kanji support~
27 # -zkl          current codepage
28
29 # this enables debug output to the serial port.
30 # comment this out on game release.
31 # serial output goes to COM1 at 9600 baud 1 stop bit odd parity.
32 # serial output is plain text ASCII.
33 DEBUGSERIAL=1
34
35 #%.C
36 #192x144
37 #wwww will add these
38 !ifdef __LINUX__
39 REMOVECOMMAND=rm -f
40 COPYCOMMAND=cp -f
41 DIRSEP=/
42 OBJ=o
43 !else
44 REMOVECOMMAND=del
45 COPYCOMMAND=copy /y
46 DIRSEP=\
47 OBJ=obj
48 !endif
49
50 TARGET_OS = dos
51
52 #EXMMTESTDIR=16$(DIRSEP)exmmtest$(DIRSEP)
53 PDIR=..$(DIRSEP)
54 SRC=src$(DIRSEP)
55 DATADIR=data$(DIRSEP)
56 SPRI=$(DATADIR)$(DIRSEP)spri$(DIRSEP)
57 SRCLIB=$(SRC)lib$(DIRSEP)
58 JSMNLIB=$(SRCLIB)jsmn$(DIRSEP)
59 NYANLIB=$(SRCLIB)nyan$(DIRSEP)
60 #EXMMLIB=$(SRCLIB)exmm$(DIRSEP)
61 MODEXLIB=$(SRCLIB)modex16$(DIRSEP)
62 MODEXLIB_=$(SRCLIB)modex$(DIRSEP)
63 VGMSNDLIB=$(SRCLIB)vgmsnd$(DIRSEP)
64 DOSLIB=$(SRCLIB)doslib$(DIRSEP)
65 DOSLIBDIR=$(SRCLIB)doslib
66 WCPULIB=$(SRCLIB)wcpu$(DIRSEP)
67
68 #
69 # quiet flags
70 #
71 WLIBQ=-q
72 WCLQ=-zq $(WLIBQ)
73 UPXQ=-qqq
74
75 #
76 # compile flags
77 #
78 AFLAGS=-mh -0 -d1
79 SFLAGS=-sg -st -of+ -zu -zdf -zff -zgf -k32768#54096#60000
80 DFLAGS=-DTARGET_MSDOS=16 -DMSDOS=1 $(SFLAGS)
81 ZFLAGS=-zk0 -zc -zp8 -zm $(WCLQ)
82 LFLAG=-lr -l=dos -fd
83 CFLAGS=$(AFLAGS) $(IFLAGS) -wo -i$(DOSLIB) $(LFLAG)
84 OFLAGS=-obmilr -oe=24 -out -oh -ei -zp8 -fpi87  -onac -ol+ -ok####x
85 FLAGS=$(CFLAGS) $(OFLAGS) $(DFLAGS) $(ZFLAGS)
86
87 #
88 # objects
89 #
90 VGMSNDOBJ = vgmSnd.$(OBJ) 16_snd.$(OBJ)
91 DOSLIBOBJ = adlib.$(OBJ) 8254.$(OBJ) 8259.$(OBJ) dos.$(OBJ) cpu.$(OBJ)
92 16LIBOBJS = 16_in.$(OBJ) 16_mm.$(OBJ) wcpu.$(OBJ) 16_head.$(OBJ) 16_ca.$(OBJ) 16_dbg.$(OBJ) kitten.$(OBJ) 16_hc.$(OBJ) 16_timer.$(OBJ)
93
94 GFXLIBOBJS = modex16.$(OBJ) bitmap.$(OBJ) planar.$(OBJ) 16text.$(OBJ) bakapee.$(OBJ) scroll16.$(OBJ) 16render.$(OBJ) 16planar.$(OBJ) $(DOSLIBLIBS)
95
96 DOSLIBLIBS=$(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)cpu$(DIRSEP)dos86h$(DIRSEP)cpu.lib $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)dos$(DIRSEP)dos86h$(DIRSEP)dos.lib $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga$(DIRSEP)dos86h$(DIRSEP)vga.lib
97
98 !ifeq DEBUGSERIAL 1
99 FLAGS += -DDEBUGSERIAL
100 DOSLIBOBJ += 8250.$(OBJ)
101 DOSLIBLIBS += $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)8250$(DIRSEP)dos86h$(DIRSEP)8250.lib
102 !endif
103
104 TESTEXEC = test.exe test0.exe pcxtest.exe pcxtest2.exe test2.exe palettec.exe maptest.exe fmemtest.exe fonttest.exe fontgfx.exe scroll.exe vgmtest.exe inputest.exe palettel.exe planrpcx.exe exmmtest.exe
105
106 EXEC = 16.exe bakapi.exe tesuto.exe 0.exe $(TESTEXEC)
107
108 all: $(EXEC) joytest.exe
109 #16.lib => $(16LIBOBJS) bug....
110 16LIB=$(16LIBOBJS)
111 !ifeq DEBUGSERIAL 1
112 16LIB += $(DOSLIBLIBS)
113 !endif
114 #
115 #game and bakapi executables
116 #
117 16.exe: 16.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib
118         wcl $(FLAGS) $(16FLAGS) 16.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib -fm=16.mah
119
120 bakapi.exe: bakapi.$(OBJ) gfx.lib $(DOSLIBLIBS)
121         wcl $(FLAGS) $(BAKAPIFLAGS) bakapi.$(OBJ) gfx.lib $(DOSLIBLIBS) -fm=bakapi.mah
122 #modex.lib
123 #
124 #Test Executables!
125 #
126 scroll.exe: scroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib
127         wcl $(FLAGS) scroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib -fm=scroll.mah
128 scroll.$(OBJ): $(SRC)scroll.c
129         wcl $(FLAGS) -c $(SRC)scroll.c
130
131
132 # NOTE: dos86h = 16-bit huge memory model. memory model must match!
133 tesuto.exe: tesuto.$(OBJ) $(DOSLIBLIBS) 16_head.$(OBJ) gfx.lib
134 #       %write tmp.cmd option quiet option max=tesuto.mah $(DOSLIB_LDFLAGS_DOS16H) file tesuto.obj name tesuto.exe
135 #       %write tmp.cmd library $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)cpu$(DIRSEP)dos86h$(DIRSEP)cpu.lib
136 #       %write tmp.cmd library $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)dos$(DIRSEP)dos86h$(DIRSEP)dos.lib
137 #       @wlink @tmp.cmd
138         wcl $(FLAGS) $(WCLQ) tesuto.$(OBJ) $(DOSLIBLIBS) 16_head.$(OBJ) gfx.lib
139 tesuto.$(OBJ): $(SRC)tesuto.c
140         wcl $(FLAGS) $(WCLQ) -c $(SRC)tesuto.c
141
142 0.exe: 0.$(OBJ) $(DOSLIBLIBS) 16_head.$(OBJ) gfx.lib
143         wcl $(FLAGS) $(WCLQ) 0.$(OBJ) $(DOSLIBLIBS) 16_head.$(OBJ) gfx.lib
144 0.$(OBJ): $(SRC)0.c
145         wcl $(FLAGS) $(WCLQ) -c $(SRC)0.c
146
147 test.exe: test.$(OBJ) gfx.lib 16_in.$(OBJ) 16_head.$(OBJ) $(DOSLIBLIBS) $(16LIB)
148         wcl $(FLAGS) test.$(OBJ) gfx.lib 16_in.$(OBJ) 16_head.$(OBJ) $(DOSLIBLIBS) $(16LIB) -fm=test.mah
149
150 test2.exe: test2.$(OBJ) $(DOSLIBLIBS) gfx.lib
151         wcl $(FLAGS) test2.$(OBJ) $(DOSLIBLIBS) gfx.lib -fm=test2.mah
152
153 test0.exe: test0.$(OBJ)
154         wcl $(FLAGS) test0.$(OBJ) -fm=test0.mah
155
156 fonttest.exe: fonttest.$(OBJ) $(16LIB) gfx.lib
157         wcl $(FLAGS) fonttest.$(OBJ) $(16LIB) gfx.lib -fm=fonttest.mah
158
159 #fonttes0.exe: fonttes0.$(OBJ) $(16LIB)
160 #       wcl $(FLAGS) fonttes0.$(OBJ) $(16LIB)
161
162 fontgfx.exe: fontgfx.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS)
163         wcl $(FLAGS) fontgfx.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS) -fm=fontgfx.mah
164
165 inputest.exe: inputest.$(OBJ) $(16LIB)
166         wcl $(FLAGS) inputest.$(OBJ) $(16LIB) -fm=inputest.mah
167
168 #sountest.exe: sountest.$(OBJ) $(16LIB)
169 #       wcl $(FLAGS) sountest.$(OBJ) $(16LIB)
170
171 pcxtest.exe: pcxtest.$(OBJ) gfx.lib
172         wcl $(FLAGS) pcxtest.$(OBJ) gfx.lib -fm=pcxtest.mah
173
174 palettec.exe: palettec.$(OBJ) gfx.lib #$(16LIB)
175         wcl $(FLAGS) palettec.$(OBJ) gfx.lib -fm=palettec.mah #$(16LIB)
176
177 palettel.exe: palettel.$(OBJ) gfx.lib #$(16LIB)
178         wcl $(FLAGS) palettel.$(OBJ) gfx.lib -fm=palettel.mah #$(16LIB)
179
180 pcxtest2.exe: pcxtest2.$(OBJ) gfx.lib
181         wcl $(FLAGS) pcxtest2.$(OBJ) gfx.lib -fm=pcxtest2.mah
182
183 planrpcx.exe: planrpcx.$(OBJ) gfx.lib
184         wcl $(FLAGS) planrpcx.$(OBJ) gfx.lib -fm=planrpcx.mah
185
186 maptest.exe: maptest.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib
187         wcl $(FLAGS) maptest.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib -fm=maptest.mah
188
189 fmemtest.exe: fmemtest.$(OBJ) $(16LIB)
190         wcl $(FLAGS) fmemtest.$(OBJ) $(16LIB) -fm=fmemtest.mah
191
192 exmmtest.exe: exmmtest.$(OBJ) 16_in.$(OBJ) 16_mm.$(OBJ) wcpu.$(OBJ) 16_head.$(OBJ) 16_ca.$(OBJ) 16_hc.$(OBJ) kitten.$(OBJ)
193         wcl $(FLAGS) exmmtest.$(OBJ) -fm=exmmtest.mah $(16LIB)
194 ####0000        ./wlink32 @__wcl__.lnk
195
196 vgmtest.exe: vgmtest.$(OBJ) vgmsnd.lib $(16LIB)
197         wcl $(FLAGS) vgmtest.$(OBJ) vgmsnd.lib -fm=vgmtest.mah $(16LIB)
198         #====wcl -mc vgmtest.$(OBJ) $(VGMSNDOBJ) -fm=vgmtest.mah
199
200
201 #
202 #executable's objects
203 #
204 16.$(OBJ): $(SRC)16.h $(SRC)16.c
205         wcl $(FLAGS) -c $(SRC)16.c
206
207 bakapi.$(OBJ): $(SRC)bakapi.h $(SRC)bakapi.c
208         wcl $(FLAGS) -c $(SRC)bakapi.c
209
210 test.$(OBJ): $(SRC)test.c $(SRCLIB)modex16.h
211         wcl $(FLAGS) -c $(SRC)test.c
212
213 test2.$(OBJ): $(SRC)test2.c $(SRCLIB)modex16.h
214         wcl $(FLAGS) -c $(SRC)test2.c
215
216 test0.$(OBJ): $(SRC)test0.c
217         wcl $(FLAGS) -c $(SRC)test0.c
218
219 pcxtest.$(OBJ): $(SRC)pcxtest.c $(SRCLIB)modex16.h
220         wcl $(FLAGS) -c $(SRC)pcxtest.c
221
222 planrpcx.$(OBJ): $(SRC)planrpcx.c $(SRCLIB)modex16.h
223         wcl $(FLAGS) -c $(SRC)planrpcx.c
224
225 pcxtest2.$(OBJ): $(SRC)pcxtest2.c $(SRCLIB)modex16.h
226         wcl $(FLAGS) -c $(SRC)pcxtest2.c
227
228 palettec.$(OBJ): $(SRC)palettec.c
229         wcl $(FLAGS) -c $(SRC)palettec.c
230
231 palettel.$(OBJ): $(SRC)palettel.c
232         wcl $(FLAGS) -c $(SRC)palettel.c
233
234 maptest.$(OBJ): $(SRC)maptest.c $(SRCLIB)modex16.h
235         wcl $(FLAGS) -c $(SRC)maptest.c
236
237 #maptest0.$(OBJ): $(SRC)maptest0.c# $(SRCLIB)modex16.h
238 #       wcl $(FLAGS) $(MFLAGS) -c $(SRC)maptest0.c
239
240 #emmtest.$(OBJ): $(SRC)emmtest.c
241 #       wcl $(FLAGS) $(MFLAGS) -c $(SRC)emmtest.c
242
243 #emsdump.$(OBJ): $(SRC)emsdump.c
244 #       wcl $(FLAGS) $(MFLAGS) -c $(SRC)emsdump.c
245
246 fmemtest.$(OBJ): $(SRC)fmemtest.c
247         wcl $(FLAGS) -c $(SRC)fmemtest.c
248
249 fonttest.$(OBJ): $(SRC)fonttest.c
250         wcl $(FLAGS) -c $(SRC)fonttest.c
251
252 #fonttes0.$(OBJ): $(SRC)fonttes0.c
253 #       wcl $(FLAGS) -c $(SRC)fonttes0.c
254
255 fontgfx.$(OBJ): $(SRC)fontgfx.c
256         wcl $(FLAGS) -c $(SRC)fontgfx.c
257
258 inputest.$(OBJ): $(SRC)inputest.c
259         wcl $(FLAGS) -c $(SRC)inputest.c
260
261 #sountest.$(OBJ): $(SRC)sountest.c
262 #       wcl $(FLAGS) -c $(SRC)sountest.c
263
264 #miditest.$(OBJ): $(SRC)miditest.c
265 #       wcl $(FLAGS) -c $(SRC)miditest.c
266
267 #testemm.$(OBJ): $(SRC)testemm.c
268 #       wcl $(FLAGS) -c $(SRC)testemm.c
269
270 #testemm0.$(OBJ): $(SRC)testemm0.c
271 #       wcl $(FLAGS) -c $(SRC)testemm0.c
272
273 tsthimem.$(OBJ): $(SRC)tsthimem.c
274         wcl $(FLAGS) -c $(SRC)tsthimem.c
275
276 exmmtest.$(OBJ): $(SRC)exmmtest.c
277         wcl $(FLAGS) -c $(SRC)exmmtest.c 16_in.$(OBJ) 16_mm.$(OBJ) wcpu.$(OBJ) 16_head.$(OBJ) 16_ca.$(OBJ) 16_hc.$(OBJ) kitten.$(OBJ)
278
279 vgmtest.$(OBJ): $(SRC)vgmtest.c
280         wcl $(FLAGS) -c $(SRC)vgmtest.c
281         #====wcl -mc -c $(SRC)vgmtest.c
282
283 #
284 #non executable objects libraries
285 #
286 16.lib: $(16LIBOBJS)# doslib.lib vgmsnd.lib
287         wlib -b $(WLIBQ) 16.lib $(16LIBOBJS)# doslib.lib vgmsnd.lib
288
289 gfx.lib: $(GFXLIBOBJS) 16_in.$(OBJ) 16_head.$(OBJ)
290         wlib -b $(WLIBQ) gfx.lib $(GFXLIBOBJS) 16_in.$(OBJ) 16_head.$(OBJ)
291
292 vgmsnd.lib: $(VGMSNDOBJ)
293         wlib -b $(WLIBQ) vgmsnd.lib $(VGMSNDOBJ)
294
295 # extdep:
296 # !include $(DOSLIBDIR)$(DIRSEP)extdep.mak
297
298 # library deps 16-bit huge
299 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)cpu$(DIRSEP)dos86h$(DIRSEP)cpu.lib:
300         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)cpu && .$(DIRSEP)make.sh
301 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)dos$(DIRSEP)dos86h$(DIRSEP)dos.lib:
302         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)dos && .$(DIRSEP)make.sh
303 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga$(DIRSEP)dos86h$(DIRSEP)vgatty.lib:
304         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga && .$(DIRSEP)make.sh
305 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga$(DIRSEP)dos86h$(DIRSEP)vga.lib:
306         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga && .$(DIRSEP)make.sh
307 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)8250$(DIRSEP)dos86h$(DIRSEP)8250.lib:
308         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)8250 && .$(DIRSEP)make.sh
309
310 joytest.exe:
311         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)joystick && .$(DIRSEP)make.sh && $(COPYCOMMAND) dos86h$(DIRSEP)test.exe $(PDIR)$(PDIR)$(PDIR)$(PDIR)$(PDIR)joytest.exe
312 #$(DOSLIBLIBS): .symbolic
313 #       @cd $(DOSLIB)
314 #       @.$(DIRSEP)buildall.sh
315 #       @cd $(PDIR)$(PDIR)$(PDIR)
316
317 modex16.$(OBJ): $(SRCLIB)modex16.h $(SRCLIB)modex16.c
318         wcl $(FLAGS) -c $(SRCLIB)modex16.c
319
320 bakapee.$(OBJ): $(SRCLIB)bakapee.h $(SRCLIB)bakapee.c
321         wcl $(FLAGS) -c $(SRCLIB)bakapee.c
322
323 16render.$(OBJ): $(MODEXLIB)16render.h $(MODEXLIB)16render.c
324         wcl $(FLAGS) -c $(MODEXLIB)16render.c
325
326 16planar.$(OBJ): $(MODEXLIB)16planar.h $(MODEXLIB)16planar.c
327         wcl $(FLAGS) -c $(MODEXLIB)16planar.c
328
329 bitmap.$(OBJ): $(SRCLIB)bitmap.h $(SRCLIB)bitmap.c
330         wcl $(FLAGS) -c $(SRCLIB)bitmap.c
331
332 planar.$(OBJ): $(SRCLIB)planar.h $(SRCLIB)planar.c
333         wcl $(FLAGS) -c $(SRCLIB)planar.c
334
335 scroll16.$(OBJ): $(SRCLIB)scroll16.h $(SRCLIB)scroll16.c
336         wcl $(FLAGS) -c $(SRCLIB)scroll16.c
337
338 wcpu.$(OBJ): $(WCPULIB)wcpu.h $(WCPULIB)wcpu.c
339         wcl $(FLAGS) -c $(WCPULIB)wcpu.c
340
341 16text.$(OBJ): $(SRCLIB)16text.c
342         wcl $(FLAGS) -c $(SRCLIB)16text.c
343
344 mapread.$(OBJ): $(SRCLIB)mapread.h $(SRCLIB)mapread.c
345         wcl $(FLAGS) -c $(SRCLIB)mapread.c
346
347 16_timer.$(OBJ): $(SRCLIB)16_timer.h $(SRCLIB)16_timer.c
348         wcl $(FLAGS) -c $(SRCLIB)16_timer.c
349
350 16_in.$(OBJ): $(SRCLIB)16_in.h $(SRCLIB)16_in.c
351         wcl $(FLAGS) -c $(SRCLIB)16_in.c
352
353 16_mm.$(OBJ): $(SRCLIB)16_mm.h $(SRCLIB)16_mm.c
354         wcl $(FLAGS) -c $(SRCLIB)16_mm.c
355
356 16_ca.$(OBJ): $(SRCLIB)16_ca.h $(SRCLIB)16_ca.c
357         wcl $(FLAGS) -c $(SRCLIB)16_ca.c
358
359 16_dbg.$(OBJ): $(SRCLIB)16_dbg.h $(SRCLIB)16_dbg.c
360         wcl $(FLAGS) -c $(SRCLIB)16_dbg.c
361
362 midi.$(OBJ): $(SRCLIB)midi.h $(SRCLIB)midi.c
363         wcl $(FLAGS) -c $(SRCLIB)midi.c
364
365 16_head.$(OBJ): $(SRCLIB)16_head.h $(SRCLIB)16_head.c
366         wcl $(FLAGS) -c $(SRCLIB)16_head.c
367
368 16_hc.$(OBJ): $(SRCLIB)16_hc.h $(SRCLIB)16_hc.c
369         wcl $(FLAGS) -c $(SRCLIB)16_hc.c
370
371 16_snd.$(OBJ): $(SRCLIB)16_snd.h $(SRCLIB)16_snd.c
372         wcl $(FLAGS) -c $(SRCLIB)16_snd.c
373         #====wcl -mc -c $(SRCLIB)16_snd.c
374
375 jsmn.$(OBJ): $(JSMNLIB)jsmn.h $(JSMNLIB)jsmn.c
376         wcl $(FLAGS) -c $(JSMNLIB)jsmn.c
377
378 kitten.$(OBJ): $(NYANLIB)kitten.h $(NYANLIB)kitten.c
379         wcl $(FLAGS) -c $(NYANLIB)kitten.c
380
381 vgmSnd.$(OBJ): $(VGMSNDLIB)vgmSnd.h $(VGMSNDLIB)vgmSnd.c
382         wcl $(FLAGS) -c $(VGMSNDLIB)vgmSnd.c
383         #====wcl -c -mc $(VGMSNDLIB)vgmSnd.c
384
385 #memory.$(OBJ): $(EXMMLIB)memory.h $(EXMMLIB)memory.c
386 #       wcl $(FLAGS) $(MFLAGS) -c $(EXMMLIB)memory.c
387
388 c_utils.$(OBJ): $(MODEXLIB_)c_utils.asm
389         wcl -c $(AFLAGS) $(MODEXLIB_)c_utils.asm
390 modex.$(OBJ): $(MODEXLIB_)modex.asm
391         wcl -c $(AFLAGS) $(MODEXLIB_)modex.asm
392
393 #
394 #other~
395 #
396 clean: .symbolic
397         @$(REMOVECOMMAND) $(EXEC)
398         @$(REMOVECOMMAND) /var/www/$(EXEC)*
399         @$(REMOVECOMMAND) *.$(OBJ)
400         @$(REMOVECOMMAND) 16.lib
401         @$(REMOVECOMMAND) gfx.lib
402         @$(REMOVECOMMAND) vgmsnd.lib
403         @wlib -n $(WLIBQ) 16.lib
404         @wlib -n $(WLIBQ) gfx.lib
405         @wlib -n $(WLIBQ) vgmsnd.lib
406         @$(REMOVECOMMAND) *.16
407         @$(REMOVECOMMAND) *.16W
408         @$(REMOVECOMMAND) *.16B
409         @$(REMOVECOMMAND) *.OBJ
410         @$(REMOVECOMMAND) *.o
411         @$(REMOVECOMMAND) *.BCO
412         @$(REMOVECOMMAND) makefi~1
413         @$(REMOVECOMMAND) makefile~
414         @$(REMOVECOMMAND) __wcl__.LNK
415 #       @$(REMOVECOMMAND) *.smp
416         @$(REMOVECOMMAND) *.SMP
417         @$(REMOVECOMMAND) *.hed
418         @$(REMOVECOMMAND) *.MAH
419         @$(REMOVECOMMAND) *.mah
420         @$(REMOVECOMMAND) *.err
421         #@cd $(DOSLIB)
422         #@./buildall.sh clean
423         #@cd $(PDIR)$(PDIR)$(PDIR)
424 #       @$(COPYCOMMAND) $(SRC)exmmtest.c $(EXMMTESTDIR)$(SRC)
425 #       @$(COPYCOMMAND) $(SRCLIB)16_mm.* $(EXMMTESTDIR)$(SRCLIB)
426 #       @$(COPYCOMMAND) $(SRCLIB)16_head.* $(EXMMTESTDIR)$(SRCLIB)
427 #       @$(COPYCOMMAND) $(SRCLIB)16_ca.* $(EXMMTESTDIR)$(SRCLIB)
428 #       @$(COPYCOMMAND) $(SRCLIB)16_hc.* $(EXMMTESTDIR)$(SRCLIB)
429 #       @$(COPYCOMMAND) $(SRCLIB)types.h $(EXMMTESTDIR)$(SRCLIB)
430 #       @$(COPYCOMMAND) $(NYANLIB)* $(EXMMTESTDIR)$(NYANLIB)
431 #       @echo $(watcom)
432 #       @echo $(INCLUDE)
433
434 backupconfig: .symbolic
435         @$(COPYCOMMAND) .git$(DIRSEP)config git_con.fig
436         @$(COPYCOMMAND) .gitmodules git_modu.les
437         @$(COPYCOMMAND) .gitignore git_igno.re
438
439 comp: .symbolic
440         @upx -9 $(EXEC)
441
442 comq: .symbolic
443         @upx -9 $(UPXQ) $(EXEC)
444
445 www: .symbolic
446         @ssh -p 26 sparky4@4ch.mooo.com 'rm -f /var/www/16/*exe.zip*'
447         @rm -f /var/www/*.exe.zip*
448         #@cp ./$(EXEC) $(DIRSEP)var$(DIRSEP)www$(DIRSEP)
449         @./src/util/z.sh $(EXEC) $(EXEC)
450         @scp -r -P 26 *.exe 4ch.mooo.com:/var/www/16/
451         @scp -r -P 26 /var/www/*.exe.zip.* 4ch.mooo.com:/var/www/16/
452
453 getwww: .symbolic
454         @x4get.bat $(EXEC)
455
456 ##
457 ##      External library management~ ^^
458 ##
459 #git submodule add <repo>
460 mkdl: .symbolic
461         @cd $(DOSLIB)
462         @./buildall.sh
463         @cd $(PDIR)$(PDIR)$(PDIR)
464
465 uplibs: .symbolic
466         @cd $(JSMNLIB)
467         @git pull
468         @cd $(PDIR)$(PDIR)$(PDIR)
469         @cd $(DOSLIB)
470         @git pull
471         @cd $(PDIR)$(PDIR)$(PDIR)
472
473 reinitlibs: .symbolic
474         @rm -rf $(SRCLIB)doslib
475         @rm -rf $(SRCLIB)jsmn
476         @rm -rf 16/CatacombApocalypse
477         @rm -rf 16/wolf3d
478         @rm -rf 16/keen
479         @wmake -h initlibs
480
481 initlibs: .symbolic
482         @cp git_con.fig .git/config
483         @cp git_modu.les .gitmodules
484         @cp git_igno.re .gitignore
485         @cd $(SRCLIB)
486         @git clone https://github.com/joncampbell123/doslib.git
487         @git clone https://github.com/zserge/jsmn.git
488         @cd $(PDIR)$(PDIR)
489         @cd 16
490         @git clone https://github.com/FlatRockSoft/CatacombApocalypse.git
491         @git clone https://github.com/id-Software/wolf3d.git
492         @git clone https://github.com/keendreams/keen.git
493         @cd $(PDIR)
494
495 ##
496 ##      experimental libs
497 ##
498 xlib: .symbolic
499         @cd 16$(DIRSEP)xlib
500         @wmake -h clean
501         @wmake -h all
502         @cd $(PDIR)$(PDIR)
503
504 mx: .symbolic
505         @cd 16$(DIRSEP)xw
506 #       @wmake clean
507         @wmake -h all
508         @cd $(PDIR)$(PDIR)
509
510 mx_: .symbolic
511         @cd 16$(DIRSEP)xw_
512         @wmake -h -f makefile all
513         @cd $(PDIR)$(PDIR)
514
515 vrs: .symbolic
516         @cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga
517         #@make clean
518         @make all
519         @mv pcx2vrl ../../../../../
520         @mv pcxsscut ../../../../../
521         @mv vrl2vrs ../../../../../
522         @mv vrsdump ../../../../../
523         @cd ../../../../../