From 6aba4de2f0bb534612e811be34db695a7f8e70cd Mon Sep 17 00:00:00 2001 From: Colton Staiduhar <29374798+arizotaz@users.noreply.github.com> Date: Wed, 25 Mar 2026 16:39:11 -0400 Subject: [PATCH] Fixed Linux Support --- CMakeLists.txt | 4 ---- README.md | 16 +++++++--------- src/main.cpp | 2 +- src/texture.cpp | 2 +- 4 files changed, 9 insertions(+), 15 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a764e9b..a51b814 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -250,10 +250,6 @@ target_link_libraries("${CMAKE_PROJECT_NAME}" PRIVATE OpenGL::GL freeglut_static - "-framework Cocoa" - "-framework IOKit" - "-framework CoreVideo" - "-lpthread" stb_image miniaudio ) diff --git a/README.md b/README.md index 24073b6..2d1974e 100644 --- a/README.md +++ b/README.md @@ -40,21 +40,19 @@ However, for this guide, install Visual Studio Code and [Brew](https://brew.sh). 6. Once CMake has finished configuring, press Shift+F5 (You may also need to press fn depending on how your mac is setup), and the application will run. -### For Linux (debian/ubuntu) +### For Linux (Debian/Ubuntu) + +The following packages are needed in order for the included libraries to function: cmake, build-essential, libgl1-mesa-dev, libglu1-mesa-dev, freeglut3-dev, libx11-dev, libxcursor-dev, libxtst-dev, libxft-dev, libxmu-dev, libxi-dev -The following packages are needed in order for the included libraries to function -``` -build-essential -libgl1-mesa-dev libglu1-mesa-dev freeglut3-dev -libx11-dev libxcursor-dev libxtst-dev libxft-dev libxmu-dev libxi-dev -``` Heres an easy one-line install script ``` -sudo apt install build-essential libgl1-mesa-dev libglu1-mesa-dev freeglut3-dev libx11-dev libxcursor-dev libxtst-dev libxft-dev libxmu-dev libxi-dev -y +sudo apt install cmake build-essential libgl1-mesa-dev libglu1-mesa-dev freeglut3-dev libx11-dev libxcursor-dev libxtst-dev libxft-dev libxmu-dev libxi-dev -y ``` -After this point, follow the same instructions for MacOS, or use the CLI Interface Below +After this point, follow the same instructions for MacOS, or use the CLI Interface below. + +*NOTE* - For some reason, unix needs to use #include ``, it will thow a error if #include ``. Notice the capitalization diff --git a/src/main.cpp b/src/main.cpp index faec625..1497124 100755 --- a/src/main.cpp +++ b/src/main.cpp @@ -52,7 +52,7 @@ #if defined(use_freeglut) #include #define FREEGLUT_STATIC -#include +#include #else #include #endif diff --git a/src/texture.cpp b/src/texture.cpp index 091e8b1..79babd6 100644 --- a/src/texture.cpp +++ b/src/texture.cpp @@ -15,7 +15,7 @@ #if defined(use_freeglut) # include # define FREEGLUT_STATIC -# include +# include #else # include #endif