CMakeLists.txt与package.xml依赖项比较

这个是package.xml的依赖项

<license>Apache-2.0</license>

<buildtool_depend>ament_cmake</buildtool_depend>

<depend>curl</depend>

<depend>python3-yaml</depend>

<!-- these are needed to build fastrtps -->

<buildtool_depend>asio</buildtool_depend>

<buildtool_depend>tinyxml2</buildtool_depend>

<!-- end fastrtps deps -->

<depend>clang-tidy</depend>

<build_depend>flex</build_depend>

<build_depend>bison</build_depend>

<build_depend>libncurses-dev</build_depend>

<build_depend>usbutils</build_depend>

<exec_depend>python3-vcstool</exec_depend>

<test_depend>ament_lint_auto</test_depend>

<test_depend>ament_lint_common</test_depend>

<export>

这个是Cmakelists.txt的依赖项

find dependencies

find_package(ament_cmake REQUIRED)

uncomment the following section in order to fill in

further dependencies manually.

find_package(<dependency> REQUIRED)

if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)

the following line skips the linter which checks for copyrights

uncomment the line when a copyright and license is not present in all source files

#set(ament_cmake_copyright_FOUND TRUE)

the following line skips cpplint (only works in a git repo)

uncomment the line when this package is not in a git repo

#set(ament_cmake_cpplint_FOUND TRUE)

ament_lint_auto_find_test_dependencies()

endif()

可以看出来package.xml的依赖项远远多于cmakelists.txt依赖项,并不是一样的。

解释:cmakelists.txt只负责编译有关的依赖,其他无关不用管,package.xml包含了所有的依赖项,所以cmakelist依赖包含于package.xml依赖

相关推荐
研來如此4 天前
tinyxml2 常用读取接口对照表
xml·c++·tinyxml2
pupudawang5 天前
使用 Logback 的最佳实践:`logback.xml` 与 `logback-spring.xml` 的区别与用法
xml·spring·logback
jf加菲猫5 天前
第10章 数据处理
xml·开发语言·数据库·c++·qt·ui
Java成神之路-5 天前
序列化协议全解析:XML、SOAP、JSON 与 Protobuf 实战对比及 Protobuf 演进方案
xml·json
帅次5 天前
WebView 并发初始化竞争风险分析
android·xml·flutter·kotlin·webview·androidx·dalvik
程序员小崔日记7 天前
一篇文章带你入门漏洞靶场:从 0 到 1 玩转 bWAPP(附完整安装教程)
xml·网络安全·漏洞学习·靶场搭建
xuhaoyu_cpp_java8 天前
XML学习
xml·java·笔记·学习
Riu_Peter9 天前
【技术】Maven 配置 settings.xml 轮询下载
xml·java·maven
それども10 天前
Mybatis xml 执行提示 NoSuchPropertyException
xml·mybatis
E_ICEBLUE10 天前
在 Python 中转换 XML 为 PDF 文档:基础转换与转换设置
xml·python·pdf