[R-SIG-Mac] [R] Rd2dvi problem.

Prof Brian Ripley ripley at stats.ox.ac.uk
Mon Nov 10 21:48:18 CET 2008

On Tue, 11 Nov 2008, Rolf Turner wrote:

> On 10/11/2008, at 7:54 PM, Prof Brian Ripley wrote:
>> R_LATEXCMD is defined in R_HOME/etc/Renviron (sourced by R CMD), and
>> conditionally re-defined in Rd2dvi.
>> On a sub-architecture build such as the CRAN MacOS distribution that will
>> be R_HOME/etc/<arch>/Renviron, and on that distribution it is defined as
>> 'false'.  So you do need to define to a proper value in your environment,
>> e.g. put R_LATEXCMD=latex in your ~/.Renviron file.
> Thanks Brian.  Tried that just now --- and of course it didn't work.
> (*Nothing* ever works for me! :-( )  In more detail --- I found that
> I didn't *have* a .Renviron file.  So I created one, with the single
> line
> 	R_LATEXCMD=latex
> But I got the same error situation as before.  Is there any other action
> I need to take to get the system to notice my ~/.Renviron file?

Oops, sorry, R CMD does not read ~/.Renviron.  You need to set
R_LATEXCMD=latex in the shell you use to run 'R CMD Rd2dvi'.

> I checked that
> 	> Sys.getenv("R_LATEXCMD")
> now does indeed return "latex".

as R does read ~/.Renviron.

> Be that as it may, I tried the expedient of sudo editing the Renviron
> file in R_HOME/etc/i386 and changing ``false'' to ``latex'' in the
> definition of R_LATEXCMD.
> And *that* worked, at least.
>> It might be worth discussing on R-sig-mac why the default is not 'latex'.
>> This is what is done on Windows, another system on which a TeX
>> installation is optional.
> I am cc-ing this message to the R-sig-mac list.
> 	cheers,
> 		Rolf

Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

More information about the R-SIG-Mac mailing list