diff --git a/CMakeLists.txt b/CMakeLists.txt index f320646..bd71da6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -38,8 +38,12 @@ set(LIB_ROOT ${DEPENDENCIES_ROOT}/lib/${SYSTEM_LIB_PATH}) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${LIB_ROOT}) #for SHARED set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${LIB_ROOT}) #for STATIC +if(CMAKE_BUILD_TYPE MATCHES "Debug") + set(CPP_DEFINES -DRENDER_DEBUG) +endif() + add_library(${LIBRARY_NAME} STATIC ${LIB_SRC_LIST}) -add_definitions(-std=c++11) +add_definitions(-std=c++11 ${CPP_DEFINES}) include_directories( ${INCLUDE_ROOT} diff --git a/glassert.h b/glassert.h index 3153cca..4be8ad0 100644 --- a/glassert.h +++ b/glassert.h @@ -10,6 +10,7 @@ #include #include +#ifdef RENDER_DEBUG #define STR(x) #x #define glAssert(code) \ code; \ @@ -19,6 +20,9 @@ std::cerr<<"Erreur OpenGL ("<<__FILE__<<":"<<__LINE__<<", "<