summaryrefslogtreecommitdiffstats
path: root/Source/cmTryRunCommand.cxx
diff options
context:
space:
mode:
authorMatt McCormick <matt.mccormick@kitware.com>2015-01-02 03:30:08 (GMT)
committerBrad King <brad.king@kitware.com>2015-01-26 15:05:26 (GMT)
commite2b1f0583f7293bce280dfab397e96acf8a5b26e (patch)
treed3bbabefbf6fb944f4f2ada8fd3a0765a7964879 /Source/cmTryRunCommand.cxx
parent07cbe3640e3afc879a07b6510de4c6e437f43f3e (diff)
downloadCMake-e2b1f0583f7293bce280dfab397e96acf8a5b26e.zip
CMake-e2b1f0583f7293bce280dfab397e96acf8a5b26e.tar.gz
CMake-e2b1f0583f7293bce280dfab397e96acf8a5b26e.tar.bz2
try_run: Add support for LINK_LIBRARIES option.
Most functionality is already implemented in Source/cmCoreTryCompile.{h,cxx}. Document and improve argument parsing. This functionality is already being used by a number of modules, like CheckCSourceCompiles.cmake, but it is not documented.
Diffstat (limited to 'Source/cmTryRunCommand.cxx')
-rw-r--r--Source/cmTryRunCommand.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmTryRunCommand.cxx b/Source/cmTryRunCommand.cxx
index 8f2deeb..8bd33d0 100644
--- a/Source/cmTryRunCommand.cxx
+++ b/Source/cmTryRunCommand.cxx
@@ -48,7 +48,8 @@ bool cmTryRunCommand
{
++i;
while (i < argv.size() && argv[i] != "COMPILE_DEFINITIONS" &&
- argv[i] != "CMAKE_FLAGS")
+ argv[i] != "CMAKE_FLAGS" &&
+ argv[i] != "LINK_LIBRARIES")
{
runArgs += " ";
runArgs += argv[i];