|
|
@@ -656,6 +656,18 @@ void cmGeneratorTarget::GetSourceFiles(std::vector<cmSourceFile*> &files,
|
|
|
this->Target->GetSourceFiles(files, config);
|
|
|
}
|
|
|
|
|
|
+//----------------------------------------------------------------------------
|
|
|
+bool cmGeneratorTarget::HasSOName(const std::string& config) const
|
|
|
+{
|
|
|
+ // soname is supported only for shared libraries and modules,
|
|
|
+ // and then only when the platform supports an soname flag.
|
|
|
+ return ((this->GetType() == cmTarget::SHARED_LIBRARY ||
|
|
|
+ this->GetType() == cmTarget::MODULE_LIBRARY) &&
|
|
|
+ !this->GetPropertyAsBool("NO_SONAME") &&
|
|
|
+ this->Makefile->GetSONameFlag(
|
|
|
+ this->Target->GetLinkerLanguage(config)));
|
|
|
+}
|
|
|
+
|
|
|
//----------------------------------------------------------------------------
|
|
|
std::string cmGeneratorTarget::GetSOName(const std::string& config) const
|
|
|
{
|
|
|
@@ -1407,7 +1419,7 @@ void cmGeneratorTarget::GetLibraryNames(std::string& name,
|
|
|
// Check for library version properties.
|
|
|
const char* version = this->GetProperty("VERSION");
|
|
|
const char* soversion = this->GetProperty("SOVERSION");
|
|
|
- if(!this->Target->HasSOName(config) ||
|
|
|
+ if(!this->HasSOName(config) ||
|
|
|
this->Target->IsFrameworkOnApple())
|
|
|
{
|
|
|
// Versioning is supported only for shared libraries and modules,
|