From 7a4b2347fb3f9f67f4bc37fe38d95881ffb68813 Mon Sep 17 00:00:00 2001 From: mlangkabel Date: Tue, 19 Nov 2019 16:52:05 +0100 Subject: [PATCH] build: fix build errors on windows * fix compiler issue where string was returned instead of wstring * fix boost caching in CMakeList: for CMake 3.12.2 the "set" command requires a docstring if the CACHE flag is set --- CMakeLists.txt | 2 +- src/lib_utility/utility/utilityString.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 294b9182..8cc92bc4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -99,7 +99,7 @@ endif() # Boost ------------------------------------------------------------------------ set(Boost_USE_MULTITHREAD ON) -set(Boost_USE_STATIC_LIBS ON CACHE BOOL) +set(Boost_USE_STATIC_LIBS ON CACHE BOOL "Set to ON to force the use of the static libraries.") set(Boost_USE_STATIC_RUNTIME OFF) find_package(Boost 1.68 COMPONENTS system program_options filesystem date_time REQUIRED) diff --git a/src/lib_utility/utility/utilityString.cpp b/src/lib_utility/utility/utilityString.cpp index 807fef27..2fed84c9 100644 --- a/src/lib_utility/utility/utilityString.cpp +++ b/src/lib_utility/utility/utilityString.cpp @@ -602,7 +602,7 @@ std::wstring elide(const std::wstring& str, ElideMode mode, size_t size) return str.substr(0, size - 3) + L"..."; } - return ""; + return L""; } std::wstring convertWhiteSpacesToSingleSpaces(const std::wstring& str)