You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-04-09 05:44:44 -07:00
Build Australian Crystal.
This commit is contained in:
17
Makefile
17
Makefile
@@ -1,4 +1,4 @@
|
||||
roms := pokecrystal.gbc pokecrystal11.gbc
|
||||
roms := pokecrystal.gbc pokecrystal11.gbc pokecrystal-au.gbc
|
||||
|
||||
crystal_obj := \
|
||||
audio.o \
|
||||
@@ -17,6 +17,7 @@ gfx/sprites.o \
|
||||
lib/mobile/main.o
|
||||
|
||||
crystal11_obj := $(crystal_obj:.o=11.o)
|
||||
crystal_au_obj := $(crystal_obj:.o=_au.o)
|
||||
|
||||
|
||||
### Build tools
|
||||
@@ -37,7 +38,7 @@ RGBLINK ?= $(RGBDS)rgblink
|
||||
### Build targets
|
||||
|
||||
.SUFFIXES:
|
||||
.PHONY: all crystal crystal11 clean tidy compare tools
|
||||
.PHONY: all crystal crystal11 crystal_au clean tidy compare tools
|
||||
.SECONDEXPANSION:
|
||||
.PRECIOUS:
|
||||
.SECONDARY:
|
||||
@@ -45,15 +46,16 @@ RGBLINK ?= $(RGBDS)rgblink
|
||||
all: crystal
|
||||
crystal: pokecrystal.gbc
|
||||
crystal11: pokecrystal11.gbc
|
||||
crystal-au: pokecrystal-au.gbc
|
||||
|
||||
clean:
|
||||
rm -f $(roms) $(crystal_obj) $(crystal11_obj) $(roms:.gbc=.map) $(roms:.gbc=.sym)
|
||||
rm -f $(roms) $(crystal_obj) $(crystal11_obj) $(crystal_au_obj) $(roms:.gbc=.map) $(roms:.gbc=.sym)
|
||||
find gfx \( -name "*.[12]bpp" -o -name "*.lz" -o -name "*.gbcpal" \) -delete
|
||||
find gfx/pokemon -mindepth 1 ! -path "gfx/pokemon/unown/*" \( -name "bitmask.asm" -o -name "frames.asm" -o -name "front.animated.tilemap" -o -name "front.dimensions" \) -delete
|
||||
$(MAKE) clean -C tools/
|
||||
|
||||
tidy:
|
||||
rm -f $(roms) $(crystal_obj) $(crystal11_obj) $(roms:.gbc=.map) $(roms:.gbc=.sym)
|
||||
rm -f $(roms) $(crystal_obj) $(crystal11_obj) $(crystal_au_obj) $(roms:.gbc=.map) $(roms:.gbc=.sym)
|
||||
$(MAKE) clean -C tools/
|
||||
|
||||
compare: $(roms)
|
||||
@@ -65,6 +67,7 @@ tools:
|
||||
|
||||
$(crystal_obj): RGBASMFLAGS = -D _CRYSTAL
|
||||
$(crystal11_obj): RGBASMFLAGS = -D _CRYSTAL -D _CRYSTAL11
|
||||
$(crystal_au_obj): RGBASMFLAGS = -D _CRYSTAL -D _CRYSTAL11 -D _CRYSTAL_AU
|
||||
|
||||
# The dep rules have to be explicit or else missing files won't be reported.
|
||||
# As a side effect, they're evaluated immediately instead of when the rule is invoked.
|
||||
@@ -80,6 +83,7 @@ ifeq (,$(filter clean tools,$(MAKECMDGOALS)))
|
||||
|
||||
$(info $(shell $(MAKE) -C tools))
|
||||
|
||||
$(foreach obj, $(crystal_au_obj), $(eval $(call DEP,$(obj),$(obj:_au.o=.asm))))
|
||||
$(foreach obj, $(crystal11_obj), $(eval $(call DEP,$(obj),$(obj:11.o=.asm))))
|
||||
$(foreach obj, $(crystal_obj), $(eval $(call DEP,$(obj),$(obj:.o=.asm))))
|
||||
|
||||
@@ -96,6 +100,11 @@ pokecrystal11.gbc: $(crystal11_obj) pokecrystal.link
|
||||
$(RGBFIX) -Cjv -i BYTE -k 01 -l 0x33 -m 0x10 -n 1 -p 0 -r 3 -t PM_CRYSTAL $@
|
||||
tools/sort_symfile.sh pokecrystal11.sym
|
||||
|
||||
pokecrystal-au.gbc: $(crystal_au_obj) pokecrystal.link
|
||||
$(RGBLINK) -n pokecrystal-au.sym -m pokecrystal-au.map -l pokecrystal.link -o $@ $(crystal_au_obj)
|
||||
$(RGBFIX) -Cjv -i BYTU -k 01 -l 0x33 -m 0x10 -p 0 -r 3 -t PM_CRYSTAL $@
|
||||
tools/sort_symfile.sh pokecrystal-au.sym
|
||||
|
||||
|
||||
# For files that the compressor can't match, there will be a .lz file suffixed with the md5 hash of the correct uncompressed file.
|
||||
# If the hash of the uncompressed file matches, use this .lz instead.
|
||||
|
Reference in New Issue
Block a user