CC=g++ CFLAGS=-c -Wall -std=gnu++11 -I include EXE=hr SRC=$(wildcard ./*.cc) OBJ=$(addprefix obj/, $(SRC:.cc=.o)) all: $(EXE) $(EXE): $(OBJ) $(CC) $(OBJ) -o $@ obj/%.o: %.cc $(CC) $(CFLAGS) -o $@ $< clean: rm -rf $(EXE) $(OBJ)