Summary: | app-portage/elogviewer version bump to 2.3 | ||
---|---|---|---|
Product: | Portage Development | Reporter: | Mathias Laurin <Mathias.Laurin+gentoo> |
Component: | Third-Party Tools | Assignee: | Portage Tools Team <tools-portage> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | qt |
Priority: | Normal | Keywords: | InVCS |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
working (but does not enforce PyQt5 +widgets) ebuild for 2.3
ebuild for 2.3 |
Description
Mathias Laurin
2015-01-30 21:59:01 UTC
KDE team, cam you recommend the best/preferred way to handle the pyQT4/5/pyside deps? qt4/5 USE flags? if so what about pyside? ... only if neither of the qt flags are set? I cant figure out in upstream build sys how to enabled/disable the dependencies, looks automagic to me. The qt4/qt5 dependencies in attached ebuild maintained by qt herd. Maybe they have a better inside. ok, this is the relevant import section of the script: try: import sip as _sip except ImportError: from PySide import QtGui, QtCore else: try: from PyQt5 import QtGui, QtWidgets, QtCore except ImportError: for _type in "QDate QDateTime QString QVariant".split(): _sip.setapi(_type, 2) from PyQt4 import QtGui, QtCore QtCore.QSortFilterProxyModel = QtGui.QSortFilterProxyModel QtWidgets = QtGui Qt = QtCore.Qt So, yeah they are automagic. Is there a different way that you prefer the imports/dependencies be done? It seems this translates to RDEPEND=" || ( dev-python/PyQt5[gui,widgets,${PYTHON_USEDEP}] dev-python/PyQt4[X,${PYTHON_USEDEP}] dev-python/pyside[X,${PYTHON_USEDEP}] )" Unless upstream wants to make this non-automagic, that seems to me to be a decent solution. Created attachment 395336 [details]
ebuild for 2.3
(In reply to Ben de Groot from comment #4) > It seems this translates to > RDEPEND=" || ( > dev-python/PyQt5[gui,widgets,${PYTHON_USEDEP}] > dev-python/PyQt4[X,${PYTHON_USEDEP}] > dev-python/pyside[X,${PYTHON_USEDEP}] )" > Yep, PyQt5 is preferred to PyQt4 which is preferred to pyside. In the PyQt4/5 case, a dependency on sip is needed too. Adding a qt5 useflag doesn't seem a bad idea either... qt5? ( sip PyQt5[gui,widgets] ) !qt5? ( || ( sip PyQt4[X] ) pyside[X] ) (In reply to Ben de Groot from comment #4) > It seems this translates to > RDEPEND=" || ( > dev-python/PyQt5[gui,widgets,${PYTHON_USEDEP}] > dev-python/PyQt4[X,${PYTHON_USEDEP}] > dev-python/pyside[X,${PYTHON_USEDEP}] )" > > Unless upstream wants to make this non-automagic, that seems to me to be a > decent solution. I updated the build with the RDEPEND given above. I do not want to make it non-automagic: 1. This is Python, installing the program does not build anything and link to the dependencies. So that it will not break if the user e.g. upgrades from PyQt4 to PyQt5. 2. This is how matplotlib-1.4 handles the transition to PyQt5 as well and if it is good enough for them, it is good enough for me. Thanks, I have it in progress, I'm also editing the other ebuilds, removing no longer supported pythons 2.6, 3.1, 3.2. I'll be committing later today. I'm heading out to some volunteer work atm Done, pushed to the tree. |