[cmake-developers] [CMake 0015214]: Error getting iOS compiler identification on master

Mantis Bug Tracker mantis at public.kitware.com
Wed Oct 22 04:49:55 EDT 2014


The following issue has been SUBMITTED. 
====================================================================== 
http://www.cmake.org/Bug/view.php?id=15214 
====================================================================== 
Reported By:                Gregor Jasny
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   15214
Category:                   CMake
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2014-10-22 04:49 EDT
Last Modified:              2014-10-22 04:49 EDT
====================================================================== 
Summary:                    Error getting iOS compiler identification on master
Description: 
Hello,

If I use cmake to compile the attached example for iOS it fails to get the
compiler identification:

<pre>
Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler:
Build flags:
Id flags:

The output was:
65
=== BUILD TARGET CompilerIdC OF PROJECT CompilerIdC WITH THE DEFAULT
CONFIGURATION (Debug) ===

Check dependencies
target specifies product type 'com.apple.product-type.tool', but there's no such
product type for the 'iphoneos' platform

** BUILD FAILED **
</pre>

I bisected the master branch and the offending commit is:

<pre>
0cce556b5fbe629dccee294aeece7c275343ed64 is the first bad commit
commit 0cce556b5fbe629dccee294aeece7c275343ed64
Author: Brad King <brad.king at kitware.com>
Date:   Tue Apr 29 09:21:00 2014 -0400

    Xcode: Use sysroot and deployment target to identify compiler

    Use CMAKE_OSX_SYSROOT and CMAKE_OSX_DEPLOYMENT_TARGET to set the Xcode
    SDKROOT and MACOSX_DEPLOYMENT_TARGET build settings.  This is necessary
    because some versions of Xcode select a different compiler based on
    these settings.  We need to make sure the compiler identified during
    language initialization matches what will be used for the actual build.
</pre>

The attached exmaple work with CMake 3.0.x but not with master. But maybe my
toolchain file is incomplete?

Thanks,
Gregor

Steps to Reproduce: 
unpack the attached tarball, create a build directory and run:

<pre>
~/src/cmake/bin/cmake -GXcode  -DCMAKE_TOOLCHAIN_FILE=../iOS.toolchain.cmake ..
-- 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.



-- Configuring incomplete, errors occurred!
</pre>

Additional Information: 
Xcode 6.1 on OSX 10.10 (but fails with Xcode 5.1.1, too)
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2014-10-22 04:49 Gregor Jasny   New Issue                                    
2014-10-22 04:49 Gregor Jasny   File Added: cmakebug.tar.gz                    
======================================================================




More information about the cmake-developers mailing list