2023-11-11 09:51:04 +00:00
|
|
|
# This controls building executables in the `tools` folder.
|
|
|
|
# Can be invoked through the `Makefile` or standalone.
|
2021-06-02 00:40:11 +00:00
|
|
|
|
2021-06-02 03:22:15 +00:00
|
|
|
MAKEFLAGS += --no-print-directory
|
|
|
|
|
2023-02-25 19:48:16 +00:00
|
|
|
# Inclusive list. If you don't want a tool to be built, don't add it here.
|
2023-11-11 09:51:04 +00:00
|
|
|
TOOLS_DIR := tools
|
|
|
|
TOOL_NAMES := aif2pcm bin2c gbafix gbagfx jsonproc mapjson mid2agb preproc ramscrgen rsfont scaninc
|
2021-06-02 00:40:11 +00:00
|
|
|
|
2023-11-11 09:51:04 +00:00
|
|
|
TOOLDIRS := $(TOOL_NAMES:%=$(TOOLS_DIR)/%)
|
2021-06-02 00:40:11 +00:00
|
|
|
|
2023-11-12 00:20:09 +00:00
|
|
|
# Tool making doesnt require a pokeemerald dependency scan.
|
|
|
|
RULES_NO_SCAN += tools check-tools clean-tools $(TOOLDIRS) $(CHECKTOOLDIRS)
|
|
|
|
.PHONY: $(RULES_NO_SCAN)
|
2023-11-11 09:51:04 +00:00
|
|
|
|
|
|
|
tools: $(TOOLDIRS)
|
|
|
|
check-tools: $(CHECKTOOLDIRS)
|
2021-06-02 00:40:11 +00:00
|
|
|
|
|
|
|
$(TOOLDIRS):
|
|
|
|
@$(MAKE) -C $@
|
2023-11-11 09:51:04 +00:00
|
|
|
|
|
|
|
$(CHECKTOOLDIRS):
|
|
|
|
@$(MAKE) -C $@
|
|
|
|
|
|
|
|
clean-tools:
|
|
|
|
@$(foreach tooldir,$(TOOLDIRS),$(MAKE) clean -C $(tooldir);)
|