diff options
author | David Cole <david.cole@kitware.com> | 2012-03-03 20:03:50 (GMT) |
---|---|---|
committer | David Cole <david.cole@kitware.com> | 2012-03-09 03:43:19 (GMT) |
commit | 4693cf84927850da0c10aae4308363fdc5890379 (patch) | |
tree | 65a9cb43a0bb4b446fc233413c7e9494b914c9df /Source/cmGlobalXCodeGenerator.cxx | |
parent | ac2979e4b36577e10b2180624050e600179a53da (diff) | |
download | CMake-4693cf84927850da0c10aae4308363fdc5890379.zip CMake-4693cf84927850da0c10aae4308363fdc5890379.tar.gz CMake-4693cf84927850da0c10aae4308363fdc5890379.tar.bz2 |
Xcode: Detect new default locations of Xcode 4.3 bits and pieces (#12621)
Xcode 4.3 installs into "/Applications" by default, from the Mac App Store.
Also, the paths to the available SDKs changed: they are now within the
Xcode.app bundle.
PackageMaker is installed as a separate program, and may be installed
anywhere. It is not installed with Xcode 4.3 by default anymore.
Download the "Auxiliary Tools for Xcode" to get PackageMaker.
Put PackageMaker inside the Xcode.app bundle, in its nested Applications
folder, or put it alongside Xcode in "/Applications" and CMake will find
it.
Update references to "find" paths: add new possible locations for finding
Xcode.app and PackageMaker.app. Prefer the most recent version's locations
first, but keep the old locations as fallback search paths, too.
Thanks to all the contributors who provided and tested out various patches
for fixing this issue. Especially, but by no means limited to:
Francisco Requena EspĂ, Jamie Kirkpatrick and drfrogsplat.
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r-- | Source/cmGlobalXCodeGenerator.cxx | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx index 859503f..b764660 100644 --- a/Source/cmGlobalXCodeGenerator.cxx +++ b/Source/cmGlobalXCodeGenerator.cxx @@ -135,8 +135,17 @@ cmGlobalGenerator* cmGlobalXCodeGenerator::New() { #if defined(CMAKE_BUILD_WITH_CMAKE) cmXcodeVersionParser parser; - parser.ParseFile - ("/Developer/Applications/Xcode.app/Contents/version.plist"); + if (cmSystemTools::FileExists( + "/Applications/Xcode.app/Contents/version.plist")) + { + parser.ParseFile + ("/Applications/Xcode.app/Contents/version.plist"); + } + else + { + parser.ParseFile + ("/Developer/Applications/Xcode.app/Contents/version.plist"); + } cmsys::auto_ptr<cmGlobalXCodeGenerator> gg(new cmGlobalXCodeGenerator(parser.Version)); if (gg->XcodeVersion == 20) |