summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalXCodeGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx13
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)