aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dev/perl/perl-archive-tar/Manifest24
-rwxr-xr-xdev/perl/perl-archive-tar/perl-archive-tar.SlackBuild78
-rw-r--r--dev/perl/perl-compress-zlib/Manifest23
-rwxr-xr-xdev/perl/perl-compress-zlib/perl-compress-zlib.SlackBuild80
-rw-r--r--dev/perl/perl-io-zlib/Manifest24
-rwxr-xr-xdev/perl/perl-io-zlib/perl-io-zlib.SlackBuild74
6 files changed, 292 insertions, 11 deletions
diff --git a/dev/perl/perl-archive-tar/Manifest b/dev/perl/perl-archive-tar/Manifest
new file mode 100644
index 00000000..7abb0671
--- /dev/null
+++ b/dev/perl/perl-archive-tar/Manifest
@@ -0,0 +1,24 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST Archive-Tar-1.48.tar.gz 50094 MD5 3531682ec7625345968c6a88f2df05a5 RMD160 fb15199751b3873e930b32d6132897f7eb35983c SHA1 c41b1f187e1c27560857a9b85a1e57009b9841a9 SHA256 7fed7d8fbaf5f22120d79a984a96357335827dd05978c67fd91351e9b2617005 SHA512 923db0eb9277426219af56c43576e5f1678e5d9364c9c6714cf700a11a28c4855127dc12f46cb03e7c65cf54c29a034f048121a0f0c86301fa6ccbba06a45d7f
+MKBUILD perl-archive-tar.mkbuild 2442 MD5 a6ed00183479e611b34ed8f2fff927ea RMD160 8bfc1618bfb3f3ba663399b9bdd688fdd1233711 SHA1 fc53bb5e8ea92c42ca90d1724202c60d9c310fd5 SHA256 50a3b0b47128b7bfad3e9dc8a5f56aea3e814667cdf2298adecd95351b70fc32 SHA512 d296dd103f2d356b6856ef655cefa66ccac265c75f624192bfdce704817314d927ab99498547e7376c028da0781a9b866902ccbe8c91e892f1a9c2b3c4ecdc65
+SLACK-REQUIRED slack-required 88 MD5 0b0950a59e07f8163886f84e84949673 RMD160 e75bbcf23ed92c49eb2332396db08718085aee02 SHA1 cd110133a52015595e46be396d3882ab4aef4295 SHA256 274123c43f9746c41056d1c893f07f5fb37a34fb9237999a3670f78d949446db SHA512 3c15d56a6f570042d44151137b5e633967abdb01bc95f6ae208bcdd0998e425369482694ac5a5ed5519dc97506da9873fd90946550d1337fd399125e068517bd
+SLACKBUILD perl-archive-tar.SlackBuild 7198 MD5 2f3ccf25d1048c42e04f020fb7ee3b84 RMD160 0ef478b003b4efe4cdaad925a65031876c5af049 SHA1 5eb16bc630568cde739497ebcf832ab82a58291e SHA256 571135657f3c7553bfbcea4d484024e3212dcd97c307f3c3d12d2ebe61099aae SHA512 9187afebb0b6bc125440fb3517e1204a8c6fbb0ef25a7259552f2476463723b7f4ac5c49556d3674422e73ee6b9aa7a595d7144e80f3196b1b5d29b81276472c
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJ81vyAAoJEEHL93ESzgeiyCwQAJv49cRmNHUWCmwHEGjTE1wv
+meYpMQvtZQUTX/Eb9bIM+NAhVGbhdZHTLWw90C23KAdXSQAWpsKFk8eZEqFa3ya4
+787vfDwyhBailDNyRf2p8tCgtNEDgvguUc7ajcT8VWMJW+W13QCPLaKbnS/0KVkv
+CEufHcCEdKUgKmof641ojSGAXrOckkjMSMq//tSVdyc9iJDvHUIh+j0jwMqGmqYr
+4n5Or48hiXAr0Xfn2i6obDbwPG+9lqeaUkWrBKQMoXzKhGnEVgzWRpDiibzlXa0e
+TCZ5m/N2vtbagxmxjJLxcxc2UFO1HI6AzDazjs1Xh3fiE/1hAmxOPvifwft26c3K
+r0r0Nv0C7wBsl2fK4b1JcshAF5iDRmsJFg6dgHD2Bxc10gbHNdV5Fpawe+5cMVws
+qS4aKa/OHB5+8LhZZOFUx7+T/cmVUvn9kSMw4zy9ODWFYZR1hv2ygTc0EHtekaAm
+jpihQySFMv0MRICTDmqpSqtCwh/QH/kzsTrn4CqLsXHXXswCP9eGM7VrHo+jdXSm
+HveP+7fUbqSXHya5IAwr6+OzDotb6I0E9peg/QNEGrhTOqgezVwxQzSQtIpMDzeW
+rS/wYdegV0SFsUZCS6r5tIAQ83bN25OJ0+gafQ2JYqd+Elr6WawZ2L/MGsCW8K5Y
+hxAIbWSlxITqWSYh3UL6
+=ELlG
+-----END PGP SIGNATURE-----
diff --git a/dev/perl/perl-archive-tar/perl-archive-tar.SlackBuild b/dev/perl/perl-archive-tar/perl-archive-tar.SlackBuild
index 4a916c1f..b4a4d5ba 100755
--- a/dev/perl/perl-archive-tar/perl-archive-tar.SlackBuild
+++ b/dev/perl/perl-archive-tar/perl-archive-tar.SlackBuild
@@ -15,8 +15,9 @@
# Place - Suite 330, Boston, MA 02111-1307, USA
#
# slackbuild for perl-archive-tar, by Silvio Rhatto
-# requires: perl-io-zlib
-# tested: perl-archive-tar-1.38
+# requires:
+# tested: perl-archive-tar-1.48
+# model: perl.mkSlackBuild $Rev: 796 $
#
# Look for slackbuildrc
@@ -31,13 +32,14 @@ CWD="$(pwd)"
SRC_NAME="Archive-Tar"
PKG_NAME="perl-archive-tar"
ARCH=${ARCH:=i486}
-SRC_VERSION=${VERSION:=1.38}
+SRC_VERSION=${VERSION:=1.48}
PKG_VERSION="$(echo "$SRC_VERSION" | tr '[[:blank:]-]' '_')"
BUILD=${BUILD:=1rha}
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-archive-tar"}
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
diff --git a/dev/perl/perl-compress-zlib/Manifest b/dev/perl/perl-compress-zlib/Manifest
new file mode 100644
index 00000000..e9914869
--- /dev/null
+++ b/dev/perl/perl-compress-zlib/Manifest
@@ -0,0 +1,23 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST IO-Compress-2.017.tar.gz 204116 MD5 4b4775cfbb069f3f7c33053ac1ef301c RMD160 2024eeaf13166c47b23b72d499255e6e0e33670e SHA1 3629036707abf10c90de35134af46b816761e66b SHA256 3bc89a0ad5fba698dc8804114aedaa3c10cfb8eecaa95dcf22abb4b0fb2a888b SHA512 ce93debd695ecb316b9f252f8e863256b4cda5f12442ecb57ecf4468e51dff0d8f12910a2b3af9fb4a65cc9481bf4fb073a3c8272898148f73ed9c5bbfa3cb57
+MKBUILD perl-compress-zlib.mkbuild 2384 MD5 f69ef11ed68dd8ef67be1b6125c2c845 RMD160 64a5bdc896d1597b40f2bc3ad732b02a0e15ab6b SHA1 06e9211ba0a4a19babb73977499fd972f894690f SHA256 a775f1b4da223da7f28b249d3e1a81992f0703f2d8f975f655d870524e034a56 SHA512 ab26754de268af86c0eebf2576ab761753465262b1d6612077990c453fee71badf2d65f81fbde02dcff10e18423908694e7bb8ed720629d5f4cf236f86e123ed
+SLACKBUILD perl-compress-zlib.SlackBuild 7080 MD5 303df4d4abd15bfe9330275bfea1e532 RMD160 44da1731bfc0ed01f0db09bb1252208f60e12d97 SHA1 ba1b7693bea1192c4207989a23e52446016a56c9 SHA256 c9fb9b15ac4dcf67cfa72afca9b52c74a23188fae08e476a1b58fb7a2e6f82a8 SHA512 4ca20fbc7fc2548dc1603b70ba3f14638cff197cc71c68b7961568d90ca809d2d88143bc7d8d546dcf619bddd232907a9c577ad0d87963411f0c0751b68fcc24
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJ8152AAoJEEHL93ESzgeiD/UP/21MrEvrf55t2u7gFuP4s3fk
+cY3y7TD9AsqkGULJtApob9rG5x9P5YHK5P/9O105nVfVylK/6oscwkXZiCZcW4DQ
+k5DzGMlu8busHucbQoD01q6UzYCVgKcAO/0vyEgV7N7p+uueBmxqgjPmgFL0Helo
+MZvhHIspW5F+InMp3bKWrqtB71gXlTXUd93dT8BZYoPgQN5Pri4gxc5QMvQyhBd/
+fGhMiuJQpejAN2xuO8k4bR5wakzEab+aHzCj0xwnyPKcU0nnB1qHmoao87xe9IV6
+ira5i32JIbq4Z0Rt4jgLwu/oRgoIitcROQDtS+tC/OWdnI0K3kbg+RDWgxD4MkZ8
+u0MCdeC77xErMlYabAAS/cW427xrNxq5r3ZtVBnCvuK+VCLl3HJ5Cs57OK5Pazzd
+V8AlRCmotqP5lIiaGz7pBj/CtgE62fJin4BcRGG4ejcdto3kg5uvL4beG7CcYxDk
+IIjCEecrYmlmVjQorYr7tLqqdnTk/I/lKhKP8wCf2lXcaw4mJ9u3ohEhihWV04WO
+ulcwYRU84G7BcqwxGtOeHitCeRwMiu4Y6d4KRvzfq5Rb3R/vyJ8xluM6pQfpJvhV
+wTZbBtsNPGX/FFhf32xJuduIG/BAL24TDHeWC5CvfFlxCDdwizK0LF0tqmyA270o
+cuEMW3DqckOOBdxyrW2r
+=8Bk0
+-----END PGP SIGNATURE-----
diff --git a/dev/perl/perl-compress-zlib/perl-compress-zlib.SlackBuild b/dev/perl/perl-compress-zlib/perl-compress-zlib.SlackBuild
index 3ea80e0f..e545cc51 100755
--- a/dev/perl/perl-compress-zlib/perl-compress-zlib.SlackBuild
+++ b/dev/perl/perl-compress-zlib/perl-compress-zlib.SlackBuild
@@ -16,7 +16,8 @@
#
# slackbuild for perl-compress-zlib, by Silvio Rhatto
# requires:
-# tested: perl-compress-zlib-2.009
+# tested: perl-compress-zlib-2.017
+# model: perl.mkSlackBuild $Rev: 796 $
#
# Look for slackbuildrc
@@ -28,16 +29,17 @@ fi
# Set variables
CWD="$(pwd)"
-SRC_NAME="Compress-Zlib"
+SRC_NAME="IO-Compress"
PKG_NAME="perl-compress-zlib"
ARCH=${ARCH:=i486}
-SRC_VERSION=${VERSION:=2.009}
+SRC_VERSION=${VERSION:=2.017}
PKG_VERSION="$(echo "$SRC_VERSION" | tr '[[:blank:]-]' '_')"
BUILD=${BUILD:=1rha}
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-compress-zlib"}
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
@@ -148,9 +217,10 @@ EODESC
# 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" ]; then
+if [ "$CLEANUP" == "yes" ] || [ "$1" = "--cleanup" ]; then
rm -rf "$PKG_WORK" "$PKG"
fi
diff --git a/dev/perl/perl-io-zlib/Manifest b/dev/perl/perl-io-zlib/Manifest
new file mode 100644
index 00000000..ba9233ad
--- /dev/null
+++ b/dev/perl/perl-io-zlib/Manifest
@@ -0,0 +1,24 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST IO-Zlib-1.09.tar.gz 10092 MD5 7e0244de33de418745584adcaad4869e RMD160 97047909f79c3e55bb99299ab96a6be6867e787b SHA1 d7e5d740ed1de260019f2e6b8f1dc11726aaab18 SHA256 5ada9a6c81cbc51b1cc2061911569509834635ff3f396f22f6cdcbbb868222f3 SHA512 94a62cb8fef283a29870bd3c86b2192f864b8e6a260b4e7e6499d6052cdc496d318f4752dfd846335a686422dc762a29efadd496658e9821f5c2601310462490
+MKBUILD perl-io-zlib.mkbuild 2387 MD5 ff624527aa2baa4763cdbcf213bd8842 RMD160 e91d777c213f060f39797fea84ef15865208f738 SHA1 73da7bdf0462967e0eb060ff359a5365c8933aa8 SHA256 c53e129eb041acf7def91aa68b8b0aa4ec6df1f5044bf78e99532367cc9a33ae SHA512 c3bfe492fee1bfef8cba2de2e975d622504d33ea6fa4912c7523f8697b65dac45acc69c3a6f80e6c0db032aa2aa163f20fccf5a1f7032f1102d6daa7ed51e6c0
+SLACK-REQUIRED slack-required 90 MD5 60c9eaa3a591920e50c5e7e303037dae RMD160 a3f954a40dac4cd6d3fac428eed839d3048cc7cf SHA1 86f710184447c5e70ac1b944bf73fbeb4ce759c8 SHA256 49b9023c40dda07f327e1341d80227b61330cdcbf8ca6c9013ba7ab11718f253 SHA512 1d9f0d57f2c40a3131b4ae7df7247879c429e3eeba69ba2098990181e17f98670e9974f2b17866d66de67f5366804efd3a6b97d9c5fff45223b07c5773a2084b
+SLACKBUILD perl-io-zlib.SlackBuild 7118 MD5 e4b0cf377981d4c864c7a14e5c0b09b3 RMD160 e255ef8da6601b277a3812c25ae4fbb0948bb30f SHA1 d098b74b33e30c0a9cc15ad7aa267de62138cc25 SHA256 756e6e9d63acb4494bf6cb111abf01e812c17409fa34b8a918ec813806269111 SHA512 b5e2afd7c170f264e94b40164bc38d7c6f7520b86b59f90773394ec0532c565b130dddc42379489454390d8d393117cb39caa9b065565f1c3781d2f82abf4339
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJ817iAAoJEEHL93ESzgeiSSwP/3QfGeAZjLSjhh7oU+xsVbBW
+5leFEUTYUlo9eLN+PnxkH8tpFMRiPHaoCjfRMr6qzmw1CqTJpwixDIp6HdO9ldp8
+aJhnjxdzMuSISzwafGCwoPBq25vAmOqQ2gjuC3UBC4Vx0KVQuYLTdCx89+kPrjuH
+jm05A4KbP6WPyiNMJG8ngFzEkI2KoYDf0MvrnpLnWw0UtFBxAQFJC64mDbnt5qJZ
+W5L3o/2Tn/D/VvxLhpTpKG9dDcmSojZ87jcXyssNpl3qHC2LF+jwrJxdlDDc9t2L
+T77VWjdRN2wcoLcWaDGIwD2/tKTOtfvmsAERPcZgvsF8kqyUDFproRWnLa1vJ0aa
+fhnK1z8/ZwjQwz78GtLEfT/mIuBFJnfKoZ5zu838ASj9TL5JwGAWYLodGYvEGto2
+1rtT1xWIhFa437mUU7igudPd4I2Pk1veZdBl6P1HguS/x/uWSK5QlRo+2KDXr0XT
+YUxzju9/M0odOOpZscLVejFBUR90VIEVtGxng1NwrscUF95fUDwupEEEOVJA5QBc
+Ggddk4n1Rj6P3RGc4Jj+QsBJFalfCFZMvopBRtrw/y+2tmaZu2rN8wbQ/77e1usl
+Mh93k+luMzS0t6niGGhY2rGPNIVhfJXuv8Rcsl6AjDScq/DGwLVvruZ1mvBQFNHm
+DP7rgtMDdiKOOwYMMnlQ
+=90Ln
+-----END PGP SIGNATURE-----
diff --git a/dev/perl/perl-io-zlib/perl-io-zlib.SlackBuild b/dev/perl/perl-io-zlib/perl-io-zlib.SlackBuild
index 84356f61..757afdc4 100755
--- a/dev/perl/perl-io-zlib/perl-io-zlib.SlackBuild
+++ b/dev/perl/perl-io-zlib/perl-io-zlib.SlackBuild
@@ -15,8 +15,9 @@
# Place - Suite 330, Boston, MA 02111-1307, USA
#
# slackbuild for perl-io-zlib, by Silvio Rhatto
-# requires: perl-compress-zlib
+# requires:
# tested: perl-io-zlib-1.09
+# 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-io-zlib"}
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