From a4871a49289946893818171e7e83c6f92ae49cc0 Mon Sep 17 00:00:00 2001
From: "ol.sc"
Date: Tue, 22 Sep 2009 21:43:57 +0000
Subject: [PATCH] Build files in the extra directory (analog to apple2).
git-svn-id: svn://svn.cc65.org/cc65/trunk@4214 b7a2c559-68d2-44c3-8de9-860c34a00d81
---
libsrc/Makefile | 7 ++++++-
libsrc/apple2enh/Makefile | 10 ++++++++--
2 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/libsrc/Makefile b/libsrc/Makefile
index b68a6829b..2ba17bf09 100644
--- a/libsrc/Makefile
+++ b/libsrc/Makefile
@@ -59,7 +59,7 @@ apple2lib:
fi \
#-----------------------------------------------------------------------------
-# Apple //e
+# enhanced Apple //e
apple2enhlib:
for i in apple2enh common runtime conio dbg em joystick mouse serial tgi zlib; do \
@@ -72,6 +72,11 @@ apple2enhlib:
cp apple2enh/apple2-ssc.ser a2e.ssc.ser
cp apple2enh/apple2-280-192-8.tgi a2e.hi.tgi
cp apple2enh/apple2-40-48-16.tgi a2e.lo.tgi
+ if [ -d apple2enh/extra ]; then \
+ for i in apple2enh/extra/*.o; do \
+ cp $$i apple2enh-`basename $$i`; \
+ done \
+ fi \
#-----------------------------------------------------------------------------
# Atari
diff --git a/libsrc/apple2enh/Makefile b/libsrc/apple2enh/Makefile
index 11609b2ca..e9e5d05f9 100644
--- a/libsrc/apple2enh/Makefile
+++ b/libsrc/apple2enh/Makefile
@@ -26,6 +26,9 @@ CFLAGS = -Osir -g -T -t $(SYS) --forget-inc-paths -I ../apple2 -I ../../include
%.o: ../apple2/%.s
@$(AS) -g -o $@ $(AFLAGS) $<
+extra/%.o: ../apple2/extra/%.s
+ @$(AS) -g -o $@ $(AFLAGS) $<
+
%.emd: %.o ../runtime/zeropage.o
@$(LD) -t module -o $@ $^
@@ -109,6 +112,9 @@ S_OBJS= _scrsize.o \
wherey.o \
write.o
+S_EXTRA_OBJS= \
+ extra/iobuf-0800.o
+
#--------------------------------------------------------------------------
# Drivers
@@ -127,13 +133,13 @@ TGIS = apple2-280-192-8.tgi apple2-40-48-16.tgi
.PHONY: all clean zap
-all: $(C_OBJS) $(S_OBJS) $(EMDS) $(JOYS) $(MOUS) $(SERS) $(TGIS)
+all: $(C_OBJS) $(S_OBJS) $(S_EXTRA_OBJS) $(EMDS) $(JOYS) $(MOUS) $(SERS) $(TGIS)
../runtime/zeropage.o:
$(MAKE) -C $(dir $@) $(notdir $@)
clean:
- @$(RM) $(C_OBJS:.o=.s) $(C_OBJS) $(S_OBJS) $(EMDS:.emd=.o) $(JOYS:.joy=.o) $(MOUS:.mou=.o) $(SERS:.ser=.o) $(TGIS:.tgi=.o)
+ @$(RM) $(C_OBJS:.o=.s) $(C_OBJS) $(S_OBJS) $(S_EXTRA_OBJS) $(EMDS:.emd=.o) $(JOYS:.joy=.o) $(MOUS:.mou=.o) $(SERS:.ser=.o) $(TGIS:.tgi=.o)
zap: clean
@$(RM) $(EMDS) $(JOYS) $(MOUS) $(SERS) $(TGIS)
--
2.39.5