aboutsummaryrefslogtreecommitdiff
path: root/system/localepurge/localepurge.SlackBuild
diff options
context:
space:
mode:
authorEdinaldo P. Silva <edps.mundognu@gmail.com>2016-11-09 10:59:53 +0000
committerDavid Spencer <idlemoor@slackbuilds.org>2016-11-11 20:36:22 +0000
commitd8812bd9a703b8021b1b004d75f6d5b489ffc520 (patch)
tree5350e08cdd5991f17e32312771fdd67bab6a3fb8 /system/localepurge/localepurge.SlackBuild
parent4792487ebbcfa22db689752c3009143772d66252 (diff)
system/localepurge: Updated for version 0.7.3.4.
Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
Diffstat (limited to 'system/localepurge/localepurge.SlackBuild')
-rw-r--r--system/localepurge/localepurge.SlackBuild31
1 files changed, 19 insertions, 12 deletions
diff --git a/system/localepurge/localepurge.SlackBuild b/system/localepurge/localepurge.SlackBuild
index bdf61a156ca2f..94b2b2972bdec 100644
--- a/system/localepurge/localepurge.SlackBuild
+++ b/system/localepurge/localepurge.SlackBuild
@@ -2,7 +2,7 @@
#
# Slackware build script for localepurge.
#
-# Copyright 2015 Edinaldo P. Silva, Rio de Janeiro, Brazil.
+# Copyright 2016 Edinaldo P. Silva, Rio de Janeiro, Brazil.
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,7 +23,7 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=localepurge
-VERSION=${VERSION:-0.5.4}
+VERSION=${VERSION:-0.7.3.4}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -60,7 +60,7 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tbz2
+tar xvf $CWD/${PRGNAM}_${VERSION}.tar.xz
mv $PRGNAM $PRGNAM-$VERSION
cd $PRGNAM-$VERSION
chown -R root:root .
@@ -73,23 +73,30 @@ find -L . \
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
-mkdir -p $PKG/etc
-cp -a locale.nopurge $PKG/etc/locale.nopurge.new
+patch -uN usr/sbin/localepurge < $CWD/localepurge.diff
+patch -uN debian/localepurge.8 < $CWD/localepurge.8.diff
+patch -uN debian/localepurge.config < $CWD/localepurge.config.diff
-mkdir -p $PKG/var/cache/localepurge
-cp -a defaultlist $PKG/var/cache/localepurge/localelist
+install -D -m755 usr/sbin/localepurge $PKG/usr/bin/localepurge
+install -D -m644 debian/localepurge.8 $PKG/usr/man/man8/localepurge.8
+install -D -m755 debian/localepurge.config $PKG/usr/bin/localepurge-config
+install -D -m644 $CWD/locale.nopurge $PKG/etc/locale.nopurge
-mkdir -p $PKG/usr/man/man8
-cp -a localepurge.8 $PKG/usr/man/man8
+if [ ! -e /var/cache/localepurge/localelist ]; then
+ find /usr/share/locale -maxdepth 1 -type d -name "*" -printf "%f\n" | grep "^[a-z]" | cut -d" " -f1 | sort -u > $CWD/localelist
+else
+ install -D -m644 $CWD/localelist /var/cache/localepurge/localelist
+fi
+
+install -D -m644 $CWD/localelist $PKG/var/cache/localepurge/localelist
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/bin
-cp -a localepurge $PKG/usr/bin
+DOCS="debian/NEWS.Debian debian/README.Debian debian/changelog debian/copyright"
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a copyright $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install