From ef8aa19c33e83ff019595fd7f8fdc29c35c336a3 Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Wed, 13 Feb 2013 18:21:12 -0800 Subject: Imported Upstream version 2.8.10.2 --- Source/cmExportBuildFileGenerator.cxx | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'Source/cmExportBuildFileGenerator.cxx') diff --git a/Source/cmExportBuildFileGenerator.cxx b/Source/cmExportBuildFileGenerator.cxx index 32595ee4b..fb3f39fe6 100644 --- a/Source/cmExportBuildFileGenerator.cxx +++ b/Source/cmExportBuildFileGenerator.cxx @@ -72,8 +72,9 @@ cmExportBuildFileGenerator if(!properties.empty()) { // Get the rest of the target details. + std::vector missingTargets; this->SetImportDetailProperties(config, suffix, - target, properties); + target, properties, missingTargets); // TOOD: PUBLIC_HEADER_LOCATION // This should wait until the build feature propagation stuff @@ -82,6 +83,7 @@ cmExportBuildFileGenerator // properties); // Generate code in the export file. + this->GenerateMissingTargetsCheckCode(os, missingTargets); this->GenerateImportPropertyCode(os, config, target, properties); } } @@ -131,6 +133,25 @@ cmExportBuildFileGenerator } } +//---------------------------------------------------------------------------- +void +cmExportBuildFileGenerator::HandleMissingTarget( + std::string& link_libs, std::vector&, + cmMakefile*, cmTarget* depender, cmTarget* dependee) +{ + // The target is not in the export. + if(!this->AppendMode) + { + // We are not appending, so all exported targets should be + // known here. This is probably user-error. + this->ComplainAboutMissingTarget(depender, dependee); + } + // Assume the target will be exported by another command. + // Append it with the export namespace. + link_libs += this->Namespace; + link_libs += dependee->GetName(); +} + //---------------------------------------------------------------------------- void cmExportBuildFileGenerator -- cgit v1.2.3