Install rmp
One line in a terminal gets the framework and puts rmp on your PATH.
It installs into your home folder, as you, and asks for no administrator: nothing in it runs
sudo, and nothing in it installs a package.
The line#
On Linux and macOS:
curl -fsSL https://omardev29.github.io/rmp-docs/install.sh | shThe same script, fetched with what each system has. None of the three BSDs has
curl in its base system:
wget -qO- https://omardev29.github.io/rmp-docs/install.sh | sh # Linux without curl
fetch -o - https://omardev29.github.io/rmp-docs/install.sh | sh # FreeBSD
ftp -o - https://omardev29.github.io/rmp-docs/install.sh | sh # OpenBSD, NetBSDOn Windows, in PowerShell — Windows PowerShell 5.1 or PowerShell 7:
irm https://omardev29.github.io/rmp-docs/install.ps1 | iexThen open a new terminal and check:
rmp helpA line that pipes a download into a shell runs whatever is at that address, so read it first if
you like: it is install.sh and install.ps1.
They are the framework's tools/install.sh and tools/install.ps1, served
by this site byte for byte as they are at the commit it documents — this site's own checks fail
the day they are not.
What it needs#
Two
things, and the installer stops and says how to get whichever is missing, having installed
nothing: git, which fetches the framework and every update after it, and
Python 3.11 or newer, which rmp is written in. It asks every Python it
finds for its version rather than trusting the name: macOS's own python3 is older than
3.11, and on Windows python3 can be the Microsoft Store's placeholder. On a Mac, git
comes with Apple's command line tools, and without them the installer stops and says
xcode-select --install.
Building a game
needs more — CMake, Ninja, a C++ compiler, and on Linux and FreeBSD the X11 development headers —
and the installer looks for those at the end. What is missing is listed with the command that
installs it on this system: apt, dnf, pacman,
zypper, apk, Homebrew, pkg, pkg_add or pkgin, and on
Windows winget. The command is printed for you to run, as root where the system wants
it; the installer never runs it.
On
a Linux console with no desktop, rmp builds games for DRM/KMS, straight to the screen,
and the installer decides the same way: there it looks for the libdrm, GBM, EGL and OpenGL ES
headers instead of X11's, and says it is on a console.
Linux from a console has the packages for each
system, and what comes after.
Where it puts things#
| Linux, macOS, the BSDs | Windows | |
|---|---|---|
| The framework, a git clone of it | ~/.local/share/rmp | %LOCALAPPDATA%\rmp |
The rmp you type | ~/.local/bin/rmp, a link to the clone's | %LOCALAPPDATA%\Programs\rmp\rmp.cmd, a two-line script that calls the clone's |
| Your PATH | a marked block in your shell's startup file, only if ~/.local/bin is not on PATH already | that folder added to your user PATH |
The
clone is of the framework's main, without the file contents of old commits, so it is
the size of one checkout rather than of the whole history.
The
startup file is the one your login shell reads, from $SHELL: ~/.zshrc for
zsh, in $ZDOTDIR when that is set; ~/.bashrc for bash on Linux and, on
macOS, the first of ~/.bash_profile, ~/.bash_login and
~/.profile that exists; ~/.config/fish/conf.d/rmp.fish for fish, under
$XDG_CONFIG_HOME when that is set;
~/.cshrc for csh, and ~/.tcshrc for tcsh when there is one; for ksh, the
file $ENV names, when it names one; and ~/.profile for any other. The
block it adds starts with # added by rmp install: ~/.local/bin on PATH and ends with
# end of rmp install, and it is added once however many times you install.
On
Windows the folder on PATH holds only that small script, and not the clone itself: in the clone,
PowerShell would find rmp.ps1 first, and its default execution policy refuses to run a
script from your own disk. So nothing needs Set-ExecutionPolicy, and
rmp is the same command in PowerShell and in cmd. Your user PATH is changed in place,
keeping every entry it had, and Windows is told, so a terminal opened from now on sees it without
logging out; the PowerShell window you installed from has it already.
Running it again, and updating#
The
same line run again updates instead of installing: when the clone is already there, it runs
rmp update in it, and then rmp install, which finds everything in place and
changes nothing. Or run the update yourself, from anywhere:
rmp updateIt fetches the framework's main and moves the clone forward to it, and says which
commit it went from and to. It never merges: a clone with changes of its own, on another branch,
or with commits the framework does not have is refused, and told what to do about it.
Your games are not touched. Each game carries its own copy of the framework and of
rmp, and keeps the one it was made with; rmp new makes the next game from
the updated framework. The
rmp command explains why.
From a clone of your own#
The installer is a clone and two commands, and the commands are rmp's own. A
framework you cloned yourself — to work on it, or into a folder you chose — goes on your PATH the
same way, by running its rmp once by its path:
git clone https://github.com/omardev29/raylib_multiplatform ~/raylib_multiplatform
~/raylib_multiplatform/rmp installOn Windows, rmp.cmd install in that folder. rmp install makes the link,
or the script on Windows, and says so when it is already there; when another rmp is in
the way — a link to some other clone — it refuses and names it, and rmp install force
replaces it. rmp update then updates that clone.
Both
act on the framework the rmp you typed belongs to, wherever you type them. A game's own
copy refuses them: it is not the framework on your PATH, and it is never updated.
In your editor#
Completion, hover and go-to-declaration
come from clangd, which VS Code, LazyVim, Zed and most editors run. The framework, and every game
rmp new makes, carries its settings in .clangd: it reads what the debug build
was compiled with, so build once (rmp build) and restart clangd. It is the desktop build on
every machine, Windows included: no Android NDK and no Xcode, and the code for other platforms is
greyed out behind its #if.
Your game's code is checked as the compiler
checks it, warnings as warnings. The framework's code and what it vendors — include/rmp/,
src/rmp/, thirdparty/ — complete and navigate like any other, and clangd
reports nothing in them: the framework's own CI builds and checks them. A Visual Studio newer than
your clangd, or a MinGW flag clang does not know, is not an error in the editor either.
In the build image, with Podman#
The
packages above go on your machine, one distribution at a time. The other way is to install none
of them: CI builds every target inside one image, ghcr.io/omardev29/raylib-build, and
you can work inside the same one. It is Ubuntu with every compiler and tool rmp uses —
clang, gcc, CMake, Ninja, zig, Emscripten for the web, MinGW-w64, clang-cl and Wine for Windows,
tcc, the Android SDK and NDK, the X11, Wayland and DRM headers — at the versions CI's own builds
are proved with. It weighs several gigabytes, and carries more than a 2D desktop game will ever
ask for; in exchange, nothing in it has to be installed later, and none of it touches your
system. Every game carries the digest it was made with, in
thirdparty/FROZEN_VERSIONS.md.
Podman runs it with no daemon and no root: rootless.
Inside the container you are root, and that root is your own user outside, so whatever it writes in
your game's folder is yours. Install Podman from your system's packages
(apt, dnf, pacman and apk all call it
podman), then, from your game's folder:
IMAGE=ghcr.io/omardev29/raylib-build@$(sed -nE 's/^build_image_digest +//p' thirdparty/FROZEN_VERSIONS.md)
podman pull "$IMAGE"
podman create --name my-game-dev -it --init \
-v "$PWD":/work:Z -w /work "$IMAGE" bash
podman start -ai my-game-devThat is a container of your own, kept between sessions: podman start -ai
my-game-dev opens it again, with anything you added to it still there, and your game's
folder is /work inside it. Build and test there with the game's own
rmp:
./rmp build
./rmp test
./rmp build windowsA few things worth knowing. --init is not optional: without an init process a game
started as the container's first process does not stop when asked. :Z labels the folder
for SELinux, where the system has it (Fedora does), and changes nothing where it does not. The build
folders remember the path they were configured from, /work inside the container, so
CMake refuses one made outside it, and the other way round: build in one place, or
./rmp clean when you move.
The game's window needs a display. On a Linux desktop, X11 or Wayland with XWayland, give the
container yours when you create it — -e DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix
--device /dev/dri --security-opt label=disable — and ./rmp run opens on your
screen. With no display to give, the next section's container brings a desktop of its own, in the
browser.
In a container, nothing installed#
The
framework, and every game rmp new makes, carries a development container:
.devcontainer/devcontainer.json. It is the build image CI runs in, pinned by the same
digest — every compiler, tool and library rmp uses, tcc, MinGW-w64, clang-cl and Wine
included — with a light desktop on top for the game's window. In VS Code, Dev Containers: Reopen
in Container; in a GitHub Codespace it is what starts. rmp run,
rmp test and rmp build windows work at once, with nothing installed on
your machine but the editor and Docker.
The desktop is a page in the browser: open the forwarded port 6080 and type the password
vscode, and the game's window is there. It draws with the CPU, not your graphics card,
which is plenty for a 2D game and slow for a heavy 3D one.
Uninstalling#
Nothing is installed anywhere else, so removing it is deleting what the table above lists. On Linux, macOS and the BSDs:
rm ~/.local/bin/rmp
rm -rf ~/.local/share/rmpand, if the installer added one, the block from # added by rmp install to
# end of rmp install in your shell's startup file — for fish, the whole of
rmp.fish. Other programs install into ~/.local/bin
too, so you may want to keep that folder on your PATH anyway.
On Windows, delete %LOCALAPPDATA%\rmp and %LOCALAPPDATA%\Programs\rmp,
and take %LOCALAPPDATA%\Programs\rmp out of your user PATH in Windows' "Edit
environment variables for your account".
Your games keep working without it: each has its own rmp at its root,
./rmp, rmp.ps1 and rmp.cmd, and its own copy of the
framework.
Next: make a game.