You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to clarify if there is any background to have this variable set as the environment variable or if it just needs to be fixed.
(I'll make a PR if it's the latter case.)
The text was updated successfully, but these errors were encountered:
furushchev
changed the title
AMENT_PREFIX_PATH: Environment variables vs CMake variables
AMENT_PREFIX_PATH: Environment variable vs CMake variable
Dec 19, 2023
Hmm, I think these lines can be removed from the templates you referenced. From what I can tell, AMENT_PREFIX_PATH is only ever set and only ever used as an environment variable and never as a CMake variable. In this context, sourcing the setup scripts sets the variable appropriately.
We should survey the ROS 2 codebase to be absolutely sure nobody is relying on this variable being set in this way before merging a change to drop it.
Keep in mind that defining the variable shouldn't cause any misbehavior, it's just misleading.
@nuclearsandwich originally added the flag to the ament_cmake templates - do you have any context to add?
I found the CMake variable
AMENT_PREFIX_PATH
is set in the following files in this repository:bloom/bloom/generators/debian/templates/ament_cmake/rules.em
Line 36 in d3d21ae
bloom/bloom/generators/rpm/templates/ament_cmake/template.spec.em
Line 49 in d3d21ae
However, the variable is not assumed to be the CMake variable but the environment variable in the
ament/ament_cmake
repository.for instance:
https://github.com/ament/ament_cmake/blob/dc576abb40986f9d1ce8e534eb17770a625014cd/ament_cmake_core/cmake/environment/ament_cmake_environment_package_hook.cmake#L33
I want to clarify if there is any background to have this variable set as the environment variable or if it just needs to be fixed.
(I'll make a PR if it's the latter case.)
The text was updated successfully, but these errors were encountered: