If you install some libs with sip with python 3.6 - PyQt5 for example - sip doesn't honor the default sip dir. in python3: import sipconfig sipconfig.Configuration().default_sip_dir #/usr/local/share/py36-sip But files (for example QtXmlmod.sip) are installed in: /usr/local/share/py-sip for example /usr/local/share/py-sip/PyQt5/QtXml/QtXmlmod.sip Thanks.
https://reviews.freebsd.org/D8714 i prepared a versioned sip directory in that review a while ago. Maybe you can pick the proper parts from it if you have time :) Mfg Tobias
*** This bug has been marked as a duplicate of bug 219641 ***
With the new versions of Qt, there is always an error (see qgis bug 233726#c9) in python3: import sipconfig sipconfig.Configuration().default_sip_dir #/usr/local/share/PyQtsip/3.6/sip instead of /usr/local/share/PyQt5/3.6/sip
(In reply to lbartoletti from comment #3) The issue here is an error in pyqt.mk: in sip there is no _PYQT_VERSION defined, and therefore the sip-file locations line _SIPDIR_REL are broken.
Created attachment 201000 [details] py-sip fix with PyQt5 as default Tobias, This is your patch. I only add a line for reinplace PyQt5 as default (post-install section) Thanks
(In reply to lbartoletti from comment #5) I think something like this should work -- but it will require an exp-run, and some more thinking :)
I just tried on a system without Qt4 and unfortunately SIP continues to propose /usr/local/share/PyQt4/3.6/sip as a path if we don't apply the patch
Yes cleaning up PyQt is the next step. Mfg Tobias
Created attachment 208888 [details] fix sipconfig. Simplest version.
Created attachment 208889 [details] fix sipconfig. Simplest version.
Created attachment 208891 [details] fix sipconfig. Simplest version with --sipdir and an explicit variable Tobias, the patch following up our discussion. Thanks
Created attachment 208894 [details] pass sipdir explicitly Considering than sip port has already tied to Qt5, hardcoder sipdir to PyQt5. With this patch other ports, which rely on getting info from sipconfig may remove their workarounds (I know at least one)
Created attachment 208905 [details] fix sipconfig. Simplest version with --sipdir and an explicit variable I forgot ${PYTHON_VER} in my previous patch...
Created attachment 209329 [details] final patch PYQT_SIPDIR and ?= in pyqt.mk
A commit references this bug: Author: tcberner Date: Sun Nov 24 08:39:31 UTC 2019 New revision: 518302 URL: https://svnweb.freebsd.org/changeset/ports/518302 Log: devel/py-sip: doesn't honor sip_dir pyqt.mk had a long standing bug, where the sip-dir was not properly set for the port devel/py-sip. The underlying issue was the following: When using pyqt.mk consumers would specify USES=pyqt:<version> To also have easy access for the data from pyqt.mk in the py-sip port, we allowed version=sip, which only unhides a very limited scope of pyqt.mk. However, we also set _VERSION_SUBDIR_REL= PyQt${_PYQT_VERSION}/${PYTHON_VER} and used that in _SIPDIR_REL= share/${_VERSION_SUBDIR_REL}/sip PYQT_SIPDIR= ${PREFIX}/${_SIPDIR_REL} Therefore, py-sip got a very mangled PYQT_SIPDIR value passed to its configure script. Big thanks to Lo?c for figuring out the issue :) PR: 223409 Submitted by: Lo?c Bartoletti <lbartoletti@tuxfamily.org> Changes: head/Mk/Uses/pyqt.mk head/devel/py-sip/Makefile
Committed -- thanks :)