]> 4ch.mooo.com Git - 16.git/blob - makefile
what?! OMG!
[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 #192x144
36 #wwww will add these
37 !ifdef __LINUX__
38 #!ifdef UNIX
39 to_os_path=\=/
40 REMOVECOMMAND=rm -f
41 COPYCOMMAND=cp -f
42 DIRSEP=/
43 OBJ=obj
44 DUMP=cat
45 !else           #DOS ^^
46 to_os_path=/=\
47 REMOVECOMMAND=*del
48 COPYCOMMAND=*copy /y
49 DIRSEP=\
50 OBJ=obj
51 DUMP=*type
52 !endif
53
54 TARGET_OS = dos
55 DOS=1
56
57 #EXMMTESTDIR=16$(DIRSEP)exmmtest$(DIRSEP)
58 PDIR=..$(DIRSEP)
59 SRC=src$(DIRSEP)
60 DATADIR=data$(DIRSEP)
61 SPRI=$(DATADIR)$(DIRSEP)spri$(DIRSEP)
62 SRCLIB=$(SRC)lib$(DIRSEP)
63 JSMNLIB=$(SRCLIB)jsmn$(DIRSEP)
64 NYANLIB=$(SRCLIB)nyan$(DIRSEP)
65 #EXMMLIB=$(SRCLIB)exmm$(DIRSEP)
66 MODEXLIB=$(SRCLIB)modex16$(DIRSEP)
67 MODEXLIB_=$(SRCLIB)modex$(DIRSEP)
68 VGMSNDLIB=$(SRCLIB)vgmsnd$(DIRSEP)
69 DOSLIB=$(SRCLIB)doslib$(DIRSEP)
70 DOSLIBDIR=$(SRCLIB)doslib
71 WCPULIB=$(SRCLIB)wcpu$(DIRSEP)
72
73 #
74 # quiet flags
75 #
76 WLIBQ=-q
77 WCLQ=-zq $(WLIBQ)
78 UPXQ=-qqq
79
80 #
81 # compile flags
82 #
83 AFLAGS=-mh -0 -d1
84 SFLAGS=-sg -st -of+ -zu -zdf -zff -zgf -k32768#54096#60000
85 DFLAGS=-bt=dos -DTARGET_MSDOS=16 -DMSDOS=1 $(SFLAGS)
86 ZFLAGS=-zk0 -zc -zp8 -zm $(WCLQ)
87 LFLAGS=-lr -l=dos
88 CFLAGS=$(AFLAGS) $(IFLAGS) -wo -i$(DOSLIB) $(LFLAGS) -fo=.$(OBJ)
89 OFLAGS=-obmilr -oe=24 -out -oh -ei -zp8 -fpi87  -onac -ol+ -ok##x
90 FLAGS=$(CFLAGS) $(OFLAGS) $(DFLAGS) $(ZFLAGS)
91
92 #
93 # objects
94 #
95 VGMSNDOBJ = vgmSnd.$(OBJ) 16_snd.$(OBJ)
96 DOSLIBOBJ = adlib.$(OBJ) 8254.$(OBJ) 8259.$(OBJ) dos.$(OBJ) cpu.$(OBJ)
97 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)
98 GFXLIBOBJS = modex16.$(OBJ) bitmap.$(OBJ) 16text.$(OBJ) bakapee.$(OBJ) scroll16.$(OBJ) 16render.$(OBJ) $(DOSLIBLIBS) 16_vrs.$(OBJ) 16_sprit.$(OBJ)
99 #planar.$(OBJ) 16planar.$(OBJ)
100 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
101
102 !ifeq DEBUGSERIAL 1
103 FLAGS += -DDEBUGSERIAL
104 DOSLIBOBJ += 8250.$(OBJ)
105 DOSLIBLIBS += $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)8250$(DIRSEP)dos86h$(DIRSEP)8250.lib
106 !endif
107
108 TESTEXEC = test.exe test0.exe pcxtest.exe pcxtest2.exe palettec.exe maptest.exe fmemtest.exe fonttest.exe fontgfx.exe scroll.exe vgmtest.exe inputest.exe palettel.exe exmmtest.exe vrstest.exe
109 ##planrpcx.exe test2.exe
110 EXEC = 16.exe bakapi.exe tesuto.exe 0.exe $(TESTEXEC)
111
112 all: $(EXEC) joytest.exe
113 #16.lib => $(16LIBOBJS) bug....
114 16LIB=$(16LIBOBJS)
115 #16LIB=16.lib
116
117 !ifeq DEBUGSERIAL 1
118 16LIBOBJS += $(DOSLIBLIBS)
119 !endif
120
121 #
122 #game and bakapi executables
123 #
124 16.exe: 16.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib
125         *wcl $(FLAGS) $(16FLAGS) 16.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib -fm=16.mah
126
127 bakapi.exe: bakapi.$(OBJ) gfx.lib $(DOSLIBLIBS)
128         *wcl $(FLAGS) $(BAKAPIFLAGS) bakapi.$(OBJ) gfx.lib $(DOSLIBLIBS) -fm=bakapi.mah
129
130 #
131 #Test Executables!
132 #
133 scroll.exe: scroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib
134         *wcl $(FLAGS) scroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib -fm=scroll.mah
135 scroll.$(OBJ): $(SRC)scroll.c
136         *wcl $(FLAGS) -c $(SRC)scroll.c
137
138 tesuto.exe: tesuto.$(OBJ) $(DOSLIBLIBS) 16_head.$(OBJ) gfx.lib
139         *wcl $(FLAGS) $(WCLQ) tesuto.$(OBJ) $(DOSLIBLIBS) 16_head.$(OBJ) gfx.lib
140 tesuto.$(OBJ): $(SRC)tesuto.c
141         *wcl $(FLAGS) $(WCLQ) -c $(SRC)tesuto.c
142
143 0.exe: 0.$(OBJ) $(DOSLIBLIBS) gfx.lib $(16LIB)
144         *wcl $(FLAGS) $(WCLQ) 0.$(OBJ) $(DOSLIBLIBS) gfx.lib $(16LIB)
145 0.$(OBJ): $(SRC)0.c
146         *wcl $(FLAGS) $(WCLQ) -c $(SRC)0.c
147
148 test.exe: test.$(OBJ) gfx.lib $(DOSLIBLIBS) $(16LIB)
149         *wcl $(FLAGS) test.$(OBJ) gfx.lib $(DOSLIBLIBS) $(16LIB) -fm=test.mah
150
151 #test2.exe: test2.$(OBJ) $(DOSLIBLIBS) gfx.lib
152 #       *wcl $(FLAGS) test2.$(OBJ) $(DOSLIBLIBS) gfx.lib -fm=test2.mah
153
154 test0.exe: test0.$(OBJ)
155         *wcl $(FLAGS) test0.$(OBJ) -fm=test0.mah
156
157 fonttest.exe: fonttest.$(OBJ) $(16LIB) gfx.lib
158         *wcl $(FLAGS) fonttest.$(OBJ) $(16LIB) gfx.lib -fm=fonttest.mah
159
160 #fonttes0.exe: fonttes0.$(OBJ) $(16LIB)
161 #       *wcl $(FLAGS) fonttes0.$(OBJ) $(16LIB)
162
163 fontgfx.exe: fontgfx.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS)
164         *wcl $(FLAGS) fontgfx.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS) -fm=fontgfx.mah
165
166 inputest.exe: inputest.$(OBJ) $(16LIB)
167         *wcl $(FLAGS) inputest.$(OBJ) $(16LIB) -fm=inputest.mah
168
169 #sountest.exe: sountest.$(OBJ) $(16LIB)
170 #       *wcl $(FLAGS) sountest.$(OBJ) $(16LIB)
171
172 pcxtest.exe: pcxtest.$(OBJ) gfx.lib
173         *wcl $(FLAGS) pcxtest.$(OBJ) gfx.lib -fm=pcxtest.mah
174
175 vrstest.exe: vrstest.$(OBJ) gfx.lib $(16LIB)
176         *wcl $(FLAGS) vrstest.$(OBJ) gfx.lib $(16LIB) -fm=vrstest.mah
177
178 palettec.exe: palettec.$(OBJ) gfx.lib #$(16LIB)
179         *wcl $(FLAGS) palettec.$(OBJ) gfx.lib -fm=palettec.mah #$(16LIB)
180
181 palettel.exe: palettel.$(OBJ) gfx.lib #$(16LIB)
182         *wcl $(FLAGS) palettel.$(OBJ) gfx.lib -fm=palettel.mah #$(16LIB)
183
184 pcxtest2.exe: pcxtest2.$(OBJ) gfx.lib
185         *wcl $(FLAGS) pcxtest2.$(OBJ) gfx.lib -fm=pcxtest2.mah
186
187 ##planrpcx.exe: planrpcx.$(OBJ) gfx.lib
188 ##      *wcl $(FLAGS) planrpcx.$(OBJ) gfx.lib -fm=planrpcx.mah
189
190 maptest.exe: maptest.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib
191         *wcl $(FLAGS) maptest.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib -fm=maptest.mah
192
193 fmemtest.exe: fmemtest.$(OBJ) $(16LIB)
194         *wcl $(FLAGS) fmemtest.$(OBJ) $(16LIB) -fm=fmemtest.mah
195
196 exmmtest.exe: exmmtest.$(OBJ) 16_in.$(OBJ) 16_mm.$(OBJ) wcpu.$(OBJ) 16_head.$(OBJ) 16_ca.$(OBJ) 16_hc.$(OBJ) kitten.$(OBJ)
197         *wcl $(FLAGS) exmmtest.$(OBJ) -fm=exmmtest.mah $(16LIB)
198
199 vgmtest.exe: vgmtest.$(OBJ) vgmsnd.lib $(16LIB)
200         *wcl $(FLAGS) vgmtest.$(OBJ) vgmsnd.lib -fm=vgmtest.mah $(16LIB)
201
202
203 #
204 #executable's objects
205 #
206 {$(SRC)}.C.$(OBJ):
207         *wcl $(FLAGS) -c $[@
208
209 16.$(OBJ): $(SRC)16.h $(SRC)16.c
210 ####    *wcl $(FLAGS) -c $(SRC)16.c
211
212 bakapi.$(OBJ): $(SRC)bakapi.h $(SRC)bakapi.c
213 ####    *wcl $(FLAGS) -c $(SRC)bakapi.c
214
215 test.$(OBJ): $(SRC)test.c $(SRCLIB)modex16.h
216 ####    *wcl $(FLAGS) -c $(SRC)test.c
217
218 #test2.$(OBJ): $(SRC)test2.c $(SRCLIB)modex16.h
219 #####   *wcl $(FLAGS) -c $(SRC)test2.c
220
221 test0.$(OBJ): $(SRC)test0.c
222 ####    *wcl $(FLAGS) -c $(SRC)test0.c
223
224 pcxtest.$(OBJ): $(SRC)pcxtest.c $(SRCLIB)modex16.h
225 ####    *wcl $(FLAGS) -c $(SRC)pcxtest.c
226
227 vrstest.$(OBJ): $(SRC)vrstest.c $(SRCLIB)modex16.h
228 ####    *wcl $(FLAGS) -c $(SRC)vrstest.c
229
230 ##planrpcx.$(OBJ): $(SRC)planrpcx.c $(SRCLIB)modex16.h
231 ######  *wcl $(FLAGS) -c $(SRC)planrpcx.c
232
233 pcxtest2.$(OBJ): $(SRC)pcxtest2.c $(SRCLIB)modex16.h
234 ####    *wcl $(FLAGS) -c $(SRC)pcxtest2.c
235
236 palettec.$(OBJ): $(SRC)palettec.c
237 ####    *wcl $(FLAGS) -c $(SRC)palettec.c
238
239 palettel.$(OBJ): $(SRC)palettel.c
240 ####    *wcl $(FLAGS) -c $(SRC)palettel.c
241
242 maptest.$(OBJ): $(SRC)maptest.c $(SRCLIB)modex16.h
243 ####    *wcl $(FLAGS) -c $(SRC)maptest.c
244
245 #emmtest.$(OBJ): $(SRC)emmtest.c
246 #####   *wcl $(FLAGS) $(MFLAGS) -c $(SRC)emmtest.c
247
248 #emsdump.$(OBJ): $(SRC)emsdump.c
249 #####   *wcl $(FLAGS) $(MFLAGS) -c $(SRC)emsdump.c
250
251 fmemtest.$(OBJ): $(SRC)fmemtest.c
252 ####    *wcl $(FLAGS) -c $(SRC)fmemtest.c
253
254 fonttest.$(OBJ): $(SRC)fonttest.c
255 ####    *wcl $(FLAGS) -c $(SRC)fonttest.c
256
257 #fonttes0.$(OBJ): $(SRC)fonttes0.c
258 #####   *wcl $(FLAGS) -c $(SRC)fonttes0.c
259
260 fontgfx.$(OBJ): $(SRC)fontgfx.c
261 ####    *wcl $(FLAGS) -c $(SRC)fontgfx.c
262
263 inputest.$(OBJ): $(SRC)inputest.c
264 ####    *wcl $(FLAGS) -c $(SRC)inputest.c
265
266 #sountest.$(OBJ): $(SRC)sountest.c
267 #       *wcl $(FLAGS) -c $(SRC)sountest.c
268
269 #miditest.$(OBJ): $(SRC)miditest.c
270 #       *wcl $(FLAGS) -c $(SRC)miditest.c
271
272 #testemm.$(OBJ): $(SRC)testemm.c
273 #       *wcl $(FLAGS) -c $(SRC)testemm.c
274
275 #testemm0.$(OBJ): $(SRC)testemm0.c
276 #       *wcl $(FLAGS) -c $(SRC)testemm0.c
277
278 tsthimem.$(OBJ): $(SRC)tsthimem.c
279 ####    *wcl $(FLAGS) -c $(SRC)tsthimem.c
280
281 exmmtest.$(OBJ): $(SRC)exmmtest.c
282 ####    *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)
283
284 vgmtest.$(OBJ): $(SRC)vgmtest.c
285 ####    *wcl $(FLAGS) -c $(SRC)vgmtest.c
286         #====*wcl -mc -c $(SRC)vgmtest.c
287
288 #
289 #non executable objects libraries
290 #
291 16.lib: $(16LIBOBJS)# doslib.lib vgmsnd.lib
292         *wlib -b $(WLIBQ) 16.lib $(16LIBOBJS)# doslib.lib vgmsnd.lib
293
294 gfx.lib: $(GFXLIBOBJS)
295         *wlib -b $(WLIBQ) gfx.lib $(GFXLIBOBJS)
296
297 vgmsnd.lib: $(VGMSNDOBJ)
298         *wlib -b $(WLIBQ) vgmsnd.lib $(VGMSNDOBJ)
299
300 # extdep:
301 # !include $(DOSLIBDIR)$(DIRSEP)extdep.mak
302
303 # library deps 16-bit huge
304 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)cpu$(DIRSEP)dos86h$(DIRSEP)cpu.lib:
305         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)cpu && .$(DIRSEP)make.sh
306 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)dos$(DIRSEP)dos86h$(DIRSEP)dos.lib:
307         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)dos && .$(DIRSEP)make.sh
308 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga$(DIRSEP)dos86h$(DIRSEP)vgatty.lib:
309         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga && .$(DIRSEP)make.sh
310 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga$(DIRSEP)dos86h$(DIRSEP)vga.lib:
311         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga && .$(DIRSEP)make.sh
312 $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)8250$(DIRSEP)dos86h$(DIRSEP)8250.lib:
313         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)8250 && .$(DIRSEP)make.sh
314
315 joytest.exe:
316         cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)joystick && .$(DIRSEP)make.sh && $(COPYCOMMAND) dos86h$(DIRSEP)test.exe $(PDIR)$(PDIR)$(PDIR)$(PDIR)$(PDIR)joytest.exe
317 #$(DOSLIBLIBS): .symbolic
318 #       @cd $(DOSLIB)
319 #       @.$(DIRSEP)buildall.sh
320 #       @cd $(PDIR)$(PDIR)$(PDIR)
321
322 modex16.$(OBJ): $(SRCLIB)modex16.h $(SRCLIB)modex16.c
323         *wcl $(FLAGS) -c $(SRCLIB)modex16.c
324
325 bakapee.$(OBJ): $(SRCLIB)bakapee.h $(SRCLIB)bakapee.c
326         *wcl $(FLAGS) -c $(SRCLIB)bakapee.c
327
328 16render.$(OBJ): $(MODEXLIB)16render.h $(MODEXLIB)16render.c
329         *wcl $(FLAGS) -c $(MODEXLIB)16render.c
330
331 ##16planar.$(OBJ): $(MODEXLIB)16planar.h $(MODEXLIB)16planar.c
332 ##      *wcl $(FLAGS) -c $(MODEXLIB)16planar.c
333
334 16_vrs.$(OBJ): $(SRCLIB)16_vrs.h $(SRCLIB)16_vrs.c $(DOSLIBLIBS)
335         *wcl $(FLAGS) -c $(SRCLIB)16_vrs.c $(DOSLIBLIBS)
336 16_sprit.$(OBJ): $(SRCLIB)16_sprit.h $(SRCLIB)16_sprit.c
337         *wcl $(FLAGS) -c $(SRCLIB)16_sprit.c
338
339
340 bitmap.$(OBJ): $(SRCLIB)bitmap.h $(SRCLIB)bitmap.c
341         *wcl $(FLAGS) -c $(SRCLIB)bitmap.c
342
343 ##planar.$(OBJ): $(SRCLIB)planar.h $(SRCLIB)planar.c
344 ##      *wcl $(FLAGS) -c $(SRCLIB)planar.c
345
346 scroll16.$(OBJ): $(SRCLIB)scroll16.h $(SRCLIB)scroll16.c
347         *wcl $(FLAGS) -c $(SRCLIB)scroll16.c
348
349 wcpu.$(OBJ): $(WCPULIB)wcpu.h $(WCPULIB)wcpu.c
350         *wcl $(FLAGS) -c $(WCPULIB)wcpu.c
351
352 16text.$(OBJ): $(SRCLIB)16text.c
353         *wcl $(FLAGS) -c $(SRCLIB)16text.c
354
355 mapread.$(OBJ): $(SRCLIB)mapread.h $(SRCLIB)mapread.c
356         *wcl $(FLAGS) -c $(SRCLIB)mapread.c
357
358 16_timer.$(OBJ): $(SRCLIB)16_timer.h $(SRCLIB)16_timer.c
359         *wcl $(FLAGS) -c $(SRCLIB)16_timer.c
360
361 16_in.$(OBJ): $(SRCLIB)16_in.h $(SRCLIB)16_in.c
362         *wcl $(FLAGS) -c $(SRCLIB)16_in.c
363
364 16_mm.$(OBJ): $(SRCLIB)16_mm.h $(SRCLIB)16_mm.c
365         *wcl $(FLAGS) -c $(SRCLIB)16_mm.c
366
367 16_ca.$(OBJ): $(SRCLIB)16_ca.h $(SRCLIB)16_ca.c
368         *wcl $(FLAGS) -c $(SRCLIB)16_ca.c
369
370 16_dbg.$(OBJ): $(SRCLIB)16_dbg.h $(SRCLIB)16_dbg.c
371         *wcl $(FLAGS) -c $(SRCLIB)16_dbg.c
372
373 midi.$(OBJ): $(SRCLIB)midi.h $(SRCLIB)midi.c
374         *wcl $(FLAGS) -c $(SRCLIB)midi.c
375
376 16_head.$(OBJ): $(SRCLIB)16_head.h $(SRCLIB)16_head.c
377         *wcl $(FLAGS) -c $(SRCLIB)16_head.c
378
379 16_hc.$(OBJ): $(SRCLIB)16_hc.h $(SRCLIB)16_hc.c
380         *wcl $(FLAGS) -c $(SRCLIB)16_hc.c
381
382 16_snd.$(OBJ): $(SRCLIB)16_snd.h $(SRCLIB)16_snd.c
383         *wcl $(FLAGS) -c $(SRCLIB)16_snd.c
384         #====*wcl -mc -c $(SRCLIB)16_snd.c
385
386 jsmn.$(OBJ): $(JSMNLIB)jsmn.h $(JSMNLIB)jsmn.c
387         *wcl $(FLAGS) -c $(JSMNLIB)jsmn.c
388
389 kitten.$(OBJ): $(NYANLIB)kitten.h $(NYANLIB)kitten.c
390         *wcl $(FLAGS) -c $(NYANLIB)kitten.c
391
392 vgmSnd.$(OBJ): $(VGMSNDLIB)vgmSnd.h $(VGMSNDLIB)vgmSnd.c
393         *wcl $(FLAGS) -c $(VGMSNDLIB)vgmSnd.c
394         #====*wcl -c -mc $(VGMSNDLIB)vgmSnd.c
395
396 #memory.$(OBJ): $(EXMMLIB)memory.h $(EXMMLIB)memory.c
397 #       *wcl $(FLAGS) $(MFLAGS) -c $(EXMMLIB)memory.c
398
399 c_utils.$(OBJ): $(MODEXLIB_)c_utils.asm
400         *wcl -c $(AFLAGS) $(MODEXLIB_)c_utils.asm
401 modex.$(OBJ): $(MODEXLIB_)modex.asm
402         *wcl -c $(AFLAGS) $(MODEXLIB_)modex.asm
403
404 #
405 #other~
406 #
407 clean: .symbolic
408         @$(REMOVECOMMAND) $(EXEC)
409         @$(REMOVECOMMAND) *.$(OBJ)
410 !ifdef __LINUX__
411         @rm *.LIB
412 !endif
413         @$(REMOVECOMMAND) 16.lib
414         @$(REMOVECOMMAND) gfx.lib
415         @$(REMOVECOMMAND) vgmsnd.lib
416         @*wlib -n $(WLIBQ) 16.lib
417         @*wlib -n $(WLIBQ) gfx.lib
418         @*wlib -n $(WLIBQ) vgmsnd.lib
419         @$(REMOVECOMMAND) *.16W
420         @$(REMOVECOMMAND) *.16B
421         @$(REMOVECOMMAND) *.OBJ
422         @$(REMOVECOMMAND) *.o
423         @$(REMOVECOMMAND) *.BCO
424         #@$(REMOVECOMMAND) makefi~1
425         #@$(REMOVECOMMAND) makefile~
426         @$(REMOVECOMMAND) __wcl__.LNK
427 #       @$(REMOVECOMMAND) *.smp
428         @$(REMOVECOMMAND) *.SMP
429         @$(REMOVECOMMAND) *.hed
430         @$(REMOVECOMMAND) *.MAH
431         @$(REMOVECOMMAND) *.mah
432         @$(REMOVECOMMAND) *.err
433         @echo $(OBJ)
434         #@cd $(DOSLIB)
435         #@./buildall.sh clean
436         #@cd $(PDIR)$(PDIR)$(PDIR)
437 #       @$(COPYCOMMAND) $(SRC)exmmtest.c $(EXMMTESTDIR)$(SRC)
438 #       @$(COPYCOMMAND) $(SRCLIB)16_mm.* $(EXMMTESTDIR)$(SRCLIB)
439 #       @$(COPYCOMMAND) $(SRCLIB)16_head.* $(EXMMTESTDIR)$(SRCLIB)
440 #       @$(COPYCOMMAND) $(SRCLIB)16_ca.* $(EXMMTESTDIR)$(SRCLIB)
441 #       @$(COPYCOMMAND) $(SRCLIB)16_hc.* $(EXMMTESTDIR)$(SRCLIB)
442 #       @$(COPYCOMMAND) $(SRCLIB)types.h $(EXMMTESTDIR)$(SRCLIB)
443 #       @$(COPYCOMMAND) $(NYANLIB)* $(EXMMTESTDIR)$(NYANLIB)
444 #       @echo $(watcom)
445 #       @echo $(INCLUDE)
446
447 backupconfig: .symbolic
448         @$(COPYCOMMAND) .git$(DIRSEP)config git_con.fig
449         @$(COPYCOMMAND) .gitmodules git_modu.les
450         @$(COPYCOMMAND) .gitignore git_igno.re
451
452 comp: .symbolic
453         @*upx -9 $(EXEC)
454
455 comq: .symbolic
456         @*upx -9 $(UPXQ) $(EXEC)
457
458 www: .symbolic
459         @ssh -p 26 sparky4@4ch.mooo.com 'rm -f /var/www/16/*exe*'
460         #@rm -f /var/www/$(EXEC)*
461         @rm -f /var/www/*.exe.zip*
462         #@cp ./$(EXEC) $(DIRSEP)var$(DIRSEP)www$(DIRSEP)
463         @./src/util/z.sh $(EXEC) $(EXEC)
464         @scp -r -P 26 *.exe 4ch.mooo.com:/var/www/16/
465         @scp -r -P 26 x4get.bat 4ch.mooo.com:/var/www/16/
466         @scp -r -P 26 /var/www/*.exe.zip.* 4ch.mooo.com:/var/www/16/
467
468 getwww: .symbolic
469         *x4get.bat $(EXEC)
470
471 vomitchan: .symbolic
472         @$(DUMP) *.err
473
474 ##
475 ##      External library management~ ^^
476 ##
477 #git submodule add <repo>
478 mkdl: .symbolic
479         @cd $(DOSLIB)
480         @./buildall.sh
481         @cd $(PDIR)$(PDIR)$(PDIR)
482
483 uplibs: .symbolic
484         @cd $(JSMNLIB)
485         @git pull
486         @cd $(PDIR)$(PDIR)$(PDIR)
487         @cd $(DOSLIB)
488         @git pull
489         @cd $(PDIR)$(PDIR)$(PDIR)
490
491 reinitlibs: .symbolic
492         @rm -rf $(SRCLIB)doslib
493         @rm -rf $(SRCLIB)jsmn
494         @rm -rf 16/CatacombApocalypse
495         @rm -rf 16/wolf3d
496         @rm -rf 16/keen
497         @wmake -h initlibs
498
499 initlibs: .symbolic
500         @cp git_con.fig .git/config
501         @cp git_modu.les .gitmodules
502         @cp git_igno.re .gitignore
503         @cd $(SRCLIB)
504         @git clone https://github.com/joncampbell123/doslib.git
505         @git clone https://github.com/zserge/jsmn.git
506         @cd $(PDIR)$(PDIR)
507         @cd 16
508         @git clone https://github.com/FlatRockSoft/CatacombApocalypse.git
509         @git clone https://github.com/id-Software/wolf3d.git
510         @git clone https://github.com/keendreams/keen.git
511         @cd $(PDIR)
512         @cp $(SRCLIB)doslib/make-lowercase .
513
514 ##
515 ##      experimental libs
516 ##
517 xlib: .symbolic
518         @cd 16$(DIRSEP)xlib
519         @wmake -h clean
520         @wmake -h all
521         @cd $(PDIR)$(PDIR)
522
523 mx: .symbolic
524         @cd 16$(DIRSEP)xw
525 #       @wmake clean
526         @wmake -h all
527         @cd $(PDIR)$(PDIR)
528
529 mx_: .symbolic
530         @cd 16$(DIRSEP)xw_
531         @wmake -h -f makefile all
532         @cd $(PDIR)$(PDIR)
533
534 vrs: .symbolic
535         @cd $(DOSLIBDIR)$(DIRSEP)hw$(DIRSEP)vga
536         #@make clean
537         @make all
538         @mv pcx2vrl ../../../../../
539         @mv pcxsscut ../../../../../
540         @mv vrl2vrs ../../../../../
541         @mv vrsdump ../../../../../
542         @cd ../../../../../