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依赖

相关推荐
java1234_小锋4 天前
MyBatis中XML映射有哪些标签?
xml·tomcat·mybatis
大腕先生4 天前
通用分页超详细介绍(附带源代码解析&页面展示效果)
xml·java·linux·服务器·开发语言·前端·idea
许彰午7 天前
Spring Boot + Vue 实现 XML 动态表单:固定字段 + 自由扩展方案
xml·vue.js·spring boot
untE EADO8 天前
Tomcat的server.xml配置详解
xml·java·tomcat
zuowei28898 天前
spring实例化对象的几种方式(使用XML配置文件)
xml·java·spring
weixin_520649878 天前
xml json ini 文件语法
xml·java·json
Full Stack Developme8 天前
Hutool XML 操作教程
xml·windows·python
阿亮爱学代码10 天前
初识Android界面布局
android·xml·view·viewgroup
eSsO KERF11 天前
使用 Logback 的最佳实践:`logback.xml` 与 `logback-spring.xml` 的区别与用法
xml·spring·logback