On Mon, May 11, 2009 at 11:26:22AM +0200, Abdelrazak Younes wrote: > Vincent van Ravesteijn - TNW wrote: > > > > > >>> 'start /min pdfview "/path/to/doc.pdf"' > >>> > >>> At least, my pdf is correctly generated. > >>> > >>> Vincent > >>> > >>> > >> Maybe PATH is different when using QProcess and therefore could not > >> find pdfview. > >> > >> Also quotations are critical because QProcess does maybe its own > >> "corrections" to the parameters. > >> > >> This is the culprit. All parameters like $$i and $$o are enclosed in \' > >> > > . > > > >> Not working here too. > >> > >> Kornel > >> > > > > To be clear, the single quotes were mine. They aren't causing the > > problem. > > > > Yep, and I already tried to replace single quotes with double and still, > python won't proceed, same for svn. This is really weird. I tried: > > python2.5 -tt "/home/younes/devel/lyx/trunk/lib/configure.py" > --with-version-suffix=2.0 > > /usr/bin/python2.5 -tt "/home/younes/devel/lyx/trunk/lib/configure.py" > --with-version-suffix=2.0 > python -tt "/home/younes/devel/lyx/trunk/lib/configure.py" > --with-version-suffix=2.0
The attached (dirty&quick) patch would work. Note that there is a subtle difference in using \" instead of \' for quoting on *nix. This only demonstrates how well thought is this QProcess attempt... -- Enrico
Index: src/support/filetools.cpp =================================================================== --- src/support/filetools.cpp (revision 29619) +++ src/support/filetools.cpp (working copy) @@ -137,7 +137,7 @@ string const quoteName(string const & na // a python script instead, where we don't have these // limitations. return (os::shell() == os::UNIX) ? - '\'' + name + '\'': + '"' + name + '"': '"' + name + '"'; case quote_python: return "\"" + subst(subst(name, "\\", "\\\\"), "\"", "\\\"")