diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-08-05 17:02:45 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-10-08 23:04:38 (GMT) |
commit | c5718217ad242ca0fc6e6b15f4ee670e4a332c93 (patch) | |
tree | d93cdea4deb3bbf9a64358978d9f95e6b7cbfd96 /Source | |
parent | bf5eb4a3f394051d9245a7f0c3a18b4a1d2c948a (diff) | |
download | CMake-c5718217ad242ca0fc6e6b15f4ee670e4a332c93.zip CMake-c5718217ad242ca0fc6e6b15f4ee670e4a332c93.tar.gz CMake-c5718217ad242ca0fc6e6b15f4ee670e4a332c93.tar.bz2 |
cmGeneratorTarget: Move HaveInstallTreeRPATH from cmTarget.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmComputeLinkInformation.cxx | 2 | ||||
-rw-r--r-- | Source/cmGeneratorTarget.cxx | 10 | ||||
-rw-r--r-- | Source/cmGeneratorTarget.h | 2 | ||||
-rw-r--r-- | Source/cmTarget.cxx | 8 | ||||
-rw-r--r-- | Source/cmTarget.h | 2 |
5 files changed, 12 insertions, 12 deletions
diff --git a/Source/cmComputeLinkInformation.cxx b/Source/cmComputeLinkInformation.cxx index d35b566..d907dd0 100644 --- a/Source/cmComputeLinkInformation.cxx +++ b/Source/cmComputeLinkInformation.cxx @@ -1920,7 +1920,7 @@ void cmComputeLinkInformation::GetRPath(std::vector<std::string>& runtimeDirs, (for_install || this->Target->Target->GetPropertyAsBool("BUILD_WITH_INSTALL_RPATH")); bool use_install_rpath = - (outputRuntime && this->Target->Target->HaveInstallTreeRPATH() && + (outputRuntime && this->Target->HaveInstallTreeRPATH() && linking_for_install); bool use_build_rpath = (outputRuntime && this->Target->HaveBuildTreeRPATH(this->Config) && diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index 3a67d2c..6ad6c69 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -1212,7 +1212,7 @@ cmGeneratorTarget::NeedRelinkBeforeInstall(const std::string& config) const // will likely change between the build tree and install tree and // this target must be relinked. return this->HaveBuildTreeRPATH(config) - || this->Target->HaveInstallTreeRPATH(); + || this->HaveInstallTreeRPATH(); } //---------------------------------------------------------------------------- @@ -4695,6 +4695,14 @@ bool cmGeneratorTarget::ComputePDBOutputDir(const std::string& kind, } //---------------------------------------------------------------------------- +bool cmGeneratorTarget::HaveInstallTreeRPATH() const +{ + const char* install_rpath = this->GetProperty("INSTALL_RPATH"); + return (install_rpath && *install_rpath) && + !this->Makefile->IsOn("CMAKE_SKIP_INSTALL_RPATH"); +} + +//---------------------------------------------------------------------------- void cmGeneratorTarget::ComputeLinkInterfaceLibraries( const std::string& config, diff --git a/Source/cmGeneratorTarget.h b/Source/cmGeneratorTarget.h index 4ca0447..f068cae 100644 --- a/Source/cmGeneratorTarget.h +++ b/Source/cmGeneratorTarget.h @@ -407,6 +407,8 @@ public: class TargetPropertyEntry; + bool HaveInstallTreeRPATH() const; + private: friend class cmTargetTraceDependencies; struct SourceEntry { std::vector<cmSourceFile*> Depends; }; diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index 40f93a3..dd1d405 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -2384,14 +2384,6 @@ void cmTarget::SetPropertyDefault(const std::string& property, } //---------------------------------------------------------------------------- -bool cmTarget::HaveInstallTreeRPATH() const -{ - const char* install_rpath = this->GetProperty("INSTALL_RPATH"); - return (install_rpath && *install_rpath) && - !this->Makefile->IsOn("CMAKE_SKIP_INSTALL_RPATH"); -} - -//---------------------------------------------------------------------------- const char* cmTarget::GetOutputTargetType(bool implib) const { switch(this->GetType()) diff --git a/Source/cmTarget.h b/Source/cmTarget.h index d37f934..4b369d3 100644 --- a/Source/cmTarget.h +++ b/Source/cmTarget.h @@ -262,8 +262,6 @@ public: bool GetImplibGNUtoMS(std::string const& gnuName, std::string& out, const char* newExt = 0) const; - bool HaveInstallTreeRPATH() const; - // Get the properties cmPropertyMap &GetProperties() const { return this->Properties; } |