summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2005-08-30 17:58:46 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2005-08-30 17:58:46 (GMT)
commit62ae06081eff9881a1ff119ff6397521d9ce5900 (patch)
tree52175f97d12d2351c30b7f8f67db603bdc5f5160
parentfeb2d86f26b40b7b12431c21a3e60d03f6c1ed79 (diff)
downloadCMake-62ae06081eff9881a1ff119ff6397521d9ce5900.zip
CMake-62ae06081eff9881a1ff119ff6397521d9ce5900.tar.gz
CMake-62ae06081eff9881a1ff119ff6397521d9ce5900.tar.bz2
ENH: use native Deployment and Development directories
-rw-r--r--Source/CTest/cmCTestTestHandler.cxx10
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx3
-rw-r--r--Source/cmTryRunCommand.cxx21
-rw-r--r--Tests/LoadCommand/CMakeLists.txt1
-rw-r--r--Tests/LoadCommandOneConfig/CMakeLists.txt1
5 files changed, 30 insertions, 6 deletions
diff --git a/Source/CTest/cmCTestTestHandler.cxx b/Source/CTest/cmCTestTestHandler.cxx
index 82797e0..799a423 100644
--- a/Source/CTest/cmCTestTestHandler.cxx
+++ b/Source/CTest/cmCTestTestHandler.cxx
@@ -927,6 +927,16 @@ std::string cmCTestTestHandler::FindTheExecutable(const char *exe)
if ( m_CTest->GetConfigType() == "" )
{
// No config type, so try to guess it
+ if (::TryExecutable(dir.c_str(),file.c_str(),&fullPath,"Deployment"))
+ {
+ return fullPath;
+ }
+
+ if (::TryExecutable(dir.c_str(),file.c_str(),&fullPath,"Development"))
+ {
+ return fullPath;
+ }
+
if (::TryExecutable(dir.c_str(),file.c_str(),&fullPath,"Release"))
{
return fullPath;
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index 6056700..57ba86b 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -114,6 +114,7 @@ void cmGlobalXCodeGenerator::EnableLanguage(std::vector<std::string>const&
else
{
mf->AddDefinition("CMAKE_CFG_INTDIR","$(CONFIGURATION)");
+ mf->AddDefinition("CMAKE_CONFIGURATION_TYPES","Developement;Deployment");
}
mf->AddDefinition("CMAKE_GENERATOR_CC", "gcc");
mf->AddDefinition("CMAKE_GENERATOR_CXX", "g++");
@@ -174,7 +175,7 @@ std::string cmGlobalXCodeGenerator::GenerateBuildCommand(const char* makeProgram
}
else
{
- makeCommand += " -configuration Debug";
+ makeCommand += " -configuration Development";
}
makeCommand += " OBJROOT=.";
return makeCommand;
diff --git a/Source/cmTryRunCommand.cxx b/Source/cmTryRunCommand.cxx
index b9d9b4c..b4f1456 100644
--- a/Source/cmTryRunCommand.cxx
+++ b/Source/cmTryRunCommand.cxx
@@ -91,11 +91,22 @@ bool cmTryRunCommand::InitialPass(std::vector<std::string> const& argv)
}
else
{
- cmOStringStream emsg;
- emsg << "Unable to find executable for TRY_RUN: tried \""
- << command1 << "\" and \""
- << command2 << "\".";
- cmSystemTools::Error(emsg.str().c_str());
+ std::string command3 = binaryDirectory;
+ command3 += "/Development/cmTryCompileExec";
+ command3 += cmSystemTools::GetExecutableExtension();
+ if(cmSystemTools::FileExists(command3.c_str()))
+ {
+ fullPath = cmSystemTools::CollapseFullPath(command3.c_str());
+ }
+ else
+ {
+ cmOStringStream emsg;
+ emsg << "Unable to find executable for TRY_RUN: tried \""
+ << command1 << "\" and \""
+ << command2 << "\" and \""
+ << command3 << "\".";
+ cmSystemTools::Error(emsg.str().c_str());
+ }
}
}
if (fullPath.size() > 1)
diff --git a/Tests/LoadCommand/CMakeLists.txt b/Tests/LoadCommand/CMakeLists.txt
index f69d292..6c1eb45 100644
--- a/Tests/LoadCommand/CMakeLists.txt
+++ b/Tests/LoadCommand/CMakeLists.txt
@@ -47,6 +47,7 @@ IF (COMPILE_OK)
LOAD_COMMAND(CMAKE_TEST_COMMAND
${LoadedCommand_BINARY_DIR}/CMakeCommands
${LoadedCommand_BINARY_DIR}/CMakeCommands/Debug
+ ${LoadedCommand_BINARY_DIR}/CMakeCommands/Development
)
# if the command loaded, execute the command
IF (COMMAND CMAKE_TEST_COMMAND)
diff --git a/Tests/LoadCommandOneConfig/CMakeLists.txt b/Tests/LoadCommandOneConfig/CMakeLists.txt
index f69d292..6c1eb45 100644
--- a/Tests/LoadCommandOneConfig/CMakeLists.txt
+++ b/Tests/LoadCommandOneConfig/CMakeLists.txt
@@ -47,6 +47,7 @@ IF (COMPILE_OK)
LOAD_COMMAND(CMAKE_TEST_COMMAND
${LoadedCommand_BINARY_DIR}/CMakeCommands
${LoadedCommand_BINARY_DIR}/CMakeCommands/Debug
+ ${LoadedCommand_BINARY_DIR}/CMakeCommands/Development
)
# if the command loaded, execute the command
IF (COMMAND CMAKE_TEST_COMMAND)