summaryrefslogtreecommitdiffhomepage
path: root/cmake/LibraryConfigurations.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/LibraryConfigurations.cmake')
-rw-r--r--cmake/LibraryConfigurations.cmake9
1 files changed, 9 insertions, 0 deletions
diff --git a/cmake/LibraryConfigurations.cmake b/cmake/LibraryConfigurations.cmake
index cc0f01e4..a16bde69 100644
--- a/cmake/LibraryConfigurations.cmake
+++ b/cmake/LibraryConfigurations.cmake
@@ -1,3 +1,12 @@
+# Set OpenGL_GL_PREFERENCE to new "GLVND" even when legacy library exists and
+# cmake is <= 3.10
+#
+# See https://cmake.org/cmake/help/latest/policy/CMP0072.html for more
+# information.
+if(POLICY CMP0072)
+ cmake_policy(SET CMP0072 NEW)
+endif()
+
if (${PLATFORM} MATCHES "Desktop")
set(PLATFORM_CPP "PLATFORM_DESKTOP")