4.2.1自定义服务接口构建功能包出错
-
```
code_textsensor_msgs/Image image --- int16 number float32 use_time int32[] top int32[] right int32[] bottom int32[] left
cmake_minimum_required(VERSION 3.8) project(chapt4_interfaces) if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") add_compile_options(-Wall -Wextra -Wpedantic) endif() # find dependencies find_package(ament_cmake REQUIRED) find_package(sensor_msgs REQUIRED) find_package(rosidl_default_generators REQUIRED) rosidl_generate_interfaces(${PROJECT_NAME} "srv/FaceDetector.srv" DEPENDENCIES sensor_msgs ) if(BUILD_TESTING) find_package(ament_lint_auto REQUIRED) # the following line skips the linter which checks for copyrights # comment the line when a copyright and license is added to all source files set(ament_cmake_copyright_FOUND TRUE) # the following line skips cpplint (only works in a git repo) # comment the line when this package is in a git repo and when # a copyright and license is added to all source files set(ament_cmake_cpplint_FOUND TRUE) ament_lint_auto_find_test_dependencies() endif() ament_package()
<?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>chapt4_interfaces</name> <version>0.0.0</version> <description>TODO: Package description</description> <maintainer email="redfish@foxmail.com">yhy</maintainer> <license>Apache-2.0</license> <buildtool_depend>ament_cmake</buildtool_depend> <member_of_group>rosidl_interface_packages</member_of_group> <depend>sensor_msgs</depend> <depend>rosidl_default_generators</depend> <test_depend>ament_lint_auto</test_depend> <test_depend>ament_lint_common</test_depend> <export> <build_type>ament_cmake</build_type> </export> </package>
求解,一步步跟着教程来的,为什么会出现构建失败的情况