On 03/25/2014 09:54 PM, Uwe Stöhr wrote:
Am 26.03.2014 01:41, schrieb Stephan Witt:
And who/what program should do this instead?
The LyX binary itself at run-time.
With platform dependent code to lookup the registry.
That would be tough. LyX needs the path to the following programs:
- Python
- MikTeX or TeXLive
- Ghostscript
- Imagemagick
- Perl
- Inkscape (if available)
- Gnumeric (if available)
- LilyPond (if available)
- GSview (if available)
- JabRef (if available)
The installer furthermore checks for image editors like Gimp so that
you can edit images from within LyX.
I haven't used Windows for over a decade, so may I may not understand
this. But it seems wrong to me for the installer to be looking for these
programs, and for the very reason you gave earlier, Uwe: If their
locations were to change (especially ImageMagick), then LyX wouldn't be
able to find them anymore, and either the user would have to change the
path prefix manually, or else re-install.
A much better solution would be to allow these programs to be found by
the configure.py script. I take it that this does not work, as things
presently are, because the relevant programs typically aren't in the
path. So we change the path_prefix on installation to allow the programs
to be found (and executed?). But if we had some other way to find these
programs in the configure.py script, then we could simply record the
absolute paths to them. We wouldn't need to change the path_prefix, and
the user could just reconfigure if she ran into a problem. And I take it
that is do-able, with Windows-specific code in the configure script.
Just to be clear: I'm not suggesting you do that work, Uwe, but that
somebody could do it. Note that it would also be a much more general
solution, since now the configure script would be able to find not just
the programs that you listed, but many more as well.
The one case where this solution would not work, of course, is Python
itself. But I take it that is no longer an issue, since we include our
own version and know its location, so we could simply use the absolute
path to call it.
Richard