From 4c7878f721c89f2172ab0c1350af303052b3250a Mon Sep 17 00:00:00 2001 From: James Czekaj <31216671+JamesC01@users.noreply.github.com> Date: Fri, 9 Feb 2024 12:55:33 +0000 Subject: [PATCH] Make the instructions for building a project clearer --- Working-on-GNU-Linux.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/Working-on-GNU-Linux.md b/Working-on-GNU-Linux.md index dce3a24..91b96a2 100644 --- a/Working-on-GNU-Linux.md +++ b/Working-on-GNU-Linux.md @@ -165,11 +165,6 @@ Continue with: #> dnf install raylib ``` -### The simplest possible build command -``` -cc main.c -lraylib -lGL -lm -lpthread -ldl -lrt -lX11 -``` - ### Arch Linux The official Arch Repository contains the `raylib` package. Install via: @@ -177,6 +172,13 @@ The official Arch Repository contains the `raylib` package. Install via: pacman -S raylib ``` +## The simplest possible build command +After installing raylib from source or package manager, you can build a project with this command (modify as necessary): +``` +cc game.c -lraylib -lGL -lm -lpthread -ldl -lrt -lX11 +``` +Creating a Makefile will help with building as the project grows. + ## Common issues #### I get an error: `error while loading shared libraries: libraylib.so.351: cannot open shared object file: No such file or directory` after rebooting. Right after building the library it worked fine.