55 lines
1.8 KiB
Plaintext
55 lines
1.8 KiB
Plaintext
# Description: full featured cross platform office suite (binary)
|
|
# URL: http://www.libreoffice.org
|
|
# Maintainer: Bartlomiej Palmowski, rotwang at crux dot org dot pl
|
|
# Depends on: mesa3d xorg-libxaw xorg-libxcursor xorg-libxft xorg-libxinerama xorg-libxi xorg-libxrandr
|
|
|
|
name=libreoffice
|
|
version=3.4.6
|
|
release=1
|
|
#http://download.documentfoundation.org/libreoffice/stable/3.5.0/rpm/
|
|
source=(http://ftp.tu-chemnitz.de/pub/tdf/$name/stable/$version/rpm/x86/LibO_${version}_Linux_x86_install-rpm_en-US.tar.gz)
|
|
|
|
build() {
|
|
local workd="$SRC/tmp_work"
|
|
mkdir $workd
|
|
|
|
cd LibO*/RPMS
|
|
for rpm in *.rpm; do
|
|
bsdtar -p -o -C $workd -xf $rpm
|
|
done
|
|
cd desktop-integration
|
|
bsdtar -p -o -C $workd -xf \
|
|
$name${version%.*}-freedesktop-menus-${version%.*}-*.noarch.rpm
|
|
|
|
cd $workd
|
|
mkdir -p $PKG/usr/lib/$name
|
|
mv opt/$name*/* $PKG/usr/lib/$name
|
|
|
|
cd $PKG/usr/lib/$name
|
|
ln -sf basis${version%.*} basis-link
|
|
|
|
mkdir -p $PKG/usr/bin
|
|
local programs=(sbase scalc sdraw simpress smath soffice spadmin swriter)
|
|
for program in ${programs[@]}; do
|
|
ln -sf /usr/lib/$name/program/$program $PKG/usr/bin/$program
|
|
done
|
|
|
|
mkdir -p $PKG/usr/share/applications
|
|
cd $PKG/usr/lib/$name/share/xdg/
|
|
sed -i '/^Exec=/s/libreoffice-printeradmin/spadmin/' printeradmin.desktop
|
|
for desktop in *.desktop; do
|
|
sed -i '/^Exec=/s/libreoffice[^ ]*/soffice/' $desktop
|
|
ln -sf /usr/lib/$name/share/xdg/$desktop $PKG/usr/share/applications/$desktop
|
|
done
|
|
mv $workd/usr/share/{mime,icons} $PKG/usr/share
|
|
|
|
find $PKG \(\
|
|
-iname '*readme*' -o \
|
|
-iname '*changelog*' -o \
|
|
-name '*TODO*' -o \
|
|
-iname '*news*' -o \
|
|
-iname '*license*' -o \
|
|
-iname '*credits*' \
|
|
\) -exec rm -rf '{}' \; || true
|
|
}
|