Browse Source
[cmake] submodules: only add to CPMUtil if git exists
Signed-off-by: crueter <crueter@eden-emu.dev>
pull/250/head
crueter
7 months ago
committed by
crueter
No known key found for this signature in database
GPG Key ID: 425ACD2D4830EBC6
1 changed files with
25 additions and
24 deletions
-
CMakeLists.txt
|
|
|
@ -268,7 +268,7 @@ function(check_submodules_present) |
|
|
|
message(FATAL_ERROR "Git submodule ${module} not found. " |
|
|
|
"Please run: \ngit submodule update --init --recursive") |
|
|
|
endif() |
|
|
|
|
|
|
|
if (EXISTS "${PROJECT_SOURCE_DIR}/${module}/.git") |
|
|
|
set(SUBMODULE_DIR "${PROJECT_SOURCE_DIR}/${module}") |
|
|
|
|
|
|
|
execute_process( |
|
|
|
@ -292,6 +292,7 @@ function(check_submodules_present) |
|
|
|
set_property(GLOBAL APPEND PROPERTY CPM_PACKAGE_NAMES ${SUBMODULE_NAME}) |
|
|
|
set_property(GLOBAL APPEND PROPERTY CPM_PACKAGE_SHAS ${SUBMODULE_SHA}) |
|
|
|
set_property(GLOBAL APPEND PROPERTY CPM_PACKAGE_URLS ${SUBMODULE_URL}) |
|
|
|
endif() |
|
|
|
endforeach() |
|
|
|
endfunction() |
|
|
|
|
|
|
|
|