1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-10-14 02:08:27 +08:00

CMakePrintHelpers: Work around CACHE argument of set()

Fixes: #21919
This commit is contained in:
Kyle Edwards
2021-03-11 08:55:05 -05:00
parent 2da1a8f92d
commit bb9a701a2b

View File

@@ -101,7 +101,10 @@ function(cmake_print_properties)
if(CPP_CACHE_ENTRIES) if(CPP_CACHE_ENTRIES)
set(items ${CPP_CACHE_ENTRIES}) set(items ${CPP_CACHE_ENTRIES})
set(mode ${mode} CACHE_ENTRIES) set(mode ${mode} CACHE_ENTRIES)
set(keyword CACHE) # This is a workaround for the fact that passing `CACHE` as an argument to
# set() causes a cache variable to be set.
set(keyword "")
string(APPEND keyword CACHE)
endif() endif()
if(NOT mode) if(NOT mode)