From f58cbd728143f14633b9ad1f8adcdd74fce19980 Mon Sep 17 00:00:00 2001 From: Konstantinos Sideris Date: Sat, 6 Oct 2018 17:45:56 +0300 Subject: [PATCH] Remove debug logs from Windows builds --- CMakeLists.txt | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 45134632..701e8610 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -122,10 +122,15 @@ else(NOT (CMAKE_BUILD_TYPE OR CMAKE_CONFIGURATION_TYPES)) message("Build type set to '${CMAKE_BUILD_TYPE}'") endif(NOT (CMAKE_BUILD_TYPE OR CMAKE_CONFIGURATION_TYPES)) -if(${CMAKE_BUILD_TYPE} STREQUAL "Debug") - set(SPDLOG_DEBUG_ON true) -else() - set(SPDLOG_DEBUG_ON false) +set(SPDLOG_DEBUG_ON false) + +# Windows doesn't handle CMAKE_BUILD_TYPE. +if(NOT WIN32) + if(${CMAKE_BUILD_TYPE} STREQUAL "Debug") + set(SPDLOG_DEBUG_ON true) + else() + set(SPDLOG_DEBUG_ON false) + endif() endif() find_program(GIT git)