Invalid list index "rticonnextmsgcppd.lib" fail build ROS2 ws on window10

asked 2021-09-19 21:08:39 -0500

C.L. Eric Lu gravatar image

updated 2021-09-20 02:07:27 -0500

gvdhoorn gravatar image

Hi guys!

I built a ROS2 workspace with three packages. Two of them successfully built One of them with customized message but fail to built.

The error message repeated as follow. Seems that something wrong with RTOConnext, anyone knows how to solve it?

Platform

Window 10

ROS2 Foxy

Error Msg

CMake Warning (dev) at C:/dev/ros2_foxy/share/connext_cmake_module/cmake/Modules/FindConnext.cmake:163 (list):
  Policy CMP0121 is not set: The list() command now validates parsing of
  index arguments.  Run "cmake --help-policy CMP0121" for policy details.
  Use the cmake_policy command to set the policy and suppress this warning.
  Invalid list index "rticonnextmsgcppd.lib".
Call Stack (most recent call first):
  C:/dev/ros2_foxy/share/connext_cmake_module/cmake/Modules/FindConnext.cmake:199 (_count_found_libraries)
  C:/dev/ros2_foxy/share/rosidl_typesupport_connext_c/cmake/rosidl_typesupport_connext_c-extras.cmake:5 (find_package)
  C:/dev/ros2_foxy/share/rosidl_typesupport_connext_c/cmake/rosidl_typesupport_connext_cConfig.cmake:41 (include)
  C:/dev/ros2_foxy/share/rosidl_typesupport_c/cmake/rosidl_typesupport_c-extras.cmake:13 (find_package)
  C:/dev/ros2_foxy/share/rosidl_typesupport_c/cmake/rosidl_typesupport_cConfig.cmake:41 (include)
  C:/dev/ros2_foxy/share/rosidl_default_generators/cmake/rosidl_default_generators-extras.cmake:21 (find_package)
  C:/dev/ros2_foxy/share/rosidl_default_generators/cmake/rosidl_default_generatorsConfig.cmake:41 (include)
  CMakeLists.txt:24 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

CMakefile

cmake_minimum_required(VERSION 3.5)
project(turtle_interfaces)

if(NOT CMAKE_C_STANDARD)
  set(CMAKE_C_STANDARD 99)
endif()

if(NOT CMAKE_CXX_STANDARD)
  set(CMAKE_CXX_STANDARD 14)
endif()

if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
  add_compile_options(-Wall -Wextra -Wpedantic)
endif()

find_package(ament_cmake REQUIRED)

find_package(rosidl_default_generators REQUIRED)

rosidl_generate_interfaces(${PROJECT_NAME}
  "msg/Turtlemsg.msg"
)

if(BUILD_TESTING)
  find_package(ament_lint_auto REQUIRED)
  ament_lint_auto_find_test_dependencies()
endif()

ament_package()

package.xml

<?xml version="1.0"?>
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
  <name>turtle_interfaces</name>
  <version>0.0.0</version>
  <description>TODO: Package description</description>
  <maintainer email="eric5@todo.todo">eric5</maintainer>
  <license>TODO: License declaration</license>

  <buildtool_depend>ament_cmake</buildtool_depend>

  <test_depend>ament_lint_auto</test_depend>
  <test_depend>ament_lint_common</test_depend>

  <build_depend>rosidl_default_generators</build_depend>

  <exec_depend>rosidl_default_runtime</exec_depend>

  <member_of_group>rosidl_interface_packages</member_of_group>

  <export>
    <build_type>ament_cmake</build_type>
  </export>
</package>
edit retag flag offensive close merge delete