Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Installation

Homebrew

For installing rastair locally on macOS and Linux, you can use homebrew:

brew tap bsblabludwig/rastair https://bitbucket.org/bsblabludwig/homebrew-rastair.git
brew install rastair

Docker

You can use the pre-built docker image in the usual way:

docker pull sbludwig/rastair:version-{{DOCKER_VERSION}}

Building using Docker

You can also build Rastair using Docker. Ensure you have Docker installed and running on your system, then, clone the repo and build the image:

docker build -t rastair .

This image is based on the R base image and includes all necessary dependencies to also run the bundled R scripts.

Conda

conda create -n rastair_env -c conda-forge -c bioconda rastair={{VERSION}}
conda activate rastair_env

Pre-built binaries

You can also download pre-built binaries for a number of platforms.

Linux

We provide a pre-built binary for Linux (x86):

This binary was built on Ubuntu 20.04 but should work on most recent distributions.

Info

While rastair itself is statically linked and therefore independent of system libraries, this is unfortunately not yet the case for htslib. If your system uses a GLIBC older than 2.30, then you will have to compile from source.

macOS

For Apple users, we provide both Apple Silicon and Intel binaries:

Building from source

Pre-requisites

To compile from source, you need a working Rust installation. You do not need to pick a version: the repository contains a rust-toolchain.toml, so rustup downloads and uses the exact toolchain rastair is built and tested with. Rastair depends on rust-htslib, which currently requires a working clang compiler as well as cmake. On most systems, these are either already available or can be installed using a standard package manager:

First, clone the repo:

git clone git@github.com:{{REPO_FULL_NAME}}.git

Then follow the platform-specific instructions below.

Ubuntu

sudo apt install clang cmake

Fedora

sudo dnf install -y clang cmake

macOS (Homebrew)

We assume that you have Xcode developer tools installed. In that case, you only need

brew install cmake

Compile

Finally, build the project using:

cargo xtask release

The binary will be located in target/release/rastair.

Tip

On some systems, you might get performance improvements by allowing the compiler to use platform-specific optimisations:

RUSTFLAGS="-C target-cpu=native" cargo xtask release