summaryrefslogtreecommitdiff
path: root/Source/cmExportFileGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmExportFileGenerator.cxx')
-rw-r--r--Source/cmExportFileGenerator.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx
index ef336ea47a..14be5cd470 100644
--- a/Source/cmExportFileGenerator.cxx
+++ b/Source/cmExportFileGenerator.cxx
@@ -185,6 +185,10 @@ bool cmExportFileGenerator::PopulateInterfaceLinkLibrariesProperty(
ImportPropertyMap &properties,
std::vector<std::string> &missingTargets)
{
+ if(!target->IsLinkable())
+ {
+ return false;
+ }
const char *input = target->GetProperty("INTERFACE_LINK_LIBRARIES");
if (input)
{
@@ -631,6 +635,7 @@ cmExportFileGenerator
if (iface->ImplementationIsInterface)
{
+ // Policy CMP0022 must not be NEW.
this->SetImportLinkProperty(suffix, target,
"IMPORTED_LINK_INTERFACE_LIBRARIES",
iface->Libraries, properties, missingTargets);