summaryrefslogtreecommitdiff
path: root/manualPorts/libreoffice-bin/Pkgfile
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2023-02-03 22:17:43 +0100
committerErich Eckner <git@eckner.net>2023-02-03 22:17:43 +0100
commit0447e07a1d1e37ba8f78c82b2d4d166f5cb5c6dd (patch)
tree53c4d9ba2db9199d213f7a7d2d787258a1ef7d91 /manualPorts/libreoffice-bin/Pkgfile
parenta2729973ca3feb414f15a304211cdac5e4d6987e (diff)
downloadcrux-ports-0447e07a1d1e37ba8f78c82b2d4d166f5cb5c6dd.tar.xz
libreoffice-bin new
Diffstat (limited to 'manualPorts/libreoffice-bin/Pkgfile')
-rw-r--r--manualPorts/libreoffice-bin/Pkgfile54
1 files changed, 54 insertions, 0 deletions
diff --git a/manualPorts/libreoffice-bin/Pkgfile b/manualPorts/libreoffice-bin/Pkgfile
new file mode 100644
index 0000000..cc3bfbf
--- /dev/null
+++ b/manualPorts/libreoffice-bin/Pkgfile
@@ -0,0 +1,54 @@
+# Description: a powerful office suite, compiled upstream
+# URL: https://www.libreoffice.org/
+# Maintainer: Erich Eckner, crux at eckner dot net
+# Contributor: John McQuah, jmcquah at disroot dot org
+# Depends on: gtk3 freetype avahi cups nss nspr
+# Optional: qt5 sane
+
+name=libreoffice-bin
+Name=LibreOffice
+version=7.5.0
+release=1
+source=(https://download.documentfoundation.org/${name%-bin}/stable/$version/rpm/x86_64/${Name}_${version}_Linux_x86-64_rpm.tar.gz)
+
+build() {
+ cd ${Name}*/RPMS
+
+ for RPM in *.rpm; do
+ [[ $RPM =~ "-firebird-" ]] && continue
+ [[ $RPM =~ "-report-builder-" ]] && continue
+ [[ $RPM =~ "-mediawiki-" ]] && continue
+ [[ $RPM =~ "-mediawiki-" ]] && continue
+ [[ $RPM =~ "-onlineupdate-" ]] && continue
+ [[ $RPM =~ "-kde-integration-" ]] && continue
+ [[ $RPM =~ "-postgresql-" ]] && continue
+ [[ $RPM =~ "-nlpsolver-" ]] && continue
+ [[ $RPM =~ "-ooofonts-" ]] && continue
+ [[ $RPM =~ "-ogltrans-" ]] && continue
+ [[ $RPM =~ "-javascript-" ]] && continue
+ [[ $RPM =~ "-beanshell-" ]] && continue
+ [[ $RPM =~ "-dict-" ]] && [[ ! $RPM =~ "-dict-${LANG:0:2}" ]] && continue
+ bsdtar -p -C $PKG -xf "$RPM"
+ done
+
+ mv "$PKG/opt" "$PKG/usr/lib"
+ find "$PKG" -type d -perm 700 -exec chmod 755 {} +
+
+ rm -f "$PKG"/usr/share/applications/*.desktop
+ cd "$PKG"/usr/share/applications
+ for APP in ../../lib/libreoffice7.5/share/xdg/*.desktop; do
+ ln -sf $APP libreoffice7.5-${APP##*/}
+ done
+
+ rm -f "$PKG"/usr/bin/*
+ cd "$PKG"/usr/bin
+ for APP in soffice; do
+ ln -sf ../lib/libreoffice*/program/$APP ${APP}
+ done
+
+ # clean up junk files
+ rm -rf "$PKG"/usr/lib/libreoffice7.5/readmes
+ find "$PKG" \( -name "README*" -o -name "LICENSE*" -o -name "NOTICE*" \
+ -o -name "COPYING*" \) -exec rm {} +
+ find "$PKG" -name "wininst*.exe" -exec rm {} +
+}