부스트를 컴파일하려고하는데 (다른 라이브러리 설치의 일부로) 내 gcc가 손상되었다고보고합니다. 내가 cmake를 실행할 때cmake로 부스트 컴파일 중 Bash 오류가 발생했습니다.
나는
-- The C compiler identification is unknown
-- The CXX compiler identification is GNU 4.7.2
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- broken
CMake Error at /usr/share/cmake-2.8/Modules/CMakeTestCCompiler.cmake:52 (MESSAGE):
The C compiler "/usr/bin/gcc" is not able to compile a simple test program.
It fails with the following output:
Change Dir: /home/lecopivo/code/bempp-inst/bempp/build/contrib/boost/build/CMakeFiles/CMakeTmp
Run Build Command:/usr/bin/make "cmTryCompileExec3895803733/fast"
/usr/bin/make -f CMakeFiles/cmTryCompileExec3895803733.dir/build.make
CMakeFiles/cmTryCompileExec3895803733.dir/build
make[1]: Entering directory
`/home/lecopivo/code/bempp-inst/bempp/build/contrib/boost/build/CMakeFiles/CMakeTmp'
/usr/bin/cmake -E cmake_progress_report
/home/lecopivo/code/bempp-inst/bempp/build/contrib/boost/build/CMakeFiles/CMakeTmp/CMakeFiles
1
Building C object
CMakeFiles/cmTryCompileExec3895803733.dir/testCCompiler.c.o
/usr/bin/gcc -m64 -O3 -march=native (Default on Linux) -o
CMakeFiles/cmTryCompileExec3895803733.dir/testCCompiler.c.o -c
/home/lecopivo/code/bempp-inst/bempp/build/contrib/boost/build/CMakeFiles/CMakeTmp/testCCompiler.c
/bin/sh: 1: Syntax error: "(" unexpected
make[1]: *** [CMakeFiles/cmTryCompileExec3895803733.dir/testCCompiler.c.o]
Error 2
make[1]: Leaving directory
`/home/lecopivo/code/bempp-inst/bempp/build/contrib/boost/build/CMakeFiles/CMakeTmp'
make: *** [cmTryCompileExec3895803733/fast] Error 2
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:28 (project)
-- Configuring incomplete, errors occurred!
내가 정말 잘못 될 일을 모르는
를 얻을. C에서 제 자신의 cmake 프로젝트를 만들 때 컴파일하는데 문제가 없습니다.
'Boost.CMake'는 건물을 부스트하는 일반적인 방법이 아닙니다. 보통 우리는'Boost.Build' 시스템을 사용합니다. [www.boost.org : 시작하기] (http://www.boost.org/doc/libs/1_55_0/more/getting_started/unix-variants.html)를 참조하십시오. 또한 컴파일러는 약간 구식입니다. (http://www.gnu.org/software/gcc/releases.html)이 중 어떤 것도 문제는 아니지만 삶을 어렵게 만들 수 있습니다. CMake는 분명히이 줄에 문제가있다 :'/ usr/bin/gcc -m64 -O3 -march = native (Linux에서는 기본값) ... ' – Drop