From c92a6a5eb7cd809809eacfba0c7c181167aa8187 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Wed, 22 Feb 2017 20:34:51 -0500 Subject: [PATCH] CMakeLists: Change set into a list append Same thing, less repetition. Also puts quotes around the added path to correctly handle any spaces in paths. --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2b3b398a..9f2fc89c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -29,8 +29,8 @@ if ("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_BINARY_DIR}") message(SEND_ERROR "In-source builds are not allowed.") endif() -# Signify where the module directories are -set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/CMakeModules) +# Add the module directory to the list of paths +list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/CMakeModules") # Compiler flags if (MSVC)