summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile11
-rwxr-xr-x[-rw-r--r--]build_tools.sh0
2 files changed, 8 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 320a36ba1..26993020d 100644
--- a/Makefile
+++ b/Makefile
@@ -44,14 +44,16 @@ SCANINC := tools/scaninc/scaninc
PREPROC := tools/preproc/preproc
RAMSCRGEN := tools/ramscrgen/ramscrgen
-# Clear the default suffixes.
+# Clear the default suffixes
.SUFFIXES:
+# Don't delete intermediate files
+.SECONDARY:
+# Delete files that weren't built properly
+.DELETE_ON_ERROR:
# Secondary expansion is required for dependency variables in object rules.
.SECONDEXPANSION:
-.PRECIOUS: %.1bpp %.4bpp %.8bpp %.gbapal %.lz %.rl %.pcm %.bin sound/direct_sound_samples/cry_%.bin
-
.PHONY: rom clean compare tidy
$(shell mkdir -p $(C_BUILDDIR) $(ASM_BUILDDIR) $(DATA_ASM_BUILDDIR) $(SONG_BUILDDIR))
@@ -167,3 +169,6 @@ $(ELF): $(OBJ_DIR)/ld_script.ld $(OBJS)
$(ROM): $(ELF)
$(OBJCOPY) -O binary --gap-fill 0xFF --pad-to 0x9000000 $< $@
+
+baserom.gba: ;
+ $(error baserom.gba is required to build)
diff --git a/build_tools.sh b/build_tools.sh
index f4656e2d8..f4656e2d8 100644..100755
--- a/build_tools.sh
+++ b/build_tools.sh