Prerequisites
To build raylib on AmigaOS 4, you will need:
- Ogles2 & Warp3DNova SDKs from A-Eon Technology’s Software Enhancer Pack 2.2+
- SDK Addon (contains clib4)
- CMake for AmigaOS 4
- Simplegit
Steps
- Backup your existing AmigaOS 4 SDK (just in case). You can simply copy the contents of SDK: to a new directory
- Download and install SDK add-on (gets you clib4)
- In Workbench go to SDK:Tools/, and run set_DefGCC. Choose the newest GCC compiler version (was 11.5.0 when I wrote this)
- Download CMake for AmigaOS 4
- Install CMake as per instructions in AmigaOS4.README.txt, and reboot
- Install simplegit
- Build and install GL4ES from: https://github.com/ptitSeb/gl4es
- sgit clone https://github.com/ptitSeb/gl4es.git gl4es
- cd gl4es
- sgit checkout tags/v1.1.6
- mkdir build
- cd build
- cmake -DAMIGAOS4=on -DSTATICLIB=on -DAMIGAOS4_CLIB=clib4 -DCMAKE_INSTALL_PREFIX=/SDK/local/clib4 ..
- make
- Copy lib/libgl.a to SDK:clib4/lib
- Copy include/GL/* to SDK:local/common/include/GL/
- Build and install GLFW from: https://github.com/ksdhans/glfw/
- cmake -DBUILD_SHARED_LIBS=OFF -DGLFW_BUILD_OS4=ON -DAMIGAOS4=1 -DGLFW_BUILD_DOCS=OFF -DGLFW_BUILD_TESTS=OFF -DCLIB4=1 -DCMAKE_INSTALL_PREFIX=/SDK/clib4 ..
- make
- make install
- Build and install Raylib from: https://github.com/afxgroup/raylib (the raylib5 branch)
cmake -DCMAKE_BUILD_TYPE=Release -DAMIGAOS4=1 -DAMIGAOS4_CLIB=clib4 -DBUILD_SHARED_LIBS=OFF -DUSE_EXTERNAL_GLFW=ON -DCMAKE_PREFIX_PATH=/SDK/clib4 -DOPENGL_INCLUDE_DIR=/SDK/clib4/include/GL -DGRAPHICS=GRAPHICS_API_OPENGL_21 ..
make
make install