Skip to content

Commit

Permalink
change cmake debug settings to be more global
Browse files Browse the repository at this point in the history
  • Loading branch information
kylefleming committed Nov 5, 2015
1 parent d4e1b5e commit 0e170d2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ valgrind:
.PHONY : valgrind

lldb:
@true @$(eval DEBUGGER = lldb -o "breakpoint set -n cereal::RapidJSONException -n std::out_of_range" -o "r")
@true @$(eval DEBUGGER = lldb -o "breakpoint set -n cereal::RapidJSONException -n std::out_of_range -n std::runtime_error" -o "r")
@true @$(eval PARAMS = --nothrow)
.PHONY : lldb

Expand All @@ -20,7 +20,7 @@ mkdir:
.PHONY : mkdir

cmake: mkdir
@cd $(BUILD_DIR) && cmake ..
@cd $(BUILD_DIR) && cmake -DCMAKE_BUILD_TYPE=Debug ..
.PHONY : cmake

compile:
Expand Down
4 changes: 3 additions & 1 deletion engine/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,11 @@ include_directories(SYSTEM ${Boost_INCLUDE_DIRS})
include_directories(SYSTEM ${LIB_HEADER_DIRS})
include_directories(${HEADER_DIRS})

set(CMAKE_BUILD_TYPE Debug)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O0")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -O0")

add_library(SymmetryEngine STATIC ${SRCS})

target_include_directories(SymmetryEngine SYSTEM PUBLIC ${CPM_INCLUDE_DIRS})
Expand Down
2 changes: 2 additions & 0 deletions engine/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ ENDMACRO()
set(CMAKE_BUILD_TYPE Debug)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O0")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -O0")

if (NOT TARGET SymmetryEngine)
add_subdirectory(".." "${CMAKE_CURRENT_BINARY_DIR}/engine")
Expand Down

0 comments on commit 0e170d2

Please sign in to comment.