]> git.sur5r.net Git - cc65/blobdiff - libsrc/apple2/Makefile
added sleep() implementation
[cc65] / libsrc / apple2 / Makefile
index be8fe57e81f37f7c1e8a9fd24345a606faff526a..75addc8274f5efa95364fd03c1437c533f44924e 100644 (file)
 %.o:   %.s
        @$(AS) -g -o $@ $(AFLAGS) $<
 
+%.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
 
@@ -28,23 +37,41 @@ OBJS=       _scrsize.o      \
        crt0.o          \
        ctype.o         \
        cvline.o        \
+        get_ostype.o    \
+        getenv.o        \
+        joy_stddrv.o    \
        kbhit.o         \
+        mainargs.o      \
         randomize.o     \
        read.o          \
        revers.o        \
         systime.o       \
+        sysuname.o      \
        where.o         \
        write.o
 
+#--------------------------------------------------------------------------
+# Drivers
+
+EMDS =
+
+JOYS = apple2-stdjoy.joy
+
+TGIS =
+
 #--------------------------------------------------------------------------
 # Targets
 
 .PHONY:        all clean zap
 
-all:   $(OBJS)
+all:   $(OBJS) $(EMDS) $(JOYS) $(TGIS)
+
+../runtime/zeropage.o:
+       $(MAKE) -C $(dir $@) $(notdir $@)
 
 clean:
-       @rm -f $(OBJS)
+       @rm -f $(OBJS) $(EMDS:.emd=.o) $(JOYS:.joy=.o) $(TGIS:.tgi=.o)
 
 zap:   clean
+       @rm -f $(EMDS) $(JOYS) $(TGIS)