Files
mk64/assets/include/onomatopoeia.mk
T
Tyler McGavran 1aa6824d33 Match the last 2 data files (#574)
* Match the last 2 data files

Signed-off-by: Taggerung <tyler.taggerung@email.com>

* Update one of the file names based on comments

Signed-off-by: Taggerung <tyler.taggerung@email.com>

* Fix bad path in onomatopoeia asset file

Signed-off-by: Taggerung <tyler.taggerung@email.com>

---------

Signed-off-by: Taggerung <tyler.taggerung@email.com>
Co-authored-by: Taggerung <tyler.taggerung@email.com>
2024-02-28 10:11:38 -05:00

40 lines
1.3 KiB
Makefile

ONOMATOPOEIA_DIR := assets/onomatopoeia
ONOMATOPOEIA_PALETTE := $(ONOMATOPOEIA_DIR)/gTLUTOnomatopoeia.png
ONOMATOPOEIA_PNG := \
$(ONOMATOPOEIA_DIR)/gTextureOnomatopoeiaCrash1.png \
$(ONOMATOPOEIA_DIR)/gTextureOnomatopoeiaCrash2.png \
$(ONOMATOPOEIA_DIR)/gTextureOnomatopoeiaWhrrrr1.png \
$(ONOMATOPOEIA_DIR)/gTextureOnomatopoeiaWhrrrr2.png \
$(ONOMATOPOEIA_DIR)/gTextureOnomatopoeiaPoomp1.png \
$(ONOMATOPOEIA_DIR)/gTextureOnomatopoeiaPoomp2.png \
$(ONOMATOPOEIA_DIR)/gTextureBalloon1.png \
$(ONOMATOPOEIA_DIR)/gTextureBalloon2.png
ONOMATOPOEIA_EXPORT_SENTINEL := $(ONOMATOPOEIA_DIR)/.export
$(BUILD_DIR)/$(DATA_DIR)/other_textures.o: $(ONOMATOPOEIA_PNG:%.png=%.mio0)
$(BUILD_DIR)/src/data/some_data.o: $(ONOMATOPOEIA_PALETTE:%.png=%.inc.c)
$(ONOMATOPOEIA_PNG:%.png=%.mio0): %.mio0 : %.bin
$(MIO0TOOL) -c $< $@
$(ONOMATOPOEIA_PNG:%.png=%.bin): %.bin : %.png
$(N64GRAPHICS) -Z $@ -g $< -s raw -f ci8 -c rgba16 -p $(ONOMATOPOEIA_PALETTE)
$(ONOMATOPOEIA_PALETTE:%.png=%.inc.c): %.inc.c : %.png
$(N64GRAPHICS) -i $@ -g $< -s u8 -f rgba16
$(ONOMATOPOEIA_PNG) $(ONOMATOPOEIA_PALETTE): $(ONOMATOPOEIA_EXPORT_SENTINEL) ;
$(ONOMATOPOEIA_EXPORT_SENTINEL): $(ASSET_DIR)/onomatopoeia.json
$(ASSET_EXTRACT) $(BASEROM) $<
$(TOUCH) $@
.PHONY: distclean_onomatopoeia
distclean_onomatopoeia:
rm -rf $(ONOMATOPOEIA_DIR)
distclean_assets: distclean_onomatopoeia