office/mdbtools: Updated for version 0.5

This commit is contained in:
Hans Goossen 2010-05-13 00:39:20 +02:00 committed by David Somero
parent e957851010
commit 88ac41b32f
2 changed files with 13 additions and 26 deletions

View file

@ -31,16 +31,19 @@ BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo} # For consistency's sake, use this
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp} # Drop the package in /tmp
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
fi
set -e # Exit on most errors
@ -58,25 +61,22 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
--libdir=/usr/lib$LIBDIRSUFFIX \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/man \
--enable-sql \
--enable-static=no \
--enable-shared=yes
--enable-shared=yes \
--build=$ARCH-slackware-linux
# Compile the application and install it into the $PKG directory
make
make install DESTDIR=$PKG
# Strip binaries and libraries - this can be done with 'make install-strip'
# in many source trees, and that's usually acceptable if so, but if not,
# use this:
( cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
@ -88,28 +88,13 @@ make install DESTDIR=$PKG
for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
)
# Remove perllocal.pod and other special files that don't need to be installed,
# as they will overwrite what's already on the system. If this is not needed,
# remove it from the script.
( cd $PKG
# Remove 'special' files
find . -name perllocal.pod \
-o -name ".packlist" \
-o -name "*.bs" \
| xargs rm -f
)
# Copy program documentation into the package
# Also, include the SlackBuild script in the documentation directory
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a AUTHORS COPYING ChangeLog NEWS README TODO HACKING $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
# Copy the slack-desc (and a custom doinst.sh if necessary) into ./install
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
# Make the package; be sure to leave it in $OUTPUT
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}

View file

@ -2,7 +2,9 @@ PRGNAM="mdbtools"
VERSION="0.5"
HOMEPAGE="http://mdbtools.sourceforge.net/"
DOWNLOAD="http://prdownloads.sourceforge.net/mdbtools/mdbtools-0.5.tar.gz"
DOWNLOAD_x86_64=""
MD5SUM="4a18bf96e67161101cade64526756d22"
MD5SUM_x86_64=""
MAINTAINER="Hans Goossen"
EMAIL="goosseno@gmail.com"
APPROVED="David Somero"
APPROVED="David Somero,pprkut"