[PyQt] Having multiple SIP installations
Kovid Goyal
kovid at kovidgoyal.net
Tue Apr 15 18:52:18 BST 2014
Thanks.
Couple of reasons for needing custom builds:
1) The system SIP is too old for the current PyQt5 release
2) I like to sometimes alter the source code and re-build to help me
understand how something works when I am investigating a new package.
3) Generally when dealing with cutting edge packages I prefer not to
have them available system wide, just in case they cause problems with
other software on the system.
Kovid.
On Tue, Apr 15, 2014 at 05:27:31PM +0100, Phil Thompson wrote:
> On 11-04-2014 5:20 am, Kovid Goyal wrote:
> > Hi Phil,
> >
> > I have been investigating porting calibre to PyQt5/Qt5 and in order
> > to
> > do that I needed to have a custom PyQt5/SIP build on my system
> > alongside
> > the distribution provided one.
> >
> > My requirements are that I need to use:
> > 1) The system python interpreter
> > 2) A custom compiled Qt5, SIP and PyQt5. The custom SIP version is
> > different from the system SIP version.
> >
> > The problem is that the configure script for PyQt5 places the python
> > include dir before the sip include dir which causes the system sip.h
> > to
> > be used, breaking the build. The relevant lines in configure.py are
> >
> > if target_config.py_inc_dir != target_config.sip_inc_dir:
> > pro_lines.append('INCLUDEPATH += %s' %
> > target_config.sip_inc_dir)
> >
> > I can obviously patch it myself to do what I need, but I think it
> > should
> > be changed to place the sip include dir before the python include
> > dir,
> > if they differ. So the lines should be:
> >
> > if target_config.py_inc_dir != target_config.sip_inc_dir:
> > pro_lines.insert(len(pro_lines)-1, 'INCLUDEPATH += %s' %
> > target_config.sip_inc_dir)
> >
> > As far as I can see, this is the only way to build PyQt5 successfully
> > using the system python interpreter and a custom SIP, when the custom
> > SIP and the system SIP are of different versions.
> >
> > There may of course be other side effects that I do not realize.
> >
> > Thanks,
> >
> > Kovid.
>
> Done.
>
> Out of interest why to do you need custom builds?
>
> Phil
> _______________________________________________
> PyQt mailing list PyQt at riverbankcomputing.com
> http://www.riverbankcomputing.com/mailman/listinfo/pyqt
>
> !DSPAM:3,534d5e01281102034712199!
>
>
--
_____________________________________
Dr. Kovid Goyal
http://www.kovidgoyal.net
http://calibre-ebook.com
_____________________________________
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20140415/2c1c2681/attachment.pgp>
More information about the PyQt
mailing list