|
@@ -791,12 +791,13 @@ void
|
|
|
cmExportFileGenerator
|
|
|
::SetImportLinkInterface(const std::string& config, std::string const& suffix,
|
|
|
cmGeneratorExpression::PreprocessContext preprocessRule,
|
|
|
- cmTarget* target, ImportPropertyMap& properties,
|
|
|
+ cmGeneratorTarget* target, ImportPropertyMap& properties,
|
|
|
std::vector<std::string>& missingTargets)
|
|
|
{
|
|
|
// Add the transitive link dependencies for this configuration.
|
|
|
- cmTarget::LinkInterface const* iface = target->GetLinkInterface(config,
|
|
|
- target);
|
|
|
+ cmTarget::LinkInterface const* iface = target->Target->GetLinkInterface(
|
|
|
+ config,
|
|
|
+ target->Target);
|
|
|
if (!iface)
|
|
|
{
|
|
|
return;
|
|
@@ -829,12 +830,14 @@ cmExportFileGenerator
|
|
|
}
|
|
|
|
|
|
const bool newCMP0022Behavior =
|
|
|
- target->GetPolicyStatusCMP0022() != cmPolicies::WARN
|
|
|
- && target->GetPolicyStatusCMP0022() != cmPolicies::OLD;
|
|
|
+ target->Target
|
|
|
+ ->GetPolicyStatusCMP0022() != cmPolicies::WARN
|
|
|
+ && target->Target
|
|
|
+ ->GetPolicyStatusCMP0022() != cmPolicies::OLD;
|
|
|
|
|
|
if(newCMP0022Behavior && !this->ExportOld)
|
|
|
{
|
|
|
- cmMakefile *mf = target->GetMakefile();
|
|
|
+ cmMakefile *mf = target->Target->GetMakefile();
|
|
|
std::ostringstream e;
|
|
|
e << "Target \"" << target->GetName() << "\" has policy CMP0022 enabled, "
|
|
|
"but also has old-style LINK_INTERFACE_LIBRARIES properties "
|
|
@@ -854,7 +857,7 @@ cmExportFileGenerator
|
|
|
preprocessRule);
|
|
|
if (!prepro.empty())
|
|
|
{
|
|
|
- this->ResolveTargetsInGeneratorExpressions(prepro, target,
|
|
|
+ this->ResolveTargetsInGeneratorExpressions(prepro, target->Target,
|
|
|
missingTargets,
|
|
|
ReplaceFreeTargets);
|
|
|
properties["IMPORTED_LINK_INTERFACE_LIBRARIES" + suffix] = prepro;
|
|
@@ -866,12 +869,13 @@ void
|
|
|
cmExportFileGenerator
|
|
|
::SetImportDetailProperties(const std::string& config,
|
|
|
std::string const& suffix,
|
|
|
- cmTarget* target, ImportPropertyMap& properties,
|
|
|
+ cmGeneratorTarget* target,
|
|
|
+ ImportPropertyMap& properties,
|
|
|
std::vector<std::string>& missingTargets
|
|
|
)
|
|
|
{
|
|
|
// Get the makefile in which to lookup target information.
|
|
|
- cmMakefile* mf = target->GetMakefile();
|
|
|
+ cmMakefile* mf = target->Makefile;
|
|
|
|
|
|
// Add the soname for unix shared libraries.
|
|
|
if(target->GetType() == cmTarget::SHARED_LIBRARY ||
|
|
@@ -884,14 +888,14 @@ cmExportFileGenerator
|
|
|
{
|
|
|
std::string prop;
|
|
|
std::string value;
|
|
|
- if(target->HasSOName(config))
|
|
|
+ if(target->Target->HasSOName(config))
|
|
|
{
|
|
|
if(mf->IsOn("CMAKE_PLATFORM_HAS_INSTALLNAME"))
|
|
|
{
|
|
|
- value = this->InstallNameDir(target, config);
|
|
|
+ value = this->InstallNameDir(target->Target, config);
|
|
|
}
|
|
|
prop = "IMPORTED_SONAME";
|
|
|
- value += target->GetSOName(config);
|
|
|
+ value += target->Target->GetSOName(config);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -904,8 +908,9 @@ cmExportFileGenerator
|
|
|
}
|
|
|
|
|
|
// Add the transitive link dependencies for this configuration.
|
|
|
- if(cmTarget::LinkInterface const* iface = target->GetLinkInterface(config,
|
|
|
- target))
|
|
|
+ if(cmTarget::LinkInterface const* iface =
|
|
|
+ target->Target
|
|
|
+ ->GetLinkInterface(config, target->Target))
|
|
|
{
|
|
|
this->SetImportLinkProperty(suffix, target,
|
|
|
"IMPORTED_LINK_INTERFACE_LANGUAGES",
|
|
@@ -931,7 +936,7 @@ template <typename T>
|
|
|
void
|
|
|
cmExportFileGenerator
|
|
|
::SetImportLinkProperty(std::string const& suffix,
|
|
|
- cmTarget* target,
|
|
|
+ cmGeneratorTarget* target,
|
|
|
const std::string& propName,
|
|
|
std::vector<T> const& entries,
|
|
|
ImportPropertyMap& properties,
|
|
@@ -955,7 +960,7 @@ cmExportFileGenerator
|
|
|
sep = ";";
|
|
|
|
|
|
std::string temp = *li;
|
|
|
- this->AddTargetNamespace(temp, target, missingTargets);
|
|
|
+ this->AddTargetNamespace(temp, target->Target, missingTargets);
|
|
|
link_entries += temp;
|
|
|
}
|
|
|
|