diff options
Diffstat (limited to 'system/ink/ink.SlackBuild')
-rw-r--r-- | system/ink/ink.SlackBuild | 49 |
1 files changed, 29 insertions, 20 deletions
diff --git a/system/ink/ink.SlackBuild b/system/ink/ink.SlackBuild index b344b72592548..c1dbb400500c5 100644 --- a/system/ink/ink.SlackBuild +++ b/system/ink/ink.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for ink -# Copyright 2006 Robby Workman (http://rlworkman.net) +# Copyright 2006-2008 Robby Workman (http://rlworkman.net) # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -22,46 +22,55 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# Modified by the SlackBuilds.org project - PRGNAM=ink -VERSION=0.3.1 +VERSION=0.4.1 ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -CWD=`pwd` + +CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-march=i486 -mtune=i686" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-march=i686 -mtune=i686" +fi + +set -e + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT -cd $TMP || exit 1 -rm -rf $PRGNAM -tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz || exit 1 -cd $PRGNAM || exit 1 +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION chown -R root:root . -chmod -R a-s,u+w,go+r-w . +find . \ + \( -perm 777 -o -perm 775 -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 {} \; + +# Patch the Makefile to fix DESTDIR and add PREFIX +# Sent upstream 20070106 --rworkman +patch -p1 < $CWD/ink-0.4.1-Makefile.diff -# Don't set uid and gid during install; we'll handle it in the build script -cat $CWD/Makefile.diff | patch -p1 || exit 1 -make || exit 1 -make install DESTDIR=$PKG/usr || exit 1 +CFLAGS="$SLKCFLAGS" make +make PREFIX=/usr DESTDIR=$PKG install -( cd $PKG - find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null -) +strip --strip-unneeded $PKG/usr/bin/ink # No man pages mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cat $CWD/README > $PKG/usr/doc/$PRGNAM-$VERSION/README +cp -a AUTHORS COPYING README $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 cd $PKG -chown -R root.root . /sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz - |