aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/PySide6/QtGui/CMakeLists.txt
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2024-03-25 10:20:03 +0100
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2024-04-09 09:05:11 +0200
commitf619b4c45b042c3a656a80b57cb4f154ef15bd1a (patch)
treeb17adfd7c0f0bd9984a464380c49a1215f4db2c2 /sources/pyside6/PySide6/QtGui/CMakeLists.txt
parent7cea5aad257b12b34c8fec89cc4750fe0f3c4bbb (diff)
Fix building without QtOpenGL
Introduce a CMake macro to either add the dependency or an entry to the dropped items for typesystem parsing. Pick-to: 6.7 Fixes: PYSIDE-2649 Change-Id: Idb4e6d530075ab8c08c92e2e26d4de1bfd0459cf Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Diffstat (limited to 'sources/pyside6/PySide6/QtGui/CMakeLists.txt')
-rw-r--r--sources/pyside6/PySide6/QtGui/CMakeLists.txt22
1 files changed, 16 insertions, 6 deletions
diff --git a/sources/pyside6/PySide6/QtGui/CMakeLists.txt b/sources/pyside6/PySide6/QtGui/CMakeLists.txt
index 641cef6a1..7cd7871f3 100644
--- a/sources/pyside6/PySide6/QtGui/CMakeLists.txt
+++ b/sources/pyside6/PySide6/QtGui/CMakeLists.txt
@@ -25,8 +25,6 @@ ${QtGui_GEN_DIR}/qrhicommandbuffer_wrapper.cpp
${QtGui_GEN_DIR}/qrhicomputepipeline_wrapper.cpp
${QtGui_GEN_DIR}/qrhidepthstencilclearvalue_wrapper.cpp
${QtGui_GEN_DIR}/qrhidriverinfo_wrapper.cpp
-${QtGui_GEN_DIR}/qrhigles2initparams_wrapper.cpp
-${QtGui_GEN_DIR}/qrhigles2nativehandles_wrapper.cpp
${QtGui_GEN_DIR}/qrhigraphicspipeline_targetblend_wrapper.cpp
${QtGui_GEN_DIR}/qrhigraphicspipeline_wrapper.cpp
${QtGui_GEN_DIR}/qrhigraphicspipeline_stencilopstate_wrapper.cpp
@@ -175,9 +173,6 @@ ${QtGui_GEN_DIR}/qmovie_wrapper.cpp
${QtGui_GEN_DIR}/qnativegestureevent_wrapper.cpp
${QtGui_GEN_DIR}/qnativeinterface_wrapper.cpp
${QtGui_GEN_DIR}/qoffscreensurface_wrapper.cpp
-${QtGui_GEN_DIR}/qopenglcontextgroup_wrapper.cpp
-${QtGui_GEN_DIR}/qopenglextrafunctions_wrapper.cpp
-${QtGui_GEN_DIR}/qopenglfunctions_wrapper.cpp
${QtGui_GEN_DIR}/qpagedpaintdevice_wrapper.cpp
${QtGui_GEN_DIR}/qpagelayout_wrapper.cpp
${QtGui_GEN_DIR}/qpageranges_wrapper.cpp
@@ -221,7 +216,6 @@ ${QtGui_GEN_DIR}/qsinglepointevent_wrapper.cpp
${QtGui_GEN_DIR}/qstandarditem_wrapper.cpp
${QtGui_GEN_DIR}/qstandarditemmodel_wrapper.cpp
${QtGui_GEN_DIR}/qstatustipevent_wrapper.cpp
-${QtGui_GEN_DIR}/qopenglcontext_wrapper.cpp
${QtGui_GEN_DIR}/qaccessible_state_wrapper.cpp
${QtGui_GEN_DIR}/qaccessibleinterface_wrapper.cpp
${QtGui_GEN_DIR}/qscreen_wrapper.cpp
@@ -298,6 +292,22 @@ elseif(WIN32)
${QtGui_GEN_DIR}/qnativeinterface_qwindowsscreen_wrapper.cpp)
endif()
+if("opengl" IN_LIST QtGui_enabled_features OR "opengles2" IN_LIST QtGui_enabled_features
+ OR "opengles3" IN_LIST QtGui_enabled_features)
+ list(APPEND QtGui_SRC
+ ${QtGui_GEN_DIR}/qopenglcontextgroup_wrapper.cpp
+ ${QtGui_GEN_DIR}/qopenglextrafunctions_wrapper.cpp
+ ${QtGui_GEN_DIR}/qopenglfunctions_wrapper.cpp
+ ${QtGui_GEN_DIR}/qopenglcontext_wrapper.cpp
+ ${QtGui_GEN_DIR}/qrhigles2initparams_wrapper.cpp
+ ${QtGui_GEN_DIR}/qrhigles2nativehandles_wrapper.cpp)
+else()
+ list(APPEND QtGui_DROPPED_ENTRIES
+ QOpenGLContext QOpenGLContextGroup QOpenGLPaintDevice
+ QOpenGLExtraFunctions QOpenGLFunctions
+ QRhiGles2InitParams QRhiGles2NativeHandles)
+endif()
+
set(QtGui_private_include_dirs
${Qt${QT_MAJOR_VERSION}Core_PRIVATE_INCLUDE_DIRS}
${Qt${QT_MAJOR_VERSION}Gui_PRIVATE_INCLUDE_DIRS})