.Phony : all
all : move_lib_tests move_game

.PHONY : clean
clean :
	rm -fv *~ *.o move_lib_tests move_game

# $< is the first dependency
# $^ is all the dependencies
# $@ is the target

.cpp.o :
	g++ $< -c -Wall -std=c++11 -o $@

move_lib_tests : move_lib.o move_lib_tests.o
	g++ $^ -lgtest -lgtest_main -lpthread  -o $@

move_game : move_main.o move_lib.o
	g++ $^ -o $@


