aboutsummaryrefslogtreecommitdiff
path: root/dev/perl/perl-net-ip
diff options
context:
space:
mode:
authorrhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4>2009-09-16 02:23:49 +0000
committerrhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4>2009-09-16 02:23:49 +0000
commit8feb8716fd9ad21b5507407986073235446bb003 (patch)
treec81a310eb5fb1ad29f38ffb8c6abc1e88d1b54c8 /dev/perl/perl-net-ip
parent36d20148a5e3fdf56178c4e9c603d5c574c5cd40 (diff)
downloadslackbuilds-8feb8716fd9ad21b5507407986073235446bb003.tar.gz
slackbuilds-8feb8716fd9ad21b5507407986073235446bb003.tar.bz2
amavisd-new: adding amavisd-new (thanks to x-doctor) and updating dependencies
git-svn-id: svn+slack://slack.fluxo.info/var/svn/slackbuilds@2241 370017ae-e619-0410-ac65-c121f96126d4
Diffstat (limited to 'dev/perl/perl-net-ip')
-rw-r--r--dev/perl/perl-net-ip/Manifest24
-rwxr-xr-xdev/perl/perl-net-ip/perl-net-ip.SlackBuild74
2 files changed, 96 insertions, 2 deletions
diff --git a/dev/perl/perl-net-ip/Manifest b/dev/perl/perl-net-ip/Manifest
new file mode 100644
index 00000000..fca38a7c
--- /dev/null
+++ b/dev/perl/perl-net-ip/Manifest
@@ -0,0 +1,24 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA256
+
+DIST Net-IP-1.25.tar.gz 25749 MD5 a49c0b02a9b793ff60191cdafc0c202e RMD160 92116a215d255d1a16b819df23c98bb0324df2f6 SHA1 058a0ce86a50e882e9254371157c0c602b88f691 SHA256 4cd6e2202fd88c46d5458d19bbea80e257b6ba0ec57ea3ac8ae94ed48c9a60c7 SHA512 1f79224946f6e132ee03b3417176f595de3cc49a30e6cef173a5c9d350a71c25b7b1e68c79f2889541672e03f06f1e3bc4a56e805585ba354158230eded517e7
+MKBUILD perl-net-ip.mkbuild 2378 MD5 f665ffaf5dac18ca5c329f3566686ae6 RMD160 8e3fafe302e1e5ec2726864ab1b2c1ad7e923e3c SHA1 a718d7cddb5a68dc6e85ec9f8a0bf3714239d6aa SHA256 c3afbca3c05e85f7254a42c731c53b7c814b27bdc43f66814a9885faef12a139 SHA512 94b06a4df3eb1c3db65b95129ca0b8a80830a365f80463e50a4725683fc98c1cc08d853c0293c28e608de9f62e5e55bdd18a8f79f855fcc819b2f70ec90e13ad
+SLACK-REQUIRED slack-required 87 MD5 fbd33c868ab11a9866b2309a3e203897 RMD160 0fef091bc4c3f44ff8b6eee7f7f2e748c53e586f SHA1 8c94250816358a0dd844bcdf8daa70ab855d142c SHA256 a881f5989d358808d1a4549138b29462bca7e2b28f30f40abe721598a914ba6a SHA512 a501542908287d814ec0d8057c7378f3b32644d1c845d4ca92a7e89ba6e41f12cb61ddda2ba8cb009b04b67e43eabb4efa0e13f231ec52eefed1cbd241a64d23
+SLACKBUILD perl-net-ip.SlackBuild 7107 MD5 de8d00ab6b8f9704398252b7adf06833 RMD160 d2b2d5b973451ba88e727b2bd77b17ce3591f5b4 SHA1 80520cd04fc854a50de718be0db2af739ee7608e SHA256 fb1d2f95f03372671632f6fca406156f9756d7e5aa5a11812111c280392ecf8c SHA512 d104602d1a9d567e97f942e3c0568c68e7fd6c937760e20c1c0a9d25b9e17b2ff67c89a40b3caf8b8305e2848316fda259168b50da7cb6239f982639ff215648
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBCAAGBQJKsEnuAAoJEEHL93ESzgeiHyIP/12qyM4ScZR5xC5JpNBVTPvF
+ZidaMzAkCiM2OfLO8mr2IqaReGtGZWZ/u7mlE49+9oSEg+2MnPfDQoA2S4u5WpTG
++R7Q8MwBuwHQw1zRmEZj3X+XUMV/l0aaa7V9/EhlFlQ8CfKMm1wJleGJB02nSyDd
+SA9y2gy72Fue7PeXUq7NjOPNZ8A07lA0cAaBN66SVX1fQVxw7RRjNzXJmjMlbkMo
+D7np9l2ToQjXyuStIHO9Ec6q/+FNs252wzfbMMXTDtTP8JMM+1RXu69+su5MKh8+
++AhlFuZ3jX47On9ZKEfnGLj/yfA0nzR7bSoABpVTPHmT9yGnT1VnQbF43uUYU/IK
+K6jK0dwOsrGAm09opWV7ugYbN5tDN8HfYFoETE79OxZZdkejXMC2DIeb+Nqc21A2
+jlacOE77ZV4fc7X5RXx2iXBAW0shigNlrUbT2uuFUfqzRhYvFpABmE7vHNSEMceb
+HEDMhVofxlKcJKWvr3aUo9f7c2W1M5ma2XnvtKIbWKntKI07zYJxVanPR0iqKUpd
+ATAKevD/OUSKHiTKN1Kd4IS2P70t5jMX6ivIFF8kXwrpjoaRqukL+pDOc0EcbDkq
+ol3CKL6b9jqQPYspXN6V8GH/nJaA5eJjXqKfZkg1Lo7mR9oDy6DETTwK5QHtmKrP
+zKoNwv9Ewr4d05tQVO4Z
+=t9mr
+-----END PGP SIGNATURE-----
diff --git a/dev/perl/perl-net-ip/perl-net-ip.SlackBuild b/dev/perl/perl-net-ip/perl-net-ip.SlackBuild
index 9b36590e..2d2ee981 100755
--- a/dev/perl/perl-net-ip/perl-net-ip.SlackBuild
+++ b/dev/perl/perl-net-ip/perl-net-ip.SlackBuild
@@ -15,8 +15,9 @@
# Place - Suite 330, Boston, MA 02111-1307, USA
#
# slackbuild for perl-net-ip, by Silvio Rhatto
-# requires: perl-math-bigint
+# requires:
# tested: perl-net-ip-1.25
+# model: perl.mkSlackBuild $Rev: 796 $
#
# Look for slackbuildrc
@@ -38,6 +39,7 @@ SRC_DIR=${SRC_DIR:=$CWD}/$PKG_NAME
TMP=${TMP:=/tmp}
PKG=${PKG:=$TMP/package-$PKG_NAME}
REPOS=${REPOS:=$TMP}
+SLACKBUILD_PATH=${SLACKBUILD_PATH:="dev/perl/perl-net-ip"}
PREFIX=${PREFIX:=/usr}
PKG_WORK="$TMP/$SRC_NAME"
CONF_OPTIONS=${CONF_OPTIONS:=""}
@@ -64,6 +66,7 @@ ERROR_WGET=31; ERROR_MAKE=32; ERROR_INSTALL=33
ERROR_MD5=34; ERROR_CONF=35; ERROR_HELP=36
ERROR_TAR=37; ERROR_MKPKG=38; ERROR_GPG=39
ERROR_PATCH=40; ERROR_VCS=41; ERROR_MKDIR=42
+ERROR_MANIFEST=43;
# Clean up any leftovers of previous builds
rm -rf "$PKG_SRC" 2> /dev/null
@@ -83,6 +86,72 @@ if [ ! -s "$SRC_DIR/$SRC" ] || ! gunzip -t "$SRC_DIR/$SRC" 2> /dev/null; then
wget "$URL" -O "$SRC_DIR/$SRC" || exit $ERROR_WGET
fi
+# Check Manifest file
+if [ -e "$CWD/Manifest" ]; then
+
+ # Manifest signature checking
+ if grep -q -- "-----BEGIN PGP SIGNED MESSAGE-----" $CWD/Manifest; then
+ echo "Checking Manifest signature..."
+ gpg --verify $CWD/Manifest
+ if [ "$?" != "0" ]; then
+ exit $ERROR_MANIFEST
+ fi
+ fi
+
+ MANIFEST_LINES="`grep -E -v "^(MKBUILD|SLACKBUILD)" $CWD/Manifest | wc -l`"
+
+ for ((MANIFEST_COUNT=1; MANIFEST_COUNT <= $MANIFEST_LINES; MANIFEST_COUNT++)); do
+
+ MANIFEST_LINE="`grep -E -v "^(MKBUILD|SLACKBUILD)" $CWD/Manifest | head -n $MANIFEST_COUNT | tail -n 1`"
+ MANIFEST_FILE="`echo $MANIFEST_LINE | awk '{ print $2 }'`"
+ MANIFEST_FILE_TYPE="`echo $MANIFEST_LINE | awk '{ print $1 }'`"
+
+ if [ -e "$SRC_DIR/$MANIFEST_FILE" ]; then
+ MANIFEST_FILE="$SRC_DIR/$MANIFEST_FILE"
+ else
+ MANIFEST_FILE="`find $CWD -name $MANIFEST_FILE`"
+ fi
+
+ if [ ! -e "$MANIFEST_FILE" ] || [ -d "$MANIFEST_FILE" ]; then
+ continue
+ fi
+
+ echo "Checking Manifest for $MANIFEST_FILE_TYPE $MANIFEST_FILE integrity..."
+
+ SIZE_SRC="`wc -c $MANIFEST_FILE | awk '{ print $1 }'`"
+ SIZE_MANIFEST="`echo $MANIFEST_LINE | awk '{ print $3 }'`"
+
+ # Check source code size
+ if [ "$SIZE_SRC" != "$SIZE_MANIFEST" ]; then
+ echo "SIZE Manifest: $SIZE_MANIFEST; SIZE $SRC: $SIZE_SRC"
+ exit $ERROR_MANIFEST
+ else
+ echo "Size match."
+ fi
+
+ # Check source code integrity
+ for ALGO in md5 sha1 sha256 sha512 rmd160; do
+ if [ $ALGO = "rmd160" ]; then
+ ALGO_SRC="`openssl rmd160 $MANIFEST_FILE | awk '{ print $2 }'`"
+ else
+ ALGO_SRC="`"$ALGO"sum $MANIFEST_FILE | awk '{ print $1 }'`"
+ fi
+ ALGO="`echo $ALGO | tr '[:lower:]' '[:upper:]'`"
+ ALGO_MANIFEST=$(echo $MANIFEST_LINE | sed "s/.* $ALGO //" | awk '{ print $1 }')
+ if [ "$ALGO_SRC" != "$ALGO_MANIFEST" ]; then
+ echo "$ALGO Manifest: $ALGO_MANIFEST; $ALGO $SRC: $ALGO_SRC"
+ exit $ERROR_MANIFEST
+ else
+ echo "$ALGO match."
+ fi
+ done
+
+ done
+
+else
+ exit $ERROR_MANIFEST
+fi
+
# Untar
cd "$PKG_WORK"
tar --no-same-owner --no-same-permissions -xvf "$SRC_DIR/$SRC" || exit $ERROR_TAR
@@ -154,7 +223,8 @@ fi
# Build the package
cd "$PKG"
-makepkg -l y -c n "$REPOS/$PKG_NAME-$PKG_VERSION-$ARCH-$BUILD.tgz" || exit $ERROR_MKPKG
+mkdir -p $REPOS/$SLACKBUILD_PATH
+makepkg -l y -c n "$REPOS/$SLACKBUILD_PATH/$PKG_NAME-$PKG_VERSION-$ARCH-$BUILD.tgz" || exit $ERROR_MKPKG
# Delete source and build directories if requested
if [ "$CLEANUP" == "yes" ] || [ "$1" = "--cleanup" ]; then