Repository navigation
fix(rmw_service): build against Rolling's const rmw_send_response (rmw 7.11.4) - #104
Conversation
…w 7.11.4) ros2/rmw#437, released in rmw 7.11.4 on Rolling, changed the response parameter of rmw_send_response from `void *` to `const void *`. Our definition sits in an extern "C" block, so the old signature is now a "conflicting declaration of C function" and the Rolling build farm job (Rbin_unv8_uRv8 rmw_unix_socket_cpp #2) fails. Gate the parameter on rmw_VERSION >= 7.11.4. jazzy (7.3.4) and lyrical (7.10.3) keep `void *`; the body already passes the pointer to shm_serialize_prepare_send, which takes `const void *`.
|
@coderabbitai review |
|
No actionable comments were generated in the recent review. Walkthrough
Change: Bug fix Merge Risk:
|
Action performed
|
Description
The Rolling build farm job
Rbin_unv8_uRv8__rmw_unix_socket_cpp__ubuntu_resolute_arm64__binary#2 fails. No source change on our side: it was an automatic rebuild after upstreamrmwwas re-released.ros2/rmw#437, released in rmw 7.11.4 (Rolling, 2026-11-30), changed:
Our definition in
src/rmw_service.cppis insideextern "C", so it is now a hard error:We release one branch to three distros, so the parameter is gated on the installed rmw:
CMakeLists.txt:rmw_VERSION >= 7.11.4setsRMW_SEND_RESPONSE_CONST(same pattern asRMW_HAS_LOCALHOST_ONLY).src/rmw_service.cpp:#ifdefpicksconst void *orvoid *. The body is unchanged: it only hands the pointer toshm_serialize_prepare_send, which already takesconst void *.void *void *const void *The core RMWs (fastrtps, cyclonedds, zenoh, connextdds) changed in lockstep with #437 and are green on the farm again; this package was the first non-core RMW to rebuild against it.
Is this user-facing behavior change?
No. Runtime behaviour is identical; Rolling binaries build again.
How was this tested?
rmw_service.cppagainst jazzy headers withrmw.hpatched to the 7.11.4 signature: sameconflicting declaration of C function.ros:rollingcontainer, rmw 7.11.4 overlaid from its release tag,--shm-size=2g): builds,RMW_SEND_RESPONSE_CONST=1is set,service|cross_processtests: 14 passed, 0 failures./opt/ros/jazzy, rmw 7.3.4): configure + build OK, define off.After merge, the farm needs a release (0.6.1,
--bump patch) on therollingtrack; jazzy and lyrical don't need one.Did you use Generative AI?
Yes: Claude Code (Claude Opus 5.5) diagnosed the farm failure, wrote the patch and ran the checks above.
Additional Information
rmw_int2dds(sameextern "C"+void *) will hit the same error when its queued Rolling job runs.rmw_desertbuilds only because its definition is notextern "C", so it exports a mangledrmw_send_responseinstead of the C symbol.🤖 Generated with Claude Code
Summary by CodeRabbit