1 CC := gcc 2 CLIBS := `sdl2-config --libs` -lSDL2_ttf -lm 3 CFLAGS := `sdl2-config --cflags` -Wall -Wshadow -pedantic -ansi -std=c99 4 SRCS := $(wildcard *.c) 5 OBJS := $(SRCS:.c=.o) 6 7 TARGET := menu 8 9 .PHONY: all clean 10 11 $(TARGET): $(OBJS) $(HEADERS) 12 $(CC) $(CLIBS) $(CFLAGS) -o $@ $^ 13 14 %.o: %.c 15 $(CC) $(CLIBS) $(CFLAGS) -c $< -o $@ 16 17 clean: 18 rm -f $(OBJS)