-
Notifications
You must be signed in to change notification settings - Fork 79
/
GNUmakefile
1513 lines (1194 loc) · 31.4 KB
/
GNUmakefile
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
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
#
# EDuke32 Makefile for GNU Make
#
### Global Profiles
ifeq ($(FURY),1)
APPBASENAME := fury
APPNAME := Ion Fury
NETCODE := 0
POLYMER := 0
RETAIL_MENU := 1
STANDALONE := 1
USE_LIBVPX := 0
SDL_STATIC := 1
endif
### Platform and Toolchain Configuration
include Common.mak
### File Extensions
asm := nasm
o := o
### Directories
source := source
obj := obj
### Functions
# Some of this still needs work--"getfiltered" takes a list of files and strips the paths off of them,
# while the other functions end up expanding the result later by adding the paths back.
# This is inefficient, but it was a better use of time than reworking all of this at the moment.
define parent
$(word 1,$(subst _, ,$1))
endef
define expandobjs
$$(addprefix $$($$(call parent,$1)_obj)/,$$(addsuffix .$$o,$$(basename $$($1_objs) $$($1_rsrc_objs) $$($1_gen_objs))))
endef
define expandsrcs
$(addprefix $($(call parent,$1)_src)/,$($1_objs)) $(addprefix $($(call parent,$1)_rsrc)/,$($1_rsrc_objs)) $(addprefix $($(call parent,$1)_obj)/,$($1_gen_objs))
endef
define expanddeps
$(strip $1 $(foreach j,$1,$(call $0,$($j_deps))))
endef
define getdeps
$(call expanddeps,$1_$2 $(common_$2_deps) engine)
endef
define getfiltered
$(filter-out $(strip $($1_excl)), $(subst $($1_src)/, ,$(wildcard $($1_src)/$2)))
endef
##### External Library Definitions
#### libxmp-lite
libxmplite := libxmp-lite
libxmplite_root := $(source)/$(libxmplite)
libxmplite_src := $(libxmplite_root)/src
libxmplite_inc := $(libxmplite_root)/include
libxmplite_obj := $(obj)/$(libxmplite)
libxmplite_excl :=
libxmplite_objs := $(call getfiltered,libxmplite,*.c)
libxmplite_cflags := -DHAVE_ROUND -DLIBXMP_CORE_PLAYER -DLIBXMP_NO_PROWIZARD -DLIBXMP_NO_DEPACKERS -DBUILDING_STATIC -I$(libxmplite_inc)/libxmp-lite -Wno-unused-parameter -Wno-unused-variable -Wno-sign-compare -Wno-cast-qual
#### PhysicsFS
physfs := physfs
physfs_root := $(source)/$(physfs)
physfs_src := $(physfs_root)/src
physfs_inc := $(physfs_root)/include
physfs_obj := $(obj)/$(physfs)
physfs_excl :=
ifeq ($(PLATFORM),WINDOWS)
physfs_excl += physfs_platform_unix.c
else
physfs_excl += physfs_platform_windows.c
endif
ifneq (0,$(USE_PHYSFS))
physfs_objs := $(call getfiltered,physfs,*.c)
else
physfs_objs :=
endif
ifeq ($(PLATFORM),APPLE)
physfs_objs += physfs_platform_apple.m
endif
physfs_cflags :=
#### glad
glad := glad
glad_root := $(source)/$(glad)
glad_src := $(glad_root)/src
glad_inc := $(glad_root)/include
glad_obj := $(obj)/$(glad)
glad_excl :=
ifneq ($(RENDERTYPE),WIN)
glad_excl += glad_wgl.c
endif
ifneq (0,$(USE_OPENGL))
glad_objs := $(call getfiltered,glad,*.c)
else
glad_objs :=
endif
glad_cflags :=
#### mimalloc
mimalloc := mimalloc
mimalloc_root := $(source)/$(mimalloc)
mimalloc_src := $(mimalloc_root)/src
mimalloc_inc := $(mimalloc_root)/include
mimalloc_obj := $(obj)/$(mimalloc)
mimalloc_excl := \
alloc-override.c \
arena-abandon.c \
free.c \
page-queue.c \
static.c \
mimalloc_objs := $(call getfiltered,mimalloc,*.c)
mimalloc_objs += prim/prim.c
mimalloc_cflags := -D_WIN32_WINNT=0x0600 -DMI_USE_RTLGENRANDOM -DMI_SHOW_ERRORS -fexceptions -Wno-cast-qual -Wno-unknown-pragmas -Wno-array-bounds -Wno-null-dereference -Wno-missing-field-initializers
ifeq (,$(filter 1 2 3 4 5 6 7,$(GCC_MAJOR)))
mimalloc_cflags += -Wno-class-memaccess
endif
#### imgui
imgui := imgui
imgui_root := $(source)/$(imgui)
imgui_src := $(imgui_root)/src
imgui_inc := $(imgui_root)/include
imgui_obj := $(obj)/$(imgui)
imgui_excl :=
ifneq ($(RENDERTYPE),SDL)
imgui_excl += imgui_impl_sdl2.cpp
endif
ifneq ($(RENDERTYPE),WIN)
imgui_excl += imgui_impl_win32.cpp
endif
imgui_objs := $(call getfiltered,imgui,*.cpp)
imgui_cflags := -I$(imgui_inc) -Wno-cast-qual -Wno-cast-function-type -Wno-null-dereference -Wno-stringop-overflow
#### Voidwrap
voidwrap := voidwrap
voidwrap_root := $(source)/$(voidwrap)
voidwrap_src := $(voidwrap_root)/src
voidwrap_inc := $(voidwrap_root)/include
voidwrap_obj := $(obj)/$(voidwrap)
voidwrap_excl :=
ifneq ($(PLATFORM),WINDOWS)
voidwrap_excl += dllmain.cpp
endif
voidwrap_objs := $(call getfiltered,voidwrap,*.cpp)
ifeq ($(IMPLICIT_ARCH),x86_64)
ifeq ($(PLATFORM),WINDOWS)
voidwrap_lib := voidwrap_steam_x64.dll
steamworks_lib := win64/steam_api64.dll
else
voidwrap_lib := libvoidwrap_steam.so
steamworks_lib := linux64/libsteam_api.so
endif
else
ifeq ($(PLATFORM),WINDOWS)
voidwrap_lib := voidwrap_steam_x86.dll
steamworks_lib := steam_api.dll
else
voidwrap_lib := libvoidwrap_steam.so
steamworks_lib := linux32/libsteam_api.so
endif
endif
voidwrap_cflags := -I$(voidwrap_root)/sdk/public/steam -fPIC -fvisibility=hidden -Wno-invalid-offsetof
#### libsmackerdec
libsmackerdec := libsmackerdec
libsmackerdec_objs := \
BitReader.cpp \
FileStream.cpp \
HuffmanVLC.cpp \
LogError.cpp \
SmackerDecoder.cpp \
libsmackerdec_root := $(source)/$(libsmackerdec)
libsmackerdec_src := $(libsmackerdec_root)/src
libsmackerdec_inc := $(libsmackerdec_root)/include
libsmackerdec_obj := $(obj)/$(libsmackerdec)
libsmackerdec_cflags :=
#### hmpplay
hmpplay := hmpplay
hmpplay_objs := \
hmpplay.cpp \
fmmidi3.cpp \
hmpplay_root := $(source)/$(hmpplay)
hmpplay_src := $(hmpplay_root)/src
hmpplay_inc := $(hmpplay_root)/include
hmpplay_obj := $(obj)/$(hmpplay)
hmpplay_cflags :=
##### Component Definitions
#### EBacktrace
ifndef ebacktrace_dll
ebacktrace_dll := ebacktrace1.dll
ifeq ($(findstring x86_64,$(COMPILERTARGET)),x86_64)
ebacktrace_dll := ebacktrace1-64.dll
endif
endif
#### BUILD Engine
engine := build
engine_root := $(source)/$(engine)
engine_src := $(engine_root)/src
engine_inc := $(engine_root)/include
engine_obj := $(obj)/$(engine)
engine_cflags :=
engine_deps :=
ifneq (1,$(SDL_TARGET))
engine_deps += imgui
endif
ifneq (0,$(USE_PHYSFS))
engine_deps += physfs
endif
ifneq (0,$(USE_MIMALLOC))
engine_deps += mimalloc
endif
engine_editor_objs := \
build.cpp \
config.cpp \
engine_tools_objs := \
colmatch.cpp \
compat.cpp \
crc32.cpp \
klzw.cpp \
kplib.cpp \
loguru.cpp \
lz4.cpp \
pragmas.cpp \
smmalloc.cpp \
smmalloc_generic.cpp \
smmalloc_tls.cpp \
vfs.cpp \
engine_excl := \
a-c.cpp \
sdlayer12.cpp \
sdlkeytrans.cpp \
startgtk.editor.cpp \
startwin.editor.cpp \
$(engine_editor_objs) \
ifeq (1,$(USE_OPENGL))
engine_deps += glad
else
engine_excl += \
glbuild.cpp \
glsurface.cpp \
mdsprite.cpp \
polymer.cpp \
polymost.cpp \
tilepacker.cpp \
voxmodel.cpp \
endif
ifeq ($(PLATFORM),WINDOWS)
ifeq ($(STARTUP_WINDOW),1)
engine_editor_objs += startwin.editor.cpp
endif
else
engine_excl += winbits.cpp
endif
ifeq ($(PLATFORM),WII)
LINKERFLAGS += -Wl,-wrap,c_default_exceptionhandler
else
engine_excl += wiibits.cpp
endif
ifneq ($(RENDERTYPE),SDL)
engine_excl += sdlayer.cpp
endif
ifneq ($(RENDERTYPE),WIN)
engine_excl += winlayer.cpp rawinput.cpp
endif
ifeq (1,$(HAVE_GTK2))
ifeq ($(STARTUP_WINDOW),1)
engine_editor_objs += startgtk.editor.cpp
endif
else
engine_excl += gtkbits.cpp dynamicgtk.cpp
endif
ifeq ($(USE_LIBVPX),0)
engine_excl += animvpx.cpp
endif
engine_objs := \
$(call getfiltered,engine,*.c) \
$(call getfiltered,engine,*.cpp) \
polymost1Frag.glsl \
polymost1Vert.glsl \
ifeq (0,$(NOASM))
engine_objs += a.nasm
else
engine_objs += a-c.cpp
endif
ifeq ($(PLATFORM),DARWIN)
engine_objs += osxbits.mm
engine_tools_objs += osxbits.mm
ifeq ($(STARTUP_WINDOW),1)
engine_editor_objs += startosx.editor.mm
endif
ifeq ($(SDL_TARGET),1)
ifneq ($(SDL_FRAMEWORK),0)
engine_objs += SDLMain.mm
endif
endif
endif
#### mact
mact := mact
mact_root := $(source)/$(mact)
mact_src := $(mact_root)/src
mact_inc := $(mact_root)/include
mact_obj := $(obj)/$(mact)
mact_excl :=
mact_objs := $(call getfiltered,mact,*.cpp)
mact_cflags :=
#### AudioLib
audiolib := audiolib
audiolib_root := $(source)/$(audiolib)
audiolib_src := $(audiolib_root)/src
audiolib_inc := $(audiolib_root)/include
audiolib_obj := $(obj)/$(audiolib)
audiolib_deps :=
audiolib_excl := \
music_external.cpp \
ifneq ($(PLATFORM),WINDOWS)
audiolib_excl += driver_directsound.cpp driver_winmm.cpp
endif
ifneq ($(SUBPLATFORM),LINUX)
audiolib_excl += driver_alsa.cpp
endif
ifneq ($(RENDERTYPE),SDL)
audiolib_excl += driver_sdl.cpp
endif
audiolib_objs := $(call getfiltered,audiolib,*.cpp)
audiolib_cflags :=
ifneq (0,$(HAVE_XMP))
audiolib_cflags += -I$(libxmplite_inc)
audiolib_deps += libxmplite
endif
#### Tools
tools := tools
tools_objs := \
compat_tools.cpp \
tools_root := $(source)/$(tools)
tools_src := $(tools_root)/src
tools_obj := $(obj)/$(tools)
tools_cflags := $(engine_cflags) -I$(engine_src)
tools_deps := engine_tools
ifneq (0,$(USE_MIMALLOC))
tools_deps += mimalloc
endif
tools_targets := \
arttool \
bsuite \
cacheinfo \
generateicon \
givedepth \
ivfrate \
kextract \
kgroup \
kmd2tool \
map2stl \
md2tool \
mkpalette \
transpal \
unpackssi \
wad2art \
wad2map \
ifeq ($(PLATFORM),WINDOWS)
tools_targets += enumdisplay getdxdidf
endif
ifeq ($(RENDERTYPE),SDL)
tools_targets += makesdlkeytrans
endif
#### KenBuild (Test Game)
kenbuild := kenbuild
kenbuild_root := $(source)/$(kenbuild)
kenbuild_src := $(kenbuild_root)/src
kenbuild_rsrc := $(kenbuild_root)/rsrc
kenbuild_obj := $(obj)/$(kenbuild)
kenbuild_cflags := -I$(kenbuild_src)
kenbuild_game := ekenbuild
kenbuild_editor := ekenbuild-editor
kenbuild_game_deps := audiolib
kenbuild_game_proper := EKenBuild
kenbuild_editor_proper := EKenBuild-Editor
kenbuild_game_objs := \
common.cpp \
config.cpp \
kdmeng.cpp \
game.cpp \
kenbuild_editor_objs := \
bstub.cpp \
common.cpp \
kenbuild_game_rsrc_objs :=
kenbuild_editor_rsrc_objs :=
kenbuild_game_gen_objs :=
kenbuild_editor_rsrc_objs :=
ifeq (11,$(HAVE_GTK2)$(STARTUP_WINDOW))
kenbuild_game_objs += startgtk.game.cpp
kenbuild_game_gen_objs += game_banner.c
kenbuild_editor_gen_objs += build_banner.c
endif
ifeq ($(RENDERTYPE),SDL)
kenbuild_game_rsrc_objs += game_icon.c
kenbuild_editor_rsrc_objs += build_icon.c
endif
ifeq ($(PLATFORM),WINDOWS)
kenbuild_game_objs += startwin.game.cpp
kenbuild_game_rsrc_objs += gameres.rc
kenbuild_editor_rsrc_objs += buildres.rc
endif
ifeq ($(PLATFORM),DARWIN)
ifeq ($(STARTUP_WINDOW),1)
kenbuild_game_objs += StartupWinController.game.mm
endif
endif
#### TekWar
tekwar := tekwar
tekwar_root := $(source)/$(tekwar)
tekwar_src := $(tekwar_root)/src
tekwar_rsrc := $(tekwar_root)/rsrc
tekwar_obj := $(obj)/$(tekwar)
tekwar_cflags := -I$(tekwar_src)
tekwar_game := etekwar
tekwar_editor := etekwar-editor
tekwar_game_proper := ETekWar
tekwar_editor_proper := ETekWar Editor
tekwar_game_deps := audiolib mact libsmackerdec hmpplay
tekwar_game_objs := \
b5compat.cpp \
common.cpp \
config.cpp \
grpscan.cpp \
osdcmds.cpp \
tekcdr.cpp \
tekchng.cpp \
tekgame.cpp \
tekgun.cpp \
tekldsv.cpp \
tekmap.cpp \
tekmsc.cpp \
tekprep.cpp \
teksmk.cpp \
teksnd.cpp \
tekspr.cpp \
tekstat.cpp \
tektag.cpp \
tektxt.cpp \
tekver.cpp \
tekwar_editor_objs := \
bstub.cpp \
tekwar_game_rsrc_objs :=
tekwar_editor_rsrc_objs :=
tekwar_game_gen_objs :=
tekwar_editor_rsrc_objs :=
ifeq (11,$(HAVE_GTK2)$(STARTUP_WINDOW))
tekwar_game_objs += startgtk.game.cpp
tekwar_game_gen_objs += game_banner.c
tekwar_editor_gen_objs += build_banner.c
endif
ifeq ($(RENDERTYPE),SDL)
tekwar_game_rsrc_objs += game_icon.c
tekwar_editor_rsrc_objs += game_icon.c
endif
ifeq ($(PLATFORM),WINDOWS)
tekwar_game_objs += startwin.game.cpp
tekwar_game_rsrc_objs += gameres.rc
tekwar_editor_rsrc_objs += buildres.rc
endif
#### Duke Nukem 3D
duke3d := duke3d
duke3d_game_ldflags :=
duke3d_editor_ldflags :=
duke3d_game_stripflags :=
duke3d_editor_stripflags :=
duke3d_root := $(source)/$(duke3d)
duke3d_src := $(duke3d_root)/src
duke3d_rsrc := $(duke3d_root)/rsrc
duke3d_obj := $(obj)/$(duke3d)
ifneq (,$(APPBASENAME))
ifeq ($(PLATFORM),WINDOWS)
duke3d_rsrc := $(duke3d_root)/rsrc/$(APPBASENAME)
endif
duke3d_obj := $(obj)/$(APPBASENAME)
endif
duke3d_cflags :=
common_editor_deps := duke3d_common_editor engine_editor
duke3d_game_deps := audiolib mact
duke3d_editor_deps := audiolib
duke3d_game := eduke32
duke3d_editor := mapster32
ifneq (,$(APPBASENAME))
duke3d_game := $(APPBASENAME)
endif
duke3d_game_proper := EDuke32
duke3d_editor_proper := Mapster32
duke3d_common_editor_objs := \
m32common.cpp \
m32def.cpp \
m32exec.cpp \
m32vars.cpp \
duke3d_editor_objs := \
astub.cpp \
common.cpp \
grpscan.cpp \
sounds_mapster32.cpp \
duke3d_excl := \
in_android.cpp \
m32structures.cpp \
mdump.cpp \
startgtk.game.cpp \
startwin.game.cpp \
$(duke3d_common_editor_objs) \
$(duke3d_editor_objs) \
duke3d_game_objs := $(call getfiltered,duke3d,*.cpp) \
common.cpp \
grpscan.cpp \
duke3d_game_rsrc_objs :=
duke3d_editor_rsrc_objs :=
duke3d_game_gen_objs :=
duke3d_editor_gen_objs :=
duke3d_game_miscdeps :=
duke3d_editor_miscdeps :=
duke3d_game_orderonlydeps :=
duke3d_editor_orderonlydeps :=
ifeq ($(SUBPLATFORM),LINUX)
LIBS += -lFLAC -lasound
endif
ifeq ($(PLATFORM),BSD)
LIBS += -lFLAC -lexecinfo
endif
ifeq ($(PLATFORM),DARWIN)
LIBS += -lFLAC \
-Wl,-framework,Cocoa -Wl,-framework,Carbon \
-Wl,-framework,CoreMIDI -Wl,-framework,AudioUnit \
-Wl,-framework,AudioToolbox -Wl,-framework,IOKit
ifneq (00,$(DARWIN9)$(DARWIN10))
LIBS += -Wl,-framework,QuickTime
endif
ifeq ($(STARTUP_WINDOW),1)
duke3d_game_objs += GrpFile.game.mm GameListSource.game.mm startosx.game.mm
endif
endif
ifeq ($(PLATFORM),WINDOWS)
LIBS += -lFLAC -ldsound
duke3d_game_objs += winbits.cpp
duke3d_game_rsrc_objs += gameres.rc
duke3d_editor_rsrc_objs += buildres.rc
ifeq ($(STARTUP_WINDOW),1)
duke3d_game_objs += startwin.game.cpp
endif
endif
ifeq (11,$(HAVE_GTK2)$(STARTUP_WINDOW))
duke3d_game_objs += startgtk.game.cpp
duke3d_game_gen_objs += game_banner.c
duke3d_editor_gen_objs += build_banner.c
endif
ifeq ($(RENDERTYPE),SDL)
duke3d_game_rsrc_objs += game_icon.c
duke3d_editor_rsrc_objs += build_icon.c
endif
#### Blood
blood := blood
blood_game_ldflags :=
blood_game_stripflags :=
blood_root := $(source)/$(blood)
blood_src := $(blood_root)/src
blood_rsrc := $(blood_root)/rsrc
blood_obj := $(obj)/$(blood)
blood_cflags := -I$(blood_src)
blood_game_deps := audiolib mact libsmackerdec
ifneq (0,$(NETCODE))
blood_game_deps += enet
endif
blood_game := nblood
ifneq (,$(APPBASENAME))
blood_game := $(APPBASENAME)
endif
blood_game_proper := NBlood
blood_game_objs := \
blood.cpp \
actor.cpp \
ai.cpp \
aibat.cpp \
aibeast.cpp \
aiboneel.cpp \
aiburn.cpp \
aicaleb.cpp \
aicerber.cpp \
aicult.cpp \
aigarg.cpp \
aighost.cpp \
aigilbst.cpp \
aihand.cpp \
aihound.cpp \
aiinnoc.cpp \
aipod.cpp \
airat.cpp \
aispid.cpp \
aitchern.cpp \
aizomba.cpp \
aizombf.cpp \
asound.cpp \
barf.cpp \
callback.cpp \
choke.cpp \
common.cpp \
config.cpp \
controls.cpp \
credits.cpp \
db.cpp \
demo.cpp \
dude.cpp \
endgame.cpp \
eventq.cpp \
fire.cpp \
fx.cpp \
gamemenu.cpp \
gameutil.cpp \
getopt.cpp \
gfx.cpp \
gib.cpp \
globals.cpp \
gui.cpp \
inifile.cpp \
iob.cpp \
levels.cpp \
loadsave.cpp \
map2d.cpp \
menu.cpp \
messages.cpp \
mirrors.cpp \
misc.cpp \
network.cpp \
osdcmd.cpp \
player.cpp \
qav.cpp \
qheap.cpp \
replace.cpp \
resource.cpp \
screen.cpp \
sectorfx.cpp \
seq.cpp \
sfx.cpp \
sound.cpp \
tile.cpp \
trig.cpp \
triggers.cpp \
view.cpp \
warp.cpp \
weapon.cpp \
ifeq ($(NOONE_EXTENSIONS),1)
blood_game_objs += nnextsif.cpp
blood_game_objs += nnexts.cpp
blood_game_objs += nnextstr.cpp
blood_game_objs += nnextcdud.cpp
blood_game_objs += aicdud.cpp
endif
blood_game_rsrc_objs :=
blood_game_gen_objs :=
blood_game_miscdeps :=
blood_game_orderonlydeps :=
ifeq ($(PLATFORM),DARWIN)
ifeq ($(STARTUP_WINDOW),1)
blood_game_objs += startosx.game.mm
endif
endif
ifeq ($(PLATFORM),WINDOWS)
blood_game_objs += winbits.cpp
blood_game_rsrc_objs += gameres.rc
ifeq ($(STARTUP_WINDOW),1)
blood_game_objs += startwin.game.cpp
endif
endif
ifeq (11,$(HAVE_GTK2)$(STARTUP_WINDOW))
blood_game_objs += startgtk.game.cpp
blood_game_gen_objs += game_banner.c
endif
ifeq ($(RENDERTYPE),SDL)
blood_game_rsrc_objs += game_icon.c
endif
#### Redneck Rampage
rr := rr
rr_game_ldflags :=
rr_editor_ldflags :=
rr_game_stripflags :=
rr_editor_stripflags :=
rr_root := $(source)/$(rr)
rr_src := $(rr_root)/src
rr_rsrc := $(rr_root)/rsrc
rr_obj := $(obj)/$(rr)
rr_cflags := -I$(rr_src)
common_editor_deps := rr_common_editor engine_editor
rr_game_deps := audiolib mact
rr_editor_deps := audiolib
ifneq (0,$(NETCODE))
rr_game_deps += enet
endif
rr_game := rednukem
rr_editor := rrmapster32
ifneq (,$(APPBASENAME))
rr_game := $(APPBASENAME)
endif
rr_game_proper := Rednukem
rr_editor_proper := RRMapster32
rr_common_editor_objs := \
m32common.cpp \
m32def.cpp \
m32exec.cpp \
m32vars.cpp \
rr_game_objs := \
game.cpp \
global.cpp \
actors.cpp \
gamedef.cpp \
gameexec.cpp \
gamevars.cpp \
player.cpp \
premap.cpp \
sector.cpp \
anim.cpp \
common.cpp \
config.cpp \
demo.cpp \
input.cpp \
menus.cpp \
namesdyn.cpp \
net.cpp \
savegame.cpp \
rts.cpp \
osdfuncs.cpp \
osdcmds.cpp \
grpscan.cpp \
sounds.cpp \
soundsdyn.cpp \
cheats.cpp \
sbar.cpp \
screentext.cpp \
screens.cpp \
cmdline.cpp \
rrdh.cpp \
filestream.cpp \
playmve.cpp \
rr_editor_objs := \
astub.cpp \
common.cpp \
grpscan.cpp \
sounds_mapster32.cpp \
rr_game_rsrc_objs :=
rr_editor_rsrc_objs :=
rr_game_gen_objs :=
rr_editor_gen_objs :=
rr_game_miscdeps :=
rr_editor_miscdeps :=
rr_game_orderonlydeps :=
rr_editor_orderonlydeps :=
ifeq ($(PLATFORM),DARWIN)
ifeq ($(STARTUP_WINDOW),1)
rr_game_objs += GrpFile.game.mm GameListSource.game.mm startosx.game.mm
endif
endif
ifeq ($(PLATFORM),WINDOWS)
rr_game_objs += winbits.cpp
rr_game_rsrc_objs += gameres.rc
rr_editor_rsrc_objs += buildres.rc
ifeq ($(STARTUP_WINDOW),1)
rr_game_objs += startwin.game.cpp
endif
endif
ifeq (11,$(HAVE_GTK2)$(STARTUP_WINDOW))
rr_game_objs += startgtk.game.cpp
rr_game_gen_objs += game_banner.c
rr_editor_gen_objs += build_banner.c
endif
ifeq ($(RENDERTYPE),SDL)
rr_game_rsrc_objs += game_icon.c
rr_editor_rsrc_objs += build_icon.c
endif
n64 := n64
n64_src := $(rr_src)/$(n64)
n64_obj := $(rr_obj)/$(n64)
n64_objs := \
reality.cpp \
reality_music.cpp \
reality_player.cpp \
reality_render.cpp \
reality_sbar.cpp \
reality_screens.cpp \
reality_sound.cpp \
reality_util.cpp \
n64_cflags :=
rr_game_deps += n64
#### Shadow Warrior
sw := sw
sw_root := $(source)/$(sw)
sw_src := $(sw_root)/src
sw_rsrc := $(sw_root)/rsrc
sw_obj := $(obj)/$(sw)
sw_cflags :=
sw_game_deps := audiolib mact
sw_editor_deps := audiolib
sw_game := voidsw
sw_editor := wangulator