叶枯 2022-08-31 12:38 采纳率: 25%
浏览 55
已结题

使用cmake编译pcl库出错

因为工作安排要接手一个已经写好的项目,编译项目的时候需要pcl点云库,需要通过源码编译然后添加到cmake的方式,但是编译pcl就需要用到flann,编译flann又需要用到pkg-config,但是我按照网上的教程安装pkg-config后发现这个cmake还是要我去添加pkg-config的文件,但是他给的指定路径我电脑上并不存在,他要的文件我在安装后的pkg-config文件夹中也找不到,求问这种情况要怎么解决,或者有没有其他方法来直接编译pcl库?

问题代码:
CMake Warning (dev) at CMakeLists.txt:21 (if):
Policy CMP0054 is not set: Only interpret if() arguments as variables or
keywords when unquoted. Run "cmake --help-policy CMP0054" for policy
details. Use the cmake_policy command to set the policy and suppress this
warning.

Quoted variables like "MSVC" will no longer be dereferenced when the policy
is set to NEW. Since the policy is not set the OLD behavior will be used.
This warning is for project developers. Use -Wno-dev to suppress it.

Could NOT find PythonInterp (missing: PYTHON_EXECUTABLE)
Could NOT find GTest (missing: GTEST_LIBRARY GTEST_INCLUDE_DIR GTEST_MAIN_LIBRARY)
CMake Warning at CMakeLists.txt:120 (message):
gtest library not found, some tests will not be run

CMake Error at H:/CMake/share/cmake-3.17/Modules/FindPackageHandleStandardArgs.cmake:165 (message):
Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)

  Reason given by package: The command
    "C:/Strawberry/perl/bin/pkg-config" --version
  failed with output
    

Call Stack (most recent call first):
H:/CMake/share/cmake-3.17/Modules/FindPackageHandleStandardArgs.cmake:458 (_FPHSA_FAILURE_MESSAGE)
H:/CMake/share/cmake-3.17/Modules/FindPkgConfig.cmake:59 (find_package_handle_standard_args)
CMakeLists.txt:149 (find_package)

  • 写回答

2条回答 默认 最新

  • 赵4老师 2022-08-31 13:48
    关注

    Could NOT find PythonInterp (missing: PYTHON_EXECUTABLE)
    安装python
    Could NOT find GTest (missing: GTEST_LIBRARY GTEST_INCLUDE_DIR GTEST_MAIN_LIBRARY)
    安装gtest

    评论

报告相同问题?

问题事件

  • 已结题 (查看结题原因) 9月13日
  • 创建了问题 8月31日

悬赏问题

  • ¥15 #MATLAB仿真#车辆换道路径规划
  • ¥15 java 操作 elasticsearch 8.1 实现 索引的重建
  • ¥15 数据可视化Python
  • ¥15 要给毕业设计添加扫码登录的功能!!有偿
  • ¥15 kafka 分区副本增加会导致消息丢失或者不可用吗?
  • ¥15 微信公众号自制会员卡没有收款渠道啊
  • ¥100 Jenkins自动化部署—悬赏100元
  • ¥15 关于#python#的问题:求帮写python代码
  • ¥20 MATLAB画图图形出现上下震荡的线条
  • ¥15 关于#windows#的问题:怎么用WIN 11系统的电脑 克隆WIN NT3.51-4.0系统的硬盘