aboutsummaryrefslogtreecommitdiff
path: root/multimedia/GoogleEarth/GoogleEarth.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'multimedia/GoogleEarth/GoogleEarth.SlackBuild')
-rw-r--r--multimedia/GoogleEarth/GoogleEarth.SlackBuild39
1 files changed, 20 insertions, 19 deletions
diff --git a/multimedia/GoogleEarth/GoogleEarth.SlackBuild b/multimedia/GoogleEarth/GoogleEarth.SlackBuild
index 7b9287173f456..191ea8fe4c46a 100644
--- a/multimedia/GoogleEarth/GoogleEarth.SlackBuild
+++ b/multimedia/GoogleEarth/GoogleEarth.SlackBuild
@@ -1,7 +1,6 @@
#!/bin/sh
# Slackware build script for google-earth
-# Written by (Michiel van Wessem <BP{k}>) (michiel@slackbuilds.org)
# Copyright 2007 Michiel van Wessem (http://michielvwessem.wordpress.com)
# All rights reserved.
@@ -23,17 +22,18 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-# Thanks to rworkman for the additional code and script cleanups, and danieldk
-# and Alan_Hicks for their comments.
+# Thanks to rworkman for the additional code and script cleanups
+# and to Daniel de Kok and Alan_Hicks for their comments.
set -e
PRGNAM=googleearth
PKGNAME=GoogleEarth
-VERSION=4.1.7076.4458
+VERSION=4.2.205.5730
ARCH=${ARCH:-i486}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
@@ -46,10 +46,11 @@ mkdir -p $TMP $PKG $OUTPUT
cd $TMP
sh $CWD/${PKGNAME}Linux.bin --noexec --target $PKG/opt/$PKGNAME
-( cd $PKG/opt/$PKGNAME
-tar -xvf $PRGNAM-data.tar && rm $PRGNAM-data.tar || exit 1
-tar -xvf $PRGNAM-linux-x86.tar && rm $PRGNAM-linux-x86.tar || exit 1
-) || exit 1
+cd $PKG/opt/$PKGNAME
+ tar -xvf $PRGNAM-data.tar
+ tar -xvf $PRGNAM-linux-x86.tar
+ rm $PRGNAM-data.tar $PRGNAM-linux-x86.tar
+cd -
# Set the ownership and permissions right after all parts are extracted.
cd $PKG
@@ -60,17 +61,17 @@ mv $PKG/opt/$PKGNAME/bin/$PRGNAM $PKG/opt/$PKGNAME/$PRGNAM
rmdir $PKG/opt/$PKGNAME/bin
( cd $PKG
-find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
-find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
)
# Let's use the information from the included postinstall.sh
# script to create menu entry and mime stuff
DESKTOPFILE=$PKG/usr/share/applications/GoogleEarth.desktop
MIMEFILE=$PKG/usr/share/mime/googleearth-mimetypes.xml
-mkdir -p $PKG/usr/share/{applications,mime,pixmaps}
+mkdir -p $PKG/usr/share/{applications,mime,pixmaps} $PKG/usr/bin
-cat >$DESKTOPFILE <<EOF
+cat > $DESKTOPFILE << EOF
[Desktop Entry]
Encoding=UTF-8
Name=Google Earth
@@ -85,7 +86,7 @@ Categories=Application;Network
MimeType=application/vnd.google-earth.kml+xml;application/vnd.google-earth.kmz;application/earthviewer;application/keyhole
EOF
-cat >$MIMEFILE <<EOF
+cat > $MIMEFILE << EOF
<?xml version="1.0"?>
<mime-info xmlns='http://www.freedesktop.org/standards/shared-mime-info'>
<mime-type type="application/vnd.google-earth.kml+xml">
@@ -111,15 +112,15 @@ EOF
# Let's take care of documentation
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION
-mv $PKG/opt/$PKGNAME/EULA* $PKG/usr/doc/$PKGNAME-$VERSION
mv $PKG/opt/$PKGNAME/README.linux $PKG/usr/doc/$PKGNAME-$VERSION
cat $CWD/$PKGNAME.SlackBuild > $PKG/usr/doc/$PKGNAME-$VERSION/$PKGNAME.SlackBuild
-mv $PKG/opt/$PKGNAME/{$PRGNAM-icon.png,$PRGNAM.xpm} $PKG/usr/share/pixmaps
-
-( mkdir -p $PKG/usr/bin/
- cd $PKG/usr/bin
- ln -s ../../opt/$PKGNAME/$PRGNAM $PRGNAM
+# Make some needed symlinks in the package
+( cd $PKG/usr/share/pixmaps
+ ln -s /opt/$PKGNAME/$PRGNAM-icon.png .
+ ln -s /opt/$PKGNAME/$PRGNAM.xpm .
+ cd $PKG/usr/bin
+ ln -s /opt/$PKGNAME/$PRGNAM .
)
mkdir -p $PKG/install