From 05f1069e2facc277ebe71c0ddee0f2348c389f35 Mon Sep 17 00:00:00 2001 From: McMassiveNZ <12842622+McMassiveNZ@users.noreply.github.com> Date: Mon, 8 May 2023 20:07:51 +0200 Subject: [PATCH] Update CMakeLists.txt only link to opengl32.lib on windows --- src/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 3d847d9..b727799 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -30,7 +30,10 @@ add_executable( ) target_include_directories(${current_target} PUBLIC ${CMAKE_SOURCE_DIR}/external) -target_link_libraries(${current_target} PUBLIC opengl32.lib) + +if(MSVC) + target_link_libraries(${current_target} PUBLIC opengl32.lib) +endif() if( ENABLE_ALL_REASONABLE_WARNINGS ) MESSAGE("-- Additional Warnings Enabled")