小鱼 ROS 2 新书上线!点击链接查看, 新书配套视频点击链接查看。
提问前必看的发帖注意事项—— 提问前必看!不符合要求的问题拒绝回答!!
社区使用指南—如何添加标签修改密码
在入门篇第2章1.2.2使用终极命令后还报错
-
使用终极命令:
sudo g++ -o first_ros2_node first_ros2_node.cpp -I/opt/ros/humble/include/rclcpp/ -I /opt/ros/humble/include/rcl/ -I /opt/ros/humble/include/rcutils/ -I /opt/ros/humble/include/rmw -I /opt/ros/humble/include/rcl_yaml_param_parser/ -I /opt/ros/humble/include/rosidl_runtime_c -I /opt/ros/humble/include/rosidl_typesupport_interface -I /opt/ros/humble/include/rcpputils -I /opt/ros/humble/include/builtin_interfaces -I /opt/ros/humble/include/rosidl_runtime_cpp -I /opt/ros/humble/include/tracetools -I /opt/ros/humble/include/rcl_interfaces -I /opt/ros/humble/include/libstatistics_collector -I /opt/ros/humble/include/statistics_msgs -L /opt/ros/humble/lib/ -lrclcpp -lrcutils
出现报错;报错如下:
/usr/bin/ld: warning: liblibstatistics_collector.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librcl.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librcl_interfaces__rosidl_typesupport_cpp.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librcl_yaml_param_parser.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librosgraph_msgs__rosidl_typesupport_cpp.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libstatistics_msgs__rosidl_typesupport_cpp.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libtracetools.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librmw_implementation.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libament_index_cpp.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librcl_logging_interface.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librmw.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: librcpputils.so, needed by /opt/ros/humble/lib//librclcpp.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_qos_durability_policy_from_str' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_timer_call'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_serialize' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_service_names_and_types'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_timer_is_ready' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_publisher_names_and_types_by_node'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_init_options_get_allocator' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_set_on_new_message_callback'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference toros_trace_rclcpp_timer_link_node' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_get_network_flow_endpoints'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_disable_ros_time_override' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_subscription_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_init_options_copy' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_set_content_filter'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_qos_reliability_policy_to_str' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_take_event'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_context' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_take_request'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tolibstatistics_collector::collector::GenerateStatisticMessage(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, builtin_interfaces::msg::Time_<std::allocator<void> >, builtin_interfaces::msg::Time_<std::allocator<void> >, libstatistics_collector::moving_average_statistics::StatisticData const&)' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_service_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_clock_add_jump_callback' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_resolve_name'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait_set_clear' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_logging_multiple_output_handler'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_timer' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_assert_liveliness'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_clock_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_timer_callback_added'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_guard_condition_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_event_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_event_set_callback' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_client_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_yaml_node_struct_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_get_namespace'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference toros_trace_rclcpp_service_callback_added' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_client_set_on_new_response_callback'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_subscription_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcpputils::path_for_library(std::_cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_clock_get_now' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_qos_reliability_policy_from_str'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_names_and_types_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_take_serialized_message'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publisher_get_options' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
vtable for libstatistics_collector::moving_average_statistics::MovingAverageStatistics'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_service_request_subscription_get_actual_qos' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_validate_namespace'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tolibstatistics_collector::collector::Collector::ClearCurrentMeasurements()' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_get_fully_qualified_name'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait_set_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_node_names'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_node_options_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_service_type_support_t const* rosidl_typesupport_cpp::get_service_type_support_handle<rcl_interfaces::srv::SetParameters>()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_publisher' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_service_type_support_t const* rosidl_typesupport_cpp::get_service_type_support_handle<rcl_interfaces::srv::DescribeParameters>()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_guard_condition_get_default_options' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_can_loan_messages'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publish_loaned_message' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_init_options_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_enable_ros_time_override' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_get_actual_qos'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_parse_arguments' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_arguments_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_client_names_and_types_by_node' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference toament_index_cpp::get_package_prefix(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_executor_get_next_ready'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcpputils::SharedLibrary::SharedLibrary(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_return_loaned_message_from_subscription'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_remove_ros_arguments' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_can_loan_messages'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_arguments_get_unparsed_ros' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_message_type_support_t const* rosidl_typesupport_cpp::get_message_type_support_handle<statistics_msgs::msg::MetricsMessage<std::allocator<void> > >()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_subscription_is_cft_enabled' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_get_default_options'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_subscriptions_info_by_topic' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_topic_name_validation_result_string'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_trigger_guard_condition' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_init_options_get_domain_id'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_qos_history_policy_from_str' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_clock_remove_jump_callback'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_subscription_get_topic_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_service_get_default_options'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_subscription_get_publisher_count' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_event_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_init_options' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_zero_initialized_subscription'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_subscriber_names_and_types_by_node' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_callback_register'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tolibstatistics_collector::collector::Collector::AcceptData(double)' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_logging_configure_with_output_handler'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_get_zero_initialized_network_flow_endpoint_array' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_set_ros_time_override'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_subscription_get_content_filter' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_take'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_node_name_validation_result_string' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_zero_initialized_service'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torosidl_message_type_support_t const* rosidl_typesupport_cpp::get_message_type_support_handle<rcl_interfaces::msg::ParameterEvent_<std::allocator<void> > >()' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_count_publishers'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_borrow_loaned_message' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_client_response_subscription_get_actual_qos'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_node_get_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_content_filter_options_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torosidl_service_type_support_t const* rosidl_typesupport_cpp::get_service_type_support_handle<rcl_interfaces::srv::GetParameterTypes>()' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_clock_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tovtable for rcpputils::IllegalStateException' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_publish'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_wait_set' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_event_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_logging_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcpputils::IllegalStateException::IllegalStateException(char const*)'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait_set_add_service' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_validate_topic_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_wait_set_resize'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publisher_get_actual_qos' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_wait_set_add_guard_condition'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_arguments_get_param_overrides' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_service_type_support_t const* rosidl_typesupport_cpp::get_service_type_support_handle<rcl_interfaces::srv::ListParameters>()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_get_zero_initialized_topic_endpoint_info_array' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_validate_node_name'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_node_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_is_valid_except_context'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_init_options_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_default_topic_name_substitutions'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_context_get_domain_id' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_context_is_valid' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
typeinfo for rcpputils::IllegalStateException'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait_set_add_event' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_publishers_info_by_topic'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_send_request' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_arguments_get_count_unparsed_ros'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_subscription_content_filter_options' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_service_type_support_t const* rosidl_typesupport_cpp::get_service_type_support_handle<rcl_interfaces::srv::GetParameters>()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference toros_trace_callback_start' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_remap_topic_name'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_qos_durability_policy_to_str' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_get_context'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_network_flow_endpoint_array_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_get_default_options'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_parse_yaml_file' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_get_options'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_get_gid_for_publisher' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_network_flow_endpoint_get_internet_protocol_string'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_get_zero_initialized_names_and_types' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
tracetools::detail::get_symbol_funcptr(void*)'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publisher_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_shutdown'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_clock_valid' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_full_topic_name_validation_result_string'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_node_names_with_enclaves' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_topic_names_and_types'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torosidl_message_type_support_t const* rosidl_typesupport_cpp::get_message_type_support_handle<rcl_interfaces::msg::SetParametersResult_<std::allocator<void> > >()' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_message_type_support_t const* rosidl_typesupport_cpp::get_message_type_support_handle<rcl_interfaces::msg::ListParametersResult<std::allocator<void> > >()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait_set_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
libstatistics_collector::collector::Collector::Start()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_context_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_topic_endpoint_info_array_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torosidl_service_type_support_t const* rosidl_typesupport_cpp::get_service_type_support_handle<rcl_interfaces::srv::SetParametersAtomically>()' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_compare_gids_equal'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_zero_initialized_event'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_subscription_content_filter_options_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_get_zero_initialized_client'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_yaml_node_struct_fini' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_qos_liveliness_policy_to_str'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
tracetools::detail::demangle_symbol(char const*)'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_service_get_service_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_expand_topic_name'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_node' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_message_type_support_t const* rosidl_typesupport_cpp::get_message_type_support_handle<rosgraph_msgs::msg::Clock<std::allocator<void> > >()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_arguments' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcpputils::fs::path::path(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_send_response' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_init_options_set_domain_id'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_clock_time_started' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_get_rmw_handle'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_qos_policy_kind_to_str' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publish_serialized_message'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publisher_get_topic_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_take_response'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_validate_full_topic_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_qos_profile_check_compatible'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_network_flow_endpoint_get_transport_protocol_string' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_node_get_graph_guard_condition'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_logging_get_logging_directory' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_timer_get_time_until_next_call'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_client_request_publisher_get_actual_qos' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcpputils::SharedLibrary::get_symbol(std::_cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tolibstatistics_collector::collector::Collector::GetStatisticsResults() const' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_executor_execute'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_take_loaned_message' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_get_network_flow_endpoints'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_timer_reset' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_service_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference toros_trace_rclcpp_subscription_callback_added' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_timer_fini'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_service_set_on_new_request_callback' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_service_server_is_available'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_is_enabled_ros_time_override' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_client_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_timer_is_canceled' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_callback_end'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_qos_liveliness_policy_from_str' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_client_get_service_name'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_count_subscribers' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rosidl_message_type_support_t const* rosidl_typesupport_cpp::get_message_type_support_handle<rcl_interfaces::msg::ParameterDescriptor<std::allocator<void> > >()'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_wait_set_add_timer' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_wait_set_add_client'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference totypeinfo for ament_index_cpp::PackageNotFoundError' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_subscription_options_set_content_filter_options'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tormw_namespace_validation_result_string' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_deserialize'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_service_names_and_types_by_node' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rmw_qos_history_policy_to_str'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publish' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_take'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_publisher_get_default_options' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
libstatistics_collector::collector::Collector::GetStatusStringabi:cxx11 const'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_zero_initialized_guard_condition' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_guard_condition_init'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_node_get_logger_name' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
ros_trace_rclcpp_executor_wait_for_work'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_get_default_domain_id' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_wait_set_add_subscription'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_timer_init' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_service_response_publisher_get_actual_qos'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference torcl_timer_cancel' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
typeinfo for libstatistics_collector::collector::Collector'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference tolibstatistics_collector::collector::Collector::Stop()' /usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to
rcl_publisher_get_subscription_count'
/usr/bin/ld: /opt/ros/humble/lib//librclcpp.so: undefined reference to `rcl_client_get_default_options'
collect2: error: ld returned 1 exit status -
@254944954 跳过跳过看新教程
-
@小鱼 跳过使用后面的make方法,结果也一样,Cmake也不成功
-
@小鱼 已解决了