Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 485244 - kde-apps/pykde4: does hackery on top of Python script wrapping
Summary: kde-apps/pykde4: does hackery on top of Python script wrapping
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal QA (vote)
Assignee: Gentoo KDE team
URL:
Whiteboard: last-rite
Keywords: PMASKED
Depends on: kde-apps-17.04.3 627704
Blocks: 484398
  Show dependency tree
 
Reported: 2013-09-17 20:44 UTC by Michał Górny
Modified: 2017-08-19 08:46 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-17 20:44:59 UTC
src_install() {
    installation() {
        emake DESTDIR="${D}" install

        mv "${ED}"/usr/bin/pykdeuic4-{${EPYTHON/python/},${EPYTHON}} || die
        python_optimize
    }
    python_foreach_impl run_in_build_dir installation

    dosym python-exec /usr/bin/pykdeuic4
(snip)

I'm not even sure if it's allowed by the Geneva convention. In any case, it's terribly fragile.
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-17 20:48:30 UTC
FYI: I've forced python-exec:0 in the ebuild now. We will probably revisit your sinister ways near python-exec:2 going stable, so please keep the bug open.
Comment 2 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-17 22:44:33 UTC
BTW I'm not sure if it's exactly the same but you can take a look at e.g. dev-python/unittest2. Its setup.py installs both 'foo' and 'foo-X.Y', and the eclass simply wraps both. While it may be a little unnecessary, it gives 100% consistent behavior -- that is, there's:

- foo which supports all simpls,
- foo-pythonX.Y,
- foo-X.Y which support only X.Y impl,
- foo-X.Y-pythonX.Y (only for matching X.Y) :).
Comment 3 Michael Palimaka (kensington) gentoo-dev 2013-09-18 09:02:38 UTC
(In reply to Michał Górny from comment #0)
> I'm not even sure if it's allowed by the Geneva convention. In any case,
> it's terribly fragile.
Don't blame us, we had this voodoo review by python team before committing. ;-)

pykde4 has no setup.py, but upstream has introduced the option PYKDEUIC4_ALTINSTALL which appears to make the build system automagically name the binary the way we hack it now. I will test this option.
Comment 4 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-18 10:12:31 UTC
(In reply to Michael Palimaka (kensington) from comment #3)
> pykde4 has no setup.py, but upstream has introduced the option
> PYKDEUIC4_ALTINSTALL which appears to make the build system automagically
> name the binary the way we hack it now. I will test this option.

I don't really want to (rebuild and) install all the necessary dependencies, so if you're going to change it, I'd appreciate if you could test it as well with python-exec:2 (you'll need to unmask it).
Comment 5 Michael Palimaka (kensington) gentoo-dev 2013-09-18 10:22:51 UTC
No problem, will do.
Comment 6 Johannes Huber (RETIRED) gentoo-dev 2013-11-23 19:05:37 UTC
(In reply to Michael Palimaka (kensington) from comment #5)
> No problem, will do.

@Michael: Any news on this?
Comment 7 Michael Palimaka (kensington) gentoo-dev 2014-03-16 11:58:17 UTC
OK, pykde4 installs /usr/bin/pykdeuic4-X.Y, which we hack to pykdeuic4-python3.2, which is a symlink to /usr/lib64/pythonX.Y/site-packages/PyQt4/uic/pykdeuic4.py.
.
PYKDEUIC4_ALTINSTALL controls whether to create symlink /usr/bin/pykdeuic4 to /usr/bin/pykdeuic4-X.Y - and we disable these symlinks and create them in the ebuild.

This fails with python-exec:2, I guess because the symlinks are installed into /usr/bin.

I guess we could revert to the original behaviour (build system creates /usr/bin/pykdeuic4 -> /usr/bin/pykdeuic4-X.Y) then run python_replicate_script for each implementation?

I don't think we have any particular preference about how this is handled, and I'm happy to test any suggestions you have.
Comment 8 Alexandre 2014-07-18 23:10:46 UTC
Successful compiled against dev-python/PyQt4-4.11.1.
Comment 9 Michael Palimaka (kensington) gentoo-dev 2014-07-19 15:13:15 UTC
This bug is not related to the PyQt4-4.11 build failure.
Comment 10 Andreas Sturmlechner gentoo-dev 2017-06-25 09:05:34 UTC
We'll get rid of this package by stabilising KDE Applications 17.04 and last-riting the last remaining rdep (kde-misc/kanyremote).
Comment 11 Patrice Clement gentoo-dev 2017-07-15 21:47:40 UTC
has it been last-rited already?
Comment 12 Andreas Sturmlechner gentoo-dev 2017-07-15 23:12:29 UTC
Afaik kensington was working on a kanyremote version bump, but it seems that doesn't work all that well.
Comment 13 Andreas Sturmlechner gentoo-dev 2017-08-19 08:46:28 UTC
Package masked for removal in git commit a28d39293c44377d011e7f8fe80814424aac6669