Line 1... |
Line 1... |
#
|
#
|
# Makefile for ECO32 ROM monitor
|
# Makefile for ECO32 ROM monitor
|
#
|
#
|
|
|
BUILD = ../../build
|
BUILD = ../../../../build
|
|
|
SRC = start.s main.c command.c instr.c asm.c disasm.c \
|
SRC = start.s \
|
load.c boot.c cpu.c mmu.c getline.c romlib.c \
|
../../common/main.c \
|
keyboard.s ../kbdtbls/kbdtbls.s display.s \
|
../../common/command.c \
|
serial.s sctio-ctl.s sctio-ser.s end.s
|
../../common/instr.c \
|
|
../../common/asm.c \
|
|
../../common/disasm.c \
|
|
../../common/load.c \
|
|
../../common/boot.c \
|
|
../../common/cpu.c \
|
|
../../common/mmu.c \
|
|
../../common/getline.c \
|
|
../../common/romlib.c \
|
|
../../common/keyboard.s \
|
|
../../kbdtbls/kbdtbls.s \
|
|
../../common/display.s \
|
|
../../common/serial.s \
|
|
../../common/sctio-ctl.s \
|
|
../../common/sctio-ser.s \
|
|
../../common/end.s
|
|
|
.PHONY: all install clean
|
.PHONY: all install clean
|
|
|
all: monitor.bin monitor.mcs
|
all: monitor.bin monitor.mcs
|
|
|
install: monitor.bin monitor.mcs
|
install: monitor.bin monitor.mcs
|
mkdir -p $(BUILD)/monitor
|
mkdir -p $(BUILD)/monitor/s3e-500
|
cp monitor.bin $(BUILD)/monitor
|
cp monitor.bin $(BUILD)/monitor/s3e-500
|
cp monitor.mcs $(BUILD)/monitor
|
cp monitor.mcs $(BUILD)/monitor/s3e-500
|
|
|
monitor.mcs: monitor.bin
|
monitor.mcs: monitor.bin
|
$(BUILD)/bin/bin2mcs 0x00000000 monitor.bin monitor.mcs
|
$(BUILD)/bin/bin2mcs 0x00000000 monitor.bin monitor.mcs
|
|
|
monitor.bin: $(SRC)
|
monitor.bin: $(SRC)
|
$(BUILD)/bin/lcc -A -Wo-rom -Wl-rc -Wl0xC0000000 \
|
$(BUILD)/bin/lcc -A -Wo-rom -Wl-rc -Wl0xC0000000 \
|
-Wl-rd -Wl0xC000C000 \
|
-Wl-rd -Wl0xC000C000 \
|
-Wl-m -Wlmonitor.map \
|
-Wl-m -Wlmonitor.map \
|
-o prelim.bin $(SRC)
|
-o prelim.bin $(SRC)
|
cat copy/copy.bin prelim.bin >monitor.bin
|
cat ../../copy/copy.bin prelim.bin >monitor.bin
|
rm prelim.bin
|
rm prelim.bin
|
|
|
clean:
|
clean:
|
rm -f *~
|
rm -f *~
|
rm -f monitor.map monitor.bin
|
rm -f prelim.bin monitor.map monitor.bin
|
rm -f monitor.mcs
|
rm -f monitor.mcs
|