Windows R.
These instructions were simplified from Duncan Murdoch's
website, and may make life easier for those who are trying to build R
packages under WindowsXP. It makes no claim to being up to date, but did
work under R 2.4.0 as of 7 December 2006. I assume that you have an R
package, with a DESCRIPTION file, etc. as described in Writing
R Extensions, Section 1.1.
- Unzip
the Unix
tools for R. Put these in a sensible directory (I use C:/Program
Files/GnuWin32/bin).
- Install ActivePerl
for Windows.
- Install compilers
by choosing gcc, g77, etc. when prompted.
- Install the Microsoft HTML Help
Workshop.
- If you accepted the default installation locations (and the location for the
Unix tools that I suggest above), add the following to your path environmental
variable:
C:\Program Files\R\R-2.4.0\bin;C:\Program
Files\GnuWin32\bin;C:\MinGW\bin;C:\Program Files\HTML
Help Workshop;
Make sure there is a semi-colon at
the end of the PATH before you append; that is, every path should be separated by a
semi-colon. Also make sure that Perl is in the PATH, but the Perl installer
should have taken care of that. And as R changes versions, put the appropriate
version number in the R PATH.
- Start a command shell and go to the directory prior to the directory that
holds your R package (e.g., if your package is mypackage, located in
C:\working\mypackage, go to C:\working), and type
R CMD INSTALL --build mypackage
and you should have a mypackage_x.y-z.zip where x.y-z is the
version number from your DESCRIPTION file.
Good luck!