BUG: fix single module generation

This commit is contained in:
Ken Martin 2007-11-29 10:23:26 -05:00
parent 0d5e854e91
commit ad581280a5

View File

@ -1059,8 +1059,12 @@ bool cmDocumentation::PrintDocumentationSingleModule(std::ostream& os)
} }
} }
if(!moduleName.empty() if(!moduleName.empty())
&& this->CreateSingleModule(moduleName.c_str(), {
cmDocumentationSection *sec =
new cmDocumentationSection("Standard CMake Modules", "MODULES");
this->AllSections["Modules"] = sec;
if (this->CreateSingleModule(moduleName.c_str(),
this->CurrentArgument.c_str(), this->CurrentArgument.c_str(),
*this->AllSections["Modules"])) *this->AllSections["Modules"]))
{ {
@ -1070,6 +1074,8 @@ bool cmDocumentation::PrintDocumentationSingleModule(std::ostream& os)
os << moduleName << "\n"; os << moduleName << "\n";
return true; return true;
} }
}
// Argument was not a module. Complain. // Argument was not a module. Complain.
os << "Argument \"" << this->CurrentArgument.c_str() os << "Argument \"" << this->CurrentArgument.c_str()
<< "\" to --help-module is not a CMake module.\n"; << "\" to --help-module is not a CMake module.\n";