From 56cae3e167a95c06d6e9f2dd7f7cea9df8fbcf32 Mon Sep 17 00:00:00 2001 From: Kevin Mihelich Date: Tue, 10 Sep 2024 23:05:06 +0000 Subject: [PATCH] extra/libreoffice-fresh to 24.8.0-5 --- extra/libreoffice-fresh/.SRCINFO | 2 +- extra/libreoffice-fresh/PKGBUILD | 30 +++++++++++++++++++++++------- 2 files changed, 24 insertions(+), 8 deletions(-) diff --git a/extra/libreoffice-fresh/.SRCINFO b/extra/libreoffice-fresh/.SRCINFO index 4ac82bfd3..83973ed9a 100644 --- a/extra/libreoffice-fresh/.SRCINFO +++ b/extra/libreoffice-fresh/.SRCINFO @@ -1,6 +1,6 @@ pkgbase = libreoffice-fresh pkgver = 24.8.0 - pkgrel = 4 + pkgrel = 5 url = https://www.libreoffice.org/ arch = x86_64 license = MPL-2.0 diff --git a/extra/libreoffice-fresh/PKGBUILD b/extra/libreoffice-fresh/PKGBUILD index 2434378a2..6ad369602 100644 --- a/extra/libreoffice-fresh/PKGBUILD +++ b/extra/libreoffice-fresh/PKGBUILD @@ -20,7 +20,7 @@ pkgbase=libreoffice-fresh pkgname=('libreoffice-fresh-sdk' 'libreoffice-fresh') _LOver=24.8.0.3 pkgver=24.8.0 -pkgrel=4 +pkgrel=5 arch=('x86_64') license=('MPL-2.0' 'LGPL-3.0-or-later') url="https://www.libreoffice.org/" @@ -349,14 +349,30 @@ package_libreoffice-fresh() { install -dm755 "${pkgdir}"/etc/profile.d install -m644 "${srcdir}"/libreoffice-fresh.{sh,csh} "${pkgdir}"/etc/profile.d/ - # make pyuno find its modules - local site_packages=$(python -c "import site; print(site.getsitepackages()[0])") + # move python bits into site-packages + local site_packages=$(python -c "import site; print(site.getsitepackages()[0])") install -dm755 "${pkgdir}"/$site_packages - ln -svf /usr/lib/libreoffice/program/uno.py \ - "${pkgdir}"/$site_packages/uno.py - ln -svf /usr/lib/libreoffice/program/unohelper.py \ - "${pkgdir}"/$site_packages/unohelper.py + + pushd "${pkgdir}"/$site_packages + echo "import sys, os" > uno.py + echo "sys.path.append('/usr/lib/libreoffice/program/')" >> uno.py + echo "os.putenv('URE_BOOTSTRAP', 'vnd.sun.star.pathname:/usr/lib/libreoffice/program/fundamentalrc')" >> uno.py + cat "${pkgdir}"/usr/lib/libreoffice/program/uno.py >> uno.py + rm -f "${pkgdir}"/usr/lib/libreoffice/program/uno.py* + mv -f "${pkgdir}"/usr/lib/libreoffice/program/unohelper.py* . + mv -f "${pkgdir}"/usr/lib/libreoffice/program/officehelper.py* . + popd + + # make pyuno find its modules +# local site_packages=$(python -c "import site; print(site.getsitepackages()[0])") +# +# install -dm755 "${pkgdir}"/$site_packages +# ln -svf /usr/lib/libreoffice/program/uno.py \ +# "${pkgdir}"/$site_packages/uno.py +# ln -svf /usr/lib/libreoffice/program/unohelper.py \ +# "${pkgdir}"/$site_packages/unohelper.py + # add a symlink required for gnome-documents; FS#51887 # https://lists.freedesktop.org/archives/libreoffice/2016-March/073787.html