principia/utils/featured-list-creator/Makefile
ROllerozxa 66923575b4 Merge in featured-list-creator into utils/
Originally a C program (previously Python script) at https://github.com/principia-game/featured-list-creator for creating fl.cache files for the community site, merge into the main repository so it is with all the other util programs.
2026-06-02 00:31:44 +02:00

27 lines
468 B
Makefile

BIN = ../bin
PRINCIPIA = ../..
PROGRAM = featured-list-creator
SRCS := main.c
# always static unless you do STATIC=0
STATIC ?= 1
CC ?= gcc
CFLAGS ?= -O2 -ffunction-sections -fdata-sections
LDFLAGS ?= -Wl,--gc-sections
ifeq ($(STATIC),1)
LDFLAGS += -l:libjansson.a
else
LDFLAGS += -ljansson
endif
all: $(BIN)/$(PROGRAM)
$(BIN)/$(PROGRAM): $(SRCS)
@mkdir -p $(BIN)
$(CC) $(CFLAGS) $(INCLUDES) -o $@ $^ $(LDFLAGS)
clean:
rm $(BIN)/$(PROGRAM)
.PHONY: all clean