l/libsamplerate: Updated for Slackware-13.0.

This commit is contained in:
Damien Goutte-Gattat 2009-09-12 12:17:27 +02:00
parent 1659a239fc
commit 09d3779167
1 changed files with 9 additions and 9 deletions

View File

@ -34,15 +34,16 @@ ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.gz}
WGET=${WGET:-http://www.mega-nerd.com/SRC/$ARCHIVE}
# Build infos
NAMETGZ=${NAMETGZ:-libsamplerate}
BUILD=${BUILD:-1GGD}
NAMEPKG=${NAMEPKG:-libsamplerate}
BUILD=${BUILD:-2GGD}
ARCH=${ARCH:-i486}
JOBS=${JOBS:-1}
EXT=${EXT:-txz}
# Directories
TMP=${TMP:-/tmp}
OUT=${OUT:-$TMP/build}
PKG=${PKG:-$OUT/$NAMETGZ}
PKG=${PKG:-$OUT/$NAMEPKG}
CWD=$(pwd)
set -e # Quit if a command returns non-zero
@ -58,12 +59,14 @@ if [ ! -d $TMP ]; then
fi
# Compilation flags
LIBDIRSUFFIX=""
case "$ARCH" in
i?86)
CPUOPT="-O2 -march=$ARCH -mtune=i686"
;;
x86_64)
CPUOPT="-O2 -fPIC"
LIBDIRSUFFIX="64"
;;
*)
CPUOPT="-O2"
@ -87,14 +90,11 @@ CFLAGS=$CPUOPT \
CXXFLAGS=$CPUOPT \
./configure \
--prefix=/usr \
--libdir=/usr/lib$LIBDIRSUFFIX \
--disable-static \
--disable-dependency-tracking
make -j $JOBS
make install DESTDIR=$PKG
# Strip binaries
find $PKG | xargs file | grep "ELF 32-bit LSB" | cut -d : -f 1 | \
xargs strip --strip-unneeded 2> /dev/null
make install-strip DESTDIR=$PKG
# Install the documentation
mkdir -p $PKG/usr/doc/$NAME
@ -109,7 +109,7 @@ cd $PKG
mkdir -p $OUT
PACKAGING="
chown root:root . -R
/sbin/makepkg -l y -c n $OUT/$NAMETGZ-$VERSION-$ARCH-$BUILD.tgz
/sbin/makepkg -l y -c n $OUT/$NAMEPKG-$VERSION-$ARCH-$BUILD.$EXT
rm -rf $PKG
rm -rf $TMP/$NAME
"