makefile 677 Bytes
Newer Older
gabime's avatar
gabime committed
1
CXX	= g++
gabime's avatar
gabime committed
2
CXXFLAGS	= -march=native -Wall -Wextra -Wshadow -pedantic -std=c++11 -pthread -I../include 
gabime's avatar
gabime committed
3
CXX_RELEASE_FLAGS = -O3 -flto
gabime's avatar
gabime committed
4 5 6
CXX_DEBUG_FLAGS= -g 


gabime's avatar
gabime committed
7 8 9 10 11 12 13 14
all:	example bench
debug: example-debug bench-debug

example: example.cpp
	$(CXX) example.cpp -o example $(CXXFLAGS) $(CXX_RELEASE_FLAGS)

bench: bench.cpp
	$(CXX) bench.cpp -o bench $(CXXFLAGS) $(CXX_RELEASE_FLAGS)
gabime's avatar
gabime committed
15 16
	

gabime's avatar
gabime committed
17 18 19 20 21
example-debug: example.cpp
	$(CXX) example.cpp -o example-debug $(CXXFLAGS) $(CXX_DEBUG_FLAGS)
	
bench-debug: bench.cpp
	$(CXX) bench.cpp -o bench-debug $(CXXFLAGS) $(CXX_DEBUG_FLAGS)	
gabime's avatar
gabime committed
22 23 24 25



clean:
gabime's avatar
gabime committed
26
	rm -f *.o *.txt example example-debug bench bench-debug 
gabime's avatar
gabime committed
27 28


gabime's avatar
gabime committed
29 30 31 32
rebuild: clean all
rebuild-debug: clean debug