Part of kcenon/common_system#454
What
cmake/database_system-config.cmake.in declares common_system as QUIET in find_dependency, but the build-time CMakeLists.txt treats it as FATAL_ERROR if missing.
- Current:
find_dependency(common_system CONFIG QUIET) — silently proceeds if common_system is not installed
- Expected:
find_dependency(common_system CONFIG REQUIRED) — fails immediately with a clear error
- Scope:
cmake/database_system-config.cmake.in line 36
Why
When a consumer installs database_system via vcpkg and common_system is somehow missing (e.g., manual install without transitive deps), find_package(database_system CONFIG) will silently skip common_system. The consumer then gets cryptic linker errors instead of a clear "common_system not found" configure-time error.
At build time, CMakeLists.txt enforces common_system as mandatory:
if(NOT common_system_FOUND)
message(FATAL_ERROR "common_system not found! database_system requires common_system v1.0+.")
endif()
The installed config template should reflect this same requirement level.
Additionally, container_system is also declared QUIET on line 39 but may warrant the same change depending on whether the USE_CONTAINER_SYSTEM option is active.
Where
cmake/database_system-config.cmake.in — line 36: find_dependency(common_system CONFIG QUIET)
cmake/database_system-config.cmake.in — line 39: find_dependency(container_system CONFIG QUIET) (secondary)
CMakeLists.txt — line ~235: find_system_dependency(common_system) with FATAL_ERROR on failure
How
Technical Approach
-
Change line 36 of cmake/database_system-config.cmake.in:
# Before
find_dependency(common_system CONFIG QUIET)
# After
find_dependency(common_system CONFIG REQUIRED)
-
Optionally, make container_system conditional on the build-time feature flag:
set(_DATABASE_USE_CONTAINER @USE_CONTAINER_SYSTEM@)
if(_DATABASE_USE_CONTAINER)
find_dependency(container_system CONFIG REQUIRED)
endif()
Acceptance Criteria
Part of kcenon/common_system#454
What
cmake/database_system-config.cmake.indeclarescommon_systemasQUIETinfind_dependency, but the build-time CMakeLists.txt treats it asFATAL_ERRORif missing.find_dependency(common_system CONFIG QUIET)— silently proceeds ifcommon_systemis not installedfind_dependency(common_system CONFIG REQUIRED)— fails immediately with a clear errorcmake/database_system-config.cmake.inline 36Why
When a consumer installs
database_systemvia vcpkg andcommon_systemis somehow missing (e.g., manual install without transitive deps),find_package(database_system CONFIG)will silently skipcommon_system. The consumer then gets cryptic linker errors instead of a clear "common_system not found" configure-time error.At build time,
CMakeLists.txtenforcescommon_systemas mandatory:The installed config template should reflect this same requirement level.
Additionally,
container_systemis also declaredQUIETon line 39 but may warrant the same change depending on whether theUSE_CONTAINER_SYSTEMoption is active.Where
cmake/database_system-config.cmake.in— line 36:find_dependency(common_system CONFIG QUIET)cmake/database_system-config.cmake.in— line 39:find_dependency(container_system CONFIG QUIET)(secondary)CMakeLists.txt— line ~235:find_system_dependency(common_system)withFATAL_ERRORon failureHow
Technical Approach
Change line 36 of
cmake/database_system-config.cmake.in:Optionally, make
container_systemconditional on the build-time feature flag:Acceptance Criteria
find_dependency(common_system CONFIG REQUIRED)in installed config templatefind_package(database_system CONFIG)fails immediately with a clear error whencommon_systemis not installedcontainer_systemdependency is conditional on build-timeUSE_CONTAINER_SYSTEMflag