It works with many compilers on windows, linux and Mac OS. Works with makefiles, visual studio, and VSCode.
Simply follow the instructions in that link and you will be done, you do not need to use the rest of this document.
## Building Library
To build your raylib game for GNU/Linux you need to download raylib git repository. raylib already comes with ready-to-use makefiles and CMake system to compile source code, examples and templates.
This guide is for all GNU/Linux distros, just note that APT is used as package manager for Debian based distros.
#Dependencies
Raylib as several dependencies that you need in order to work with it.
#### Install required tools
You need a **GCC** (or alternative C99 compiler), **make** and **git** (to download raylib repo).
sudo apt install build-essential git
Optionally, you could use **CMake** building system.
sudo apt install cmake
#### Install required libraries
You need to install some required libraries; **ALSA** for audio, **Mesa** for OpenGL accelerated graphics and **X11** for windowing system.
@ -35,6 +17,24 @@ You need to install some required libraries; **ALSA** for audio, **Mesa** for Op
It works with many compilers on windows, linux and Mac OS. Works with makefiles, visual studio, and VSCode.
Simply follow the instructions in that link and you will be done, you do not need to use the rest of this document.
## Building Library Manually
To build your raylib game for GNU/Linux you need to download raylib git repository. raylib already comes with ready-to-use makefiles and CMake system to compile source code, examples and templates.
This guide is for all GNU/Linux distros, just note that APT is used as package manager for Debian based distros.
#### Wayland
> WARNING: Wayland building requires manual generation of some wayland specific files. GLFW support for Wayland is "experimental and incomplete". For more info check issue [#2666](https://github.com/raysan5/raylib/issues/2666)
@ -73,6 +73,8 @@ Install the library to the standard directories, `usr/local/lib` and `/usr/local
_NOTE:_ raylib is configurable and can be be built in a variety of ways. Please read [`src/Makefile`](https://github.com/raysan5/raylib/blob/master/src/Makefile), [`src/config.h`](https://github.com/raysan5/raylib/blob/master/src/config.h) and [`raylib.h`](https://github.com/raysan5/raylib/blob/master/src/raylib.h) itself for a full listing of available options and values.
### Build raylib using CMake
sudo apt install cmake
Building with cmake on Linux is easy, just use the following: