From b51b6e97a26b604f184646003adb7d5fb6077131 Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Thu, 19 Dec 2013 14:24:46 +0100 Subject: [PATCH] Export: Skip INTERFACE libraries when generating -config files. The properties object has just been created, so is always empty, which means the if block is never entered. The following lines do not have any effect because an INTERFACE library has no LOCATION. At the end, no code is generated for INTERFACE libraries in config-specific exported files, so skip them early. --- Source/cmExportInstallFileGenerator.cxx | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Source/cmExportInstallFileGenerator.cxx b/Source/cmExportInstallFileGenerator.cxx index 79e78df3d..1025dc0d1 100644 --- a/Source/cmExportInstallFileGenerator.cxx +++ b/Source/cmExportInstallFileGenerator.cxx @@ -297,16 +297,14 @@ cmExportInstallFileGenerator { // Collect import properties for this target. cmTargetExport const* te = *tei; - ImportPropertyMap properties; - std::set importedLocations; - if (!properties.empty() - && te->Target->GetType() == cmTarget::INTERFACE_LIBRARY) + if (te->Target->GetType() == cmTarget::INTERFACE_LIBRARY) { - this->GenerateImportPropertyCode(os, config, te->Target, properties); - this->GenerateImportedFileChecksCode(os, te->Target, properties, - importedLocations); continue; } + + ImportPropertyMap properties; + std::set importedLocations; + this->SetImportLocationProperty(config, suffix, te->ArchiveGenerator, properties, importedLocations); this->SetImportLocationProperty(config, suffix, te->LibraryGenerator,