summaryrefslogtreecommitdiffstats
path: root/Source/cmComputeLinkInformation.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2008-01-31 13:05:34 (GMT)
committerBrad King <brad.king@kitware.com>2008-01-31 13:05:34 (GMT)
commitafd7d4ca4c5a4855b6f932af644e09a886b20a3d (patch)
treec7c17086f25cac2e89f20e613397f80eb257513c /Source/cmComputeLinkInformation.cxx
parent3a05425309dd19f4c91febdf96b4ac3fc1d17ce5 (diff)
downloadCMake-afd7d4ca4c5a4855b6f932af644e09a886b20a3d.zip
CMake-afd7d4ca4c5a4855b6f932af644e09a886b20a3d.tar.gz
CMake-afd7d4ca4c5a4855b6f932af644e09a886b20a3d.tar.bz2
ENH: Add target property LINK_SEARCH_END_STATIC to help people building static binaries on some platforms.
Diffstat (limited to 'Source/cmComputeLinkInformation.cxx')
-rw-r--r--Source/cmComputeLinkInformation.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/Source/cmComputeLinkInformation.cxx b/Source/cmComputeLinkInformation.cxx
index 1e340c0..ec55c45 100644
--- a/Source/cmComputeLinkInformation.cxx
+++ b/Source/cmComputeLinkInformation.cxx
@@ -340,7 +340,15 @@ bool cmComputeLinkInformation::Compute()
// Restore the target link type so the correct system runtime
// libraries are found.
- this->SetCurrentLinkType(this->StartLinkType);
+ const char* lss = this->Target->GetProperty("LINK_SEARCH_END_STATIC");
+ if(cmSystemTools::IsOn(lss))
+ {
+ this->SetCurrentLinkType(LinkStatic);
+ }
+ else
+ {
+ this->SetCurrentLinkType(this->StartLinkType);
+ }
// Compute the linker search path.
this->ComputeLinkerSearchDirectories();