Commit 0ad2a1c1 authored by Stephen Kelly's avatar Stephen Kelly
Browse files

Export: Never treat private link libraries as public package dependencies.

Multiple libraries in a single buildsystem can be exported to multiple
export-sets.

If a library from one export set depends on a library from
another export set, the export logic generates a check in the targets
file to verify that the target in the other export set is found. That
check is executed at downstream-find_package-time.

However, a target may depend privately on a target in another export
set. In that case, the depend used to also be listed in the required
targets in the targets file. Change the export logic to ignore the
private link entries instead.
parent faef6b4e
......@@ -736,9 +736,10 @@ cmExportFileGenerator
"IMPORTED_LINK_INTERFACE_LANGUAGES",
iface->Languages, properties, missingTargets);
std::vector<std::string> dummy;
this->SetImportLinkProperty(suffix, target,
"IMPORTED_LINK_DEPENDENT_LIBRARIES",
iface->SharedDeps, properties, missingTargets);
iface->SharedDeps, properties, dummy);
if(iface->Multiplicity > 0)
{
std::string prop = "IMPORTED_LINK_INTERFACE_MULTIPLICITY";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment