From: Alan Cox Date: Thu, 2 Jun 2016 22:59:27 +0000 (+0100) Subject: dw: add Makefiles for Z80 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=7ba4e59e2f4590a07c4c8740a4d34b5d9ce87231;p=FUZIX.git dw: add Makefiles for Z80 --- diff --git a/Applications/dw/Makefile b/Applications/dw/Makefile new file mode 100644 index 00000000..bbbf3d57 --- /dev/null +++ b/Applications/dw/Makefile @@ -0,0 +1,56 @@ +CC = sdcc +ASM = sdasz80 +AR = sdar +LINKER = sdcc +FCC = ../../Library/tools/fcc +FCCOPTS = -O2 +PLATFORM = +#PLATFORM = -tzx128 + +PROGLOAD=`(cat ../../Kernel/platform/config.h; echo PROGLOAD) | cpp -E | tail -n1` + +.SUFFIXES: .c .rel + +SRCSNS = + +SRCS = dw.c dwgetty.c dwterm.c + +SRCSBAD = + +OBJS = $(SRCS:.c=.rel) +OBJSNS = $(SRCSNS:.c=.rel) +OBJSBAD = $(SRCSBAD:.c=.rel) + +LIBS = ../../Library/libs/syslib.lib + +APPSNS = $(OBJSNS:.rel=) + +APPS = $(OBJS:.rel=) $(OBJSBAD:.rel=) $(OBJSNS:.rel=) + +all: $(APPS) sizes + + +$(APPSNS): OPTS = --nostdio + +$(OBJS): %.rel: %.c + +$(OBJSNS): %.rel: %.c + +$(OBJSBAD): %.rel: %.c + $(FCC) $(PLATFORM) -c $< + +.c.rel: + $(FCC) $(PLATFORM) $(FCCOPTS) -c $< + +%: %.rel + $(FCC) $(PLATFORM) $(OPTS) $< -o $@ + +sizes: $(APPS) + ls -l $(APPS) >size.report + +clean: + rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report + +rmbak: + rm -f *~ core +