summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libraries/wv/slack-desc10
-rw-r--r--libraries/wv/wv.SlackBuild28
2 files changed, 22 insertions, 16 deletions
diff --git a/libraries/wv/slack-desc b/libraries/wv/slack-desc
index f80deb2630..dbffa9b6f8 100644
--- a/libraries/wv/slack-desc
+++ b/libraries/wv/slack-desc
@@ -7,13 +7,13 @@
|-----handy-ruler---------------------------------------------------------|
wv: wv (MS Word document import library)
-wv:
+wv:
wv: wv converts Word 2,6,7,8,9 files to html and latex.
wv: The Word 2 conversion is still incomplete (no formatting),
wv: but it will do a passable job extracting the text, which
wv: is what you probably want anyway.
-wv:
+wv:
wv: Homepage: http://wvware.sourceforge.net/
-wv:
-wv:
-wv:
+wv:
+wv:
+wv:
diff --git a/libraries/wv/wv.SlackBuild b/libraries/wv/wv.SlackBuild
index a727f75c70..95b67ae213 100644
--- a/libraries/wv/wv.SlackBuild
+++ b/libraries/wv/wv.SlackBuild
@@ -24,10 +24,19 @@
PRGNAM=wv
VERSION=1.2.4
-ARCH=${ARCH:-i486}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) export ARCH=i486 ;;
+ arm*) export ARCH=arm ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) export ARCH=$( uname -m ) ;;
+ esac
+fi
+
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
@@ -42,6 +51,9 @@ elif [ "$ARCH" = "s390" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
set -e
@@ -73,17 +85,11 @@ CXXFLAGS="$SLKCFLAGS" \
make
make install DESTDIR=$PKG
-( 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 || true
-)
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
-( cd $PKG/usr/man
- find . -type f -exec gzip -9 {} \;
- for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
-)
+find $PKG/usr/man -type f -exec gzip -9 {} \;
+for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a COPYING INSTALL README $PKG/usr/doc/$PRGNAM-$VERSION