[Rd] Rd2dvi - script (PR#1029)

Kurt Hornik Kurt.Hornik@ci.tuwien.ac.at
Sun, 22 Jul 2001 17:02:04 +0200

>>>>> olefc  writes:

> Full_Name: Ole Christensen
> Version: 1.3.0
> OS: Solaris
> Submission from: (NULL) (

> I have discovered a problem with script Rd2dvi for R-1.3.0 on our
> Solaris machines.  When writing R CMD Rd2dvi Name_of_Package, then
> things go wrong with the conversion to Latex of the DESCRIPTION file
> in the package.

> Having discussed the problem with our system administrator, he
> constructed a script illustrating the problem (see below: script a,
> and output b).  It seems that our Solaris machines makes a further
> expansion in the shell scripts than intended ( \\b -> \b ->
> <Backspace> ).

> We have also tested the script on a SunOS 4.1.2 and a Debian/GNU Linux
> 2.0.36 machine, where everything worked fine.

> ...

Thanks for pointing this out.

As newer versions of the autoconf manual point out

	The simple @code{echo} is probably the most surprising source of
	portability troubles.  It is not possible to use @samp{echo}
	portably unless both options and escape sequences are omitted.
	New applications which are not aiming at portability should use
	@samp{printf} instead of @samp{echo}.


	Do not use backslashes in the arguments, as there is no
	consensus on their handling.

The problem is that Solaris builtin echo and /usr/bin/echo by default
interpret `\b' et al as special backslash-escaped sequences.

The solution is not to use echo for producing LaTeX text but here
documents instead.  Will fix.

[There is similar code in doc/manual/Makefile.in, but it does not use
any `recognized' escape sequences ...]

r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch