From e6221ed2c41de86020083c4d2af58c7b28d36bb0 Mon Sep 17 00:00:00 2001 From: David Cole Date: Fri, 28 Jan 2011 09:52:47 -0500 Subject: Xcode: Allow override of CMAKE_CONFIGURATION_TYPES (#8914) --- Source/cmGlobalXCodeGenerator.cxx | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx index 1395865..d73c833 100644 --- a/Source/cmGlobalXCodeGenerator.cxx +++ b/Source/cmGlobalXCodeGenerator.cxx @@ -165,13 +165,16 @@ void cmGlobalXCodeGenerator::EnableLanguage(std::vectorconst& } else { - mf->AddCacheDefinition( - "CMAKE_CONFIGURATION_TYPES", - "Debug;Release;MinSizeRel;RelWithDebInfo", - "Semicolon separated list of supported configuration types, " - "only supports Debug, Release, MinSizeRel, and RelWithDebInfo, " - "anything else will be ignored.", - cmCacheManager::STRING); + if(!mf->GetDefinition("CMAKE_CONFIGURATION_TYPES")) + { + mf->AddCacheDefinition( + "CMAKE_CONFIGURATION_TYPES", + "Debug;Release;MinSizeRel;RelWithDebInfo", + "Semicolon separated list of supported configuration types, " + "only supports Debug, Release, MinSizeRel, and RelWithDebInfo, " + "anything else will be ignored.", + cmCacheManager::STRING); + } } mf->AddDefinition("CMAKE_GENERATOR_CC", "gcc"); mf->AddDefinition("CMAKE_GENERATOR_CXX", "g++"); -- cgit v0.12