全新空工作空间catkin编译出错,无法识别c编译器

新建一个工作空间,执行catkin_make的时候,提示**The C compiler identification is unknown**,接下来就发生错误,编译失败,错误是**CMake Error at /usr/share/cmake-3.5/Modules/CMakeTestCCompiler.cmake:61 (message):The C compiler "/usr/bin/cc" is not able to compile a simple test program.**, 完整的编译输出如下:

Base path: /home/inky/t                                                              Source space: /home/inky/t/src                                                       Build space: /home/inky/t/build                                                      Devel space: /home/inky/t/devel                                                      Install space: /home/inky/t/install                                                  ####                                                                                 #### Running command: "cmake /home/inky/t/src -DCATKIN_DEVEL_PREFIX=/home/inky/t/devel -DCMAKE_INSTALL_PREFIX=/home/inky/t/install -G Unix Makefiles" in "/home/inky/t/build"                                                                                  ####                                                                                 -- The C compiler identification is unknown                                          -- The CXX compiler identification is GNU 5.4.0                                      -- Check for working C compiler: /usr/bin/cc                                         -- Check for working C compiler: /usr/bin/cc -- broken                               CMake Error at /usr/share/cmake-3.5/Modules/CMakeTestCCompiler.cmake:61 (message):     The C compiler "/usr/bin/cc" is not able to compile a simple test program.                                                                                                It fails with the following output:                                                                                                                                        Change Dir: /home/inky/t/build/CMakeFiles/CMakeTmp                                                                                                                                                                                                                                                                                                 Run Build Command:"/usr/bin/make" "cmTC_6a4d8/fast"                                                                                                                       /usr/bin/make -f CMakeFiles/cmTC_6a4d8.dir/build.make                                CMakeFiles/cmTC_6a4d8.dir/build                                                                                                                                           make[1]: Entering directory '/home/inky/t/build/CMakeFiles/CMakeTmp'                                                                                                      Building C object CMakeFiles/cmTC_6a4d8.dir/testCCompiler.c.o                                                                                                             /usr/bin/cc -o CMakeFiles/cmTC_6a4d8.dir/testCCompiler.c.o -c                        /home/inky/t/build/CMakeFiles/CMakeTmp/testCCompiler.c                                                                                                                    CMakeFiles/cmTC_6a4d8.dir/build.make:65: recipe for target                           'CMakeFiles/cmTC_6a4d8.dir/testCCompiler.c.o' failed                                                                                                                      make[1]: *** [CMakeFiles/cmTC_6a4d8.dir/testCCompiler.c.o] Error 1                                                                                                        make[1]: Leaving directory '/home/inky/t/build/CMakeFiles/CMakeTmp'                                                                                                       Makefile:126: recipe for target 'cmTC_6a4d8/fast' failed                                                                                                                  make: *** [cmTC_6a4d8/fast] Error 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           CMake will not be able to correctly generate this project.                         Call Stack (most recent call first):                                                   CMakeLists.txt                                                                                                                                                                                                                                               -- Configuring incomplete, errors occurred!                                          See also "/home/inky/t/build/CMakeFiles/CMakeOutput.log".                            See also "/home/inky/t/build/CMakeFiles/CMakeError.log".                             Invoking "cmake" failed 











请问有谁能看出这是什么问题吗?
我试过更新和重装gcc,更新和重装make和cmake,但是都没有效果,我在其他地方克隆来的一个项目却能够正常编译,这个问题困扰我有几天了。

刚刚遇到了和你一样的问题,最后把工作空间删除了,在home路经下重新建了个空间就解决了