summaryrefslogtreecommitdiffstats
path: root/Source/cmSystemTools.h
diff options
context:
space:
mode:
authorDavid Cole <david.cole@kitware.com>2008-11-26 19:38:43 (GMT)
committerDavid Cole <david.cole@kitware.com>2008-11-26 19:38:43 (GMT)
commitceaef94cccf10a02e1bcce29d3cfa6955acf4565 (patch)
treea0cbd04050fee7082c6e3e3ad38c73877fa6f806 /Source/cmSystemTools.h
parent003dbff85d58d6fc2668f2e1819b413a6357b2bc (diff)
downloadCMake-ceaef94cccf10a02e1bcce29d3cfa6955acf4565.zip
CMake-ceaef94cccf10a02e1bcce29d3cfa6955acf4565.tar.gz
CMake-ceaef94cccf10a02e1bcce29d3cfa6955acf4565.tar.bz2
ENH: Implement feature request from issue 7885. Allow setting environment variables on a per-test basis for ctest using set_test_properties ENVIRONMENT.
Diffstat (limited to 'Source/cmSystemTools.h')
-rw-r--r--Source/cmSystemTools.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/cmSystemTools.h b/Source/cmSystemTools.h
index 1ff12bf..3726c44 100644
--- a/Source/cmSystemTools.h
+++ b/Source/cmSystemTools.h
@@ -335,6 +335,17 @@ public:
/** Get the list of all environment variables */
static std::vector<std::string> GetEnvironmentVariables();
+
+ /** Append multiple variables to the current environment.
+ Return the original environment, as it was before the
+ append. */
+ static std::vector<std::string> AppendEnv(
+ std::vector<std::string>* env);
+
+ /** Restore the full environment to "env" - use after
+ AppendEnv to put the environment back to the way it
+ was. */
+ static void RestoreEnv(const std::vector<std::string>& env);
#endif
/** Setup the environment to enable VS 8 IDE output. */