| 74 | } |
| 75 | |
| 76 | void cmInstallExportGenerator::GenerateScript(std::ostream& os) |
| 77 | { |
| 78 | // Skip empty sets. |
| 79 | if (this->ExportSet->GetTargetExports().empty()) { |
| 80 | std::ostringstream e; |
| 81 | e << "INSTALL(" << this->InstallSubcommand() << ") given unknown export \"" |
| 82 | << this->ExportSet->GetName() << "\""; |
| 83 | cmSystemTools::Error(e.str()); |
| 84 | return; |
| 85 | } |
| 86 | |
| 87 | // Create the temporary directory in which to store the files. |
| 88 | this->ComputeTempDir(); |
| 89 | cmSystemTools::MakeDirectory(this->TempDir); |
| 90 | |
| 91 | // Construct a temporary location for the file. |
| 92 | this->MainImportFile = cmStrCat(this->TempDir, '/', this->FileName); |
| 93 | |
| 94 | // Generate the import file for this export set. |
| 95 | this->EFGen->SetExportFile(this->MainImportFile.c_str()); |
| 96 | this->EFGen->SetNamespace(this->Namespace); |
| 97 | if (this->ConfigurationTypes->empty()) { |
| 98 | if (!this->ConfigurationName.empty()) { |
| 99 | this->EFGen->AddConfiguration(this->ConfigurationName); |
| 100 | } else { |
| 101 | this->EFGen->AddConfiguration(""); |
| 102 | } |
| 103 | } else { |
| 104 | for (std::string const& c : *this->ConfigurationTypes) { |
| 105 | this->EFGen->AddConfiguration(c); |
| 106 | } |
| 107 | } |
| 108 | this->EFGen->GenerateImportFile(); |
| 109 | |
| 110 | // Perform the main install script generation. |
| 111 | this->cmInstallGenerator::GenerateScript(os); |
| 112 | } |
| 113 | |
| 114 | void cmInstallExportGenerator::GenerateScriptConfigs(std::ostream& os, |
| 115 | Indent indent) |
nothing calls this directly
no test coverage detected