CMake警告:无法为目标生成安全的链接器搜索路径

时间:2016-02-05 17:45:16

标签: c++ linker cmake

在为pcl项目运行CMake时,我收到了一条警告消息:

-- Configuring done
CMake Warning at CMakeLists.txt:12 (add_executable):
  Cannot generate a safe linker search path for target
  handgenerator_output_to_pcd because files in some directories may conflict
  with libraries in implicit directories:

    link library [libboost_system.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib
    link library [libboost_filesystem.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib
    link library [libboost_thread.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib
    link library [libboost_date_time.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib
    link library [libboost_iostreams.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib
    link library [libboost_serialization.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib
    link library [libboost_chrono.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /usr/local/lib

  Some of these libraries may not be found correctly.

-- Generating done

如何解决此问题?

0 个答案:

没有答案