SET(PYQT_INCLUDES ${PYQT_INCLUDES} -I${PYQT_SIPS}/QtNetwork -I${PYQT_SIPS}/QtSql)
SET(PYQT_INCLUDES ${PYQT_INCLUDES} -I${PYQT_SIPS}/QtSvg -I${PYQT_SIPS}/QtTest)
-file(READ ${PYQT_SIPS}/QtCore/QtCoremod.sip SUPPORTED)
-STRING(REGEX MATCH "Qt_[0-9]_[0-9]_[0-9]}" SUPPORTED ${SUPPORTED})
-STRING(LENGTH ${SUPPORTED} len)
-MATH(EXPR len "${len}-1")
-STRING(SUBSTRING ${SUPPORTED} 0 ${len} SUPPORTED)
+EXECUTE_PROCESS(COMMAND ${PYTHON_EXECUTABLE} -c "import re, pyqtconfig; s=pyqtconfig.Configuration().pyqt_sip_flags;m=re.search('(Qt_[0-9_]+)',s);print m.group(1)" OUTPUT_VARIABLE SUPPORTED)
IF(WINDOWS)
SET(ws_flag WS_WIN)