-
Notifications
You must be signed in to change notification settings - Fork 51
/
Copy pathMakefile.tiny
2967 lines (2167 loc) · 72.2 KB
/
Makefile.tiny
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
SRC_DIR = $(CORE_DIR)/src
LIBRETRO_COMM_DIR = $(SRC_DIR)/osd/retro/libretro-common
DEPS_DIR = $(SRC_DIR)/lib
INCFLAGS := \
-I$(LIBRETRO_COMM_DIR)/include \
-I$(SRC_DIR)/$(TARGET) \
-I$(OBJ)/$(TARGET)/layout \
-I$(SRC_DIR)/emu \
-I$(OBJ)/emu \
-I$(OBJ)/emu/layout \
-I$(DEPS_DIR)/util \
-I$(SRC_DIR)/lib \
-I$(SRC_DIR)/osd \
-I$(SRC_DIR)/osd/retro \
# add expat XML library
INCFLAGS += -I$(DEPS_DIR)/expat
EXPAT = $(OBJ)/libexpat.a
# add ZLIB compression library
ifeq ($(BUILD_ZLIB),1)
INCFLAGS += -I$(DEPS_DIR)/zlib
ZLIB = $(OBJ)/libz.a
else
LIBS += -lz
ZLIB =
endif
# add flac library
INCFLAGS += -I$(DEPS_DIR)/util
FLAC_LIB = $(OBJ)/libflac.a
# add jpeglib image library
INCFLAGS += -I$(DEPS_DIR)/libjpeg
JPEG_LIB = $(OBJ)/libjpeg.a
# add SoftFloat floating point emulation library
SOFTFLOAT = $(OBJ)/libsoftfloat.a
# add formats emulation library
FORMATS_LIB = $(OBJ)/libformats.a
# add LUA library
LUA_LIB = $(OBJ)/liblua.a
# add PortMidi MIDI library
ifeq ($(BUILD_MIDILIB),1)
INCFLAGS += -I$(DEPS_DIR)/portmidi
MIDI_LIB = $(OBJ)/libportmidi.a
else
#LIBS += -lportmidi
MIDI_LIB =
endif
# then the various core pieces
###########################################################################
#
# mame.mak
#
# MAME target makefile
#
# Copyright Nicola Salmoria and the MAME Team.
# Visit http://mamedev.org for licensing and usage restrictions.
#
###########################################################################
MAMESRC = $(SRC_DIR)/mame
MAMEOBJ = $(OBJ)/mame
AUDIO = $(MAMEOBJ)/audio
DRIVERS = $(MAMEOBJ)/drivers
LAYOUT = $(MAMEOBJ)/layout
MACHINE = $(MAMEOBJ)/machine
VIDEO = $(MAMEOBJ)/video
OBJDIRS += \
$(AUDIO) \
$(DRIVERS) \
$(LAYOUT) \
$(MACHINE) \
$(VIDEO) \
#-------------------------------------------------
# specify available CPU cores; some of these are
# only for MESS, but are included so that they get
# updated with any MAME core changes
#-------------------------------------------------
CPUS += Z80
CPUS += M6502
CPUS += MCS48
CPUS += MCS51
CPUS += M6800
CPUS += M6809
CPUS += M680X0
#-------------------------------------------------
# specify available sound cores; some of these are
# only for MESS and so aren't included
#-------------------------------------------------
SOUNDS += CUSTOM
SOUNDS += SAMPLES
SOUNDS += DAC
SOUNDS += SPEAKER
SOUNDS += DISCRETE
SOUNDS += AY8910
SOUNDS += YM2151
SOUNDS += YM2610
SOUNDS += ASTROCADE
SOUNDS += TMS5220
SOUNDS += OKIM6295
SOUNDS += YM3812
SOUNDS += HC55516
SOUNDS += CEM3394
#-------------------------------------------------
# this is the list of driver libraries that
# comprise MAME plus mamedriv.o which contains
# the list of drivers
#-------------------------------------------------
DRVLIBS = \
$(MAMEOBJ)/testdriv.o \
$(DRIVERS)/neogeo.o $(VIDEO)/neogeo.o \
$(MACHINE)/neoboot.o \
$(MACHINE)/neocrypt.o \
$(MACHINE)/neoprot.o \
$(MACHINE)/ticket.o \
$(DRIVERS)/carpolo.o $(MACHINE)/carpolo.o $(VIDEO)/carpolo.o \
$(DRIVERS)/circus.o $(AUDIO)/circus.o $(VIDEO)/circus.o \
$(DRIVERS)/exidy.o $(AUDIO)/exidy.o $(VIDEO)/exidy.o \
$(DRIVERS)/starfire.o $(VIDEO)/starfire.o \
$(DRIVERS)/victory.o $(VIDEO)/victory.o \
$(AUDIO)/targ.o \
$(DRIVERS)/astrocde.o $(VIDEO)/astrocde.o \
$(DRIVERS)/gridlee.o $(AUDIO)/gridlee.o $(VIDEO)/gridlee.o \
$(DRIVERS)/williams.o $(MACHINE)/williams.o $(AUDIO)/williams.o $(VIDEO)/williams.o \
$(AUDIO)/gorf.o \
$(AUDIO)/wow.o \
$(DRIVERS)/gaelco.o $(VIDEO)/gaelco.o $(MACHINE)/gaelcrpt.o \
$(DRIVERS)/wrally.o $(MACHINE)/wrally.o $(VIDEO)/wrally.o \
$(EMUMACHINE)/ldpr8210.o $(EMUMACHINE)/ldvp931.o \
$(DRIVERS)/neogeo.o: $(MAMESRC)/drivers/neodrvr.c
###########################################################################
#
# emu.mak
#
# MAME emulation core makefile
#
# Copyright Nicola Salmoria and the MAME Team.
# Visit http://mamedev.org for licensing and usage restrictions.
#
###########################################################################
EMUSRC = $(SRC_DIR)/emu
EMUOBJ = $(OBJ)/emu
EMUAUDIO = $(EMUOBJ)/audio
EMUDRIVERS = $(EMUOBJ)/drivers
EMULAYOUT = $(EMUOBJ)/layout
EMUMACHINE = $(EMUOBJ)/machine
EMUVIDEO = $(EMUOBJ)/video
OBJDIRS += \
$(EMUOBJ)/cpu \
$(EMUOBJ)/sound \
$(EMUOBJ)/debug \
$(EMUOBJ)/debugint \
$(EMUOBJ)/audio \
$(EMUOBJ)/drivers \
$(EMUOBJ)/machine \
$(EMUOBJ)/layout \
$(EMUOBJ)/video \
#-------------------------------------------------
# emulator core objects
#-------------------------------------------------
EMUOBJS = \
$(EMUOBJ)/attotime.o \
$(EMUOBJ)/audit.o \
$(EMUOBJ)/cheat.o \
$(EMUOBJ)/clifront.o \
$(EMUOBJ)/config.o \
$(EMUOBJ)/crsshair.o \
$(EMUOBJ)/debugger.o \
$(EMUOBJ)/devcb.o \
$(EMUOBJ)/devcpu.o \
$(EMUOBJ)/devimage.o \
$(EMUOBJ)/devlegcy.o \
$(EMUOBJ)/devintrf.o \
$(EMUOBJ)/didisasm.o \
$(EMUOBJ)/diexec.o \
$(EMUOBJ)/diimage.o \
$(EMUOBJ)/dimemory.o \
$(EMUOBJ)/dinvram.o \
$(EMUOBJ)/disound.o \
$(EMUOBJ)/distate.o \
$(EMUOBJ)/drawgfx.o \
$(EMUOBJ)/driver.o \
$(EMUOBJ)/emualloc.o \
$(EMUOBJ)/emucore.o \
$(EMUOBJ)/emuopts.o \
$(EMUOBJ)/emupal.o \
$(EMUOBJ)/fileio.o \
$(EMUOBJ)/hash.o \
$(EMUOBJ)/hashfile.o \
$(EMUOBJ)/image.o \
$(EMUOBJ)/info.o \
$(EMUOBJ)/input.o \
$(EMUOBJ)/inputseq.o \
$(EMUOBJ)/inptport.o \
$(EMUOBJ)/ioprocs.o \
$(EMUOBJ)/mame.o \
$(EMUOBJ)/machine.o \
$(EMUOBJ)/mconfig.o \
$(EMUOBJ)/memory.o \
$(EMUOBJ)/output.o \
$(EMUOBJ)/render.o \
$(EMUOBJ)/rendfont.o \
$(EMUOBJ)/rendlay.o \
$(EMUOBJ)/rendutil.o \
$(EMUOBJ)/romload.o \
$(EMUOBJ)/schedule.o \
$(EMUOBJ)/softlist.o \
$(EMUOBJ)/sound.o \
$(EMUOBJ)/state.o \
$(EMUOBJ)/streams.o \
$(EMUOBJ)/tilemap.o \
$(EMUOBJ)/timer.o \
$(EMUOBJ)/ui.o \
$(EMUOBJ)/uigfx.o \
$(EMUOBJ)/uiimage.o \
$(EMUOBJ)/uiinput.o \
$(EMUOBJ)/uimenu.o \
$(EMUOBJ)/validity.o \
$(EMUOBJ)/video.o \
$(EMUOBJ)/watchdog.o \
$(EMUOBJ)/debug/debugcmd.o \
$(EMUOBJ)/debug/debugcmt.o \
$(EMUOBJ)/debug/debugcon.o \
$(EMUOBJ)/debug/debugcpu.o \
$(EMUOBJ)/debug/debughlp.o \
$(EMUOBJ)/debug/debugvw.o \
$(EMUOBJ)/debug/dvdisasm.o \
$(EMUOBJ)/debug/dvmemory.o \
$(EMUOBJ)/debug/dvstate.o \
$(EMUOBJ)/debug/dvtext.o \
$(EMUOBJ)/debug/express.o \
$(EMUOBJ)/debug/textbuf.o \
$(EMUOBJ)/debugint/debugint.o
ifdef PROFILER
EMUOBJS += \
$(EMUOBJ)/profiler.o
endif
EMUSOUNDOBJS = \
$(EMUOBJ)/sound/filter.o \
$(EMUOBJ)/sound/flt_vol.o \
$(EMUOBJ)/sound/flt_rc.o \
$(EMUOBJ)/sound/wavwrite.o \
EMUAUDIOOBJS = \
$(EMUAUDIO)/generic.o \
EMUDRIVEROBJS = \
$(EMUDRIVERS)/empty.o \
EMUMACHINEOBJS = \
$(EMUMACHINE)/53c810.o \
$(EMUMACHINE)/6532riot.o \
$(EMUMACHINE)/6522via.o \
$(EMUMACHINE)/6526cia.o \
$(EMUMACHINE)/6821pia.o \
$(EMUMACHINE)/6840ptm.o \
$(EMUMACHINE)/6850acia.o \
$(EMUMACHINE)/68681.o \
$(EMUMACHINE)/7474.o \
$(EMUMACHINE)/74123.o \
$(EMUMACHINE)/74148.o \
$(EMUMACHINE)/74153.o \
$(EMUMACHINE)/74181.o \
$(EMUMACHINE)/8042kbdc.o \
$(EMUMACHINE)/8237dma.o \
$(EMUMACHINE)/8257dma.o \
$(EMUMACHINE)/8255ppi.o \
$(EMUMACHINE)/adc083x.o \
$(EMUMACHINE)/adc1038.o \
$(EMUMACHINE)/adc1213x.o \
$(EMUMACHINE)/am53cf96.o \
$(EMUMACHINE)/at28c16.o \
$(EMUMACHINE)/cdp1852.o \
$(EMUMACHINE)/ds1302.o \
$(EMUMACHINE)/ds2401.o \
$(EMUMACHINE)/ds2404.o \
$(EMUMACHINE)/eeprom.o \
$(EMUMACHINE)/f3853.o \
$(EMUMACHINE)/generic.o \
$(EMUMACHINE)/i8243.o \
$(EMUMACHINE)/i8255a.o \
$(EMUMACHINE)/i2cmem.o \
$(EMUMACHINE)/idectrl.o \
$(EMUMACHINE)/ins8154.o \
$(EMUMACHINE)/ins8250.o \
$(EMUMACHINE)/intelfsh.o \
$(EMUMACHINE)/k033906.o \
$(EMUMACHINE)/k056230.o \
$(EMUMACHINE)/latch8.o \
$(EMUMACHINE)/ldcore.o \
$(EMUMACHINE)/ldpr8210.o \
$(EMUMACHINE)/ldv1000.o \
$(EMUMACHINE)/ldvp931.o \
$(EMUMACHINE)/mb14241.o \
$(EMUMACHINE)/mb3773.o \
$(EMUMACHINE)/mb87078.o \
$(EMUMACHINE)/mc146818.o \
$(EMUMACHINE)/microtch.o \
$(EMUMACHINE)/msm6242.o \
$(EMUMACHINE)/pc16552d.o \
$(EMUMACHINE)/pci.o \
$(EMUMACHINE)/pic8259.o \
$(EMUMACHINE)/pit8253.o \
$(EMUMACHINE)/pd4990a.o \
$(EMUMACHINE)/roc10937.o \
$(EMUMACHINE)/rp5h01.o \
$(EMUMACHINE)/rtc65271.o \
$(EMUMACHINE)/scsi.o \
$(EMUMACHINE)/scsicd.o \
$(EMUMACHINE)/scsidev.o \
$(EMUMACHINE)/scsihd.o \
$(EMUMACHINE)/cr589.o \
$(EMUMACHINE)/smc91c9x.o \
$(EMUMACHINE)/timekpr.o \
$(EMUMACHINE)/tmp68301.o \
$(EMUMACHINE)/tms6100.o \
$(EMUMACHINE)/upd4701.o \
$(EMUMACHINE)/wd33c93.o \
$(EMUMACHINE)/x2212.o \
$(EMUMACHINE)/x76f041.o \
$(EMUMACHINE)/x76f100.o \
$(EMUMACHINE)/z80ctc.o \
$(EMUMACHINE)/z80dart.o \
$(EMUMACHINE)/z80dma.o \
$(EMUMACHINE)/z80pio.o \
$(EMUMACHINE)/z80sio.o \
$(EMUMACHINE)/z80sti.o \
EMUVIDEOOBJS = \
$(EMUVIDEO)/generic.o \
$(EMUVIDEO)/hd63484.o \
$(EMUVIDEO)/mc6845.o \
$(EMUVIDEO)/pc_vga.o \
$(EMUVIDEO)/pc_video.o \
$(EMUVIDEO)/poly.o \
$(EMUVIDEO)/resnet.o \
$(EMUVIDEO)/rgbutil.o \
$(EMUVIDEO)/s2636.o \
$(EMUVIDEO)/saa5050.o \
$(EMUVIDEO)/tlc34076.o \
$(EMUVIDEO)/tms34061.o \
$(EMUVIDEO)/tms9927.o \
$(EMUVIDEO)/tms9928a.o \
$(EMUVIDEO)/v9938.o \
$(EMUVIDEO)/vector.o \
$(EMUVIDEO)/voodoo.o \
LIBEMUOBJS = $(EMUOBJS) $(EMUSOUNDOBJS) $(EMUAUDIOOBJS) $(EMUDRIVEROBJS) $(EMUMACHINEOBJS) $(EMUVIDEOOBJS)
$(LIBEMU): $(LIBEMUOBJS)
#-------------------------------------------------
# CPU core objects
#-------------------------------------------------
###########################################################################
#
# cpu.mak
#
# Rules for building CPU cores
#
# Copyright Nicola Salmoria and the MAME Team.
# Visit http://mamedev.org for licensing and usage restrictions.
#
###########################################################################
CPUSRC = $(EMUSRC)/cpu
CPUOBJ = $(EMUOBJ)/cpu
#-------------------------------------------------
# Shared code
#-------------------------------------------------
OBJDIRS += $(CPUOBJ)
CPUOBJS += $(CPUOBJ)/vtlb.o
#-------------------------------------------------
# Dynamic recompiler objects
#-------------------------------------------------
DRCOBJ = \
$(CPUOBJ)/drcbec.o \
$(CPUOBJ)/drcbeut.o \
$(CPUOBJ)/drccache.o \
$(CPUOBJ)/drcfe.o \
$(CPUOBJ)/drcuml.o \
DRCDEPS = \
$(CPUSRC)/drcbeut.h \
$(CPUSRC)/drccache.h \
$(CPUSRC)/drcfe.h \
$(CPUSRC)/drcuml.h \
$(CPUSRC)/drcumlsh.h \
# fixme - need to make this work for other target architectures (PPC)
ifndef FORCE_DRC_C_BACKEND
ifeq ($(PTR64),1)
DRCOBJ += \
$(CPUOBJ)/drcbex64.o \
$(CPUOBJ)/x86log.o $(CPUOBJ)/i386/i386dasm.o
DRCDEPS += \
$(CPUSRC)/x86emit.h
DEFS += -DNATIVE_DRC=drcbe_x64_be_interface
else
DRCOBJ += \
$(CPUOBJ)/drcbex86.o \
$(CPUOBJ)/x86log.o $(CPUOBJ)/i386/i386dasm.o
DRCDEPS += \
$(CPUSRC)/x86emit.h
DEFS += -DNATIVE_DRC=drcbe_x86_be_interface
endif
endif
$(DRCOBJ): $(DRCDEPS)
#-------------------------------------------------
# Acorn ARM series
#-------------------------------------------------
ifneq ($(filter ARM,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/arm
CPUOBJS += $(CPUOBJ)/arm/arm.o
DASMOBJS += $(CPUOBJ)/arm/armdasm.o
endif
ifneq ($(filter ARM7,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/arm7
CPUOBJS += $(CPUOBJ)/arm7/arm7.o
DASMOBJS += $(CPUOBJ)/arm7/arm7dasm.o
endif
$(CPUOBJ)/arm/arm.o: $(CPUSRC)/arm/arm.c \
$(CPUSRC)/arm/arm.h
$(CPUOBJ)/arm7/arm7.o: $(CPUSRC)/arm7/arm7.c \
$(CPUSRC)/arm7/arm7.h \
$(CPUSRC)/arm7/arm7exec.c \
$(CPUSRC)/arm7/arm7core.c
#-------------------------------------------------
# Advanced Digital Chips SE3208
#-------------------------------------------------
ifneq ($(filter SE3208,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/se3208
CPUOBJS += $(CPUOBJ)/se3208/se3208.o
DASMOBJS += $(CPUOBJ)/se3208/se3208dis.o
endif
$(CPUOBJ)/se3208/se3208.o: $(CPUSRC)/se3208/se3208.c \
$(CPUSRC)/se3208/se3208.h
#-------------------------------------------------
# Alpha 8201
#-------------------------------------------------
ifneq ($(filter ALPHA8201,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/alph8201
CPUOBJS += $(CPUOBJ)/alph8201/alph8201.o
DASMOBJS += $(CPUOBJ)/alph8201/8201dasm.o
endif
$(CPUOBJ)/alph8201/alph8201.o: $(CPUSRC)/alph8201/alph8201.c \
$(CPUSRC)/alph8201/alph8201.h
#-------------------------------------------------
# Analog Devices ADSP21xx series
#-------------------------------------------------
ifneq ($(filter ADSP21XX,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/adsp2100
CPUOBJS += $(CPUOBJ)/adsp2100/adsp2100.o
DASMOBJS += $(CPUOBJ)/adsp2100/2100dasm.o
endif
$(CPUOBJ)/adsp2100/adsp2100.o: $(CPUSRC)/adsp2100/adsp2100.c \
$(CPUSRC)/adsp2100/adsp2100.h \
$(CPUSRC)/adsp2100/2100ops.c
#-------------------------------------------------
# Analog Devices "Sharc" ADSP21062
#-------------------------------------------------
ifneq ($(filter ADSP21062,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/sharc
CPUOBJS += $(CPUOBJ)/sharc/sharc.o
DASMOBJS += $(CPUOBJ)/sharc/sharcdsm.o
endif
$(CPUOBJ)/sharc/sharc.o: $(CPUSRC)/sharc/sharc.c \
$(CPUSRC)/sharc/sharc.h \
$(CPUSRC)/sharc/sharcops.c \
$(CPUSRC)/sharc/sharcops.h \
$(CPUSRC)/sharc/sharcdsm.c \
$(CPUSRC)/sharc/sharcdsm.h \
$(CPUSRC)/sharc/compute.c \
$(CPUSRC)/sharc/sharcdma.c \
$(CPUSRC)/sharc/sharcmem.c
#-------------------------------------------------
# APEXC
#-------------------------------------------------
ifneq ($(filter APEXC,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/apexc
CPUOBJS += $(CPUOBJ)/apexc/apexc.o
DASMOBJS += $(CPUOBJ)/apexc/apexcdsm.o
endif
$(CPUOBJ)/apexc/apexc.o: $(CPUSRC)/apexc/apexc.c \
$(CPUSRC)/apexc/apexc.h
#-------------------------------------------------
# AT&T DSP32C
#-------------------------------------------------
ifneq ($(filter DSP32C,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/dsp32
CPUOBJS += $(CPUOBJ)/dsp32/dsp32.o
DASMOBJS += $(CPUOBJ)/dsp32/dsp32dis.o
endif
$(CPUOBJ)/dsp32/dsp32.o: $(CPUSRC)/dsp32/dsp32.c \
$(CPUSRC)/dsp32/dsp32.h \
$(CPUSRC)/dsp32/dsp32ops.c
#-------------------------------------------------
# Atari custom RISC processor
#-------------------------------------------------
ifneq ($(filter ASAP,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/asap
CPUOBJS += $(CPUOBJ)/asap/asap.o
DASMOBJS += $(CPUOBJ)/asap/asapdasm.o
endif
$(CPUOBJ)/asap/asap.o: $(CPUSRC)/asap/asap.c \
$(CPUSRC)/asap/asap.h
#-------------------------------------------------
# AMD Am29000
#-------------------------------------------------
ifneq ($(filter AM29000,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/am29000
CPUOBJS += $(CPUOBJ)/am29000/am29000.o
DASMOBJS += $(CPUOBJ)/am29000/am29dasm.o
endif
$(CPUOBJ)/am29000/am29000.o: $(CPUSRC)/am29000/am29000.c \
$(CPUSRC)/am29000/am29000.h \
$(CPUSRC)/am29000/am29ops.h \
#-------------------------------------------------
# Atari Jaguar custom DSPs
#-------------------------------------------------
ifneq ($(filter JAGUAR,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/jaguar
CPUOBJS += $(CPUOBJ)/jaguar/jaguar.o
DASMOBJS += $(CPUOBJ)/jaguar/jagdasm.o
endif
$(CPUOBJ)/jaguar/jaguar.o: $(CPUSRC)/jaguar/jaguar.c \
$(CPUSRC)/jaguar/jaguar.h
#-------------------------------------------------
# Simutrek Cube Quest bit-sliced CPUs
#-------------------------------------------------
ifneq ($(filter CUBEQCPU,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/cubeqcpu
CPUOBJS += $(CPUOBJ)/cubeqcpu/cubeqcpu.o
DASMOBJS += $(CPUOBJ)/cubeqcpu/cubedasm.o
endif
$(CPUOBJ)/cubeqcpu/cubeqcpu.o: $(CPUSRC)/cubeqcpu/cubeqcpu.c \
$(CPUSRC)/cubeqcpu/cubeqcpu.h
#-------------------------------------------------
# Entertainment Sciences AM29116-based RIP
#-------------------------------------------------
ifneq ($(filter ESRIP,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/esrip
CPUOBJS += $(CPUOBJ)/esrip/esrip.o
DASMOBJS += $(CPUOBJ)/esrip/esripdsm.o
endif
$(CPUOBJ)/esrip/esrip.o: $(CPUSRC)/esrip/esrip.c \
$(CPUSRC)/esrip/esrip.h
#-------------------------------------------------
# RCA CDP1802
#-------------------------------------------------
ifneq ($(filter CDP1802,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/cdp1802
CPUOBJS += $(CPUOBJ)/cdp1802/cdp1802.o
DASMOBJS += $(CPUOBJ)/cdp1802/1802dasm.o
endif
$(CPUOBJ)/cdp1802/cdp1802.o: $(CPUSRC)/cdp1802/cdp1802.c \
$(CPUSRC)/cdp1802/cdp1802.h
#-------------------------------------------------
# National Semiconductor COP400 family
#-------------------------------------------------
ifneq ($(filter COP400,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/cop400
CPUOBJS += $(CPUOBJ)/cop400/cop400.o
DASMOBJS += $(CPUOBJ)/cop400/cop410ds.o
DASMOBJS += $(CPUOBJ)/cop400/cop420ds.o
DASMOBJS += $(CPUOBJ)/cop400/cop440ds.o
endif
$(CPUOBJ)/cop400/cop400.o: $(CPUSRC)/cop400/cop400.c \
$(CPUSRC)/cop400/cop400.h \
$(CPUSRC)/cop400/cop400op.c
#-------------------------------------------------
# CP1610
#-------------------------------------------------
ifneq ($(filter CP1610,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/cp1610
CPUOBJS += $(CPUOBJ)/cp1610/cp1610.o
DASMOBJS += $(CPUOBJ)/cp1610/1610dasm.o
endif
$(CPUOBJ)/cp1610/cp1610.o: $(CPUSRC)/cp1610/cp1610.c \
$(CPUSRC)/cp1610/cp1610.h
#-------------------------------------------------
# Cinematronics vector "CPU"
#-------------------------------------------------
ifneq ($(filter CCPU,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/ccpu
CPUOBJS += $(CPUOBJ)/ccpu/ccpu.o
DASMOBJS += $(CPUOBJ)/ccpu/ccpudasm.o
endif
$(CPUOBJ)/ccpu/ccpu.o: $(CPUSRC)/ccpu/ccpu.c \
$(CPUSRC)/ccpu/ccpu.h
#-------------------------------------------------
# DEC T-11
#-------------------------------------------------
ifneq ($(filter T11,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/t11
CPUOBJS += $(CPUOBJ)/t11/t11.o
DASMOBJS += $(CPUOBJ)/t11/t11dasm.o
endif
$(CPUOBJ)/t11/t11.o: $(CPUSRC)/t11/t11.c \
$(CPUSRC)/t11/t11.h \
$(CPUSRC)/t11/t11ops.c \
$(CPUSRC)/t11/t11table.c
#-------------------------------------------------
# F8
#-------------------------------------------------
ifneq ($(filter F8,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/f8
CPUOBJS += $(CPUOBJ)/f8/f8.o
DASMOBJS += $(CPUOBJ)/f8/f8dasm.o
endif
$(CPUOBJ)/f8/f8.o: $(CPUSRC)/f8/f8.c \
$(CPUSRC)/f8/f8.h
#-------------------------------------------------
# G65816
#-------------------------------------------------
ifneq ($(filter G65816,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/g65816
CPUOBJS += \
$(CPUOBJ)/g65816/g65816.o \
$(CPUOBJ)/g65816/g65816o0.o \
$(CPUOBJ)/g65816/g65816o1.o \
$(CPUOBJ)/g65816/g65816o2.o \
$(CPUOBJ)/g65816/g65816o3.o \
$(CPUOBJ)/g65816/g65816o4.o
DASMOBJS += $(CPUOBJ)/g65816/g65816ds.o
endif
G65816DEPS = \
$(CPUSRC)/g65816/g65816.h \
$(CPUSRC)/g65816/g65816cm.h \
$(CPUSRC)/g65816/g65816op.h
$(CPUOBJ)/g65816/g65816.o: $(CPUSRC)/g65816/g65816.c \
$(G65816DEPS)
$(CPUOBJ)/g65816/g65816o0.o: $(CPUSRC)/g65816/g65816o0.c \
$(G65816DEPS)
$(CPUOBJ)/g65816/g65816o1.o: $(CPUSRC)/g65816/g65816o1.c \
$(G65816DEPS)
$(CPUOBJ)/g65816/g65816o2.o: $(CPUSRC)/g65816/g65816o2.c \
$(G65816DEPS)
$(CPUOBJ)/g65816/g65816o3.o: $(CPUSRC)/g65816/g65816o3.c \
$(G65816DEPS)
$(CPUOBJ)/g65816/g65816o4.o: $(CPUSRC)/g65816/g65816o4.c \
$(G65816DEPS)
#-------------------------------------------------
# Hitachi 6309
#-------------------------------------------------
ifneq ($(filter HD6309,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/hd6309
CPUOBJS += $(CPUOBJ)/hd6309/hd6309.o
DASMOBJS += $(CPUOBJ)/hd6309/6309dasm.o
endif
$(CPUOBJ)/hd6309/hd6309.o: $(CPUSRC)/hd6309/hd6309.c \
$(CPUSRC)/hd6309/hd6309.h \
$(CPUSRC)/hd6309/6309ops.c \
$(CPUSRC)/hd6309/6309tbl.c
#-------------------------------------------------
# Hitachi H8/30xx (16/32-bit H8/3xx series)
#-------------------------------------------------
ifneq ($(filter H83002,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/h83002
CPUOBJS += $(CPUOBJ)/h83002/h8_16.o $(CPUOBJ)/h83002/h8periph.o
DASMOBJS += $(CPUOBJ)/h83002/h8disasm.o
endif
$(CPUOBJ)/h83002/h8_16.o: $(CPUSRC)/h83002/h8_16.c \
$(CPUSRC)/h83002/h8.h \
$(CPUSRC)/h83002/h8ops.h \
$(CPUSRC)/h83002/h8priv.h
$(CPUOBJ)/h83002/h8disasm.o: $(CPUSRC)/h83002/h8disasm.c
$(CPUOBJ)/h83002/h8periph.o: $(CPUSRC)/h83002/h8periph.c \
$(CPUSRC)/h83002/h8priv.h
#-------------------------------------------------
# Hitachi H8/3334 (8/16-bit H8/3xx series)
#-------------------------------------------------
ifneq ($(filter H83334,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/h83002
CPUOBJS += $(CPUOBJ)/h83002/h8_8.o $(CPUOBJ)/h83002/h8periph.o
DASMOBJS += $(CPUOBJ)/h83002/h8disasm.o
endif
$(CPUOBJ)/h83002/h8_8.o: $(CPUSRC)/h83002/h8_8.c \
$(CPUSRC)/h83002/h8.h \
$(CPUSRC)/h83002/h8ops.h \
$(CPUSRC)/h83002/h8priv.h
$(CPUOBJ)/h83002/h8disasm.o: $(CPUSRC)/h83002/h8disasm.c
$(CPUOBJ)/h83002/h8periph.o: $(CPUSRC)/h83002/h8periph.c \
$(CPUSRC)/h83002/h8priv.h
#-------------------------------------------------
# Hitachi SH1/SH2
#-------------------------------------------------
ifneq ($(filter SH2,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/sh2
CPUOBJS += $(CPUOBJ)/sh2/sh2.o $(CPUOBJ)/sh2/sh2comn.o $(CPUOBJ)/sh2/sh2drc.o $(CPUOBJ)/sh2/sh2fe.o $(DRCOBJ)
DASMOBJS += $(CPUOBJ)/sh2/sh2dasm.o
endif
$(CPUOBJ)/sh2/sh2.o: $(CPUSRC)/sh2/sh2.c \
$(CPUSRC)/sh2/sh2.h \
$(CPUSRC)/sh2/sh2comn.h
$(CPUOBJ)/sh2/sh2comn.o: $(CPUSRC)/sh2/sh2comn.c \
$(CPUSRC)/sh2/sh2comn.h \
$(CPUSRC)/sh2/sh2.h
$(CPUOBJ)/sh2/sh2drc.o: $(CPUSRC)/sh2/sh2drc.c \
$(CPUSRC)/sh2/sh2.h \
$(CPUSRC)/sh2/sh2comn.h
$(CPUOBJ)/sh2/sh2fe.o: $(CPUSRC)/sh2/sh2fe.c \
$(CPUSRC)/sh2/sh2.h \
$(CPUSRC)/sh2/sh2comn.h
#-------------------------------------------------
# Hitachi SH4
#-------------------------------------------------
ifneq ($(filter SH4,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/sh4
CPUOBJS += $(CPUOBJ)/sh4/sh4.o $(CPUOBJ)/sh4/sh4comn.o
DASMOBJS += $(CPUOBJ)/sh4/sh4dasm.o
endif
$(CPUOBJ)/sh4/sh4.o: $(CPUSRC)/sh4/sh4.c \
$(CPUSRC)/sh4/sh4.h \
$(CPUSRC)/sh4/sh4regs.h \
$(CPUSRC)/sh4/sh4comn.h
$(CPUOBJ)/sh4/sh4comn.o: $(CPUSRC)/sh4/sh4comn.c \
$(CPUSRC)/sh4/sh4comn.h \
$(CPUSRC)/sh4/sh4regs.h \
$(CPUSRC)/sh4/sh4.h
#-------------------------------------------------
# Hudsonsoft 6280
#-------------------------------------------------
ifneq ($(filter H6280,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/h6280
CPUOBJS += $(CPUOBJ)/h6280/h6280.o
DASMOBJS += $(CPUOBJ)/h6280/6280dasm.o
endif
$(CPUOBJ)/h6280/h6280.o: $(CPUSRC)/h6280/h6280.c \
$(CPUSRC)/h6280/h6280.h \
$(CPUSRC)/h6280/h6280ops.h \
$(CPUSRC)/h6280/tblh6280.c
#-------------------------------------------------
# Hyperstone E1 series
#-------------------------------------------------
ifneq ($(filter E1,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/e132xs
CPUOBJS += $(CPUOBJ)/e132xs/e132xs.o
DASMOBJS += $(CPUOBJ)/e132xs/32xsdasm.o
endif
$(CPUOBJ)/e132xs/e132xs.o: $(CPUSRC)/e132xs/e132xs.c \
$(CPUSRC)/e132xs/e132xs.h \
$(CPUSRC)/e132xs/e132xsop.c
#-------------------------------------------------
# Intel 4004
#-------------------------------------------------
ifneq ($(filter I4004,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/i4004
CPUOBJS += $(CPUOBJ)/i4004/i4004.o
DASMOBJS += $(CPUOBJ)/i4004/4004dasm.o
endif
$(CPUOBJ)/i4004/i4004.o: $(CPUSRC)/i4004/i4004.c \
$(CPUSRC)/i4004/i4004.h
#-------------------------------------------------
# Intel 8008
#-------------------------------------------------
ifneq ($(filter I8008,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/i8008
CPUOBJS += $(CPUOBJ)/i8008/i8008.o
DASMOBJS += $(CPUOBJ)/i8008/8008dasm.o
endif
$(CPUOBJ)/i8008/i8008.o: $(CPUSRC)/i8008/i8008.c \
$(CPUSRC)/i8008/i8008.h
#-------------------------------------------------
# National Semiconductor SC/MP
#-------------------------------------------------
ifneq ($(filter SCMP,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/scmp
CPUOBJS += $(CPUOBJ)/scmp/scmp.o
DASMOBJS += $(CPUOBJ)/scmp/scmpdasm.o
endif
$(CPUOBJ)/scmp/scmp.o: $(CPUSRC)/scmp/scmp.c \
$(CPUSRC)/scmp/scmp.h
#-------------------------------------------------
# Intel 8080/8085A
#-------------------------------------------------
ifneq ($(filter I8085,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/i8085
CPUOBJS += $(CPUOBJ)/i8085/i8085.o
DASMOBJS += $(CPUOBJ)/i8085/8085dasm.o
endif
$(CPUOBJ)/i8085/i8085.o: $(CPUSRC)/i8085/i8085.c \
$(CPUSRC)/i8085/i8085.h \
$(CPUSRC)/i8085/i8085cpu.h
#-------------------------------------------------
# Intel MCS-48 (8039 and derivatives)
#-------------------------------------------------
ifneq ($(filter MCS48,$(CPUS)),)
OBJDIRS += $(CPUOBJ)/mcs48
CPUOBJS += $(CPUOBJ)/mcs48/mcs48.o