2 # makefile for CC65 runtime library
8 #--------------------------------------------------------------------------
13 AS = ../../src/ca65/ca65
14 CC = ../../src/cc65/cc65
15 LD = ../../src/ld65/ld65
17 AFLAGS = -t $(SYS) -I../../asminc
18 CFLAGS = -Osir -g -T -t $(SYS) --forget-inc-paths -I . -I ../../include
20 #--------------------------------------------------------------------------
25 @$(AS) -o $@ $(AFLAGS) $(*).s
28 @$(AS) -g -o $@ $(AFLAGS) $<
30 %.emd: %.o ../runtime/zeropage.o
31 @$(LD) -t module -o $@ $^
33 %.joy: %.o ../runtime/zeropage.o
34 @$(LD) -t module -o $@ $^
36 %.mou: %.o ../runtime/zeropage.o
37 @$(LD) -t module -o $@ $^
39 %.ser: %.o ../runtime/zeropage.o
40 @$(LD) -t module -o $@ $^
42 %.tgi: %.o ../runtime/zeropage.o
43 @$(LD) -t module -o $@ $^
45 #--------------------------------------------------------------------------
68 #--------------------------------------------------------------------------
71 EMDS = c64-georam.emd c64-ram.emd c64-ramcart.emd c64-reu.emd c64-vdc.emd
73 JOYS = c64-hitjoy.joy c64-numpad.joy c64-ptvjoy.joy c64-stdjoy.joy
75 MOUS = c64-1351.mou c64-joymouse.mou
79 TGIS = c64-320-200-2.tgi
81 #--------------------------------------------------------------------------
86 all: $(OBJS) $(EMDS) $(JOYS) $(MOUS) $(SERS) $(TGIS)
88 ../runtime/zeropage.o:
89 $(MAKE) -C $(dir $@) $(notdir $@)
92 @$(RM) $(OBJS) $(EMDS:.emd=.o) $(JOYS:.joy=.o) $(MOUS:.mou=.o) $(SERS:.ser=.o) $(TGIS:.tgi=.o)
95 @$(RM) $(EMDS) $(JOYS) $(MOUS) $(SERS) $(TGIS)