Repository navigation
fix(build): stop Rolling CMake configure aborting in the localhost_only probe - #10
Merged
Merged
Conversation
…, so Rolling configure stops aborting
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
On Rolling,
colcon buildaborts at CMake configure time, before any source compiles:The
RMW_HAS_LOCALHOST_ONLYprobe (commitfb9ee3d) runscheck_cxx_source_compiles(...)withCMAKE_REQUIRED_LIBRARIES = rmw::rmw rcutils::rcutils, which links those imported targets into a CXX-only scratch project.rcutilsis a C library whose exported target now carries a CINTERFACE_COMPILE_FEATURES; resolving a C compile feature in a project where the C language was never enabled makes the innertry_compilefail to generate. This is upstream drift — the sameCMakeLists.txtpassed Rolling on 2026-06-01, andjazzy/kiltedare unaffected.Fix
The probe only needs the rmw headers (it references the type + a macro and links nothing). Feed it the
rmwandrcutilsinclude dirs viaCMAKE_REQUIRED_INCLUDESinstead of linking the targets — no imported target is linked, so no C compile-feature is pulled into the CXX scratch project. (rmw/init_options.htransitively includesrcutils/allocator.h, hence both include dirs.)Verified
-DRMW_HAS_LOCALHOST_ONLY=1, builds clean with 0 warnings.localhost_only; kilted 7.8.2 and rolling 7.10.1 do not (removed at rmw 7.8) — the probe resolves correctly on each.Independent of the audit-fix PRs (#4–#9); fixes Rolling CI for all of them once merged.