Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 642804 - app-office/ledger-3.1.1: python interface is broken
Summary: app-office/ledger-3.1.1: python interface is broken
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Erik Mackdanz
URL:
Whiteboard:
Keywords: EBUILD, PATCH
Depends on:
Blocks:
 
Reported: 2017-12-31 07:11 UTC by James Wah
Modified: 2018-07-20 20:56 UTC (History)
3 users (show)

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


Attachments
Updated ebuild with working Python module (ledger-3.1.1-r1.ebuild,2.51 KB, text/plain)
2017-12-31 07:11 UTC, James Wah
Details

Note You need to log in before you can comment on or make changes to this bug.
Description James Wah 2017-12-31 07:11:26 UTC
Created attachment 512144 [details]
Updated ebuild with working Python module

When the "python" USE flag is enabled, the ebuild deletes the library that implements the interface.

If installed with USE="python", "import ledger" succeeds but no types are imported or can be used. This is because the ebuild deliberately deletes "ledger.so" from /usr/lib64/python2.7/site-packages/ to avoid a warning. Instead, it installs a folder of demos from the source package.

The warning is due to a null DT_RUNPATH in the library. This is an upstream bug and I believe is fixed automatically by scanelf. The warning can be avoided by supplying an appropriate flag to CMake. 

The attached ebuild:
a) removes the deletion,
b) does not install the demos into site-packages,
c) amends the CMake flags to avoid the warning.
Comment 1 plapadoo 2018-07-07 11:30:55 UTC
I can confirm that the problem with the broken python interface exists and that the attached ebuild by James fixes the issue.
Comment 2 Larry the Git Cow gentoo-dev 2018-07-20 04:03:07 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2642ca2a2e080d478b417a37edd1500cf1c283fd

commit 2642ca2a2e080d478b417a37edd1500cf1c283fd
Author:     Erik Mackdanz <stasibear@gentoo.org>
AuthorDate: 2018-07-20 04:01:29 +0000
Commit:     Erik Mackdanz <stasibear@gentoo.org>
CommitDate: 2018-07-20 04:02:31 +0000

    app-office/ledger: Bug fixes, EAPI=6
    
    Closes: https://bugs.gentoo.org/635730
    Closes: https://bugs.gentoo.org/635924
    Closes: https://bugs.gentoo.org/642804
    Closes: https://bugs.gentoo.org/654326
    Package-Manager: Portage-2.3.40, Repoman-2.3.9

 .../files/ledger-3.1.1-r1-boost-python.patch       |  13 +++
 app-office/ledger/ledger-3.1.1-r1.ebuild           | 125 +++++++++++++++++++++
 2 files changed, 138 insertions(+)
Comment 3 Erik Mackdanz gentoo-dev 2018-07-20 04:04:33 UTC
Thanks for this update.  I've used the change verbatim in -r1.
Comment 4 James Wah 2018-07-20 05:38:09 UTC
Thanks Erik!