aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/libpyside/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'sources/pyside2/libpyside/CMakeLists.txt')
-rw-r--r--sources/pyside2/libpyside/CMakeLists.txt13
1 files changed, 5 insertions, 8 deletions
diff --git a/sources/pyside2/libpyside/CMakeLists.txt b/sources/pyside2/libpyside/CMakeLists.txt
index 3069b1ca2..ec6713b62 100644
--- a/sources/pyside2/libpyside/CMakeLists.txt
+++ b/sources/pyside2/libpyside/CMakeLists.txt
@@ -17,6 +17,7 @@ if(${Qt5Quick_FOUND})
endif()
endif()
+set(QML_PRIVATE_API_SUPPORT 0)
if(Qt5Qml_FOUND)
# Used for registering custom QQuickItem classes defined in Python code.
set(QML_SUPPORT 1)
@@ -28,7 +29,6 @@ if(Qt5Qml_FOUND)
set(QML_PRIVATE_API_SUPPORT 1)
set(QML_INCLUDES ${QML_INCLUDES} ${Qt5Qml_PRIVATE_INCLUDE_DIRS})
else()
- set(QML_PRIVATE_API_SUPPORT 0)
message(WARNING "QML private API include files could not be found, support for catching QML exceptions inside Python code will not work.")
endif()
else()
@@ -40,14 +40,10 @@ endif()
qt5_wrap_cpp(DESTROYLISTENER_MOC "destroylistener.h")
-configure_file("${CMAKE_CURRENT_SOURCE_DIR}/signalmanager.cpp.in"
- "${CMAKE_CURRENT_BINARY_DIR}/signalmanager.cpp" @ONLY)
-
set(libpyside_SRC
dynamicqmetaobject.cpp
destroylistener.cpp
- ${CMAKE_CURRENT_BINARY_DIR}/signalmanager.cpp
- globalreceiver.cpp
+ signalmanager.cpp
globalreceiverv2.cpp
pysideclassinfo.cpp
pysidemetafunction.cpp
@@ -86,7 +82,8 @@ include_directories(${CMAKE_CURRENT_SOURCE_DIR}
${SHIBOKEN_INCLUDE_DIR}
${SHIBOKEN_PYTHON_INCLUDE_DIR}
${QML_INCLUDES}
- ${Qt5Core_INCLUDE_DIRS})
+ ${Qt5Core_INCLUDE_DIRS}
+ ${Qt5Core_PRIVATE_INCLUDE_DIRS})
add_library(pyside2 SHARED ${libpyside_SRC} ${other_files})
target_link_libraries(pyside2
${SHIBOKEN_PYTHON_LIBRARIES}
@@ -107,6 +104,7 @@ endif()
if(QML_SUPPORT)
target_compile_definitions(pyside2 PUBLIC PYSIDE_QML_SUPPORT=1)
endif()
+target_compile_definitions(pyside2 PRIVATE PYSIDE_QML_PRIVATE_API_SUPPORT=${QML_PRIVATE_API_SUPPORT})
if(PYSIDE_QT_CONF_PREFIX)
set_property(SOURCE pyside.cpp
@@ -122,7 +120,6 @@ endif()
set(libpyside_HEADERS
destroylistener.h
dynamicqmetaobject.h
- globalreceiver.h
pysideclassinfo.h
pysidemacros.h
signalmanager.h