[R] make R package for windows on Linux
Prof Brian Ripley
ripley at stats.ox.ac.uk
Wed Jan 5 12:27:56 CET 2005
On Wed, 5 Jan 2005, [ISO-8859-1] Halldor Björnsson wrote:
> I made a package on a linux box. All worked fine.
> The package contains only R code (no C). I then wanted to make a zip file so
> that I could test the package on a windows machine.
Why? R works the same on Windows and Linux.
> I have tried all the obvious ways to do this (and even some that are
> not!), but to no avail. The only instructions I find about building
> packages for windows (e.g. mypkg.zip) seem to imply that the build be
> done on a windows machine.
You've not noticed the section on cross-building: it _is_ documented
in README.packages (in the Windows installation, and in the sources).
> Is there a simple way to make mypkg.zip under linux and then install it as a
> zip file on a windows machine?
The following *may* work (it _is_ the obvious way so you have probably
tried it?).
On the Linux (or any other OS) box
cd R_HOME/library
zip -r9X mypkg mypkg
Send mypkg.zip to the Windows box.
On the Windows box
unzip mypkg.zip -d /path/to/R/library
I've just tried 'urn' and it worked for me.
--
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-help
mailing list