summaryrefslogtreecommitdiff
path: root/libraries/ebook-tools/ebook-tools.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/ebook-tools/ebook-tools.SlackBuild')
-rw-r--r--libraries/ebook-tools/ebook-tools.SlackBuild11
1 files changed, 9 insertions, 2 deletions
diff --git a/libraries/ebook-tools/ebook-tools.SlackBuild b/libraries/ebook-tools/ebook-tools.SlackBuild
index eeb68c7e33..6b238e0604 100644
--- a/libraries/ebook-tools/ebook-tools.SlackBuild
+++ b/libraries/ebook-tools/ebook-tools.SlackBuild
@@ -2,7 +2,7 @@
# Slackware build script for ebook-tools
-# Copyright 2008 Heinz Wiesinger <hmwiesinger@gmx.at>
+# Copyright 2008-2009 Heinz Wiesinger <pprkut@liwjatan.at>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -35,10 +35,13 @@ 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
@@ -52,12 +55,16 @@ cd $PRGNAM-$VERSION
chown -R root:root .
chmod -R u+w,go+r-w,a-s .
+#fix correctly installing libraries in lib$LIBDIRSUFFIX
+sed -i "s/lib /lib\${LIB_SUFFIX} /g" src/libepub/CMakeLists.txt
+
mkdir -p build
cd build
cmake \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_INSTALL_PREFIX=/usr \
+ -DLIB_SUFFIX="$LIBDIRSUFFIX" \
..
make
make install DESTDIR=$PKG
@@ -76,4 +83,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}