game/tetris/Makefile

19 lines
394 B
Makefile
Raw Normal View History

2020-09-11 12:29:06 +00:00
CXX ?= g++
CFLAGS ?= -O2 -Wall -Wextra -g
PREFIX ?= /usr/local/bin
LDFLAGS ?= -lSDL2 -lSDL2_image -lSDL2_gfx -lSDL2_ttf -pthread
.PHONY: default
default: tetris
tetris: tetris.o sdlpp.o
$(CXX) $(CFLAGS) -o $@ $^ ${LDFLAGS}
sdlpp.o: ../sdlpp.cpp ../sdlpp.hpp
$(CXX) $(CFLAGS) -c -o $@ $<
2020-09-11 13:05:41 +00:00
tetris.o: tetris.cpp ../sdlpp.hpp config.hpp
2020-09-11 12:29:06 +00:00
$(CXX) $(CFLAGS) -c -o $@ $<
clean:
rm -Rf *.o tetris