summaryrefslogtreecommitdiff
path: root/system/mktorrent/mktorrent.SlackBuild
diff options
context:
space:
mode:
authorGrigorios Bouzakis <grbzks@xsmail.com>2010-05-13 00:40:58 +0200
committerRobby Workman <rworkman@slackbuilds.org>2010-05-13 00:40:58 +0200
commit34a3c95984d9db494b804c0e64af04fd07fbed21 (patch)
treecc3167fa3fb04644591fa995e3f7e0ec399e8ea3 /system/mktorrent/mktorrent.SlackBuild
parent7bb8593a3d7375fe70d26c62f9c4f19d5bd154b6 (diff)
downloadslackbuilds-34a3c95984d9db494b804c0e64af04fd07fbed21.tar.gz
system/mktorrent: Updated for version 0.9.9
Diffstat (limited to 'system/mktorrent/mktorrent.SlackBuild')
-rw-r--r--system/mktorrent/mktorrent.SlackBuild30
1 files changed, 15 insertions, 15 deletions
diff --git a/system/mktorrent/mktorrent.SlackBuild b/system/mktorrent/mktorrent.SlackBuild
index ec8412a83e..b1667c80a0 100644
--- a/system/mktorrent/mktorrent.SlackBuild
+++ b/system/mktorrent/mktorrent.SlackBuild
@@ -1,12 +1,12 @@
#!/bin/sh
# Slackware build script for mktorrent
-# Written by Grigorios Bouzakis (grbzks@gmail.com)
+# Written by Grigorios Bouzakis (grbzks@xsmail.com)
PRGNAM=mktorrent
VERSION=${VERSION:-0.9.9}
-ARCH=${ARCH:-i486}
-BUILD=${BUILD:-1}
+ARCH=${ARCH:-x86_64}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
CWD=$(pwd)
@@ -16,14 +16,15 @@ 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
-DOCS="CHANGES LICENSE"
-
set -e
rm -rf $PKG
@@ -39,25 +40,24 @@ 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" \
-
-make
-
+make CFLAGS+="-w $SLKCFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DFS64"
mkdir -p $PKG/usr/bin
-cp -a mktorrent $PKG/usr/bin/
+cat mktorrent > $PKG/usr/bin/mktorrent
+chmod 0755 $PKG/usr/bin/mktorrent
( 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
+ 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
)
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a CHANGES LICENSE $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.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.tgz
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}