From 3c161f8ff4ebe2f249fbb5cd253908a21256d65b Mon Sep 17 00:00:00 2001 From: salh Date: Fri, 17 Apr 2026 21:54:07 +0300 Subject: [PATCH] fix: allow vendored rexglue thirdparty deps without submodules Stop requiring a .git folder for vendored dependencies so source-only clones and monorepo mirrors can configure on Linux/CI. Made-with: Cursor --- thirdparty/rexglue-sdk/thirdparty/CMakeLists.txt | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/thirdparty/rexglue-sdk/thirdparty/CMakeLists.txt b/thirdparty/rexglue-sdk/thirdparty/CMakeLists.txt index b184f288..9c2cb651 100644 --- a/thirdparty/rexglue-sdk/thirdparty/CMakeLists.txt +++ b/thirdparty/rexglue-sdk/thirdparty/CMakeLists.txt @@ -17,7 +17,7 @@ else() endif() #============================================================================= -# Verify git submodules are initialized (only vendored ones) +# Verify vendored dependencies are present #============================================================================= set(REQUIRED_SUBMODULES cli11 @@ -47,11 +47,16 @@ if(REXGLUE_BUILD_TESTS) endif() foreach(submodule ${REQUIRED_SUBMODULES}) - if(NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${submodule}/.git") + # This repo vendors third-party sources directly. Some upstream layouts use + # git submodules, but requiring a `${submodule}/.git` checkout breaks when + # dependencies are vendored as plain directories (for example, in source + # tarballs or monorepo mirrors). + if(NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${submodule}") message(FATAL_ERROR - "Git submodule '${submodule}' is not initialized.\n" - "Please run: git submodule update --init --recursive\n" - "from the repository root directory." + "Required third-party dependency '${submodule}' is missing.\n" + "Expected directory: ${CMAKE_CURRENT_SOURCE_DIR}/${submodule}\n" + "If you cloned from git and this repo uses submodules in your fork,\n" + "run: git submodule update --init --recursive\n" ) endif() endforeach()