diff options
Diffstat (limited to 'system/anacron/anacron.SlackBuild')
-rw-r--r-- | system/anacron/anacron.SlackBuild | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/system/anacron/anacron.SlackBuild b/system/anacron/anacron.SlackBuild index a37f01a3d8fca..392d00077f144 100644 --- a/system/anacron/anacron.SlackBuild +++ b/system/anacron/anacron.SlackBuild @@ -1,6 +1,7 @@ #!/bin/sh # Slackware build script for anacron + # (C) 2007 Michael Wagner <lapinours@web.de> # All rights reserved. # @@ -26,6 +27,7 @@ VERSION=2.3 ARCH=${ARCH:-i486} BUILD=${BUILD:-2} TAG=${TAG:-_SBo} + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -33,11 +35,12 @@ OUTPUT=${OUTPUT:-/tmp} DOCS="COPYING ChangeLog README TODO" -# Omit -O2 as it is already included in the Makefile if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-march=i486 -mtune=i686" + SLKCFLAGS="-O2 -march=i486 -mtune=i686" elif [ "$ARCH" = "i686" ]; then - SLKCFLAGS="-march=i686 -mtune=i686" + SLKCFLAGS="-O2 -march=i686 -mtune=i686" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" fi set -e @@ -51,17 +54,18 @@ cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . -# Use $SLKCFLAGS -sed -i "s,\(`grep -m 1 CFLAGS Makefile`\),\1 $SLKCFLAGS," Makefile - # "Patch" gregor.c sed -i 's,const int isleap,int isleap,' gregor.c -make +make CFLAGS="$SLKCFLAGS" make install PREFIX=$PKG strip --strip-unneeded $PKG/usr/sbin/$PRGNAM 2> /dev/null +# Install a default /etc/anacrontab file +mkdir -p $PKG/etc +cat $CWD/anacrontab.new > $PKG/etc/anacrontab.new + for i in $PKG/usr/man/man?/*; do chmod 644 $i && gzip -9 $i 2> /dev/null done @@ -71,13 +75,9 @@ cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild chmod 644 $PKG/usr/doc/$PRGNAM-$VERSION/* -# Install a default /etc/anacrontab file -mkdir -p $PKG/etc -cat $CWD/anacrontab.new > $PKG/etc/anacrontab.new - mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh cd $PKG -/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} |