diff --git a/Makefile b/Makefile index 0e8e64e..0e30b13 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,5 @@ CXX = g++ -CXXFLAGS = -Wall -Wextra -O3 --std=c++17 -DEVFLAGS = -g +CXXFLAGS = --std=c++17 RM = rm SOURCES = $(wildcard src/*.cpp) @@ -11,7 +10,13 @@ EXE = ecosysteme %.cpp.o: src/%.cpp $(CXX) -c -o $@ $< $(CXXFLAGS) $(DEVFLAGS) -main: $(OBJETS) +main: CXXFLAGS += -O3 +main: compilation + +debug: CXXFLAGS += -Wall -Wextra -Wshadow -Wnon-virtual-dtor -pedantic -g +debug: compilation + +compilation: $(OBJETS) $(CXX) -o $(EXE) $(OBJETS) all: