summaryrefslogtreecommitdiffstats
path: root/Source/cmaketest.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmaketest.cxx')
-rw-r--r--Source/cmaketest.cxx23
1 files changed, 20 insertions, 3 deletions
diff --git a/Source/cmaketest.cxx b/Source/cmaketest.cxx
index 521c965..cf13f5e 100644
--- a/Source/cmaketest.cxx
+++ b/Source/cmaketest.cxx
@@ -86,12 +86,23 @@ int main (int argc, char *argv[])
std::string generator = "-G";
generator += CMAKE_GENERATOR;
args.push_back(generator);
-
+
+ std::vector<std::string> progArgs;
if(argc > 6)
{
- for (int j = 6; j < argc ; j++)
+ if(strcmp(argv[6] , "CMAKE_ARGS") == 0)
+ {
+ for (int j = 7; j < argc ; j++)
+ {
+ args.push_back(argv[j]);
+ }
+ }
+ else
{
- args.push_back(argv[j]);
+ for(int j = 6; j < argc; j++)
+ {
+ progArgs.push_back(argv[j]);
+ }
}
}
@@ -254,6 +265,12 @@ int main (int argc, char *argv[])
return 1;
}
fullPath = cmSystemTools::ConvertToOutputPath(fullPath.c_str());
+ for(std::vector<std::string>::iterator p = progArgs.begin();
+ p != progArgs.end(); ++p)
+ {
+ fullPath += " ";
+ fullPath += *p;
+ }
std::cout << "Running test executable: " << fullPath.c_str() << "\n";
int ret = 0;
if (!cmSystemTools::RunCommand(fullPath.c_str(), output, ret, 0, true))