From: Jean-Marc Lasgouttes Date: Thu, 27 Jan 2011 11:14:32 +0000 (+0000) Subject: Finish fixing bug #6623 (Sweave cannot read local files) X-Git-Tag: 2.0.0~994 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=fe54f0c3413fff45fb0d6c6f3a2563f43dd98c81;p=features.git Finish fixing bug #6623 (Sweave cannot read local files) * in converters, make sure that $$p and $$r are slash-terminated paths (like in viwers, BTW) * pass the full intput path to lyxsweave.R git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37337 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/lib/configure.py b/lib/configure.py index 998f3a0b0a..aecbfaf2b4 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -627,7 +627,7 @@ def checkConverterEntries(): rc_entry = [r'''\converter literate latex "%%" "" \converter literate pdflatex "%%" ""''']) # - checkProg('a Sweave -> LaTeX converter', ['Rscript --no-save --no-restore $$s/scripts/lyxsweave.R $$i $$e $$r'], + checkProg('a Sweave -> LaTeX converter', ['Rscript --no-save --no-restore $$s/scripts/lyxsweave.R $$p$$i $$e $$r'], rc_entry = [r'''\converter sweave latex "%%" "" \converter sweave pdflatex "%%" ""''']) # diff --git a/src/Converter.cpp b/src/Converter.cpp index b96ef461e9..f208b7415f 100644 --- a/src/Converter.cpp +++ b/src/Converter.cpp @@ -412,8 +412,8 @@ bool Converters::convert(Buffer const * buffer, command = subst(command, token_from, quoteName(infile2)); command = subst(command, token_base, quoteName(from_base)); command = subst(command, token_to, quoteName(outfile2)); - command = subst(command, token_path, quoteName(infile.onlyPath().absFileName())); - command = subst(command, token_orig_path, quoteName(orig_from.onlyPath().absFileName())); + command = subst(command, token_path, quoteName(onlyPath(infile.absFileName()))); + command = subst(command, token_orig_path, quoteName(onlyPath(orig_from.absFileName()))); command = subst(command, token_encoding, buffer ? buffer->params().encoding().iconvName() : string()); command = libScriptSearch(command);