aboutsummaryrefslogtreecommitdiff
path: root/system/fdupes/fdupes.SlackBuild
diff options
context:
space:
mode:
authorLukenShiro <lukenshiro@ngi.it>2013-11-15 15:34:04 +0100
committerRobby Workman <rworkman@slackbuilds.org>2013-11-15 13:45:29 -0600
commitb806c84a7c07ef3e0529511905f8e0ec2831123e (patch)
treed88f9ec8efb6be0020ee0037f3f80dacea4b24ea /system/fdupes/fdupes.SlackBuild
parent6208d04856dff7905e0a1862697d6a2079619775 (diff)
system/fdupes: Updated for version 1.51.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'system/fdupes/fdupes.SlackBuild')
-rw-r--r--system/fdupes/fdupes.SlackBuild30
1 files changed, 19 insertions, 11 deletions
diff --git a/system/fdupes/fdupes.SlackBuild b/system/fdupes/fdupes.SlackBuild
index 7730e1c804330..8c9835ec4a92d 100644
--- a/system/fdupes/fdupes.SlackBuild
+++ b/system/fdupes/fdupes.SlackBuild
@@ -1,12 +1,10 @@
#!/bin/bash
# Slackware build script for duplicate file finder fdupes.
-
-# 17/12/2008 - Original script.
-# 28/05/2009 - Updated for Slackware64 and general tidy up.
-# 19/06/2011 - Updated to version 1.50-PR2
# Copyright 2008-2011 Pierre Cazenave <pwcazenave {at} gmail [dot] com>
+# Copyright 2013 LukenShiro, Italy
+
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -25,9 +23,13 @@
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+# 17/12/2008 - Original script.
+# 28/05/2009 - Updated for Slackware64 and general tidy up.
+# 19/06/2011 - Updated to version 1.50-PR2
PRGNAM=fdupes
-VERSION=1.50_PR2
+VERSION=${VERSION:-1.51}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -60,6 +62,8 @@ else
LIBDIRSUFFIX=""
fi
+DOCFILES="CHANGES CONTRIBUTORS INSTALL README TODO"
+
set -e
rm -rf $PKG
@@ -69,21 +73,25 @@ rm -rf $PRGNAM-$SRCVERS
tar -xvf $CWD/$PRGNAM-$SRCVERS.tar.gz
cd $PRGNAM-$SRCVERS
chown -R root:root .
-chmod -R u+w,go+r-w,a-s .
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-# Fix apparent typo in Makefile
-sed -i 's/-$(MKDIR)/$(MKDIR)/g' Makefile
+# apply a patch by hobbes1069<at>gmail<dot>com for DESTDIR (issue #29)
+patch -p1 < $CWD/fdupes-1.51-destdir.patch
-make install PREFIX=$PKG/usr COMPILER_OPTIONS="$SLKCFLAGS"
+make install DESTDIR=$PKG PREFIX=/usr COMPILER_OPTIONS="$SLKCFLAGS"
-find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
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 CHANGES CONTRIBUTORS INSTALL README TODO $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a $DOCFILES $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install