Part of kcenon/common_system#454
What
cmake/UnifiedDependencies.cmake defaults FetchContent fallback GIT_TAG to v0.1.0 for all kcenon ecosystem dependencies. This is outdated — common_system is at v0.2.0 and thread_system is at v0.3.1.
- Current: Default
GIT_TAG is v0.1.0 (line 232) when not explicitly overridden by the caller
- Expected: Default
GIT_TAG should match the minimum compatible version for each dependency, or at minimum warn when the hardcoded default is used
- Scope:
cmake/UnifiedDependencies.cmake lines 231-234
Why
When find_package fails and FetchContent is used as a fallback (controlled by UNIFIED_ALLOW_FETCHCONTENT_FALLBACK), the dependency is fetched at v0.1.0. This means:
common_system v0.1.0 is fetched instead of v0.2.0 — may lack APIs that logger_system v0.1.3 depends on
thread_system v0.1.0 is fetched instead of v0.3.1 — significant API changes between these versions
- Silent ABI mismatch if the consumer also has newer versions of these libraries elsewhere
The fallback is intended as a development convenience, but fetching an incompatible version defeats the purpose.
Where
| Location |
Current |
Expected |
cmake/UnifiedDependencies.cmake:232 |
set(_UFD_GIT_TAG "v0.1.0") |
Version-aware default or per-dependency map |
| FetchContent repo config (lines 98-110) |
Maps dependency names to GitHub repos |
Correct, but missing version info |
How
Technical Approach
Option A (Minimal fix): Update the hardcoded default to the minimum required versions per dependency using the existing _UNIFIED_VERSIONS map pattern:
# Per-dependency version defaults
set(_UNIFIED_DEFAULT_TAGS
"common_system=v0.2.0"
"thread_system=v0.3.1"
)
if(NOT _UFD_GIT_TAG)
# Look up per-dependency default, fall back to generic default
foreach(_entry IN LISTS _UNIFIED_DEFAULT_TAGS)
string(REGEX MATCH "^${DEP_NAME}=(.+)$" _match "${_entry}")
if(_match)
set(_UFD_GIT_TAG "${CMAKE_MATCH_1}")
break()
endif()
endforeach()
if(NOT _UFD_GIT_TAG)
set(_UFD_GIT_TAG "v0.1.0")
endif()
endif()
Option B (Simpler): Just update the single default from v0.1.0 to the lowest common compatible version, and add a warning when the default is used.
Acceptance Criteria
Part of kcenon/common_system#454
What
cmake/UnifiedDependencies.cmakedefaults FetchContent fallbackGIT_TAGtov0.1.0for all kcenon ecosystem dependencies. This is outdated —common_systemis atv0.2.0andthread_systemis atv0.3.1.GIT_TAGisv0.1.0(line 232) when not explicitly overridden by the callerGIT_TAGshould match the minimum compatible version for each dependency, or at minimum warn when the hardcoded default is usedcmake/UnifiedDependencies.cmakelines 231-234Why
When
find_packagefails and FetchContent is used as a fallback (controlled byUNIFIED_ALLOW_FETCHCONTENT_FALLBACK), the dependency is fetched atv0.1.0. This means:common_system v0.1.0is fetched instead ofv0.2.0— may lack APIs thatlogger_system v0.1.3depends onthread_system v0.1.0is fetched instead ofv0.3.1— significant API changes between these versionsThe fallback is intended as a development convenience, but fetching an incompatible version defeats the purpose.
Where
cmake/UnifiedDependencies.cmake:232set(_UFD_GIT_TAG "v0.1.0")How
Technical Approach
Option A (Minimal fix): Update the hardcoded default to the minimum required versions per dependency using the existing
_UNIFIED_VERSIONSmap pattern:Option B (Simpler): Just update the single default from
v0.1.0to the lowest common compatible version, and add a warning when the default is used.Acceptance Criteria
common_systemusesv0.2.0or laterthread_systemusesv0.3.1or laterGIT_TAGparameter inunified_find_dependency()calls still takes precedence