[PyQt] Creating a QWinmigrate mofules for PyQt5 using SIP

Andrew Cunningham pyqt at a-cunningham.com
Mon Jun 18 17:18:07 BST 2018


Hi Phil,
I tried that ,

py> QtCore.PYQT_CONFIGURATION

{'sip_flags': '-t WS_WIN -t Qt_5_7_0'}


And in configure.py


sip_cmd = " ".join([
config.sip_bin,"-c", ".", "-b", build_file,
"-t", "WS_WIN", "-t", "Qt_5_7_0",
basename + ".sip"
])


I still get
sip: HWND is undefined


My .sip files looks like this, should I be adding something else?


%Module QtWinMigrate 0

%Platforms {WS_WIN}

%Import QtGui/QtGuimod.sip
%Import QtWidgets/QtWidgetsmod.sip

%Include qwinhost.sip
%Include qwinwidget.sip
%Include qmfcapp.sip



On Sat, Jun 16, 2018 at 9:38 AM, Phil Thompson <phil at riverbankcomputing.com>
wrote:

> On 15 Jun 2018, at 9:27 pm, Andrew Cunningham <pyqt at a-cunningham.com>
> wrote:
> >
> > HI,
> >
> > I am trying to create a QWinMigrate module using SIP for Qt5.7 I
> followed the instructions on https://cbuelter.wordpress.
> com/2015/02/11/compiling-pyqt-and-qtwinmigrate-for-3ds-max-2015/3/
> >
> > But I am stuck at the SIP step. I had to modify the .sip file for QT5
> > %Import QtCore/QtCoremod.sip
> > %Import QtGui/QtGuimod.sip
> > %Import QtWidgets/QtWidgetsmod.sip
> >
> > But I still get the error message
> > sip: HWND is undefined
>
> You have to use the same -t and -x flags that were used to build the copy
> of PyQt5 you are building against. The only way to find these is to
> introspect PyQt5 using...
>
> http://pyqt.sourceforge.net/Docs/PyQt5/extension_api.html#python-api
>
> Phil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20180618/7878c602/attachment.html>


More information about the PyQt mailing list