+ bformat(_("Error reading module %1$s\n"), from_utf8(mod));
+ frontend::Alert::warning(_("Read Error"), msg);
+ }
+ }
+
+ if (cengine.empty())
+ return doc_class;
+
+ LyXCiteEngine * ce = theCiteEnginesList[cengine];
+ if (!ce) {
+ if (show_warnings) {
+ docstring const msg =
+ bformat(_("The cite engine %1$s has been requested by\n"
+ "this document but has not been found in the list of\n"
+ "available engines. If you recently installed it, you\n"
+ "probably need to reconfigure LyX.\n"), from_utf8(cengine));
+ frontend::Alert::warning(_("Cite Engine not available"), msg);
+ }
+ } else if (!ce->isAvailable() && show_warnings) {
+ docstring const prereqs = from_utf8(getStringFromVector(ce->prerequisites(), "\n\t"));
+ docstring const msg =
+ bformat(_("The cite engine %1$s requires a package that is not\n"
+ "available in your LaTeX installation, or a converter that\n"
+ "you have not installed. LaTeX output may not be possible.\n"
+ "Missing prerequisites:\n"
+ "\t%2$s\n"
+ "See section 3.1.2.3 (Modules) of the User's Guide for more information."),
+ from_utf8(cengine), prereqs);
+ frontend::Alert::warning(_("Package not available"), msg, true);
+ } else {
+ FileName layout_file = libFileSearch("citeengines", ce->getFilename());
+ if (!doc_class->read(layout_file, TextClass::CITE_ENGINE)) {
+ docstring const msg =
+ bformat(_("Error reading cite engine %1$s\n"), from_utf8(cengine));