From: Mike D. Lowis Date: Wed, 25 Apr 2012 20:59:23 +0000 (-0400) Subject: Seperated test and release compiler options so that warnings in UnitTest++ don't... X-Git-Url: https://git.mdlowis.com/?a=commitdiff_plain;h=2daf1ec5acb55e32616239f11b9a176e5685c606;p=archive%2Fdlang.git Seperated test and release compiler options so that warnings in UnitTest++ don't fail the builds --- diff --git a/Makefile b/Makefile index 357a86f..f0b1e0c 100644 --- a/Makefile +++ b/Makefile @@ -53,7 +53,8 @@ INC_DIRS = $(call incdirs, $(SRC_ROOT)) \ # Compiler and Linker Options #---------------------------- -CXXFLAGS = $(INC_DIRS) -Wall -Werror +CXXFLAGS = -c $(INC_DIRS) -Wall -Werror +TEST_CXXFLAGS = -c $(INC_DIRS) -Wall # Build Rules #------------ @@ -66,10 +67,10 @@ test: $(TEST_RUNNER) # Binaries $(PROJ_NAME): parseutils $(SRC_OBJS) - $(CXX) $(CXX_FLAGS) -o $@ $(SRC_OBJS) $(LIBS) + $(CXX) -o $@ $(SRC_OBJS) $(LIBS) $(TEST_RUNNER): parseutils unit_test_pp $(SRC_OBJS) $(TEST_OBJS) - $(CXX) $(CXX_FLAGS) -o $@ $(filter-out source/main.o,$(SRC_OBJS)) $(TEST_OBJS) $(TEST_LIBS) + $(CXX) -o $@ $(filter-out source/main.o,$(SRC_OBJS)) $(TEST_OBJS) $(TEST_LIBS) # Libraries parseutils: @@ -80,8 +81,10 @@ unit_test_pp: # Object Files $(SRC_OBJS): %.o : %.$(SRC_EXT) + $(CXX) $(CXXFLAGS) -o $@ $< $(TEST_OBJS): %.o : %.$(TEST_EXT) + $(CXX) $(TEST_CXXFLAGS) -o $@ $< # Cleanup clean: