milis/talimatname/genel/l/libreoffice-bin/talimat

58 lines
1.6 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Tanım: Tam özellikli çapraz platform ofis paketi (ikili)
# URL: http://www.libreoffice.org
# Paketçi: milisarge
# Gerekler: cups xorg-libxaw xorg-libxcursor xorg-libxft xorg-libxinerama xorg-libxi xorg-libxrandr dbus-glib krb5
isim=libreoffice-bin
namep=libreoffice
surum=5.1.3
devir=1
kaynak=(http://tdf.c3sl.ufpr.br/libreoffice/stable/5.1.3/rpm/x86_64/LibreOffice_5.1.3_Linux_x86-64_rpm.tar.gz)
derle() {
local workd="$SRC/tmp_work"
mkdir $workd
cd LibreOffice_${surum}*/RPMS
for rpm in *.rpm; do
bsdtar -p -o -C $workd -xf $rpm
done
bsdtar -p -o -C $workd -xf \
$isimp${surum%.*}*.noarch.rpm
cd $workd
mkdir -p $PKG/usr/lib/$isimp
mv opt/$isimp*/* $PKG/usr/lib/$isimp
cd $PKG/usr/lib/$isimp
ln -sf basis${surum%.*} 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/$isimp/program/$program $PKG/usr/bin/$program
done
mkdir -p $PKG/usr/share/applications
cd $PKG/usr/lib/$isimp/share/xdg/
for desktop in *.desktop; do
sed -i '/^Exec=/s/libreoffice[^ ]*/soffice/' $desktop
ln -sf /usr/lib/$isimp/share/xdg/$desktop $PKG/usr/share/applications/$desktop
done
mv $workd/usr/share/{mime,icons} $PKG/usr/share
find $PKG \(\
-inamep '*readme*' -o \
-inamep '*changelog*' -o \
-namep '*TODO*' -o \
-inamep '*news*' -o \
-inamep '*license*' -o \
-inamep '*credits*' \
\) -exec rm -rf '{}' \; || true
}