1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2024-11-11 03:39:59 +00:00
oot/tools/Makefile
Tharo 208167361b
Poe Objects (#743)
* poe objects

* Last unaccounted resolved, name suffix fixes

* remove _tex

* missed 2

* format

Co-authored-by: Fig02 <fig02srl@gmail.com>
2021-04-04 23:48:12 +02:00

28 lines
659 B
Makefile

CC := gcc
CFLAGS := -Wall -Wextra -pedantic -std=c99 -g -O2
PROGRAMS := yaz0 makeromfs elf2rom mkldscript vtxdis
ZAPD := ZAPD/ZAPD.out
all: $(PROGRAMS)
cd ZAPD && $(MAKE)
clean:
$(RM) $(PROGRAMS) $(addsuffix .exe,$(PROGRAMS))
$(MAKE) -C ZAPD clean
distclean: clean
.PHONY: all clean distclean
mkldscript_SOURCES := mkldscript.c util.c
elf2rom_SOURCES := elf2rom.c elf32.c n64chksum.c util.c
yaz0_SOURCES := yaz0tool.c yaz0.c util.c
makeromfs_SOURCES := makeromfs.c n64chksum.c util.c
vtxdis_SOURCES := vtxdis.c
define COMPILE =
$(1): $($1_SOURCES)
$(CC) $(CFLAGS) $$^ -o $$@
endef
$(foreach p,$(PROGRAMS),$(eval $(call COMPILE,$(p))))