21 lines
403 B
Makefile
21 lines
403 B
Makefile
|
|
CFLAGS = -std=c23
|
|
CFLAGS += -fsanitize=address,undefined -g
|
|
CFLAGS += -Wall -Wextra -Wpedantic -Wconversion -pedantic -pedantic-errors
|
|
|
|
LFLAGS = -lm
|
|
|
|
CFLAGS += $(shell pkg-config sdl2 --cflags)
|
|
LFLAGS += $(shell pkg-config sdl2 --libs)
|
|
|
|
CFILES = $(shell find . -name "*.c")
|
|
HFILES = $(shell find . -name "*.h")
|
|
|
|
game: $(CFILES) $(HFILES)
|
|
gcc -o $@ $(CFILES) $(CFLAGS) $(LFLAGS)
|
|
|
|
clean:
|
|
rm -rf game
|
|
|
|
|