diff options
author | Brenton Earl <brent@exitstatusone.com> | 2016-12-16 23:51:42 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2016-12-17 01:18:33 +0700 |
commit | 5e139710ca902336859da9b962e8285a912ce325 (patch) | |
tree | 3a413365cb4c465377dad16fb81849f0f994f8d0 /office/zim/zim.SlackBuild | |
parent | 512fdb62351a2e5fa775cdb131a3113b6e1fb268 (diff) | |
download | slackbuilds-5e139710ca902336859da9b962e8285a912ce325.tar.gz |
office/zim: Switch to i586.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'office/zim/zim.SlackBuild')
-rw-r--r-- | office/zim/zim.SlackBuild | 27 |
1 files changed, 22 insertions, 5 deletions
diff --git a/office/zim/zim.SlackBuild b/office/zim/zim.SlackBuild index 6641de2991..cd50dbbb98 100644 --- a/office/zim/zim.SlackBuild +++ b/office/zim/zim.SlackBuild @@ -2,10 +2,8 @@ # Slackware build script for zim -# Copyright 2015 Brenton Earl <brent@exitstatusone.com> -# All rights reserved. -# # Copyright 2013 Michael Ren <micron33@gmail.com> +# Copyright 2015-2016 Brenton Earl <brent@exitstatusone.com> # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -32,7 +30,7 @@ TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac @@ -45,7 +43,21 @@ OUTPUT=${OUTPUT:-/tmp} DOCS="CHANGELOG.txt LICENSE.txt PKG-INFO README.txt" -set -e +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -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 @@ -65,11 +77,16 @@ find -L . \ # ("automation"), hence --skip-xdg-cmd python setup.py install --root=$PKG --skip-xdg-cmd +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 + mv $PKG/usr/share/man $PKG/usr find $PKG/usr/man -type f -exec gzip -9 {} \; +for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/README.Plugins > $PKG/usr/doc/$PRGNAM-$VERSION/README.Plugins cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install |