0

So I was trying to install libssh base on instruction from https://github.com/substack/libssh/blob/master/INSTALL

Then when I was trying to build using cmake I have run into problems. I have cmake module on my linux server "cmake/3.7.2-1"

When I have executed command

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

I got following errors:

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!

Google didnt help. Any adivse appreciate.

Th. Thielemann
  • 2,592
  • 1
  • 23
  • 38
  • Are you able to call the compiler at '.../4.9.1/Linux_x86_64_compiled/bin/gcc' from commandline just from the folder you call cmake from? Why are there three dots(...)? – Th. Thielemann Mar 07 '18 at 14:10
  • Yes I can, compiler is working. I have removed full path sicne it is internal project path on which I'm working and dont what to share the name of this, but it should matter for this case. /.../gcc/4.9.1/Linux_x86_64_compiled/bin/gcc gcc: fatal error: no input files compilation terminated. – Slyboots90 Mar 07 '18 at 14:32

0 Answers0