aboutsummaryrefslogtreecommitdiff
path: root/network/ufw/ufw.SlackBuild
diff options
context:
space:
mode:
authorrodolfo gouveia <rgouveia@cosmico.net>2014-09-21 18:36:48 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-09-22 08:23:48 +0700
commite9fe87324629aedb1f1b147f3ea1959dd031d2d9 (patch)
treef30ea2ac4e8b218bf6359b39e1d2b956f85db4ff /network/ufw/ufw.SlackBuild
parentd5747e4dd48cbebeac349d9f8f1b27b7501206fd (diff)
network/ufw: New maintainer + script update.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'network/ufw/ufw.SlackBuild')
-rw-r--r--network/ufw/ufw.SlackBuild31
1 files changed, 13 insertions, 18 deletions
diff --git a/network/ufw/ufw.SlackBuild b/network/ufw/ufw.SlackBuild
index 90d82681d6b5a..e56edc6620925 100644
--- a/network/ufw/ufw.SlackBuild
+++ b/network/ufw/ufw.SlackBuild
@@ -20,6 +20,7 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
+set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
@@ -28,31 +29,25 @@ tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
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 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
- -exec chmod 644 {} \;
+ \( -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 {} \;
-zcat $CWD/ufw-0.33-conntrack.patch.gz | patch -p1 --verbose || exit 1
-zcat $CWD/ufw.conf.patch.gz | patch -p1 --verbose || exit 1
+zcat $CWD/ufw.conf.patch.gz | patch -p1 --verbose
-python ./setup.py install --root=$PKG
+python setup.py install --root=$PKG
-mv $PKG/usr/share/man $PKG/usr/man
-
-( 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 -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/init.d
+mv $PKG/usr/share/man $PKG/usr/man
-ln -s /lib/ufw/ufw-init $PKG/etc/init.d/ufw
+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 \
- AUTHORS ChangeLog* COPYING README* TODO doc/*.example \
- $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS ChangeLog* COPYING README* TODO doc/*.example $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install