From ddb57cb49a60b6173712341940195e0275ef1c9d Mon Sep 17 00:00:00 2001 From: Tom Smeding Date: Wed, 8 Aug 2018 22:58:13 +0200 Subject: Haskell solver that uses rules --- Makefile | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index ef6cc85..89c0b26 100644 --- a/Makefile +++ b/Makefile @@ -1,24 +1,14 @@ CXX = g++ -CXXFLAGS = -Wall -Wextra -std=c++11 -fwrapv -g -ifneq ($(DEBUG),) - CXXFLAGS += -g -else - CXXFLAGS += -O2 -endif -BIN = solve +CXXFLAGS = -Wall -Wextra -std=c++11 -fwrapv -O2 +CXXTARGETS = solve solve2 .PHONY: all clean remake -all: $(BIN) +all: $(CXXTARGETS) clean: - rm -rf $(BIN) *.o *.dSYM + rm -rf $(CXXTARGETS) *.o *.dSYM -remake: clean all - -$(BIN): $(patsubst %.cpp,%.o,$(wildcard *.cpp)) - $(CXX) -o $@ $^ - -%.o: %.cpp $(wildcard *.h) - $(CXX) $(CXXFLAGS) -c -o $@ $< +$(CXXTARGETS): %: %.cpp + $(CXX) $(CXXFLAGS) -o $@ $^ -- cgit v1.2.3-70-g09d2