Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 667802 - app-office/libreoffice: symlink uno.py to site-packages
Summary: app-office/libreoffice: symlink uno.py to site-packages
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Office Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-05 10:48 UTC by gerion
Modified: 2020-09-27 17:34 UTC (History)
1 user (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 gerion 2018-10-05 10:48:30 UTC
Libreoffice provides a python bridge with the help of uno.py. However, `import uno.py` in python does not work in Gentoo, because the file is not in the PYTHONPATH (the problem can be workarounded with PYTHONPATH+=":/usr/lib64/libreoffice/program/" python`).

In other distributions (I have tested Arch and Debian) the uno.py script is copied (Debian) or symlinked (Arch) to /usr/lib/pythonX/site-packages/. Can you do this as well?

I saw, that you already patch the script to use the global python interpreter (if I get it right).
Comment 1 gerion 2019-12-04 12:46:41 UTC
Ping.
Comment 2 Larry the Git Cow gentoo-dev 2020-08-18 23:08:19 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7e9dc414f75767acbd0e297979c6cfec53f6ddef

commit 7e9dc414f75767acbd0e297979c6cfec53f6ddef
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2020-08-18 23:04:50 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2020-08-18 23:07:40 +0000

    app-office/libreoffice: Link python bridge in site-packages, drop patch
    
    Essentially syncing with openSUSE changes.
    - Obsolete patching of officehelper.py, uno.py not to break tests, use heredoc
    - Fix finding pyuno by reshuffling imports
    - Obsolete patching of soffice.sh by symlinking py files to site-packages
    - Symlink byte-compiled files too
    
    Reported-by: gerion <gerion.entrup@flump.de>
    Bug: https://bugs.gentoo.org/667802
    Package-Manager: Portage-3.0.3, Repoman-3.0.0
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 app-office/libreoffice/libreoffice-6.4.6.2.ebuild | 34 ++++++++++++++++++-----
 1 file changed, 27 insertions(+), 7 deletions(-)
Comment 3 Larry the Git Cow gentoo-dev 2020-09-27 17:34:58 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5b335dc89970d19a8539a7d5eaa5dcdc1a51b7cb

commit 5b335dc89970d19a8539a7d5eaa5dcdc1a51b7cb
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2020-08-06 21:39:59 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2020-09-27 17:34:35 +0000

    app-office/libreoffice: Link python bridge in site-packages, drop patch
    
    Essentially syncing with openSUSE changes.
    - Obsolete patching of officehelper.py, uno.py not to break tests, use heredoc
    - Obsolete patching of soffice.sh by symlinking py files to site-packages
    - Fix finding pyuno by reshuffling imports
    - Fix URE_BOOTSTRAP path (bug in v1 of this patch), thanks to dilfridge
    
    Reported-by: Jan Psota <jasiupsota@gmail.com>
    Closes: https://bugs.gentoo.org/667802
    Package-Manager: Portage-3.0.1, Repoman-2.3.23
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 app-office/libreoffice/libreoffice-6.4.9999.ebuild | 34 +++++++++++++++++-----
 app-office/libreoffice/libreoffice-9999.ebuild     | 34 +++++++++++++++++-----
 2 files changed, 54 insertions(+), 14 deletions(-)