Do not unconditionally profile (that was a miscommit). Instead, make a PROFILE=1...
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 12 Oct 2012 20:47:41 +0000 (22:47 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 12 Oct 2012 20:47:41 +0000 (22:47 +0200)
Makefile

index 0bfad1f..c71b8f3 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -2,10 +2,15 @@ GTEST_DIR = /usr/src/gtest
 
 CC=gcc
 CXX=g++
-CXXFLAGS=-Wall -g -I$(GTEST_DIR)/include $(shell pkg-config --cflags eigen3 ) -fprofile-arcs -ftest-coverage
-LDFLAGS=-lSDL -lSDL_image -lGL -lrt -lpthread -fprofile-arcs -ftest-coverage
+CXXFLAGS=-Wall -g -I$(GTEST_DIR)/include $(shell pkg-config --cflags eigen3 )
+LDFLAGS=-lSDL -lSDL_image -lGL -lrt -lpthread
 RANLIB=ranlib
 
+ifeq ($(PROFILE),1)
+CXXFLAGS += -fprofile-arcs -ftest-coverage
+LDFLAGS += -fprofile-arcs -ftest-coverage
+endif
+
 DEMO_OBJS=demo.o
 TESTS=effect_chain_test mix_effect_test gamma_expansion_effect_test