diff options
author | ariarat <ariarat@gmail.com> | 2010-06-15 06:41:00 -0500 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2010-06-15 06:41:00 -0500 |
commit | 8a5a84ebfed85ad683a8eba7acef8992dc905f7d (patch) | |
tree | 96c7923078bcad9c7f2a3afc1497c45be59d1dc6 /misc/mdic/mdic.SlackBuild | |
parent | b6304352d73100269888203a2861047e5955068a (diff) |
misc/mdic: Added (multilingual dictionary)
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'misc/mdic/mdic.SlackBuild')
-rw-r--r-- | misc/mdic/mdic.SlackBuild | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/misc/mdic/mdic.SlackBuild b/misc/mdic/mdic.SlackBuild new file mode 100644 index 0000000000000..d28283dd80896 --- /dev/null +++ b/misc/mdic/mdic.SlackBuild @@ -0,0 +1,76 @@ +#!/bin/sh +# Slackware build script for Mdic dictionary +#written by Mehdi Esmaeelpour ariarat@gmail.com www.slack-world.com + +PRGNAM=mdic +VERSION=${VERSION:-0.8.1} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +CWD=$(pwd) +if [ "$TMP" = "" ]; then +TMP=${TMP:-/tmp/SBo} +fi +OUTPUT=${OUTPUT:-/tmp} +PKG=$TMP/package-$PRGNAM + +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" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +rm -rf $TMP/$PRGNAM +cd $TMP +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; + +mkdir build +cd build + cmake \ + -DCMAKE_INSTALL_PREFIX=/usr .. + make VERBOSE=1 + make install VERBOSE=1 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 + +mv $PKG/usr/share/man $PKG/usr +rm -rf $PKG/usr/share/doc + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a COPYING changelog README AUTHORS TODO $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/mdic.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/mdic.SlackBuild + +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.${PKGTYPE:-tgz} |