当前位置:网站首页>[ROS] (04) Detailed explanation of package.xml
[ROS] (04) Detailed explanation of package.xml
2022-08-02 14:19:00 【CynalFly】
文章只是个人学习过程中学习笔记,主要参考ROS教程1.
1、概述
软件包(package)清单(manifest)是一个名为 package.xml2 的 XML 文件,Must be included in any compatible catkin The packages in the root folder.This document defines the properties about the package,例如软件包名称、版本号、作者、维护者以及对其他catkin软件包的依赖关系.
Note:
package.xml类似于早期的rosbuild编译系统中使用的manifest.xml文件.
2、package.xml文件
2.1 Follow the format of the
package.xml遵循XML(可扩展标记语言)标签的写法,包含的标签有:
| 编号 | 标签 | 功能 | 备注 |
|---|---|---|---|
| 1 | <package> | 根标签,All other tags nested below it | Required |
| 2 | <name> | 软件包的名称 | Required |
| 3 | <version> | 软件包的版本号(必须是3个点分隔的整数) | Required |
| 4 | <description> | The contents of the package description | Required |
| 5 | <maintainer> | 软件包的维护者 | Required |
| 6 | <license> | 发布代码的软件许可证(例如 GPL、BSD、ASL) | Required |
| 7 | <buildtool_depend> | Build system tools,通常为catkin | – |
| 8 | <depend> | 指定依赖项为编译、导出、运行需要的依赖,最常用 | – |
| 9 | <build_depend> | 编译依赖项 | – |
| 10 | <build_export_depend> | Compile the export dependency | – |
| 11 | <exec_depend> | 执行依赖项 | – |
| 12 | <test_depend> | 测试用例依赖项 | – |
| 13 | <doc_depend> | Documentation tool dependencies | – |
2.2 文件解析
<!-- Syntax definition document ,内容遵循xml的1.0版本 -->
<?xml version="1.0"?>
<!-- (1) package为根标签,The format of the software package for2(推荐),老版本为1 -->
<package format="2">
<!-- (2) 软件包的名称 -->
<name>beginner_tutorials</name>
<!-- (3) 软件包的版本 -->
<version>0.0.0</version>
<!-- (4) The contents of the package description -->
<description>The beginner_tutorials package</description>
<!-- (5) 软件包的维护者 -->
<maintainer email="[email protected]">fly</maintainer>
<!-- (6) 发布代码的软件许可证(ROSThe core code by defaultBSD) -->
<!-- BSD, MIT, Boost Software License, GPLv2, GPLv3, LGPLv2.1, LGPLv3 -->
<license>BSD</license>
<!-- (可选) Url标签是可选的,But allows multiple,每个标签一个 -->
<!-- 可选属性类型可以是:网站、bugThe tracker or repository -->
<!-- UrlTags can help users find the document and report problems -->
<!-- <url type="website">http://wiki.ros.org/beginner_tutorials</url> -->
<!-- (可选) Author标签是可选的,But allows multiple,每个标签一个 -->
<!-- Maintainers are released package,But the author is not necessarily the maintainer -->
<!-- <author email="[email protected]">Jane Doe</author> -->
<!-- (8) depend The tag is used to specify dependencies(依赖项可以是catkin包或系统依赖项) -->
<!-- <depend>roscpp</depend> -->
<!-- 上述 depend 标签依赖,Equivalent to the following two lines -->
<!-- <build_depend>roscpp</build_depend> -->
<!-- <exec_depend>roscpp</exec_depend> -->
<!-- (9) 对编译时需要的包使用build_depend: -->
<!-- <build_depend>message_generation</build_depend> -->
<!-- (10) For the package you need to usebuild_export_dependTo build this package: -->
<!-- <build_export_depend>message_generation</build_export_depend> -->
<!-- (7) For the construction of tool bag,使用 buildtool_depend标签 -->
<!-- Build tools dependencies specified this package to build their own build system tools.通常唯一的构建工具是 catkin -->
<!-- <buildtool_depend>catkin</buildtool_depend> -->
<!-- (11) Package of runtime needs,使用 exec_depend标签 -->
<!-- 执行依赖关系,Specify the needed to run the code in a package of package,如动态链接库,可执行文件,Python模块,脚本文件 -->
<!-- <exec_depend>message_runtime</exec_depend> -->
<!-- (12) For only used to test the package usetest_depend: -->
<!-- <test_depend>gtest</test_depend> -->
<!-- (13) For only used to build the document bag,使用doc_depend -->
<!-- <doc_depend>doxygen</doc_depend> -->
<!-- ============================================ -->
<!-- 实例说明 -->
<!-- ============================================ -->
<!-- (7) 依赖的构建工具,这是必须的 -->
<buildtool_depend>catkin</buildtool_depend>
<!-- (9) Specify the compile this package need to rely on -->
<build_depend>roscpp</build_depend>
<build_depend>rospy</build_depend>
<build_depend>std_msgs</build_depend>
<!-- (10) Specified according to the package build library required dependencies(导出) -->
<build_export_depend>roscpp</build_export_depend>
<build_export_depend>rospy</build_export_depend>
<build_export_depend>std_msgs</build_export_depend>
<!-- (11) Run the package the code required dependencies -->
<exec_depend>roscpp</exec_depend>
<exec_depend>rospy</exec_depend>
<exec_depend>std_msgs</exec_depend>
<!-- The export tag contains other, unspecified, tags -->
<export>
<!-- Other tools can request additional information be placed here -->
</export>
</package>
ROS.otg. ROS教程[EB/OL]. 2020-12-22[2022-7-5].
http://wiki.ros.org/cn/ROS/Tutorials. ︎ROS.org.MaryaBelanger. package.xml[EB/OL]. 2019-07-24[2022-07-18]. https://wiki.ros.org/catkin/package.xml. ︎
边栏推荐
猜你喜欢

chapter7

chapter6可视化(不想看版)

About the development forecast of the market outlook?2021-05-23

定了!就在7月30日!

Data Organization---Chapter 6 Diagram---Graph Traversal---Multiple Choice Questions

理解TCP长连接(Keepalive)

瑞吉外卖笔记——第05讲Redis入门

如何解决mysql服务无法启动1069

深度学习框架pytorch快速开发与实战chapter4

logback源码阅读(一)获取ILoggerFactory、Logger
随机推荐
FFmpeg 的AVCodecContext结构体详解
第十三单元 混入视图基类
第二届中国Rust开发者大会(RustChinaConf 2021~2022)线上大会正式开启报名
[ROS](04)package.xml详解
如何选择正规的期货交易平台开户?
RowBounds[通俗易懂]
yolov5,yolov4,yolov3乱七八糟的
Minio文件上传
第四单元 路由层
Unit 3 view layer
Unit 7 ORM table relationships and operations
Some impressions of the 519 plummet 2021-05-21
Cloin 控制台乱码
瑞吉外卖笔记——第10讲Swagger
How does Apache, the world's largest open source foundation, work?
Chapter6 visualization (don't want to see the version)
Interview | with questions to learn, Apache DolphinScheduler Wang Fuzheng
世界上最大的开源基金会 Apache 是如何运作的?
logback源码阅读(一)获取ILoggerFactory、Logger
[ROS](02)创建&编译ROS软件包Package