summaryrefslogtreecommitdiffstats
path: root/main/php/APKBUILD
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2011-08-22 20:26:00 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2011-08-22 20:26:00 +0000
commit7ca9bed6c7cae20d1211944354c89bc5ce899f4b (patch)
tree1dc305138af3293c6bae4cb6fd87bbbb4373206a /main/php/APKBUILD
parentffdd4019b0f4125c0ec1fd0260cdba581631dd5a (diff)
downloadaports-7ca9bed6c7cae20d1211944354c89bc5ce899f4b.tar.bz2
aports-7ca9bed6c7cae20d1211944354c89bc5ce899f4b.tar.xz
main/php: upgrade to 5.3.7, remove pear
We will build pear separately
Diffstat (limited to 'main/php/APKBUILD')
-rw-r--r--main/php/APKBUILD56
1 files changed, 17 insertions, 39 deletions
diff --git a/main/php/APKBUILD b/main/php/APKBUILD
index 032d5639d..3acdbf7ce 100644
--- a/main/php/APKBUILD
+++ b/main/php/APKBUILD
@@ -1,9 +1,9 @@
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Matt Smith <mcs@darkregion.net>
pkgname=php
-pkgver=5.3.6
-_suhosinver=5.3.6-0.9.10
-pkgrel=11
+pkgver=5.3.7
+_suhosinver=5.3.7-0.9.10
+pkgrel=0
pkgdesc="The PHP language runtime engine"
url="http://www.php.net/"
arch="all"
@@ -19,7 +19,6 @@ makedepends="pcre-dev libxml2-dev libiconv-dev openssl-dev zlib-dev bzip2-dev
readline-dev enchant-dev gdbm-dev freetds-dev"
subpackages="$pkgname-dev $pkgname-doc $pkgname-common $pkgname-cgi
$pkgname-cli $pkgname-fpm $pkgname-apache2 $pkgname-embed
- $pkgname-pear
$pkgname-bcmath
$pkgname-bz2
$pkgname-calendar
@@ -73,8 +72,6 @@ subpackages="$pkgname-dev $pkgname-doc $pkgname-common $pkgname-cgi
# http://download.suhosin.org/suhosin-patch-${_suhosinver}.patch.gz
source="http://www.php.net/distributions/${pkgname}-${pkgver}.tar.bz2
- php-install-pear-xml.patch
- php-uclibc.patch
suhosin-patch-${_suhosinver}.patch
php-fpm.initd
php5-module.conf
@@ -86,13 +83,11 @@ _srcdir="$srcdir"/$pkgname-$pkgver
prepare() {
cd "$_srcdir"
- # beat the pear installer into using xml.so
- patch -p1 -i "$srcdir"/php-install-pear-xml.patch || return 1
- patch -p1 -i "$srcdir"/php-uclibc.patch || return 1
-
- # apply suhosin patch
- patch -p1 -i "${srcdir}"/suhosin-patch-${_suhosinver}.patch || return 1
-
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
# safty check for api changes
local vapi=$(sed -n '/#define PHP_API_VERSION/{s/.* //;p}' main/php.h)
if [ "$vapi" != "$_apiver" ]; then
@@ -113,6 +108,10 @@ _do_build() {
}
build() {
+ # Set PEAR_INSTALLDIR to ensure that the hard-coded include_path
+ # is properly set even if we install php-pear separately
+ export PEAR_INSTALLDIR=/usr/share/pear
+
_phpconfig="--build=${CHOST:-i486-alpine-linux-uclibc} \
--prefix=/usr \
--sysconfdir=/etc/php \
@@ -203,13 +202,12 @@ build() {
--enable-mailparse \
"
- # cgi, fcgi, cli, pear and extensions
+ # cgi, fcgi, cli and extensions
_do_build cgi \
${_phpconfig} \
--disable-cli \
--enable-cgi \
--enable-cli \
- --with-pear \
${_phpextensions} \
|| return 1
@@ -244,11 +242,8 @@ build() {
package() {
cd "$srcdir"/build-cgi
- # install php-cgi, cli, pear and modules
- make -j1 install install-pear INSTALL_ROOT="$pkgdir" || return 1
-
- # cleanup after pear
- find "$pkgdir" -name '.*' | xargs rm -rf || return 1
+ # install php-cgi, cli and modules
+ make -j1 install INSTALL_ROOT="$pkgdir" || return 1
# install fpm
install -D -m755 "$srcdir"/build-fpm/sapi/fpm/php-fpm \
@@ -359,21 +354,6 @@ embed() {
mv "$pkgdir"/usr/lib/libphp5.so "$subpkgdir"/usr/lib/
}
-pear() {
- pkgdesc="PHP Extension and Application Repository (PEAR)"
- depends="php-cli php-xml"
- mkdir -p "$subpkgdir"/usr/share "$subpkgdir"/etc/php \
- "$subpkgdir"/usr/bin
- mv "$pkgdir"/usr/bin/pecl \
- "$pkgdir"/usr/bin/pear \
- "$pkgdir"/usr/bin/peardev \
- "$subpkgdir"/usr/bin/ || return 1
- mv "$pkgdir"/etc/php/pear.conf \
- "$subpkgdir"/etc/php/ || return 1
- mv "$pkgdir"/usr/share/pear \
- "$subpkgdir"/usr/share/ || return 1
-}
-
_mv_ext() {
local ext=$1
pkgdesc="${ext} extension for PHP"
@@ -444,9 +424,7 @@ zlib() { _mv_ext zlib; }
mssql() { _mv_ext mssql; }
pdo_dblib() { _mv_ext pdo_dblib "php-pdo freetds"; }
-md5sums="2286f5a82a6e8397955a0025c1c2ad98 php-5.3.6.tar.bz2
-5111e3be06d391f8772587c675240fab php-install-pear-xml.patch
-31458da0ca6cb4ca2cbdaa2d32ab386d php-uclibc.patch
-54d3a7830c103f0efe94ed44c40dfad5 suhosin-patch-5.3.6-0.9.10.patch
+md5sums="2d47d003c96de4e88863ff38da61af33 php-5.3.7.tar.bz2
+8bd8840465d6bcd8e1e5d2cec80a1bfc suhosin-patch-5.3.7-0.9.10.patch
8f2bb2b744a2de50025842cb51fb6a3a php-fpm.initd
67719f428f44ec004da18705cbabe2ee php5-module.conf"