This page is for R 2.14.2 and later only:

Multilib toolchain

The current toolchain is based on Mingw-w64's build of gcc pre-4.6.3 and version 2.0.1 of their runtime (for both 32- and 64-bit builds). See the 'R Installation and Administration Manual' for how to make use of it.

This is part of Rtools215.exe and Rtools216.exe available from here and separately as (53MB)

Note that this is a multilib toolchain. All the tools are 32-bit Windows executables, so this toolchain can be run on 32- or 64-bit Windows. Generating 64-bit code is selected by a flag (for the compilers, -m64).

The toolchain contains separate 32- and 64-bit versions of gdb: either its bin32 or bin64 directory can put in your path or /path/to/binxx/gdb.exe used directly.

All the sources are in the multilib directory.

OpenMP and pthreads

Three alternative implementations of pthreads are available, pthreads-w32, winpthreads and winpthreads-static: all unpack to the same location as the candidate toolchain. These are needed to support OpenMP and can also be used on their own.

pthreads-w32 is a more mature implementation, but based only on DLLs which you would need to ship with a package that makes use of it. Further, as those DLLs are licensed under LGPL, you need to meet their licence requirements (the sources are here).

winpthreads is from the `experimental' branch of the MinGW-w64 project. The two versions differ in using DLLs and static linking: there are some known problems (at least with the DLL version) for 64-bit builds with packages using C++.

The current toolchain packaging includes static winpthreads, which has proved to be the most satisfactory..


32-bit build of Tcl/Tk:
64-bit build of Tcl/Tk:

The procedures and scripts used to compile the Tcl directory and in particular to produce the help file are at The sources used were tcl8.5.8-src.tar.gz, tk8.5.8-src.tar.gz, BWidget-1.8.0.tar.bz2 and Tktable2.9.tar.gz.

External software

External software to build packages should ideally be built under this toolchain: software with a C++ interface definitely will need to be.

The software we provide is under the goodies/multilib directory.

This includes a comprehensive `local' tree as which can be unpacked and pointed to by the LOCAL_SOFT macro in file src/gnuwin32/MkRules.dist when building from sources, or in the etc/{i386,x64}/Makeconf files in a binary distribution. This contains headers and static libraries for expat (2.0.1), fftw3 (3.3.3), gdal (1.9.2, includes ODBC drivers), geos (3.3.6), gmp (5.0.5), gsl (1.15), jpeg (8d), libiconv (1.14) libmpc (0.9: the mpc package does not work with 1.x), libpng (1.5.13) libsndfile (1.0.25), libxml2 (2.7.8), libz (1.2.7), mpfr (3.1.1), netcdf (4.0.1, for use with RNetCDF and ncdf, not ncdf4), proj (4.7.0), sprng (2.0b), tiff (4.0.3) and udunits2 (2.1.24)

There are also binary versions of Clp, glpk, nlopt, QuantLib and SYMPHONY for use with packages clpAPI, glpkAPI, nloptr, RQuantLib and Rsymphony. Some are packaged separately for 32- and 64-bit R, and and some are multilib.

Sources are under goodies/sources directory.