CMake: ensure shiboken does not introduce Py_LIMITED_API.
On some builds, the CMake package files for PySide6's Shiboken set the Py_LIMITED_API define on the compiler's command line. This breaks FreeCAD as it depends on definitions from the Python Stable API unavailable with the Limited API.
This commit is contained in:
@@ -37,6 +37,10 @@ macro(SetupShibokenAndPyside)
|
||||
message(STATUS "PYTHON_CONFIG_SUFFIX: ${PYTHON_CONFIG_SUFFIX}")
|
||||
find_package(Shiboken${SHIBOKEN_MAJOR_VERSION} QUIET)
|
||||
endif()
|
||||
|
||||
if(SHIBOKEN_MAJOR_VERSION EQUAL 6)
|
||||
set_target_properties(Shiboken6::libshiboken PROPERTIES INTERFACE_COMPILE_DEFINITIONS "NDEBUG")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# pyside2 changed its cmake files, this is the dance we have
|
||||
|
||||
Reference in New Issue
Block a user