#endif
-extern void QuitLyX();
+extern void QuitLyX(bool);
extern LyXServer * lyxserver;
if (last_loaded) {
bool success = false;
if (last_loaded->dispatch(batch_command, &success)) {
- QuitLyX();
+ QuitLyX(false);
exit(!success);
}
}
lyx_gui::start(batch_command, files);
else {
// Something went wrong above
- QuitLyX();
+ QuitLyX(false);
exit(EXIT_FAILURE);
}
}
signal(SIGTERM, error_handler);
// SIGPIPE can be safely ignored.
-#if !defined (USE_POSIX_PACKAGING)
- // Add the directory containing the LyX executable to the path
- // so that LyX can find things like reLyX.
- if (package().build_support().empty())
- prependEnvPath("PATH", package().binary_dir());
-#endif
-
// Check that user LyX directory is ok. We don't do that if
// running in batch mode.
bool reconfigure = false;
if (!lyxrc.path_prefix.empty())
prependEnvPath("PATH", lyxrc.path_prefix);
+#if !defined (USE_POSIX_PACKAGING)
+ // Add the directory containing the LyX executable to the path
+ // so that LyX can find things like tex2lyx.
+ if (package().build_support().empty())
+ prependEnvPath("PATH", package().binary_dir());
+#endif
+
// Having reset the PATH we're now in a position to run configure
// if necessary.
if (reconfigure)
// to create it. If the user says "no", then exit.
if (explicit_userdir &&
Alert::prompt(
- _("Missing LyX support directory"),
+ _("Missing user LyX directory"),
bformat(_("You have specified a non-existent user "
"LyX directory, %1$s.\n"
"It is needed to keep your own configuration."),
exit(1);
}
batch = arg;
- is_gui = false;
return 1;
}