2002-11-21 21:22:26 +00:00
|
|
|
#
|
|
|
|
# makefile for CC65 runtime library (C16)
|
|
|
|
#
|
|
|
|
|
|
|
|
.SUFFIXES: .o .s .c
|
|
|
|
|
2002-12-21 08:53:39 +00:00
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Rules
|
|
|
|
|
2002-11-21 21:22:26 +00:00
|
|
|
%.o: %.c
|
|
|
|
@$(CC) $(CFLAGS) $<
|
|
|
|
@$(AS) -o $@ $(AFLAGS) $(*).s
|
|
|
|
|
|
|
|
%.o: %.s
|
|
|
|
@$(AS) -g -o $@ $(AFLAGS) $<
|
|
|
|
|
2002-12-21 08:53:39 +00:00
|
|
|
%.emd: %.o ../runtime/zeropage.o
|
|
|
|
@$(LD) -t module -o $@ $^
|
|
|
|
|
|
|
|
%.joy: %.o ../runtime/zeropage.o
|
|
|
|
@$(LD) -t module -o $@ $^
|
|
|
|
|
|
|
|
%.tgi: %.o ../runtime/zeropage.o
|
|
|
|
@$(LD) -t module -o $@ $^
|
|
|
|
|
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Object files
|
|
|
|
|
2002-12-21 09:32:14 +00:00
|
|
|
OBJS = _scrsize.o \
|
|
|
|
break.o \
|
2002-11-21 21:22:26 +00:00
|
|
|
cgetc.o \
|
2002-12-21 09:32:14 +00:00
|
|
|
clrscr.o \
|
|
|
|
color.o \
|
|
|
|
conio.o \
|
|
|
|
cputc.o \
|
|
|
|
crt0.o \
|
2002-12-03 22:19:21 +00:00
|
|
|
get_tv.o \
|
2002-12-21 09:32:14 +00:00
|
|
|
joy_stddrv.o \
|
|
|
|
kbhit.o \
|
2002-11-21 21:22:26 +00:00
|
|
|
kernal.o \
|
2003-03-10 21:21:46 +00:00
|
|
|
mainargs.o \
|
2002-11-21 21:22:26 +00:00
|
|
|
randomize.o \
|
2002-12-21 08:53:39 +00:00
|
|
|
revers.o
|
|
|
|
|
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Drivers
|
2002-11-21 21:22:26 +00:00
|
|
|
|
2002-12-21 08:53:39 +00:00
|
|
|
EMDS =
|
|
|
|
|
2002-12-21 09:10:15 +00:00
|
|
|
JOYS = c16-stdjoy.joy
|
2002-12-21 08:53:39 +00:00
|
|
|
|
|
|
|
TGIS =
|
|
|
|
|
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Targets
|
|
|
|
|
2003-02-06 15:35:30 +00:00
|
|
|
.PHONY: all clean zap
|
|
|
|
|
2002-12-21 08:53:39 +00:00
|
|
|
all: $(OBJS) $(EMDS) $(JOYS) $(TGIS)
|
|
|
|
|
|
|
|
../runtime/zeropage.o:
|
|
|
|
$(MAKE) -C $(dir $@) $(notdir $@)
|
2002-11-21 21:22:26 +00:00
|
|
|
|
|
|
|
clean:
|
2002-12-21 08:53:39 +00:00
|
|
|
@rm -f $(OBJS) $(EMDS:.emd=.o) $(JOYS:.joy=.o) $(TGIS:.tgi=.o)
|
|
|
|
|
2003-02-06 15:35:30 +00:00
|
|
|
zap: clean
|
|
|
|
@rm -f $(EMDS) $(JOYS) $(TGIS)
|
2002-11-21 21:22:26 +00:00
|
|
|
|