diff --git a/cmake/CPM.cmake b/cmake/CPM.cmake index 2bd2def..cc4418b 100644 --- a/cmake/CPM.cmake +++ b/cmake/CPM.cmake @@ -41,6 +41,9 @@ It is recommended to upgrade CPM to the most recent version. \ See https://github.com/TheLartians/CPM.cmake for more information." ) endif() + if(${CMAKE_VERSION} VERSION_LESS "3.17.0") + include(FetchContent) + endif() return() endif() @@ -133,7 +136,10 @@ include(CMakeParseArguments) # Initialize logging prefix if(NOT CPM_INDENT) - set(CPM_INDENT "CPM:") + set(CPM_INDENT + "CPM:" + CACHE INTERNAL "" + ) endif() function(cpm_find_package NAME VERSION)