LINKER = m68k-uclinux-ld
CFLAGS = -fno-strict-aliasing -fomit-frame-pointer -fno-builtin -msoft-float -Wall -m68000 -Os -I../../Library/include -I../../Library/include/68000
LINKER_OPT = -L../../Library/libs -lc68000
+LINKER_FP_OPT = -L../../Library/libs -lm68000 -lc68000
LIBGCCDIR = $(dir $(shell $(CC) -print-libgcc-file-name))
LINKER_OPT += --emit-relocs -L$(LIBGCCDIR) -lgcc -T ../../Library/elf2flt.ld
+LINKER_FP_OPT += --emit-relocs -L$(LIBGCCDIR) -lgcc -T ../../Library/elf2flt.ld
CRT0 = ../../Library/libs/crt0_68000.o
CRT0NS = ../../Library/libs/crt0nostdio_68000.o
# For now while we get going. Really we want to use some kind of elf2zmagic
adv08.c adv09.c adv10.c adv11.c adv12.c adv13.c adv14a.c adv14b.c \
myst01.c myst02.c myst03.c myst04.c myst05.c myst06.c myst07.c \
myst08.c myst09.c myst10.c myst11.c fortune-gen.c qrun.c fortune.c \
- startrek.c fweep.c
+ fweep.c
+
+SRCSFP = startrek.c
OBJS = $(SRCS:.c=.o)
+OBJSFP = $(SRCSFP:.c=.o)
OBJSNS = $(SRCSNS:.c=.o)
APPS = $(OBJS:.o=)
+APPSFP = $(OBJSFP:.o=)
APPSNS = $(OBJSNS:.o=)
-all: $(APPS) $(APPSNS) size.report
+all: $(APPS) $(APPSNS) $(APPSFP) size.report
$(APPS): $(CRT0)
+$(APPSFP): $(CRT0)
$(APPSNS): $(CRT0NS)
$(APPS) $(APPSNS): %: %.o
$(LINKER) $^ -o $@.bin $(LINKER_OPT)
$(ELF2FUZIX) -o $@ $@.bin
+$(APPSFP): %: %.o
+ $(LINKER) $^ -o $@.bin $(LINKER_FP_OPT)
+ $(ELF2FUZIX) -o $@ $@.bin
+
size.report: $(APPS) $(APPSNS)
ls -l $^ > $@