ASM = m6809-unknown-as
AR = m6809-unknown-ar
LINKER = lwlink
-CFLAGS = -I../../../../Library/include -I../../../../Library/include/6502
+CFLAGS = -I../../../../Library/include -I../../../../Library/include/6502 -Wall -pedantic -fno-strict-aliasing
COPT = -Os
LINKER_OPT = --format=raw -L../../../../Library/libs -lc6809
LIBGCCDIR = $(dir $(shell $(CC) -print-libgcc-file-name))
-LINKER_OPT += -L$(LIBGCCDIR) -lgcc
+LINKER_OPT += -L$(LIBGCCDIR) -lgcc -m sh.map
LINKER_OPT += --script=../../../util/$(TARGET).link
ASM_OPT = -o
CRT0 = ../../../../Library/libs/crt0_6809.o
macro.c main.c msg.c name.c print.c service.c setbrk.c stak.c \
string.c xec.c glob.c
+INCS = brkincr.h ctype.h defs.h mac.h mode.h name.h stak.h sym.h timeout.h
+
# Workaround for gcc 6809
SRCS_HARD = word.c
all: sh
-$(OBJS): $(SRCS)
+$(OBJS): $(INCS)
$(OBJS): %.o : %.c
$(CC) -c $(CFLAGS) $(COPT) $<