Robot Operating System/ROS2

[ROS2 Dashing] prefix_path WARNING 해결 방법

jstar0525 2022. 2. 3. 19:08
반응형

Test Env. : ROS2 Dashing, Ubuntu 18.04, Jetson AGX Xavier with Jetpack 4.5

 

기존의 custom package를 삭제하고 build를 하면 아래와 같은 WARNING이 생겼다.

$ ~/colcon_ws && colcon build --symlink-install && source ~/.bashrc
                     
Summary: 0 packages finished [0.35s]
[0.987s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '~/colcon_ws/install/yolov3_pytorch_ros' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.988s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '~/colcon_ws/install/realsense2_description' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.988s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '~/colcon_ws/install/realsense2_camera' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.988s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '~/colcon_ws/install/realsense2_camera_msgs' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.988s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '~/colcon_ws/install/boundingbox_msgs' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.989s] WARNING:colcon.colcon_ros.prefix_path.catkin:The path '~/colcon_ws/install/realsense2_description' in the environment variable CMAKE_PREFIX_PATH doesn't exist
[0.989s] WARNING:colcon.colcon_ros.prefix_path.catkin:The path '~/colcon_ws/install/realsense2_camera' in the environment variable CMAKE_PREFIX_PATH doesn't exist
[0.989s] WARNING:colcon.colcon_ros.prefix_path.catkin:The path '~/colcon_ws/install/realsense2_camera_msgs' in the environment variable CMAKE_PREFIX_PATH doesn't exist

 

prefix_path를 확인하면 아래와 같다.

$ printenv AMENT_PATH CMAKE_PREFIX_PATH

~/colcon_ws/install/realsense2_description:~/colcon_ws/install/realsense2_camera:~/colcon_ws/install/realsense2_camera_msgs:~/colcon_ws/install/boundingbox_msgs

 

아래의 명령으로 path를 삭제하여 문제를 해결하였다.

$ export AMENT_PREFIX_PATH=''
$ export CMAKE_PREFIX_PATH=''
$ printenv AMENT_PATH CMAKE_PREFIX_PATH

$ ~/colcon_ws && colcon build --symlink-install && source ~/.bashrc
                     
Summary: 0 packages finished [0.37s]

 

 

Ref.

https://blog.katastros.com/a?ID=01750-c17fb2d5-280f-412c-8be6-f7739b10a28d 

 

ROS2 compilation errors and warnings - Katastros

1. A warning appears after deleting a custom package WARNING:colcon.colcon_ros.prefix_path.ament:The path xxx AMENT_PREFIX_PATH doesn't exist WARNING:colcon.colcon_ros.prefix_path.catkin:The path xxx CMAKE_PREFIX_PATH doesn't exist ROS2 Compilation warning

blog.katastros.com

 

반응형