diff --git a/Minecraft.Client/Build/CMakeLists.txt b/Minecraft.Client/Build/CMakeLists.txt index 8b1d9646c..c4c3601a5 100644 --- a/Minecraft.Client/Build/CMakeLists.txt +++ b/Minecraft.Client/Build/CMakeLists.txt @@ -5216,3 +5216,30 @@ endif() add_compile_options(-fpermissive -Wtemplate-body) target_link_libraries(${PROJECT_NAME} PRIVATE "${ADDITIONAL_LIBRARY_DEPENDENCIES}") target_link_libraries(${PROJECT_NAME} PRIVATE Minecraft.World) + +if(UNIX AND NOT APPLE) + find_package(OpenGL REQUIRED) + find_package(PkgConfig REQUIRED) + pkg_check_modules(GLFW3 REQUIRED glfw3) + + target_include_directories(${PROJECT_NAME} PRIVATE + ${GLFW3_INCLUDE_DIRS} + ${CMAKE_SOURCE_DIR}/4J.Input + ${CMAKE_SOURCE_DIR}/4J.Profile + ${CMAKE_SOURCE_DIR}/4J.Render + ${CMAKE_SOURCE_DIR}/4J.Storage + ) + + target_link_libraries(${PROJECT_NAME} PRIVATE + OpenGL::GL + ${GLFW3_LIBRARIES} + 4J_Input + 4J_Profile + 4J_Render + 4J_Storage + pthread + dl + ) + + target_compile_definitions(${PROJECT_NAME} PRIVATE __linux__) +endif() diff --git a/Minecraft.Client/Build/stdafx.h b/Minecraft.Client/Build/stdafx.h index f7ccf3faa..41f8edbdd 100644 --- a/Minecraft.Client/Build/stdafx.h +++ b/Minecraft.Client/Build/stdafx.h @@ -188,11 +188,10 @@ typedef XUID GameSessionUID; #include "../Platform/Windows64/4JLibs/inc/4J_Render.h" #include "../Platform/Windows64/4JLibs/inc/4J_Storage.h" #elif defined __linux__ - // draw the rest of the owl - #include "../Platform/Windows64/4JLibs/inc/4J_Input.h" - #include "../Platform/Windows64/4JLibs/inc/4J_Profile.h" - #include "../Platform/Windows64/4JLibs/inc/4J_Render.h" - #include "../Platform/Windows64/4JLibs/inc/4J_Storage.h" + #include "../../4J.Input/4J_Input.h" + #include "../../4J.Profile/4J_Profile.h" + #include "../../4J.Render/4J_Render.h" + #include "../../4J.Storage/4J_Storage.h" #elif defined __PSVITA__ #include "../Platform/PSVita/4JLibs/inc/4J_Input.h" #include "../Platform/PSVita/4JLibs/inc/4J_Profile.h"