I am trying to create an Xcode project from the Insight Toolkit (ITK, itk.org). I entered the following command into the terminal:
ccmake -DCMAKE_C_COMPILER=/Applications/Xcode.app/Contents/Developer/usr/bin/gcc -DCMAKE_CXX_COMPILER=/Applications/Xcode.app/Contents/Developer/usr/bin/g++ -GXcode /<path to source>
When I try to generate a project, it does not work with this error:
CMake Error at /Applications/CMake 2.8-7.app/Contents/share/cmake-2.8/Modules/CMakeTestCCompiler.cmake:52 (MESSAGE): The C compiler "/Applications/Xcode.app/Contents/Developer/usr/bin/gcc" is not able to compile a simple test program. It fails with the following output: Change Dir: /<path to destination folder>/CMakeFiles/CMakeTmp Run Build Command:/Applications/CMake\ 2.8-7.app/Contents/bin/cmakexbuild -project CMAKE_TRY_COMPILE.xcode build -target cmTryCompileExec -buildstyle Development xcodebuild: error: option '-buildstyle' is no longer supported
How to configure cmakexbuild call? I did not find the corresponding entry in the CMake configuration menu.
I found similar problems with other users with other projects, so I assume this is a CMake configuration problem.
I am using Xcode 4.3 and CMake 2.8.7 for Mac OS X Lion 10.7.3.
Thanks for your help,
Floor
source share