[CMake] CMake 3.1 unable to detect AppleClang when cross-compiling for iOS

Parag Chandra parag at ionicsecurity.com
Tue Dec 16 17:23:56 EST 2014


This problem seems related to some others:

http://www.cmake.org/Bug/view.php?id=15237
http://www.cmake.org/Bug/view.php?id=15214

Basically, my colleague gets the following errors when he tries to run CMake on a project that I created:


-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
CMake Error in :
  No CMAKE_C_COMPILER could be found.



CMake Error in :
  No CMAKE_CXX_COMPILER could be found.


However, I don't encounter this error on my machine - CMake correctly detects AppleClang for both C and C++. We are both using the same Xcode (6.1.1), both on OSX 10.9. As a workaround, he is passing -DCMAKE_C_COMPILER=clang and -DCMAKE_CXX_COMPILER=clang++ on the command line, which still results in the "compiler identification is unknown" messages, but enables CMake to still successfully generate the Xcode project. We've tried both 3.1rc2 and 3.1rc3. Does anyone have any ideas?

Thanks,


Parag Chandra
Software Engineer, Mobile Team
Mobile: +1.919.824.1410

[https://www.ionicsecurity.com/IonicSigHz.png]<https://ionic.com>

Ionic Security Inc.
1170 Peachtree St. NE STE 2285, Atlanta, GA 30309










-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20141216/1312d412/attachment-0001.html>


More information about the CMake mailing list