]> gitweb.fluxo.info Git - slackbuilds.git/commitdiff
php: snapshot slackbuild update
authorrhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4>
Sat, 4 Nov 2006 15:55:56 +0000 (15:55 +0000)
committerrhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4>
Sat, 4 Nov 2006 15:55:56 +0000 (15:55 +0000)
git-svn-id: svn+slack://slack.fluxo.info/var/svn/slackbuilds@580 370017ae-e619-0410-ac65-c121f96126d4

patches/php/php4-snapshot.SlackBuild

index a75e6afe433593279b5bb464af73fbd90c3e7fd7..e3099097a73a59ae4ba9c7916cc6512116d5fff2 100755 (executable)
@@ -31,8 +31,8 @@ if [ -f "~/.slackbuildrc" ]; then
 fi
 
 PACKAGE="php"
-VERSION=${VERSION:=4.4.2}
-SNAP_VERSION=${SNAP_VERSION:=200606181830}
+VERSION=${VERSION:=4.4.4}
+SNAP_VERSION=${SNAP_VERSION:=200611041530}
 PINE=${PINE:=4.64}
 ARCH=${ARCH:=i486}
 BUILD=${BUILD:=1rha}
@@ -43,10 +43,6 @@ ERROR_MD5=34;       ERROR_CONF=35;      ERROR_HELP=36
 ERROR_TAR=37;       ERROR_MKPKG=38;     ERROR_GPG=39
 ERROR_PATCH=40
 
-TMP=${TMP:=/tmp}
-PKG=$TMP/package-php
-SRC_DIR=${SRC:=$CWD}
-
 RTOOL="wget"
 
 SRC="php4-STABLE-$SNAP_VERSION.tar.bz2"
@@ -66,6 +62,9 @@ TEMPLATE="HTML_Template_IT-1.1.3.tgz"
 
 PEAR="http://pear.php.net/get"
 
+SRC_DIR="$SRC_DIR/$PACKAGE"
+mkdir -p $SRC_DIR
+
 if [ "$RTOOL" == "wget" ]; then
 
   if [ ! -f "$SRC_DIR/$SRC" ]; then 
@@ -95,10 +94,6 @@ if [ "$RTOOL" == "wget" ]; then
 
 fi
 
-if [ ! -d $TMP ]; then
-  mkdir -p $TMP
-fi
-
 if [ "$ARCH" = "i386" ]; then
   SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
 elif [ "$ARCH" = "i486" ]; then
@@ -137,6 +132,12 @@ else
   )
 fi
 
+TMP="$TMP/$PACKAGE"
+PKG="$TMP/package-php"
+rm -rf $TMP
+mkdir -p $TMP
+cd $TMP
+
 php_configure() {
 EXTENSION_DIR=/usr/$LIB/php/extensions \
 CFLAGS="$SLKCFLAGS" \
@@ -232,7 +233,7 @@ cd php4-STABLE-$SNAP_VERSION
 if [ "$ARCH" == "x86_64" ]; then
   # Fix lib64 - thanks SuSE
   echo patchin with $CWD/php-with-_lib-$VERSION.diff.gz...
-  zcat $CWD/php-with-_lib-$VERSION.diff.gz | patch -p1 --verbose
+  zcat $CWD/php-with-_lib-$VERSION.diff.gz | patch -p1 --verbose || exit $ERROR_PATCH
   autoconf
 fi
 
@@ -245,6 +246,10 @@ find . -perm 664 -exec chmod 644 {} \;
 find . -name "*.h" -exec chmod 644 {} \;
 # Sometimes they ship a few of these:
 find . -name "*.orig" -exec rm {} \;
+
+# Fix a UTF-8 parsing overflow:
+zcat $CWD/php4.utf8.diff.gz | patch -p1 --verbose --backup --suffix=.orig || exit $ERROR_PATCH
+
 # Patch ini files:
 
 if [ "$ARCH" == "x86_64" ]; then