diff options
author | Juan J. Martinez <jjm@usebox.net> | 2023-06-01 22:20:15 +0100 |
---|---|---|
committer | Juan J. Martinez <jjm@usebox.net> | 2023-06-01 22:20:15 +0100 |
commit | f66c2cf7a4d4f5fb4b533a79c2a1f92901a09d98 (patch) | |
tree | fd015daffb76ef30d11c527261fcbf024d907cd4 | |
parent | fdb53d106ef573cd63ea39a4f1f6b5116370e4c8 (diff) | |
download | gold-mine-run-f66c2cf7a4d4f5fb4b533a79c2a1f92901a09d98.tar.gz gold-mine-run-f66c2cf7a4d4f5fb4b533a79c2a1f92901a09d98.zip |
Convert PNG images automatically
-rw-r--r-- | src/Makefile | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/Makefile b/src/Makefile index a53c697..4852b93 100644 --- a/src/Makefile +++ b/src/Makefile @@ -3,8 +3,11 @@ CC := i586-pc-msdosdjgpp-gcc CFLAGS := -I. -c -Wall -pedantic -O2 -march=i386 LDFLAGS := -s +IMGS := $(wildcard ../data/*.png) +IMG_OBJS := $(IMGS:../data/%.png=%.o) + SRCS := $(wildcard *.c) -OBJS := $(SRCS:.c=.o) palette.o +OBJS := $(SRCS:.c=.o) $(IMG_OBJS) palette.o all: $(BIN) @@ -17,6 +20,9 @@ $(BIN): $(OBJS) palette.o: ../data/sprites.png ../tools/pngpal.py $< $@ +$(IMG_OBJS): %.o: ../data/%.png + ../tools/pngpix.py $< $@ + clean: rm -f $(BIN) *.o Makefile.deps |