From bd0bfc3aef9938f5c9ab9134d97ef0725ec90ee3 Mon Sep 17 00:00:00 2001 From: vargheseg <vargheseg@users.noreply.github.com> Date: Wed, 20 Feb 2019 11:31:27 +0100 Subject: [PATCH] Bugfix: enclose CMAKE_BUILD_TYPE in quotes; this transforms it into an wmpty string and the string command wont complain that its missing an argument when CMAKE_BUILD_TYPE is not set. --- cmake/enable_code_coverage_report.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/enable_code_coverage_report.cmake b/cmake/enable_code_coverage_report.cmake index 6f3db2b..bd1b5c4 100644 --- a/cmake/enable_code_coverage_report.cmake +++ b/cmake/enable_code_coverage_report.cmake @@ -30,7 +30,7 @@ set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O0 --coverage") # The make coverage command is only available in debug mode. Also # factor in that cmake treats CMAKE_BUILD_TYPE string as case # insensitive. -string(TOUPPER ${CMAKE_BUILD_TYPE} build_type_uppercase) +string(TOUPPER "${CMAKE_BUILD_TYPE}" build_type_uppercase) IF(build_type_uppercase STREQUAL "DEBUG") configure_file(cmake/make_coverage.sh.in ${PROJECT_BINARY_DIR}/make_coverage.sh @ONLY) -- GitLab