Installation

Get setup for development with extendr.

Note

This page does not try to be a comprehensive installation guide. Instead, it provides a quick overview of the software you need to get started with extendr. For more detailed instructions, please refer to the official documentation of each software package.

Required software

Rust language logo

Rust [docs]

Follow the rustup installation instructions to install Rust. Note that the current minimum supported Rust version (msrv) in extendr is 1.65.0. This is to ensure CRAN compliance. Windows users will also need to install the GNU toolchain as it matches Rtools. This can be done via rustup in the terminal: rustup target add x86_64-pc-windows-gnu.

R language logo

R [docs]

We recommend using a moderately new version of R (>= 4.2), which you can download from CRAN. You can check your current R version with getRversion().

rextendr

rextendr [docs]

The R package rextendr will help you setup the necessary scaffolding for extendr projects. It also provides tools for documenting Rust functions and objects. To install the release version, use install.packages("rextendr"). For the development version, use pak::pak("extendr/rextendr"). You can then run rextendr::rust_sitrep() to check your Rust installation.

rig [docs]

The R installation manager, rig, is a cli tool that makes installing R a breeze. With rig, installing R is as simple as rig add release.

rust-analyzer logo

rust-analyzer [docs]

While this is optional, we cannot recommend it enough. If you use Visual Studio Code (VS Code) or a similar IDE, the rust-analyzer will provide you type hinting and auto-completion suggestions. It is very helpful!