diff --git a/makefile b/makefile index 16bb52b..9d4ba42 100644 --- a/makefile +++ b/makefile @@ -1,14 +1,16 @@ +FLAGS=-O2 -ffunction-sections -Wl,--gc-sections,--strip-all -fno-asynchronous-unwind-tables + default: $(shell mkdir -p bin) library test library: tinyss.cpp tinyss.hpp token.hpp - g++ -c tinyss.cpp -o bin/tinyss.o + g++ -c tinyss.cpp -o bin/tinyss.o $(FLAGS) ar r bin/libtinyss.a bin/tinyss.o rm -f bin/tinyss.o cp tinyss.hpp bin/tinyss.hpp cp token.hpp bin/token.hpp test: bin/libtinyss.a test.cpp - g++ test.cpp -o bin/test -Lbin -ltinyss + g++ test.cpp -o bin/test -Lbin -ltinyss $(FLAGS) clean: - rm -f $(wildcard bin/*) \ No newline at end of file + rm -f $(wildcard bin/*)