2016-04-03 07:14:54 +08:00
|
|
|
CXX ?= g++
|
2016-09-18 07:28:41 +08:00
|
|
|
CXXFLAGS = -march=native -Wall -Wextra -pedantic -std=c++11 -pthread -I../include
|
2016-04-03 07:14:54 +08:00
|
|
|
CXX_RELEASE_FLAGS = -O3 -flto -DNDEBUG
|
|
|
|
|
|
|
|
|
2018-06-01 22:50:59 +08:00
|
|
|
binaries=bench spdlog-null-async
|
2016-04-03 07:14:54 +08:00
|
|
|
|
|
|
|
all: $(binaries)
|
|
|
|
|
2018-06-01 22:50:59 +08:00
|
|
|
bench: bench.cpp
|
|
|
|
$(CXX) bench.cpp -o bench $(CXXFLAGS) $(CXX_RELEASE_FLAGS)
|
2016-04-03 07:14:54 +08:00
|
|
|
|
2016-09-18 06:51:53 +08:00
|
|
|
spdlog-null-async: spdlog-null-async.cpp
|
|
|
|
$(CXX) spdlog-null-async.cpp -o spdlog-null-async $(CXXFLAGS) $(CXX_RELEASE_FLAGS)
|
2018-06-01 22:50:59 +08:00
|
|
|
|
2016-09-18 06:51:53 +08:00
|
|
|
|
2018-03-21 21:46:52 +08:00
|
|
|
|
2016-04-03 07:14:54 +08:00
|
|
|
.PHONY: clean
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.o logs/* $(binaries)
|
|
|
|
|
|
|
|
rebuild: clean all
|