mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-21 14:40:26 -06:00
FindOpenGL: Clarify logic constructing OPENGL_LIBRARIES
Our comment says the logic matches that for OpenGL::GL. Structure the logic the same way to make this clearer. Issue: #17437
This commit is contained in:
@@ -440,9 +440,10 @@ if(OPENGL_FOUND)
|
||||
endif()
|
||||
|
||||
# OPENGL_LIBRARIES mirrors OpenGL::GL's logic ...
|
||||
set(OPENGL_LIBRARIES ${OPENGL_gl_LIBRARY})
|
||||
if(TARGET OpenGL::GLX AND TARGET OpenGL::OpenGL)
|
||||
set(OPENGL_LIBRARIES ${OPENGL_opengl_LIBRARY} ${OPENGL_glx_LIBRARY})
|
||||
else()
|
||||
set(OPENGL_LIBRARIES ${OPENGL_gl_LIBRARY})
|
||||
endif()
|
||||
# ... and also includes GLU, if available.
|
||||
if(TARGET OpenGL::GLU)
|
||||
|
||||
Reference in New Issue
Block a user