Cleanups
[uccvend-snackrom.git] / ROM2 / Makefile
index 7995df9..672ee38 100644 (file)
@@ -1,17 +1,23 @@
 # muchly stolen from m68hc1x's example.tar.gz's Makefile
 
 OBJS = \
-       motors.o keypad.o display.o coinmech.o helpers.o main.o \
-       vectors.o
-INCLUDES = vend.h
+       motors.o keypad.o display_basic.o coinmech.o chime.o \
+       helpers.o main_basic.o comm.o \
+       vectors.o start.o
+INCLUDES = vend.h keypad.h chime.h asm.h display_basic.h ports.h types.h
 
-
-CFLAGS = -O2 -Wall -m68hc11 -mshort -Wall -Wmissing-prototypes -Os -g0 \
+CFLAGS = -O3 -m68hc11 -mshort -Wall -Os -g0 \
        -msoft-reg-count=0 -ffixed-z
 
 LDFLAGS = -m68hc11 -mshort -Wl,-m,m68hc11elfb \
          -nostartfiles \
-         -Wl,-defsym,_io_ports=0x1000
+         -Wl,-defsym,_io_ports=0x1000 \
+         -Wl,-defsym,_switch_input=0x1800 \
+         -Wl,-defsym,_misc_input=0x2000 \
+         -Wl,-defsym,_home_sensors=0x2800 \
+         -Wl,-defsym,_changer_output=0x3000 \
+         -Wl,-defsym,_misc_output=0x3800 \
+         -Wl,-defsym,_uart_regs=0x4000
 
 OBJCOPY_FLAGS=--only-section=.text \
               --only-section=.rodata \
@@ -34,7 +40,17 @@ rom2.elf: $(OBJS) memory.x
        $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LIBADD)
 
 clean:
-       rm -f $(OBJS) *.elf *.s19 *.b *.a
+       rm -f *.o *.elf *.s19 *.b *.a
+
+#
+# Some useful rules
+#
+dump:  rom2.elf
+       $(OBJDUMP) -d $<
+
+size:   rom2.s19
+       $(SIZE) $<
+
 
 #
 # Implicit rules

UCC git Repository :: git.ucc.asn.au