widelands: fix build

This commit is contained in:
q66 2020-01-02 04:35:28 +01:00
parent bf3adecb8f
commit 2ddceee333

View File

@ -0,0 +1,13 @@
This fixes linker errors with glvnd.
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -181,7 +181,7 @@ endif(OPTION_ASAN)
# This is set to avoid linker errors when using GLVND-libs on Linux
if("${OpenGL_GL_PREFERENCE}" STREQUAL "GLVND")
- set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -lGL")
+ link_libraries("GL")
add_compile_definitions(WL_USE_GLVND)
message(STATUS "Adding linker flags for GLVND.")
endif()