aboutsummaryrefslogtreecommitdiff
path: root/dev/libs
diff options
context:
space:
mode:
Diffstat (limited to 'dev/libs')
-rw-r--r--dev/libs/libdaemon/Manifest24
-rw-r--r--dev/libs/libdaemon/libdaemon.SlackBuild84
-rw-r--r--dev/libs/libtasn1/Manifest23
-rw-r--r--dev/libs/libtasn1/libtasn1.SlackBuild78
-rw-r--r--dev/libs/ptlib/Manifest24
-rw-r--r--dev/libs/ptlib/ptlib.SlackBuild223
-rw-r--r--dev/libs/pwlib/Manifest23
-rwxr-xr-xdev/libs/pwlib/pwlib.SlackBuild101
8 files changed, 554 insertions, 26 deletions
diff --git a/dev/libs/libdaemon/Manifest b/dev/libs/libdaemon/Manifest
new file mode 100644
index 00000000..bd35e7d6
--- /dev/null
+++ b/dev/libs/libdaemon/Manifest
@@ -0,0 +1,24 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST libdaemon-0.13.tar.gz 368119 MD5 ae9113fcd825d5a7f07e5ddccb3c3102 RMD160 7fc41dc7a147d969b29e5a359442716859de7e0e SHA1 2c67eedf0dfe303a86bee64feba3e40d21abbd01 SHA256 bd949d459d2da54f1cdfbd1f4592e32541e8a195aca56fa7a8329ed79836d709 SHA512 eca6f99c87f33a48c097a9d3f1aac80b16951b3460fc6258cd26044bbd1c87973397eda27ef70c77ce3b48ccfaaf459cf1e770f782d7cdbd31e5fa206b502bea
+MKBUILD libdaemon.mkbuild 4180 MD5 9dba3d21e90203dae6b8db8177239abb RMD160 ce91e1bf2a1d75f37b7586d3fbc6298bd6e67f0e SHA1 249da12ca2949db6dfab4e01085b5099ceadf7f1 SHA256 2def35f64d02f48099d5ff5eb1f557e510d5d137962c6cc8e46d1c8388a53a2f SHA512 5c75e83130e9bd89f7dd0fd5c94e5f89c85bfefdf146af0cab85b0ff21935d09a3f5c7cdf5e02dcd32a0d6c4834dad284865c293beb2664f3a07b7c74ebc40c2
+SLACK-REQUIRED slack-required 86 MD5 5a1df0e2493926f9757c291ce4192864 RMD160 5e54359f4d875cd5e9d9891c8118d9abfe0b012e SHA1 b090fe004db80dd3ef9c42050f1e12a1a0509f06 SHA256 e3a1906ec64055f4b48eb68d4f09a4d451a58febfe7a1720ac3f6d46a561efda SHA512 487f4ae74b1f18410478eeb9d7ed80a549ee5bfb459c7585bf0356d446f6aa00a29424f9c55134a5bfe81bc4495b8cec07c0e3d432de024ba49f965f59e9e35e
+SLACKBUILD libdaemon.SlackBuild 7427 MD5 178d7ea9f75f319e1805a07e862d8fce RMD160 fd7fab26686ce0ca43cc9c1a214fe64c39344245 SHA1 7af4ecf62d32a1b097097d8e058cd291d1cd8a07 SHA256 fed70a851c94515126752231ca04787c52bec206c3c7c665eef23edd56d8565d SHA512 fe17f71d077f2c6f2d7f8435570b09eadf4171f27d79125879937955dbe5d677257a24c04c33d9ca3d6ddfb658f31417e566bdf9f0b44492de068826c8464475
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJyappAAoJEEHL93ESzgeiuY0P/0H7G0mkh+fvbQbJIR+7+5T8
+eWUcwYJjy6vJbuC+uUQTMZWeP3PsG1RR1XqI6zULboYgAiFUcb077fXErTROuCdl
+pmDxQFXjp8i2SVNypospx+L6fzYjFzePg2fnh0zF5ZzQ4knFApnpxcLM6uBPs4GW
+GOfx1yGzEsAZY2Hvsv+PmGqFzbYzCsq61v4VgpkCwuZz7+aOaJUcTenuZx0U4MXt
+OUEl87lKypGDDElscyOVZvkdx38mR67/a/F8VwJmCyfB6w4/b/GVJyf89mkeq8wY
+MVGI3wg6nAEQJL3IL2iwQDKvhsAl0ocasa/yjOZsVn1RdwTi0ZPwpaX6XmqMd2ni
+Pp2VveqBMIkh8ns2eqWgzPpWEgbfVV4RSOBGiQZ+pqCweirUHPDAExFV6C1GCSzJ
+++ajI3tjZC1ISk8loBiqkBuKLBBPeuWT/eoxnmHyXzzEVR2fbduqwHHtF9/TAYFj
+0uOTAg2Jp0D4QtjFygN4AmgLVk/Rae2AgrrhO/neKNq0YsCTrF69LEQXn3OvS2kX
+00JSVUfPmtW+jeD/crsAsU/D4G1Ul38yUV1/bD2/tsefoSwi+Jgu6N5cXVHVnC68
+1n8bEb6GKJVNlra6t8nS7s9uTS+xNxsdFktlIRT35A13R6II4oW9j+SFtxC0PE36
+EpVWju3urArF95Xxurui
+=FXkd
+-----END PGP SIGNATURE-----
diff --git a/dev/libs/libdaemon/libdaemon.SlackBuild b/dev/libs/libdaemon/libdaemon.SlackBuild
index c3825f3a..6244a144 100644
--- a/dev/libs/libdaemon/libdaemon.SlackBuild
+++ b/dev/libs/libdaemon/libdaemon.SlackBuild
@@ -15,8 +15,9 @@
# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
#
# slackbuild for libdaemon, by Rudson R. Alves
-# requires: glibc-solibs
-# tested: libdaemon-0.12
+# requires:
+# tested: libdaemon-0.13
+# model: generic.mkSlackBuild $Rev: 796 $
#
# Look for slackbuildrc
@@ -31,13 +32,14 @@ CWD="$(pwd)"
SRC_NAME="libdaemon"
PKG_NAME="libdaemon"
ARCH=${ARCH:=i486}
-SRC_VERSION=${VERSION:=0.12}
+SRC_VERSION=${VERSION:=0.13}
PKG_VERSION="$(echo "$SRC_VERSION" | tr '[[:blank:]-]' '_')"
BUILD=${BUILD:=1rra}
SRC_DIR=${SRC_DIR:=$CWD}/$PKG_NAME
TMP=${TMP:=/tmp}
PKG=${PKG:=$TMP/package-$PKG_NAME}
REPOS=${REPOS:=$TMP}
+SLACKBUILD_PATH=${SLACKBUILD_PATH:="dev/libs/libdaemon"}
PREFIX=${PREFIX:=/usr}
PKG_WORK="$TMP/$SRC_NAME"
CONF_OPTIONS=${CONF_OPTIONS:="--disable-static --program-prefix= --program-suffix= --build=$ARCH-slackware-linux"}
@@ -47,9 +49,9 @@ NUMJOBS=${NUMJOBS:="-j4"}
LIBDIR="$PREFIX/lib"
if [ "$ARCH" = "i386" ]; then
- SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
+ SLKCFLAGS="-O2 -march=i386 -mtune=i686"
elif [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mcpu=i686"
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686"
elif [ "$ARCH" = "s390" ]; then
@@ -65,6 +67,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_WORK" 2> /dev/null
@@ -78,12 +81,78 @@ mkdir -p "$PKG_WORK" || exit $ERROR_MKDIR
# Dowload source if necessary
SRC="$SRC_NAME-$VERSION.tar.gz"
-URL="http://freshmeat.net/redir/libdaemon/41781/url_tgz/$SRC"
+URL="http://0pointer.de/lennart/projects/libdaemon/$SRC"
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 rmd160 sha1 sha256 sha512; 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
@@ -151,7 +220,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/libs/libtasn1/Manifest b/dev/libs/libtasn1/Manifest
new file mode 100644
index 00000000..d93a77cc
--- /dev/null
+++ b/dev/libs/libtasn1/Manifest
@@ -0,0 +1,23 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST libtasn1-1.4.tar.gz 1552101 MD5 a733ecdfed3517910e627d24e050979f RMD160 8553984f8992151b1086f6b3d7196a3916e61edd SHA1 684c9dc343b0155a074c2127ac8050f983528bc8 SHA256 84aa37835fe4f967d3b7cb6037d101db5d507b637af0050d6f92913128236196 SHA512 37d9ff9726ecc20ff07a2acded3a2e934f8f0eea5827745f2b61b99c5865df5392f24574fd08d098538257f2891eb811c6b1b86c2f1874ddbafc314ff540e4d7
+MKBUILD libtasn1.mkbuild 4203 MD5 4e0a847152bd1a11edf69c315c37dc30 RMD160 18396722462afc26a9bfa2c29b2388569820e6ec SHA1 4e6c261c48f3e53769c831233340a0a2ac1ed0cb SHA256 7c70d303de353b5023f89a20d5468137e27656efdf9bc9e82756061487993c20 SHA512 b594a9a5428ef20182b042915f6a34c265104af61669b053d4f2720f202a9a37ba9c37e7681ed8b369428990e7c0a09a902ff0297a69907aefd1fb89d687d918
+SLACKBUILD libtasn1.SlackBuild 6902 MD5 e3e64c83dea129a8854f0d38bebe5380 RMD160 535ff602e90fe6b23cbd26d7613f114c0e7db3d8 SHA1 b2f528e260e5cffd823d34d8f73daf6d6827ad20 SHA256 f12fbac5c35fbf2a8c8e26d0439cfe06574122fbd3d3954a0e5e03f2acc48ebf SHA512 5de6ab48852096ee4025021d010ce759b74837da181eccf64819870be6a0feace1cc544cb90a12b6962116224aa03ac9eb539b862af320f0665313e4a08eb03e
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJyZHZAAoJEEHL93ESzgei93kP/iYxT5oricVdB7Luvgxiqbqf
+kI4z7iq+DZ2NzI6grMGd/5XEFz4iLdDU1W1I0ZSC6DNekrIGNtQESEXJEvuOIFxZ
+ecxr/t7OIhR4OoluLoqxUbZ/bB+BqcyTj/n+eTmP3QHFtvJTH+CkDLzVzu5d6KrD
+kPrBlfSIlVGcrq/MF9AOLfAY8UoOwUyESs0oHZK2ujL7/TjSBCTeDXsErScANDtY
+aKbJXTO8Re4R2HK8W7UFF7DZ5A1d9Z8/LRmjgBR/B3l3iwQDLHfauvdyHKsjbeYr
+B5iOvse168CHINt9aR95/YtujPqMufTWOvUBecK72b5MA3YbpknKqMQfVmJaU0bt
+WrRuhmAUl6PDS0HmqjXa3TLqY4gHbdKxoHoGw6T0PPQOQIY0EOsiYDIWFZErnc/t
+TIOYyGHyByP8oS3hYsuxmYZ3XO2kC9V3Kc5akXc1T/n29HPxAcGlsh6gKM3i8d5T
+8EZVEIjPwLAgvKiF7vHkve1bnIe6SAnUDoU6PjP25QFYrKBdRmn4pXw3+OW85fPx
+RZhcZrF4yLaQX6kLCY8YnQXGt/jJH50peD6qTDC1GN4WlMhy/1OzNweCBuCmZRxi
+SV9V88CIRV9WQ2206oMwmGOKh6BRSdk1Ej3aH7XsDZpgMNlPE2wMSOc4YIQeQgdp
+kwC5AIkUunCizdkH/Z+R
+=b6ZM
+-----END PGP SIGNATURE-----
diff --git a/dev/libs/libtasn1/libtasn1.SlackBuild b/dev/libs/libtasn1/libtasn1.SlackBuild
index 32da0584..72c1b594 100644
--- a/dev/libs/libtasn1/libtasn1.SlackBuild
+++ b/dev/libs/libtasn1/libtasn1.SlackBuild
@@ -17,6 +17,7 @@
# slackbuild for libtasn1, by Alexandre Vieira de Souza
# requires:
# tested: libtasn1-1.4
+# model: generic.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/libs/libtasn1"}
PREFIX=${PREFIX:=/usr}
PKG_WORK="$TMP/$SRC_NAME"
CONF_OPTIONS=${CONF_OPTIONS:=""}
@@ -47,9 +49,9 @@ NUMJOBS=${NUMJOBS:="-j4"}
LIBDIR="$PREFIX/lib"
if [ "$ARCH" = "i386" ]; then
- SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
+ SLKCFLAGS="-O2 -march=i386 -mtune=i686"
elif [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mcpu=i686"
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686"
elif [ "$ARCH" = "s390" ]; then
@@ -65,6 +67,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_WORK" 2> /dev/null
@@ -84,6 +87,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 rmd160 sha1 sha256 sha512; 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
@@ -145,9 +214,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/libs/ptlib/Manifest b/dev/libs/ptlib/Manifest
new file mode 100644
index 00000000..5667947a
--- /dev/null
+++ b/dev/libs/ptlib/Manifest
@@ -0,0 +1,24 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST ptlib-2.4.4.tar.bz2 3009442 MD5 221ea2f96ff6bae9cf604d8766eae526 RMD160 9a84d463bf203b1619a9df5a67d0fed80b182acd SHA1 a6255cc6f2fb337518a9c49d8ce21f1790729ca7 SHA256 c9ef4267490507fc9699634551b50c0c1c225d48e0c095a81be6fa5a1fa96a3a SHA512 f9d6295025b999b1b21e60ae9f636bc21ff444a1f986bf79cdb4af21a7b36862062d0f44d2dd98a278bb96df1a5030997b082c294bc873f1720500b9a084369b
+DIST ptlib-2.6.1.tar.bz2 3296212 MD5 122ab96fcc44110ce05153f259b3285a RMD160 e7bd3f954c871725b269df0ab7561ab0fe6a23ba SHA1 b269a20f1bf98130e0088eea6ec5689197cf5521 SHA256 b8301389c1ee9968df8075942061665e33198d3865f92d8fb26e519068517305 SHA512 f074213ad00f7fbc60c8cd0c5008864acffbe45234bc267e6a152dccb9d6ea3c9d4ad090be149884aa0abfce2018e58ec3c27134c22edd11931c2ae623055cb6
+MKBUILD ptlib.mkbuild 5065 MD5 0c9587a722b4c295c41144a440ea2694 RMD160 9604fabe6b5785729d9cd367973f846997411e90 SHA1 22db177fd6ad32ae7dac061824adb1fe23997d25 SHA256 9b05ddcf3a636cd5584f7a34b9add2a02d955291bf0203c665bfd0f3b75f90d2 SHA512 44d537ac329833eae09a6678478fbb0b6b1376f98f308a2e53676efba9eb793bd0c97283006796e884d2660f8bbc3f1c9f55ea2c60193c9b2438f6085bb85126
+SLACKBUILD ptlib.SlackBuild 7115 MD5 76f3b88c695ff164f5df5c7c2740cfdf RMD160 d438bf405ff6f1dd4047606227370b6282c57d7e SHA1 4807bfe66fb071a4e20ffe8297e97a9fc7a5889e SHA256 273fc5aa8c9d5dc7fa3b07467e6aa969c287d6f9e42e29af10ce6bfa41ecef93 SHA512 a5bc98a0ec0e8591031667f256f73875bde964977ee710c3aee76ec5678a6e639b265fd1967c6082c1ad35042e814b5b91754b957f24e8e285489cf08e0f44bc
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJyjDgAAoJEEHL93ESzgeiTeoP/3AqYqQ49nwQxA5WSo57APxD
+SBEKJAXfB10TpNt8iYWzOxoQgkSX7xMS9C3d6Z4COzzoLnsSPdVbOBHDCbO6XsPU
+7+rfAwk2w9ItpDglY0WzDc7J/ggmpE1w+ixysOM0twnE7QmwJXorQtbzE63/KCxA
+AAeubvmGpMlTbzqGvrRP/m68b8ts1sJkaeHnA5ZsFUazNyn7TNSF27bhTq9ZMLLo
+GEHrmquJG27BvSEVJyFxgAJhVsSgo/5u+75WbTIr4x3DZXKdO8a9ucUIwomBn97k
+WAL7w3OeahKpfklS33pnIOtB7P9XWTrma7S6Z/J5Rra61Dm6ZBA0X8NfuNskYoUQ
+68+RXYRmnx/x9uI7FWs3kJwnQdTKp8cwnVTQWoMdQ5fquNRNCPoV/zj72AD5M3Ox
+TNgNebbfCqfKgBt1gytsZPlXbudOeugZ3/amfWhzMSoEAIDDE+f7ZpLmkArGPiRL
+7CUnn6A1SVvaphyySEzLR+jTmCqHjw0fBZUduU3xeVrT8EmLwtJwQyKf9P+F6tC+
+dVTJIwyHiuzk7uVO07echHbrNNx/AVBzYZsVWAzwC21J6X1xQCpmBLfK3Jdkjxue
+vqcSg3OKBel54bhBAJkOCMSUHJ1sO9LMMEV0pE0mlxui/vcpWIkatq/CrloJWidJ
+9sjTJCp7Ov5g1Ekz9RC2
+=GDN0
+-----END PGP SIGNATURE-----
diff --git a/dev/libs/ptlib/ptlib.SlackBuild b/dev/libs/ptlib/ptlib.SlackBuild
new file mode 100644
index 00000000..b687d2de
--- /dev/null
+++ b/dev/libs/ptlib/ptlib.SlackBuild
@@ -0,0 +1,223 @@
+#!/bin/bash
+#
+# ptlib.SlackBuild is free software; you can redistribute
+# it and/or modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of the License,
+# or any later version.
+#
+# ptlib.SlackBuild is distributed in the hope that it will
+# be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
+# Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
+#
+# slackbuild for ptlib, by Silvio Rhatto
+# requires:
+# tested: ptlib-2.4.4
+# model: generic.mkSlackBuild $Rev: 796 $
+#
+
+# Look for slackbuildrc
+if [ -f ~/.slackbuildrc ]; then
+ source ~/.slackbuildrc
+elif [ -f /etc/slackbuildrc ]; then
+ source /etc/slackbuildrc
+fi
+
+# Set variables
+CWD="$(pwd)"
+SRC_NAME="ptlib"
+PKG_NAME="ptlib"
+ARCH=${ARCH:=i486}
+SRC_VERSION=${VERSION:=2.4.4}
+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/libs/ptlib"}
+PREFIX=${PREFIX:=/usr}
+PKG_WORK="$TMP/$SRC_NAME"
+CONF_OPTIONS=${CONF_OPTIONS:=""}
+NUMJOBS=${NUMJOBS:="-j4"}
+
+# Set system libraries' path and optmization flags based on $ARCH
+LIBDIR="$PREFIX/lib"
+
+if [ "$ARCH" = "i386" ]; then
+ SLKCFLAGS="-O2 -march=i386 -mtune=i686"
+elif [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686"
+elif [ "$ARCH" = "s390" ]; then
+ SLKCFLAGS="-O2"
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIR="$PREFIX/lib64"
+ LDFLAGS="-L/lib64 -L/usr/lib64"
+fi
+
+# Set error codes (used by createpkg)
+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_WORK" 2> /dev/null
+rm -rf "$PKG" 2> /dev/null
+
+# Create directories if necessary
+mkdir -p "$SRC_DIR" || exit $ERROR_MKDIR
+mkdir -p "$PKG" || exit $ERROR_MKDIR
+mkdir -p "$REPOS" || exit $ERROR_MKDIR
+mkdir -p "$PKG_WORK" || exit $ERROR_MKDIR
+
+# Dowload source if necessary
+SRC="$SRC_NAME-$VERSION.tar.bz2"
+URL="http://www.ekiga.org/admin/downloads/latest/sources/ekiga_3.0.2/$SRC"
+
+if [ ! -s "$SRC_DIR/$SRC" ] || ! bunzip2 -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 rmd160 sha1 sha256 sha512; 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
+PKG_SRC="$PWD/`ls -l | awk '/^d/ { print $NF }'`"
+cd "$PKG_SRC"
+
+# Configure
+CFLAGS="$SLKCFLAGS" \
+ CXXFLAGS="$SLKCFLAGS" \
+ ./configure \
+ --prefix="$PREFIX" --libdir="$LIBDIR" $CONF_OPTIONS || exit $ERROR_CONF
+
+# Compile
+make $NUMJOBS || exit $ERROR_MAKE
+
+# Install
+make install DESTDIR="$PKG" || exit $ERROR_INSTALL
+
+# Strip binaries
+( 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
+)
+
+# Install documentation
+DOCS="NEWS TODO README AUTHORS INSTALL ChangeLog MAINTAINERS COPYING LICENSE SIGNATURE readme.*"
+mkdir -p "$PKG/usr/doc/$PKG_NAME-$PKG_VERSION" || exit $ERROR_MKDIR
+for doc in $DOCS; do
+ if [ -f "$doc" ]; then
+ cp -a $doc "$PKG/usr/doc/$PKG_NAME-$PKG_VERSION"
+ fi
+done
+
+# Add package description (slack-desc)
+mkdir -p "$PKG/install" || exit $ERROR_MKDIR
+cat << EODESC > "$PKG/install/slack-desc"
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler--------------------------------------------------------|
+ptlib: ptlib
+ptlib:
+ptlib: PTLib (Portable Tools Library) is a moderately large class library
+ptlib: that has it's genesis many years ago as PWLib (portable Windows
+ptlib: Library), a method to product applications to run on both Microsoft
+ptlib: Windows and Unix systems. It has also been ported to other systems
+ptlib: such as Mac OSX, VxWorks and other embedded systems
+ptlib:
+ptlib:
+ptlib:
+ptlib:
+EODESC
+
+# Build the package
+cd "$PKG"
+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
+ rm -rf "$PKG_WORK" "$PKG"
+fi
diff --git a/dev/libs/pwlib/Manifest b/dev/libs/pwlib/Manifest
new file mode 100644
index 00000000..30c8d4fd
--- /dev/null
+++ b/dev/libs/pwlib/Manifest
@@ -0,0 +1,23 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+DIST pwlib-v1_11_1-src.tar.gz 2327497 MD5 8b7a7a2ed8da6792006922476dd3b2f3 RMD160 434307ecaec5c7c5a145641890e5f8287a17689a SHA1 1cdda88e2de3be0186811d466052569b3a771668 SHA256 a909b9d52ab19ba516f31e96e5875e6a336810ac929eeb5ca13f95b0e7b8572e SHA512 64d19ac0a6c36b4f394bc5211245deab5cde8d05edd0f59a34000a6234f4bdfdcd8ec1c78ff88b59ced40539d93688ab18d6e3aafa34699ba93bf32dcb7c7400
+MKBUILD pwlib.mkbuild 4274 MD5 598b0c6fef77619657d6a3215c55fe5a RMD160 5f8084f36f84a6b008154d9d3dfe7d53953122b1 SHA1 40ce70eeb429f0072dcd3a4fe09e8040dd5d7e9f SHA256 a08de32d79ecbfdc5d4da9174a00f106ca47a284d9504490a044fd2b69450933 SHA512 811d84ea4f862b5ca8a9fb0852d313f955aee4f32578162d214e08b5559ecda989ebbc29a6c74295957234ad45889c4b8f50b7a997d8dfeae3f7e5b21a401ad3
+SLACKBUILD pwlib.SlackBuild 7060 MD5 051d66dfcfa3c5f803b52b65b30f3dc5 RMD160 49406db4996cb4d8988f032dca6aa6db8bfda4b6 SHA1 179a72a1506e8368916f3679209fcce08c7942f8 SHA256 8be9e8d0980b5a0f3df631007dbc70d98e195a3ba2b40d6c14ebd1a4bc14c0a6 SHA512 b5b0361c93a77e63be77ac283c2129bcbff21acd7683825887664c0902ba4361cda5fbe3e098c94566cbc343a33f1fd37fd300f8582538292661f504aebbb26e
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.9 (GNU/Linux)
+
+iQIcBAEBAgAGBQJJyXaZAAoJEEHL93ESzgeiB14P/iS/ZewLyVUg1Ds5TIhS0nbg
+Ie0KQIqjvZ3vSAWoSrBfueTjGJRqdKh5NKpDQ2lyBIZA1bD1vdRb9k/4B9T9K3DD
+CwPQ+AoqIAGr9/rpONb4f9pM+F8zsA6n1kx99uyqa6fQMBvTelw7GR97keNEQiFT
+4UcvxBeh1GSUaZO/jTDIQS5fO0vsnd6etaNMkiGTSR8uvBdnbNShKJ//ye6qGzsI
+9YJ+4pCxlcad4WJPrxDQIg9wEFy9gxbt3HR/c0YeDF2rz83z0W3naJuDm0cVfFkc
+g9kZKUGcyVAY+x9fIx/9Er5tN1bw5uy/+iFiZ30qNxWaqbHN+bXlpmSWxU8N8GHL
+xRYO8J+KG1x1q6vwmNK2x1/Pj+exdpYvy6v/B0++XTyYlDp+TOzT6w9Zd5e5CeqG
+euGv3dtr3afDzzBLzAFD3eTbQi+yjBB8OAt6VjP/HKpGQ/OeFib5kN5gODwvCUZe
+8UOLGB16IhqsJLdLnnpw0YIFeM/GShxsCl6GKWbpv26TPbByF6AuAX3vi9FgFSHl
+NpJb+wICAkXONuzwEj43iEO2iRvaUOud1V6rhZspv4tz3dJ3D4W9PjRp+olhHd2x
+BuLWC7LvZ1Jw9BpEdQmXBt95YjDyD+kkR//vzYeR2LFlV0ddPNUR+pXKuddZUCVz
+z+fmfQCgRuxW/Q4Ythuc
+=9Ncj
+-----END PGP SIGNATURE-----
diff --git a/dev/libs/pwlib/pwlib.SlackBuild b/dev/libs/pwlib/pwlib.SlackBuild
index 3c966f75..8c686be1 100755
--- a/dev/libs/pwlib/pwlib.SlackBuild
+++ b/dev/libs/pwlib/pwlib.SlackBuild
@@ -10,13 +10,14 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
-# You should have received a copy of the GNU General Public License along with
-# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
-# Place - Suite 330, Boston, MA 02111-1307, USA
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
#
# slackbuild for pwlib, by Rudson R. Alves
# requires:
-# tested: pwlib-1.10.10
+# tested: pwlib-1_11_1
+# model: generic.mkSlackBuild $Rev: 796 $
#
# Look for slackbuildrc
@@ -31,13 +32,14 @@ CWD="$(pwd)"
SRC_NAME="pwlib"
PKG_NAME="pwlib"
ARCH=${ARCH:=i486}
-SRC_VERSION=${VERSION:=1.10.10}
+SRC_VERSION=${VERSION:=1_11_1}
PKG_VERSION="$(echo "$SRC_VERSION" | tr '[[:blank:]-]' '_')"
BUILD=${BUILD:=1rra}
SRC_DIR=${SRC_DIR:=$CWD}/$PKG_NAME
TMP=${TMP:=/tmp}
PKG=${PKG:=$TMP/package-$PKG_NAME}
REPOS=${REPOS:=$TMP}
+SLACKBUILD_PATH=${SLACKBUILD_PATH:="dev/libs/pwlib"}
PREFIX=${PREFIX:=/usr}
PKG_WORK="$TMP/$SRC_NAME"
CONF_OPTIONS=${CONF_OPTIONS:=""}
@@ -47,16 +49,17 @@ NUMJOBS=${NUMJOBS:="-j4"}
LIBDIR="$PREFIX/lib"
if [ "$ARCH" = "i386" ]; then
- SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
+ SLKCFLAGS="-O2 -march=i386 -mtune=i686"
elif [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mcpu=i686"
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686"
elif [ "$ARCH" = "s390" ]; then
SLKCFLAGS="-O2"
elif [ "$ARCH" = "x86_64" ]; then
- SLKCFLAGS="-O2"
+ SLKCFLAGS="-O2 -fPIC"
LIBDIR="$PREFIX/lib64"
+ LDFLAGS="-L/lib64 -L/usr/lib64"
fi
# Set error codes (used by createpkg)
@@ -64,6 +67,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_WORK" 2> /dev/null
@@ -76,17 +80,83 @@ mkdir -p "$REPOS" || exit $ERROR_MKDIR
mkdir -p "$PKG_WORK" || exit $ERROR_MKDIR
# Dowload source if necessary
-SRC="$SRC_NAME-$VERSION.tar.gz"
-URL="http://www.ekiga.org/admin/downloads/latest/sources/sources/$SRC"
+SRC="$SRC_NAME-v$VERSION-src.tar.gz"
+URL="http://www.voxgratia.org/releases/$SRC"
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 rmd160 sha1 sha256 sha512; 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
-PKG_SRC="$PWD/`ls -l | awk '/^d/ { print $8 }'`"
+PKG_SRC="$PWD/`ls -l | awk '/^d/ { print $NF }'`"
cd "$PKG_SRC"
# Configure
@@ -122,9 +192,9 @@ done
mkdir -p "$PKG/install" || exit $ERROR_MKDIR
cat << EODESC > "$PKG/install/slack-desc"
# HOW TO EDIT THIS FILE:
-# The "handy ruler" below makes it easier to edit a package description. Line
+# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
-# on the right side marks the last column you can put a character in. You must
+# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':'.
@@ -144,9 +214,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