[all] cmake: tell users to clone submodules when they haven't

This gives users a command to run that will automagically fix the submodule
situation, and should reduce the amount of support requests.
This commit is contained in:
Quantum
2021-08-18 18:02:33 -04:00
committed by Geoffrey McRae
parent 1021c9ce92
commit 5a906131eb
4 changed files with 11 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
if (EXISTS "${PROJECT_TOP}/.git" AND (
(NOT EXISTS "${PROJECT_TOP}/repos/cimgui/.git") OR
(NOT EXISTS "${PROJECT_TOP}/repos/LGMP/.git") OR
(NOT EXISTS "${PROJECT_TOP}/repos/PureSpice/.git") OR
(NOT EXISTS "${PROJECT_TOP}/repos/cimgui/imgui/.git")
))
message(FATAL_ERROR "Submodules are not initialized. Run\n\tgit submodule update --init --recursive")
endif()