CMake错误安装eigen 3.3.4

时间:2017-09-29 22:27:20

标签: gcc cmake eigen

我正在尝试使用CMake安装eigen。在CMake命令之后,输出的底部显示:

  

- 配置不完整,发生错误!

CMakeError.log的亮点如下。 通常情况下,谷歌给我一个答案很快,但我遇到这个问题。

有人有什么想法吗?

c++: error: unrecognized command line option '-Wshorten-64-to-32'
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-5a0156e40feb/build/CMakeFiles/CMakeTmp'
make[1]: *** [CMakeFiles/cmTryCompileExec4154354821.dir/src.cxx.o] Error 1
make: *** [cmTryCompileExec4154354821/fast] Error 2

c++: error: unrecognized command line option '-Wenum-conversion'
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-
5a0156e40feb/build/CMakeFiles/CMakeTmp'
make[1]: *** [CMakeFiles/cmTryCompileExec362406516.dir/src.cxx.o] Error 1
make: *** [cmTryCompileExec362406516/fast] Error 2

c++: error: unrecognized command line option '-Wc++11-extensions'
make[1]: *** [CMakeFiles/cmTryCompileExec2110565347.dir/src.cxx.o] Error 1
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-5a0156e40feb/build/CMakeFiles/CMakeTmp'
make: *** [cmTryCompileExec2110565347/fast] Error 2

c++: error: unrecognized command line option '-wd981'
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-
5a0156e40feb/build/CMakeFiles/CMakeTmp'
make[1]: *** [CMakeFiles/cmTryCompileExec1208176884.dir/src.cxx.o] Error 1
make: *** [cmTryCompileExec1208176884/fast] Error 2

c++: error: unrecognized command line option '-wd2304'
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-
5a0156e40feb/build/CMakeFiles/CMakeTmp'
make[1]: *** [CMakeFiles/cmTryCompileExec853725866.dir/src.cxx.o] Error 1
make: *** [cmTryCompileExec853725866/fast] Error 2

c++: error: unrecognized command line option '-strict-ansi'
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-
5a0156e40feb/build/CMakeFiles/CMakeTmp'
make[1]: *** [CMakeFiles/cmTryCompileExec2089588030.dir/src.cxx.o] Error 1
make: *** [cmTryCompileExec2089588030/fast] Error 2

c++: error: unrecognized command line option '-Qunused-arguments'
make[1]: Leaving directory `/home/localadmin/apps/eigen/eigen-eigen-
5a0156e40feb/build/CMakeFiles/CMakeTmp'
make[1]: *** [CMakeFiles/cmTryCompileExec226858210.dir/src.cxx.o] Error 1
make: *** [cmTryCompileExec226858210/fast] Error 2

Compiling the Fortran compiler identification source file 
"CMakeFortranCompilerId.F" failed.
Compiler: CMAKE_Fortran_COMPILER-NOTFOUND 
Build flags: 
Id flags: -c

1 个答案:

答案 0 :(得分:1)

正如valiano在评论中所建议的那样,

sudo apt-get install gfortran解决了这个问题。