summaryrefslogtreecommitdiff
path: root/desktop/catfish/catfish.SlackBuild
diff options
context:
space:
mode:
authorDavid Woodfall <dave@dawoodfall.net>2014-05-08 07:09:07 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-05-12 07:35:54 +0700
commit89acdcdff57ef237ed8758496f61e10a5cf22e8f (patch)
tree6e0915c1b6cba8f53c94d2ffe9ffb2e2b07cc80f /desktop/catfish/catfish.SlackBuild
parentfe1e315ba624439c9fe37b387f2a7f86b7584c12 (diff)
downloadslackbuilds-89acdcdff57ef237ed8758496f61e10a5cf22e8f.tar.gz
desktop/catfish: Updated for version 1.0.2.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'desktop/catfish/catfish.SlackBuild')
-rw-r--r--desktop/catfish/catfish.SlackBuild56
1 files changed, 32 insertions, 24 deletions
diff --git a/desktop/catfish/catfish.SlackBuild b/desktop/catfish/catfish.SlackBuild
index 6cd1b0067e..eb1d22e711 100644
--- a/desktop/catfish/catfish.SlackBuild
+++ b/desktop/catfish/catfish.SlackBuild
@@ -1,8 +1,7 @@
#!/bin/sh
# Slackware build script for catfish
-# Original Slackbuild Copyright 2008 Frank Caraballo
-# Edits Copyright 2011 David Woodfall <dave@dawoodfall.net>
+# Copyright 2014 David Woodfall <dave@dawoodfall.net>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,61 +22,70 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=catfish
-VERSION=${VERSION:-0.3.2}
+VERSION=${VERSION:-1.0.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
-ARCH="noarch"
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
cd $PRGNAM-$VERSION
chown -R root:root .
find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \
- -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
- -exec chmod 644 {} \;
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr
make
make install DESTDIR=$PKG
-find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
-rm $PKG/usr/share/catfish/catfish.svg
-rm $PKG/usr/share/catfish/locale
-ln -s /usr/share/icons/hicolor/scalable/apps/catfish.svg \
- $PKG/usr/share/catfish/catfish.svg
-ln -s /usr/share/locale $PKG/usr/share/catfish/locale
-
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a \
- AUTHORS COPYING ChangeLog INSTALL README TODO \
- $PKG/usr/doc/$PRGNAM-$VERSION
-mv $PKG/usr/share/doc/$PRGNAM/* $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS COPYING ChangeLog INSTALL README TODO $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.sh
-# Set some saner permissions.
-chmod 0644 $PKG/usr/doc/$PRGNAM-$VERSION/*
-find $PKG/usr/share/ -type f -exec chmod 0644 {} \;
-
cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}