mirror of
https://github.com/reactos/CMake.git
synced 2025-02-10 05:42:45 +00:00
cmTarget: Remove 'head' argument from GetLinkerLanguage
It is only ever called with the 'this' target as the head. Co-Author: Stephen Kelly <steveire@gmail.com>
This commit is contained in:
parent
bd9b667bbe
commit
bcdb7ff9df
@ -3552,11 +3552,9 @@ private:
|
|||||||
};
|
};
|
||||||
|
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
std::string cmTarget::GetLinkerLanguage(const std::string& config,
|
std::string cmTarget::GetLinkerLanguage(const std::string& config) const
|
||||||
cmTarget const* head) const
|
|
||||||
{
|
{
|
||||||
cmTarget const* headTarget = head ? head : this;
|
return this->GetLinkClosure(config, this)->LinkerLanguage;
|
||||||
return this->GetLinkClosure(config, headTarget)->LinkerLanguage;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
@ -3842,8 +3840,7 @@ bool cmTarget::HasSOName(const std::string& config) const
|
|||||||
return ((this->GetType() == cmTarget::SHARED_LIBRARY ||
|
return ((this->GetType() == cmTarget::SHARED_LIBRARY ||
|
||||||
this->GetType() == cmTarget::MODULE_LIBRARY) &&
|
this->GetType() == cmTarget::MODULE_LIBRARY) &&
|
||||||
!this->GetPropertyAsBool("NO_SONAME") &&
|
!this->GetPropertyAsBool("NO_SONAME") &&
|
||||||
this->Makefile->GetSONameFlag(this->GetLinkerLanguage(config,
|
this->Makefile->GetSONameFlag(this->GetLinkerLanguage(config)));
|
||||||
this)));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
@ -4216,7 +4213,7 @@ void cmTarget::GetFullNameInternal(const std::string& config,
|
|||||||
const char* suffixVar = this->GetSuffixVariableInternal(implib);
|
const char* suffixVar = this->GetSuffixVariableInternal(implib);
|
||||||
|
|
||||||
// Check for language-specific default prefix and suffix.
|
// Check for language-specific default prefix and suffix.
|
||||||
std::string ll = this->GetLinkerLanguage(config, this);
|
std::string ll = this->GetLinkerLanguage(config);
|
||||||
if(!ll.empty())
|
if(!ll.empty())
|
||||||
{
|
{
|
||||||
if(!targetSuffix && suffixVar && *suffixVar)
|
if(!targetSuffix && suffixVar && *suffixVar)
|
||||||
@ -4555,7 +4552,7 @@ bool cmTarget::NeedRelinkBeforeInstall(const std::string& config) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Check for rpath support on this platform.
|
// Check for rpath support on this platform.
|
||||||
std::string ll = this->GetLinkerLanguage(config, this);
|
std::string ll = this->GetLinkerLanguage(config);
|
||||||
if(!ll.empty())
|
if(!ll.empty())
|
||||||
{
|
{
|
||||||
std::string flagVar = "CMAKE_SHARED_LIBRARY_RUNTIME_";
|
std::string flagVar = "CMAKE_SHARED_LIBRARY_RUNTIME_";
|
||||||
@ -5644,7 +5641,7 @@ bool cmTarget::IsChrpathUsed(const std::string& config) const
|
|||||||
#if defined(CMAKE_USE_ELF_PARSER)
|
#if defined(CMAKE_USE_ELF_PARSER)
|
||||||
// Enable if the rpath flag uses a separator and the target uses ELF
|
// Enable if the rpath flag uses a separator and the target uses ELF
|
||||||
// binaries.
|
// binaries.
|
||||||
std::string ll = this->GetLinkerLanguage(config, this);
|
std::string ll = this->GetLinkerLanguage(config);
|
||||||
if(!ll.empty())
|
if(!ll.empty())
|
||||||
{
|
{
|
||||||
std::string sepVar = "CMAKE_SHARED_LIBRARY_RUNTIME_";
|
std::string sepVar = "CMAKE_SHARED_LIBRARY_RUNTIME_";
|
||||||
|
@ -355,8 +355,7 @@ public:
|
|||||||
GetTargetVersion(bool soversion, int& major, int& minor, int& patch) const;
|
GetTargetVersion(bool soversion, int& major, int& minor, int& patch) const;
|
||||||
|
|
||||||
///! Return the preferred linker language for this target
|
///! Return the preferred linker language for this target
|
||||||
std::string GetLinkerLanguage(const std::string& config = "",
|
std::string GetLinkerLanguage(const std::string& config = "") const;
|
||||||
cmTarget const* head = 0) const;
|
|
||||||
|
|
||||||
/** Get the full name of the target according to the settings in its
|
/** Get the full name of the target according to the settings in its
|
||||||
makefile. */
|
makefile. */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user