Open m2-farzan opened 3 years ago
Install location can be changed with --install-base flag in colcon but it's not practical to use the actual /opt/ros2/foxy path in build time.
This is more complicated than I thought. I could really use some help.
There are some references to build directory that can be worked around:
-fdebug-prefix-map
.But there are some other hardcoded paths that are harder to fix. Some of them refer to build path (not install path), which we aren't even packing. It seems that only rviz_ packages have this problem.
I'm pushing some ideas to fix-path
branch of the galactic repo for now.
Might be related: https://github.com/ament/ament_cmake/issues/173
Reproduction steps:
Where
/home/mostafa/dev/ros2-pkgbuild
is the directory in which I ranmakepkg
. These should be replaced with the new installation path. This becomes serious when user cleans build cache or moves it, where this causes the ROS installation to break.The solution would either be using
colcon
arguments to correct this, or less ideally, usesed
to match/replace.I'll work on it. For now, avoid deleting or moving install cache to avoid breaking your ROS 2 installation.
The same problem exists for
ros2-git
package.