Skip to content

Ruby on Rails - Development Dependencies

Install the following packages to set up your machine for Ruby development.

rbenv

rbenv is the recommended choice for managing Ruby on a development machine. It uses a simple plugin architecture, allowing you to drop in functionality, notably the ruby-build plugin that downloads and compiles various versions of Ruby.

Install the following dependencies required by ruby-build before proceeding.

ruby-build dependencies
sudo pacman -S \
    --needed \
    base-devel \
    rust libffi \
    libyaml \
    openssl \
    zlib

You can then install rbenv and ruby-build by following the official documentation.

Recommended

Use Basic Git Checkout method for rbenv and then to clone the ruby-build plugin.


Rails

I have removed some packages from the recommended listing found here to avoid installing a full database server on your development machine, only the development libraries (headers) will be installed to be able to build their respective gems, such as Postgres or MariaDB.

rails_dependencies.sh
sudo pacman -S \
    sqlite \
    mariadb-clients \
    mariadb-libs \
    postgresql-libs \
    imagemagick \
    ffmpeg \
    mupdf \
    mupdf-tools \
    poppler \
    yarn \
    libxml2 \
    libvips