summaryrefslogtreecommitdiff
path: root/network
diff options
context:
space:
mode:
Diffstat (limited to 'network')
-rw-r--r--network/ebtables/doinst.sh15
-rw-r--r--network/ebtables/ebtables.SlackBuild5
2 files changed, 19 insertions, 1 deletions
diff --git a/network/ebtables/doinst.sh b/network/ebtables/doinst.sh
new file mode 100644
index 0000000000..092a869b6b
--- /dev/null
+++ b/network/ebtables/doinst.sh
@@ -0,0 +1,15 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+config etc/ethertypes.new
+
diff --git a/network/ebtables/ebtables.SlackBuild b/network/ebtables/ebtables.SlackBuild
index 39fa5ede9f..758a3521a5 100644
--- a/network/ebtables/ebtables.SlackBuild
+++ b/network/ebtables/ebtables.SlackBuild
@@ -24,7 +24,7 @@
PRGNAM=ebtables
VERSION=${VERSION:-2.0.10}
-BUILD=${BUILD:-2}
+BUILD=${BUILD:-3}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -91,6 +91,8 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr
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
+mv $PKG/etc/ethertypes $PKG/etc/ethertypes.new
+
# Remove Red Hat junk
rm -rf $PKG/etc/rc.d $PKG/etc/sysconfig
@@ -100,6 +102,7 @@ cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}