2019-02-11 15:58:26 +00:00
|
|
|
|
|
|
|
# Logic derived from mkspecs/features/unix/opengl.prf: prefer GLESv2 over GL
|
|
|
|
|
|
|
|
if(TARGET WrapOpenGL)
|
2019-02-12 16:12:25 +00:00
|
|
|
set(WrapOpenGL_FOUND ON)
|
2019-02-11 15:58:26 +00:00
|
|
|
return()
|
|
|
|
endif()
|
|
|
|
|
|
|
|
add_library(WrapOpenGL INTERFACE)
|
|
|
|
|
|
|
|
if(QT_FEATURE_opengles2)
|
|
|
|
find_package(GLESv2)
|
|
|
|
target_link_libraries(WrapOpenGL INTERFACE GLESv2::GLESv2)
|
|
|
|
else()
|
|
|
|
find_package(OpenGL)
|
|
|
|
target_link_libraries(WrapOpenGL INTERFACE OpenGL::GL)
|
|
|
|
endif()
|
2019-02-12 16:12:25 +00:00
|
|
|
set(WrapOpenGL_FOUND ON)
|