summaryrefslogtreecommitdiff
path: root/libraries/libsyncml/libsyncml.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/libsyncml/libsyncml.SlackBuild')
-rw-r--r--libraries/libsyncml/libsyncml.SlackBuild31
1 files changed, 17 insertions, 14 deletions
diff --git a/libraries/libsyncml/libsyncml.SlackBuild b/libraries/libsyncml/libsyncml.SlackBuild
index fc72761b2b..ef105c9bee 100644
--- a/libraries/libsyncml/libsyncml.SlackBuild
+++ b/libraries/libsyncml/libsyncml.SlackBuild
@@ -1,7 +1,8 @@
#!/bin/sh
-#
-# Slackware build script for libsyncml
-# (C) 2008 Michael Wagner <slackware.wagnerm@arcor.de>
+
+# Slackware build script for libsyncml
+
+# (C) 2008 Michael Wagner <slackware.wagnerm@arcor.de>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -21,7 +22,6 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
PRGNAM=libsyncml
VERSION=0.4.6
ARCH=${ARCH:-i486}
@@ -33,25 +33,25 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-DOCS="AUTHORS COPYING ChangeLog README"
-
-
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
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
-cd $TMP
+cd $TMP
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
-cd $PRGNAM-$VERSION
+cd $PRGNAM-$VERSION
chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
@@ -68,17 +68,20 @@ cd build
cmake \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
- -DCMAKE_INSTALL_PREFIX=/usr -Wno-dev ..
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DLIB_SUFFIX=$LIBDIRSUFFIX \
+ -Wno-dev \
+ ..
- make
- make install DESTDIR=$PKG
+ 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
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS COPYING ChangeLog README $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
chmod 644 $PKG/usr/doc/$PRGNAM-$VERSION/*
@@ -86,4 +89,4 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
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}