mirror of
https://github.com/cuberite/polarssl.git
synced 2025-09-24 05:00:45 -04:00
Merge pull request #9750 from Harry-Ramsey/improve-submodule-error-messages-3.6
[Backport 3.6] Improve submodule error messages for Github archives
This commit is contained in:
commit
07a9c676b2
@ -315,7 +315,11 @@ if(LIB_INSTALL_DIR)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/framework/CMakeLists.txt")
|
if (NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/framework/CMakeLists.txt")
|
||||||
message(FATAL_ERROR "${CMAKE_CURRENT_SOURCE_DIR}/framework/CMakeLists.txt not found. Run `git submodule update --init` from the source tree to fetch the submodule contents.")
|
if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/.git/")
|
||||||
|
message(FATAL_ERROR "${CMAKE_CURRENT_SOURCE_DIR}CMakeLists.txt not found (and does appear to be a git checkout). Run `git submodule update --init` from the source tree to fetch the submodule contents.")
|
||||||
|
else ()
|
||||||
|
message(FATAL_ERROR "${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt not found (and does not appear to be a git checkout). Please ensure you have downloaded the right archive from the release page on GitHub.")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
add_subdirectory(framework)
|
add_subdirectory(framework)
|
||||||
|
|
||||||
|
13
Makefile
13
Makefile
@ -6,11 +6,16 @@ ifneq (,$(filter-out lib library/%,$(or $(MAKECMDGOALS),all)))
|
|||||||
ifeq (,$(wildcard framework/exported.make))
|
ifeq (,$(wildcard framework/exported.make))
|
||||||
# Use the define keyword to get a multi-line message.
|
# Use the define keyword to get a multi-line message.
|
||||||
# GNU make appends ". Stop.", so tweak the ending of our message accordingly.
|
# GNU make appends ". Stop.", so tweak the ending of our message accordingly.
|
||||||
define error_message
|
ifeq (,$(wildcard .git))
|
||||||
$(MBEDTLS_PATH)/framework/exported.make not found.
|
define error_message
|
||||||
Run `git submodule update --init` to fetch the submodule contents.
|
${MBEDTLS_PATH}/framework/exported.make not found (and does appear to be a git checkout). Run `git submodule update --init` from the source tree to fetch the submodule contents.
|
||||||
This is a fatal error
|
This is a fatal error
|
||||||
endef
|
endef
|
||||||
|
else
|
||||||
|
define error_message
|
||||||
|
${MBEDTLS_PATH}/framework/exported.make not found (and does not appear to be a git checkout). Please ensure you have downloaded the right archive from the release page on GitHub.
|
||||||
|
endef
|
||||||
|
endif
|
||||||
$(error $(error_message))
|
$(error $(error_message))
|
||||||
endif
|
endif
|
||||||
include framework/exported.make
|
include framework/exported.make
|
||||||
|
Loading…
x
Reference in New Issue
Block a user