From 030c314155ca1aea16de2cd60350f30dad27d2db Mon Sep 17 00:00:00 2001 From: dsomero Date: Tue, 12 Apr 2011 14:16:39 -0400 Subject: libraries/db46: Miscellaneous build script cleanups. Signed-off-by: dsomero --- libraries/db46/db46.SlackBuild | 46 +++++++++++++++++++++--------------------- libraries/db46/db46.info | 2 +- 2 files changed, 24 insertions(+), 24 deletions(-) (limited to 'libraries/db46') diff --git a/libraries/db46/db46.SlackBuild b/libraries/db46/db46.SlackBuild index 8e18e4db3448..ab11530a688c 100644 --- a/libraries/db46/db46.SlackBuild +++ b/libraries/db46/db46.SlackBuild @@ -26,15 +26,13 @@ PRGNAM=db46 VERSION=4.6.21 -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} -# Automatically determine the architecture we're building on: if [ -z "$ARCH" ]; then case "$( uname -m )" in i?86) ARCH=i486 ;; arm*) ARCH=arm ;; - # Unless $ARCH is already set, use uname -m for all other archs: *) ARCH=$( uname -m ) ;; esac fi @@ -42,14 +40,13 @@ fi CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM -rm -rf $PKG -mkdir -p $TMP $PKG +OUTPUT=${OUTPUT:-/tmp} if [ "$ARCH" = "i486" ]; then SLKCFLAGS="-O2 -march=i486 -mtune=i686" LIBDIRSUFFIX="" -elif [ "$ARCH" = "s390" ]; then - SLKCFLAGS="-O2" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2 -fPIC" @@ -59,9 +56,13 @@ else LIBDIRSUFFIX="" fi +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT cd $TMP rm -rf db-$VERSION -tar xzvf $CWD/db-$VERSION.tar.gz || exit 1 +tar xvf $CWD/db-$VERSION.tar.gz cd db-$VERSION chown -R root:root . find . \ @@ -76,22 +77,21 @@ patch -p0 < $CWD/patches/patch.4.6.21.2 patch -p0 < $CWD/patches/patch.4.6.21.3 patch -p0 < $CWD/patches/patch.4.6.21.4 -rm -rf build-dir mkdir build-dir cd build-dir -CFLAGS="$SLKCFLAGS" \ -CXXFLAGS="$SLKCFLAGS" \ -../dist/configure \ - --prefix=/usr \ - --libdir=/usr/lib${LIBDIRSUFFIX} \ - --enable-shared \ - --enable-rpc \ - --enable-cxx \ - --enable-compat185 \ - --build=$ARCH-slackware-linux - -make -make install DESTDIR=$PKG + CFLAGS="$SLKCFLAGS" \ + CXXFLAGS="$SLKCFLAGS" \ + ../dist/configure \ + --prefix=/usr \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --enable-shared \ + --enable-rpc \ + --enable-cxx \ + --enable-compat185 \ + --build=$ARCH-slackware-linux + make + make install DESTDIR=$PKG +cd .. find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true @@ -100,7 +100,7 @@ find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ rm -rf $PKG/usr/docs mkdir -p $PKG/usr/doc/db-$VERSION cp -a \ - ../LICENSE ../README \ + LICENSE README \ $PKG/usr/doc/db-$VERSION cat << EOF > $PKG/usr/doc/db-$VERSION/README-DOCS diff --git a/libraries/db46/db46.info b/libraries/db46/db46.info index 1e16f42b1b13..5205fb25b2c3 100644 --- a/libraries/db46/db46.info +++ b/libraries/db46/db46.info @@ -7,4 +7,4 @@ DOWNLOAD_x86_64="" MD5SUM_x86_64="" MAINTAINER="John Clizbe" EMAIL="John.Clizbe@gmail.com" -APPROVED="rworkman" +APPROVED="dsomero rworkman" -- cgit v1.2.3