Closed kingwill101 closed 8 years ago
Hi @glenfordwilliams,
I had a bit of fun and games with this on Window too. My problem was that I was using the binary install of PyQt and the SIP directory pointed to by sip itself was actually empty. I got around this by downloading the PyQt source and using the --sip-extras
command line argument to configure.py
to point to the SIP code contained therein. My build script therefore was as follows:
python configure.py --qmake=C:\Qt\5.4\msvc2010_opengl\bin --sip-extras=-IC:\Users\Rob\Downloads\PyQt-gpl-5.4.2\sip
nmake
Hope this solves your problem ;-)
thanks for the reply, is that flag when you are configuring sip?
i did it with the project and got this
C:\Users\Williams\PyMyLabel-master>C:\Python34\python.exe configure.py --sip-extras=C:\Users\Williams\Desktop\pyqt\sip --qmake=C:\Qt\5.5\msvc2013_64\bin QMake version 3.0 Using Qt version 5.5.0 in C:/Qt/5.5/msvc2013_64/lib C:\Python34\sip -t WS_WIN -t Qt_5_5_0 C:\Users\Williams\Desktop\pyqt\sip -I C:\Users\Williams\PyMyLabel-master\sip -I C:\Python34\sip\PyQt5 -I C:\Python34\include -I C:\Users\Williams\PyMyLabel-master\src -c C:\Users\Williams\PyMyLabel-master\modules -b C:\Users\Williams\PyMyLabel-master\modules\PyMyLabel.sbf -w -o C:\Users\Williams\PyMyLabel-master\sip\PyMyLabel.sip sip: Usage: sip [-h] [-V] [-a file] [-b file] [-B tag] [-c dir] [-d file] [-e] [-g] [-I dir] [-j #] [-k] [-m file] [-o] [-p module] [-P] [-r] [-s suffix] [-t tag] [-w] [-x feature] [-X id:file] [-z file] [@file] [file]
You need to put -I
in the --sip-extras
argument:
C:\Users\Williams\PyMyLabel-master>C:\Python34\python.exe configure.py --sip-extras=-IC:\Users\Williams\Desktop\pyqt\sip --qmake=C:\Qt\5.5\msvc2013_64\bin
ha! i figured it out. dropped --sip-extras flag copied the sip directory from PyQt5 to python dir\sip nmake && nmake install copy the PyMyLabel.pyd to the dll folder in the python directory
Probably better to put PyMyLabel.pyd
in site-packages
.
Anyways, glad you've got it working.
If you're looking to sipify you own C++ project, take a look at my sipify script. It doesn't make complete bindings, but it might make your life easier and give you a starting point.
Hope this helps ;-)
ive been trying to get this to work using qt5.5 but keep getting an error
C:\Users\Williams\PyMyLabel-master>%python3% configure.py QMake version 3.0 Using Qt version 5.5.0 in C:/Python34/Lib/site-packages/PyQt5/lib C:\python34\sip -t WS_WIN -t Qt_5_5_0 -I C:\Users\Williams\PyMyLabel-master\sip -I C:\python34\sip\PyQt5 -I C:\python34\include -I C:\Users\Williams\PyMyLabel-master\src -c C:\Users\Williams\PyMyLabel-master\modules -b C:\Users\Williams\PyMyLabel-master\modules\PyMyLabel.sbf -w -o C:\Users\Williams\PyMyLabel-master\sip\PyMyLabel.sip sip: Unable to find file "QtGui/QtGuimod.sip"