ROS: document this package as architecture independent#786
Merged
nim65s merged 1 commit intojrl-umi3218:masterfrom Nov 6, 2025
Merged
ROS: document this package as architecture independent#786nim65s merged 1 commit intojrl-umi3218:masterfrom
nim65s merged 1 commit intojrl-umi3218:masterfrom
Conversation
Fix Gepetto/aig#66 In short, we need `find_package(jrl-cmakemodules CONFIG REQUIRED)` to work before `project(…)` call, because we want that `project(…)` to use our `PROJECT_ARGS` from `jrl-cmakemodules`'s `compute_project_args()`. But as long as `project(…)` with the correct `LANGUAGES` is not run (nor is `enable_language(…)`), `CMAKE_LIBRARY_ARCHITECTURE` is not set, and therefore, the "Config Mode Search Procedure" https://cmake.org/cmake/help/latest/command/find_package.html#config-mode-search-procedure will not include any `lib/<arch>` paths. And by default, ROS packages all have `Architecture: any` in their `debian/control`, which configure the installation of CMake export in `lib/<arch>`: https://github.com/ros2-gbp/jrl_cmakemodules-release/blob/debian/ros-humble-jrl-cmakemodules_1.1.0-1_jammy/debian/control#L10 By exporting this `architecture_independent` tag, we should be able to get `Architecture: all`, and see this package correctly installed in `lib` Unfortunately, ros-infrastructure/bloom#705 is not merged yet. Fortunately, our lord and savior Nix can easily deal with that not-merged status: lopsided98/nix-ros-overlay#736 Thanks @MaximilienNaveau for the report and the private follow-ups when I could not understand or reproduce the issue. Btw, calling `enable_language(…)` first, then `find_package(jrl-cmakemodules …)`, and finally `project(…)` is a working workaround, but CMP0165 decided to strictly forbid this in CMake >= 3.30.
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.
Fix Gepetto/aig#66
In short, we need
find_package(jrl-cmakemodules CONFIG REQUIRED)to work beforeproject(…)call, because we want thatproject(…)to use ourPROJECT_ARGSfromjrl-cmakemodules'scompute_project_args().But as long as
project(…)with the correctLANGUAGESis not run (nor isenable_language(…)),CMAKE_LIBRARY_ARCHITECTUREis not set, and therefore, the "Config Mode Search Procedure"https://cmake.org/cmake/help/latest/command/find_package.html#config-mode-search-procedure will not include any
lib/<arch>paths.And by default, ROS packages all have
Architecture: anyin theirdebian/control, which configure the installation of CMake export inlib/<arch>:https://github.com/ros2-gbp/jrl_cmakemodules-release/blob/debian/ros-humble-jrl-cmakemodules_1.1.0-1_jammy/debian/control#L10
By exporting this
architecture_independenttag, we should be able to getArchitecture: all, and see this package correctly installed inlibUnfortunately, ros-infrastructure/bloom#705 is not merged yet.
Fortunately, our lord and savior Nix can easily deal with that not-merged status: lopsided98/nix-ros-overlay#736
Thanks @MaximilienNaveau for the report and the private follow-ups when I could not understand or reproduce the issue.
Btw, calling
enable_language(…)first, thenfind_package(jrl-cmakemodules …), and finallyproject(…)is a working workaround, but CMP0165 decided to strictly forbid this in CMake >= 3.30.