Skip to content
Snippets Groups Projects
Commit 6e99de56 authored by Pascal Palenda's avatar Pascal Palenda
Browse files

Add check for CPM in index file

parent 55bb9d40
Branches
No related tags found
No related merge requests found
cmake_minimum_required (VERSION 3.20 FATAL_ERROR)
include_guard ()
# Check for CPM
file (GLOB CPM_MODULE_LOCATION ${CMAKE_BINARY_DIR}/cmake/CPM*.cmake)
if (NOT (EXISTS ${CPM_MODULE_LOCATION}))
set (CPM_DOWNLOAD_VERSION 0.37.0)
set (CPM_MODULE_LOCATION "${CMAKE_BINARY_DIR}/cmake/CPM_${CPM_DOWNLOAD_VERSION}.cmake")
if (NOT (EXISTS ${CPM_MODULE_LOCATION}))
message (STATUS "Downloading CPM.cmake")
file (DOWNLOAD https://github.com/TheLartians/CPM.cmake/releases/download/v${CPM_DOWNLOAD_VERSION}/CPM.cmake
${CPM_MODULE_LOCATION}
)
endif (NOT (EXISTS ${CPM_MODULE_LOCATION}))
endif ()
include (${CPM_MODULE_LOCATION})
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment