Error:The C compiler is not able to compile a simple test program

Hello,

I dont have any idea what I should to do. Can you help me? I thnik, the problems it's xcode because clion using C++ compilator from xcode. (I'm working on Mac)

Error:The C compiler "/Applications/Moje programy/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc" is not able to compile a simple test program.
It fails with the following output:
Change Dir: /Users/KrzysztofWojdak/Library/Caches/CLion12/cmake/generated/c3eddf6b/c3eddf6b/__default__/CMakeFiles/CMakeTmp
Run Build Command:"/usr/bin/make" "cmTC_f3f9d/fast"
/Applications/Moje programy/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTC_f3f9d.dir/build.make CMakeFiles/cmTC_f3f9d.dir/build
make: /Applications/Moje: No such file or directory
make: *** [cmTC_f3f9d/fast] Error 1
CMake will not be able to correctly generate this project.

Error:Configuration Debug
The C compiler "/Applications/Moje programy/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc" is not able to compile a simple test program.
It fails with the following output:
Change Dir: /Users/KrzysztofWojdak/Library/Caches/CLion12/cmake/generated/c3eddf6b/c3eddf6b/Debug/CMakeFiles/CMakeTmp
Run Build Command:"/usr/bin/make" "cmTC_54dc1/fast"
/Applications/Moje programy/Xcode.app/Contents/Developer/usr/bin/make -f CMakeFiles/cmTC_54dc1.dir/build.make CMakeFiles/cmTC_54dc1.dir/build
make: /Applications/Moje: No such file or directory
make: *** [cmTC_54dc1/fast] Error 1
CMake will not be able to correctly generate this project.

1 comment
Comment actions Permalink

It looks like CMake does not like the space in "/Applications/Moje programy". Please try moving Xcode to a path that does not contain spaces, and update the path to xcode by using xcode-select, or Xcode's settings.

Alternatively you could try AppCode — it has the same level of C/C++, but uses Xcode project model instead of CMake.

0

Please sign in to leave a comment.