由于cmake错误导致libssh失败

时间:2018-03-07 11:59:48

标签: cmake libssh

所以我试图在https://github.com/substack/libssh/blob/master/INSTALL

的指令下安装libssh

然后,当我尝试使用cmake构建时,我遇到了问题。我的linux服务器上有cmake模块" cmake / 3.7.2-1"

当我执行命令

cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Debug ..

我遇到以下错误:

CMake Error at /afs/.../RHEL6-x86_64/cmake/3.7.2-1/share/cmake-3.7/Modules/CMakeTestCXXCompiler.cmake:44 (message):
  The C++ compiler ".../4.9.1/Linux_x86_64_compiled/bin/gcc"
  is not able to compile a simple test program.

  It fails with the following output:

   Change Dir: /local/efrimaz/libSSH/v0-6/build/CMakeFiles/CMakeTmp


  Run Build Command:"/usr/bin/gmake" "cmTC_e97bb/fast"

  /usr/bin/gmake -f CMakeFiles/cmTC_e97bb.dir/build.make
  CMakeFiles/cmTC_e97bb.dir/build

  gmake[1]: Entering directory
  `/local/efrimaz/libSSH/v0-6/build/CMakeFiles/CMakeTmp'

  Building CXX object CMakeFiles/cmTC_e97bb.dir/testCXXCompiler.cxx.o

  /.../4.9.1/Linux_x86_64_compiled/bin/gcc -o
  CMakeFiles/cmTC_e97bb.dir/testCXXCompiler.cxx.o -c
  /local/efrimaz/libSSH/v0-6/build/CMakeFiles/CMakeTmp/testCXXCompiler.cxx

  Linking CXX executable cmTC_e97bb


  /afs/.../cmake/3.7.2-1/bin/cmake
  -E cmake_link_script CMakeFiles/cmTC_e97bb.dir/link.txt --verbose=1

  /.../4.9.1/Linux_x86_64_compiled/bin/gcc
  CMakeFiles/cmTC_e97bb.dir/testCXXCompiler.cxx.o -o cmTC_e97bb -rdynamic

  /usr/bin/ld: unrecognized option '-plugin'

  /usr/bin/ld: use the --help option for usage information

  collect2: error: ld returned 1 exit status

  gmake[1]: *** [cmTC_e97bb] Error 1

  gmake[1]: Leaving directory
  `/local/efrimaz/libSSH/v0-6/build/CMakeFiles/CMakeTmp'

  gmake: *** [cmTC_e97bb/fast] Error 2


  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  examples/CMakeLists.txt:1 (project)


-- Configuring incomplete, errors occurred!
谷歌没有帮助。任何adivse欣赏。

0 个答案:

没有答案