From 3b31adf01305e522f7e28c1435fb47418ce43267 Mon Sep 17 00:00:00 2001 From: "Juan J. Martinez" Date: Fri, 8 Jan 2021 22:07:02 +0000 Subject: Include bin in the path, moved target to game Don't use relative path to tools in bin. The idea is that the user should be able to use their versions instead. --- Makefile | 9 ++++----- game/src/Makefile | 9 +++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index cb44302..9f84961 100644 --- a/Makefile +++ b/Makefile @@ -1,10 +1,10 @@ all: libs -libs: lib ubox spman mplayer +export PATH := $(shell realpath ./bin):$(PATH) -game: bin libs bin/game.rom +libs: lib ubox spman mplayer -bin/game.rom: +game: bin libs make -C tools make -C game @@ -20,9 +20,8 @@ spman: mplayer: make -C src/mplayer -.PHONY: clean cleanall docs ubox libs bin/game.rom +.PHONY: clean cleanall docs libs game clean: - rm -f ./bin/game.rom make -C src/ubox clean make -C src/spman clean make -C src/mplayer clean diff --git a/game/src/Makefile b/game/src/Makefile index 1045b41..32354fd 100644 --- a/game/src/Makefile +++ b/game/src/Makefile @@ -20,7 +20,7 @@ LDFLAGS = -L../../lib -L. --no-std-crt0 --fomit-frame-pointer all: $(OUTPUT)/$(TARGET).rom @../../tools/chksize 8000 4000 $(OUTPUT)/$(TARGET).map - cp ../bin/$(TARGET).rom ../../bin + @cp ../bin/$(TARGET).rom ../../bin openmsx: all openmsx -carta $(OUTPUT)/$(TARGET).rom -machine msx1 @@ -32,17 +32,18 @@ $(OUTPUT)/%.rel: %.z80 $(AS) -g -o $@ $< $(OUTPUT)/akm.rel: akm.z80 song.asm effects.asm - ../../bin/rasm akm.z80 -o $(OUTPUT)/akm -s -sl -sq + rasm akm.z80 -o $(OUTPUT)/akm -s -sl -sq Disark --sourceProfile sdcc --symbolFile $(OUTPUT)/akm.sym --src16bitsValuesInHex --src8bitsValuesInHex --undocumentedOpcodesToBytes $(OUTPUT)/akm.bin $(OUTPUT)/akm_sdcc.asm $(AS) -g -o $@ $(OUTPUT)/akm_sdcc.asm $(OUTPUT)/$(TARGET).rom: $(OBJS) $(OUTPUT)/crt0.rel $(UBOX_LIBS) $(CC) $(CFLAGS) $(LDFLAGS) $(LIBS) --code-loc $(CODE) --data-loc $(DATA) $(OUTPUT)/crt0.rel $(OBJS) -o $(OUTPUT)/$(TARGET).ihx - ../../bin/hex2bin -e bin -p 00 -l $(ROM_MAX) $(OUTPUT)/$(TARGET).ihx - mv $(OUTPUT)/$(TARGET).bin ../bin/$(TARGET).rom + hex2bin -e bin -p 00 -l $(ROM_MAX) $(OUTPUT)/$(TARGET).ihx + @cp $(OUTPUT)/$(TARGET).bin ../bin/$(TARGET).rom clean: rm -f $(OUTPUT)/* + rm -f ../bin/$(TARGET).rom ../../bin/$(TARGET).rom .PHONY: all clean -- cgit v1.2.3