#!/bin/sh TMP=/tmp CWD=`pwd` PKG=$TMP/package-iptables VERSION=1.3.5 ARCH=${ARCH:-x86_64} BUILD=1 rm -rf $PKG mkdir -p $PKG cd $TMP rm -rf iptables-$VERSION tar xjvf $CWD/iptables-$VERSION.tar.bz2 cd iptables-$VERSION chown -R root:root . zcat $CWD/iptables.prefix.diff.gz | patch -p1 || exit make make install DESTDIR=$PKG make install-devel DESTDIR=$PKG make experimental make install-experimental DESTDIR=$PKG ( cd $PKG find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null ) gzip -9 $PKG/usr/man/man?/* mkdir -p $PKG/usr/doc/iptables-$VERSION cp -a COPYING INSTALL KNOWN_BUGS $PKG/usr/doc/iptables-$VERSION chmod 644 $PKG/usr/doc/iptables-$VERSION/* mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cd $PKG makepkg -l y -c n $TMP/iptables-$VERSION-$ARCH-$BUILD.tgz