[R] install or uncompress package build in one platform in another platform

Duncan Murdoch murdoch.duncan at gmail.com
Thu Apr 22 16:58:26 CEST 2010


On 22/04/2010 8:09 AM, carol white wrote:
> Hi,
> Is an R package built under Unix (package.tar.gz) could be installed on other platforms like windows or Mac? The compressed tar file (.tar.gz) built under Unix doesn't seem to be uncompressed under windows (unzip under windows instead of gunzip). How to proceed?

Use either "R CMD INSTALL foo.tar.gz" at the cmd prompt, or from within 
R, install.packages("foo.tar.gz", repos=NULL, type="source").  R knows 
how to do the decompression.

If the package contains external code, this requires that you have the 
tools set up to compile it; see www.murdoch-sutherland.com/Rtools to get 
them for Windows.  Most Windows users find it tricky to get the setup 
right at first, which is why we provide binaries for CRAN packages, and 
why Uwe provides the http://win-builder.r-project.org/ service.  Simon 
Urbanek has a web page to provide the tools for the Mac.

Duncan Murdoch



More information about the R-help mailing list