diff options
author | rhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4> | 2009-01-13 21:49:59 +0000 |
---|---|---|
committer | rhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4> | 2009-01-13 21:49:59 +0000 |
commit | 8ee204d36beb98436e708bf037c9225a432730c7 (patch) | |
tree | 629cc904b154582beac7b837b1a8272e7af4d3e0 /app/emulation | |
parent | acb1f2497ee2819f4dd881c828710b0861ce52a5 (diff) | |
download | slackbuilds-8ee204d36beb98436e708bf037c9225a432730c7.tar.gz slackbuilds-8ee204d36beb98436e708bf037c9225a432730c7.tar.bz2 |
cabextract: adding manifest
git-svn-id: svn+slack://slack.fluxo.info/var/svn/slackbuilds@2080 370017ae-e619-0410-ac65-c121f96126d4
Diffstat (limited to 'app/emulation')
-rw-r--r-- | app/emulation/wine/Manifest | 3 | ||||
-rwxr-xr-x | app/emulation/wine/wine.SlackBuild | 70 |
2 files changed, 67 insertions, 6 deletions
diff --git a/app/emulation/wine/Manifest b/app/emulation/wine/Manifest new file mode 100644 index 00000000..7169858c --- /dev/null +++ b/app/emulation/wine/Manifest @@ -0,0 +1,3 @@ +DIST wine-1.0.1.tar.bz2 13956805 MD5 b49540f4ed194c7e8da4cdc4b5bd3404 RMD160 fecd2bf970c51c80fc02ca39631034f066da145e SHA1 0550b03bf7b314514a87b6abb2198da96ef83b22 SHA256 c04bb376c6a2bd2be3bd8d5b73aa6db2dda3960791ea5d36579499fe72903479 SHA512 71ece5e13dec3c174a024b28eac802ab076207ce0b4c00b47998af167469c4d28571a02a5e2de23bd0a6f1a2c51875d15455aaa7c1140bd086068e0ae232d3a0 +MKBUILD wine.mkbuild 4471 MD5 fc3ddb4c2983fba36bac066b4731c994 RMD160 7d921e762097996d2062f0a0570784bec888cab8 SHA1 54dcd03f8e7aa6b2327cba3eafcefb2e27a85b93 SHA256 ed01911a384237a7f8fad4ceea3f48f67a33c3a218a6a64b19a4ede643e1da52 SHA512 fd83111dde2408bcf1891d3790567530ca5a495f0d74472eb174f0ecc8e4ac3fa0ed66c2ef5c7f1d5e6bde46f4de3f5cb09da2b488c3bec410535399966869e8 +SLACKBUILD wine.SlackBuild 6886 MD5 0ac0c13bbf5cf4216c1f430c58644caf RMD160 8d4d0ecebbcb44f97836d007484a63cfd9691564 SHA1 03dce0076142366cccb720e92d10a66c4287781e SHA256 f008f560d51eb08c0eb0be95142a0232cbeedbe979df6e098b3dc1beb4dcd9fc SHA512 4cabcf3f457eab31c54848c6e2968131e9ad5a3d399667ef06350bc58e5baf8ca335343093f4a8837e01fc28d5d566460a5f9882084cd387bd3360498fc2785e diff --git a/app/emulation/wine/wine.SlackBuild b/app/emulation/wine/wine.SlackBuild index e1cb2d7d..9473078b 100755 --- a/app/emulation/wine/wine.SlackBuild +++ b/app/emulation/wine/wine.SlackBuild @@ -16,7 +16,7 @@ # # slackbuild for wine, by Rudson R. Alves # requires: -# tested: wine-1.0 +# tested: wine-1.0.1 # # Look for slackbuildrc @@ -31,7 +31,7 @@ CWD="$(pwd)" SRC_NAME="wine" PKG_NAME="wine" ARCH=${ARCH:=i486} -SRC_VERSION=${VERSION:=1.1.0} +SRC_VERSION=${VERSION:=1.0.1} PKG_VERSION="$(echo "$SRC_VERSION" | tr '[[:blank:]-]' '_')" BUILD=${BUILD:=1rra} SRC_DIR=${SRC_DIR:=$CWD}/$PKG_NAME @@ -41,15 +41,15 @@ REPOS=${REPOS:=$TMP} PREFIX=${PREFIX:=/usr} PKG_WORK="$TMP/$SRC_NAME" CONF_OPTIONS=${CONF_OPTIONS:="--sysconfdir=/etc --localstatedir=/var"} -NUMJOBS=${NUMJOBS:="-j3"} +NUMJOBS=${NUMJOBS:="-j4"} # Set system libraries' path and optmization flags based on $ARCH 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 @@ -66,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_WORK" 2> /dev/null @@ -85,6 +86,63 @@ 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_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 @@ -149,6 +207,6 @@ cd "$PKG" makepkg -l y -c n "$REPOS/$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 |