From f44fb2dd4ce5e47cd0a12d1a25bda40f012d453a Mon Sep 17 00:00:00 2001 From: Brad King Date: Tue, 7 Nov 2017 07:57:09 -0500 Subject: 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 --- Modules/FindOpenGL.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Modules/FindOpenGL.cmake b/Modules/FindOpenGL.cmake index 59bee41..8cceabd 100644 --- a/Modules/FindOpenGL.cmake +++ b/Modules/FindOpenGL.cmake @@ -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) -- cgit v0.12