libraries/libnet: Updated for version 1.1.2.1

This commit is contained in:
Joe Rozner 2010-05-11 22:24:05 +02:00 committed by Robby Workman
parent f967fea660
commit 88fb200b26
2 changed files with 22 additions and 20 deletions

View file

@ -1,15 +1,18 @@
#!/bin/sh
set -e
# Slackbuild for lidnet
# Slackbuild for libnet
# Joe Rozner livinded@deabytes.net
# Wednesday 08/22/2007
# Modified by Roberto Neri <rneri@libero.it> to
# - remove CVS directories from source tree and miscellaneous script cleanup
PRGNAM=libnet
VERSION=1.1.2.1
VERSION=${VERSION:-1.1.2.1}
ARCH=${ARCH:-i486}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
@ -19,45 +22,44 @@ if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
fi
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM
tar xvf $CWD/$PRGNAM.tar.gz
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM
chown -R root:root .
chmod -R u+w,go+r,a-s .
find . -type d -name CVS | sort -r | xargs rm -rf
CFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var
--localstatedir=/var \
--build=$ARCH-slackware-linux
make
make install DESTDIR=$PKG
make install-strip 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
)
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a README VERSION doc/* $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
rm -rf $PKG/usr/doc/$PRGNAM-$VERSION/CVS
mv $PKG/usr/doc/$PRGNAM-$VERSION/man/ $PKG/usr/
rm -rf $PKG/usr/man/CVS # WTH is this?
cp -a doc/man $PKG/usr/
( 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
)
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a README VERSION doc/html $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
/sbin/makepkg -l y -c n $TMP/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz

View file

@ -1,7 +1,7 @@
PRGNAM="libnet"
VERSION="1.1.2.1"
HOMEPAGE="http://www.packetfactory.net/projects/libnet/"
DOWNLOAD="http://www.packetfactory.net/libnet/dist/libnet.tar.gz"
DOWNLOAD="http://www.packetfactory.net/libnet/dist/libnet-1.1.2.1.tar.gz"
MD5SUM="be845c41170d72c7db524f3411b50256"
MAINTAINER="Joe Rozner"
EMAIL="livinded@deadbytes.net"