Fixed up the z80 and gbz80 Makefiles to split out the objs - no more clean
[fw/sdcc] / link / Makefile
index 1e2b1fb4a5165be2f433fe616fc01a323bd71646..c4f6247c64c026cdbc445c148994e7c4e90767a5 100644 (file)
@@ -5,14 +5,7 @@ include $(PRJDIR)/Makefile.common
 PORTS = z80 gbz80
 
 all: 
-       for i in $(PORTS); do make _link THIS=$$i; done
-
-_link: clean
-ifeq ($(THIS), gbz80)
-       make -C z80 BUILDDIR=../../bin EXT=-$(THIS) OPTS=-DGAMEBOY
-else
-       make -C z80 BUILDDIR=../../bin EXT=-$(THIS)
-endif
+       make -C z80 _link-z80 _link-gbz80 E=$(E) BUILDDIR=../../bin/
 
 clean:
        make -C z80 clean