summaryrefslogtreecommitdiffstats
path: root/network/ufw
diff options
context:
space:
mode:
Diffstat (limited to 'network/ufw')
-rw-r--r--network/ufw/README16
-rw-r--r--network/ufw/ufw.SlackBuild57
-rw-r--r--network/ufw/ufw.conf.patch5
-rw-r--r--network/ufw/ufw.info10
4 files changed, 46 insertions, 42 deletions
diff --git a/network/ufw/README b/network/ufw/README
index 4bd36b3621..54d8cd35bf 100644
--- a/network/ufw/README
+++ b/network/ufw/README
@@ -1,17 +1,17 @@
-Ufw (Uncomplicated Firewall) is program for managing a netfilter firewall.
-It provides a command line interface and aims to be uncomplicated and easy
-to use.
+Ufw (Uncomplicated Firewall) is program for managing a netfilter
+firewall. It provides a command line interface and aims to be
+uncomplicated and easy to use.
-Add the following code to /etc/rc.local to start Ufw at boot time:
+Add the following code to /etc/rc.d/rc.local to start Ufw at boot time:
if [ -x /lib/ufw/ufw-init ]; then
/lib/ufw/ufw-init start
fi
-Ufw comes with a number of common application profiles. Create additional
-application profiles under /etc/ufw/applications.d. Each profile should
-contain a list of rules which include a title, description, and port(s) or
-port range.
+Ufw comes with a number of common application profiles. Create
+additional application profiles under /etc/ufw/applications.d.
+Each profile should contain a list of rules which include a title,
+description, and port(s) or port range.
A custom application profile should look similar to this:
diff --git a/network/ufw/ufw.SlackBuild b/network/ufw/ufw.SlackBuild
index 5fd512f1d9..f3b65a2a13 100644
--- a/network/ufw/ufw.SlackBuild
+++ b/network/ufw/ufw.SlackBuild
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for ufw
@@ -6,6 +6,7 @@
# Copyright 2013 Ricardson Williams <ricardsonwilliams@gmail.com>
# Copyright 2014-2015 Rodolfo Gouveia <rgouveia@cosmico.net>
# Copyright 2016 Brenton Earl <brent@exitstatusone.com>
+# Copyright 2023 Jay Lanagan <j@lngn.net>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -25,10 +26,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=ufw
-VERSION=${VERSION:-0.36}
+VERSION=${VERSION:-0.36.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -38,25 +42,15 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-if [ "$ARCH" = "i586" ]; then
- SLKCFLAGS="-O2 -march=i586 -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
@@ -73,22 +67,31 @@ find -L . \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
patch -p1 --verbose < $CWD/ufw.conf.patch
-patch -p1 --verbose < $CWD/ufw-0.35-fix-iptables-path.patch
-# Python3 support
-if $(python3 -c 'import sys' 2>/dev/null); then
- python3 setup.py install --root=$PKG
-fi
-
-python setup.py install --root=$PKG
+python3 setup.py install --root=$PKG
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
mv $PKG/usr/share/man $PKG/usr/man
-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
+# Compress and link manpages, if any:
+if [ -d $PKG/usr/man ]; then
+ ( cd $PKG/usr/man
+ for manpagedir in $(find . -type d -name "man*") ; do
+ ( cd $manpagedir
+ for eachpage in $( find . -type l -maxdepth 1) ; do
+ ln -s $( readlink $eachpage ).gz $eachpage.gz
+ rm $eachpage
+ done
+ gzip -9 *.*
+ )
+ done
+ )
+fi
+
+mkdir -p $PKG/etc/rc.d
+cat $TMP/$PRGNAM-$VERSION/doc/initscript.example > $PKG/etc/rc.d/rc.ufw
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a AUTHORS ChangeLog* COPYING README* TODO doc/*.example $PKG/usr/doc/$PRGNAM-$VERSION
@@ -99,4 +102,4 @@ 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}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/network/ufw/ufw.conf.patch b/network/ufw/ufw.conf.patch
index 0b085ae82b..eda9b184e1 100644
--- a/network/ufw/ufw.conf.patch
+++ b/network/ufw/ufw.conf.patch
@@ -1,5 +1,5 @@
---- ufw-0.33.orig/conf/ufw.conf 2012-08-18 05:12:49.000000000 +0800
-+++ ufw-0.33/conf/ufw.conf 2013-07-16 04:18:44.365425697 +0800
+--- a/conf/ufw.conf
++++ b/conf/ufw.conf
@@ -3,7 +3,7 @@
# Set to yes to start on boot. If setting this remotely, be sure to add a rule
@@ -9,3 +9,4 @@
# Please use the 'ufw' command to set the loglevel. Eg: 'ufw logging medium'.
# See 'man ufw' for details.
+
diff --git a/network/ufw/ufw.info b/network/ufw/ufw.info
index 1d396dca15..b2d57c2680 100644
--- a/network/ufw/ufw.info
+++ b/network/ufw/ufw.info
@@ -1,10 +1,10 @@
PRGNAM="ufw"
-VERSION="0.36"
+VERSION="0.36.2"
HOMEPAGE="https://launchpad.net/ufw"
-DOWNLOAD="https://launchpad.net/ufw/0.36/0.36/+download/ufw-0.36.tar.gz"
-MD5SUM="6d8ab1506da21ae003f4628f93d05781"
+DOWNLOAD="https://launchpad.net/ufw/0.36/0.36.2/+download/ufw-0.36.2.tar.gz"
+MD5SUM="4a1c52b7da2b25e66e91b5f16a7d032d"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""
-MAINTAINER="Brenton Earl"
-EMAIL="brent@exitstatusone.com"
+MAINTAINER="Jay Lanagan"
+EMAIL="j@lngn.net"