Linux x86_64
How to install Roc
In order to develop in Roc, you need to install the Roc CLI, which includes the Roc compiler and some helpful utilities.
-
Download the latest nightly from the assets here.
-
Untar the archive:
-
To be able to run the
roc
command anywhere on your system; add the line below to your shell startup script (.profile, .zshrc, ...): -
Check everything worked by executing
roc version
-
Install libc development files and ld (binutils) if you'd like to use the repl (
roc repl
):- On Ubuntu/Debian:
- On ArchLinux/Manjaro:
- on Fedora:
How to install Roc platform dependencies
This step is not necessary if you only want to use the basic-cli platform, like in the tutorial.
But, if you want to compile Roc apps with other platforms (either in examples/
or in your own projects),
you'll need to install one or more of these platform languages too.
-
Install the Rust compiler, for apps with Rust-based platforms:
|
-
For Zig-based platforms: download zig 0.11.0, extract the archive and add export PATH=$PATH:~/path/to/zig to your shell startup script (.profile, .zshrc, …).
-
Install a C compiler, for apps with C-based platforms:
# On a Debian-based distro like Ubuntu && # On an RPM-based distro like Fedora &&
# Note: If you installed Rust in this terminal session, you'll need to open a new one first!