[arch-commits] CVS update of extra/devel/php (PKGBUILD)

Pierre Schmitz pierre at archlinux.org
Fri Oct 12 12:53:13 UTC 2007


    Date: Friday, October 12, 2007 @ 08:53:13
  Author: pierre
    Path: /home/cvs-extra/extra/devel/php

Modified: PKGBUILD (1.114 -> 1.115)

upgpkg: php 5.2.4-7
use different configuration for cli; added readline support; further cleanup; implemented FS#8255


----------+
 PKGBUILD |   55 +++++++++++++++++++++++++++++--------------------------
 1 file changed, 29 insertions(+), 26 deletions(-)


Index: extra/devel/php/PKGBUILD
diff -u extra/devel/php/PKGBUILD:1.114 extra/devel/php/PKGBUILD:1.115
--- extra/devel/php/PKGBUILD:1.114	Wed Oct 10 04:37:09 2007
+++ extra/devel/php/PKGBUILD	Fri Oct 12 08:53:12 2007
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD,v 1.114 2007/10/10 08:37:09 pierre Exp $
+# $Id: PKGBUILD,v 1.115 2007/10/12 12:53:12 pierre Exp $
 # Maintainer: Pierre Schmitz <pierre at archlinux.de>
 pkgname=php
 pkgver=5.2.4
@@ -21,7 +21,7 @@
         'php.ini')
 md5sums=('55c97a671fdabf462cc7a82971a656d2' \
          '58b18d0db00bc52b004fc749190a958f' \
-         '3a6a6001e8d1cc9bf942574327832795')
+         '7cb9c272fb373ee431f4a808952e0bef')
 
 build() {
 	[ -e /usr/lib/libdb-4.1.so ] && echo 'remove db4.1 package' && return 1
@@ -31,7 +31,6 @@
 	--with-layout=GNU \
 	--with-config-file-path=/etc/php \
 	--with-config-file-scan-dir=/etc/php/conf.d \
-	--with-pear=/usr/share/pear \
 	--enable-inline-optimization \
 	--disable-debug \
 	--disable-rpath \
@@ -107,38 +106,42 @@
 	# apply suhosin patch
 	patch -p1 -i ${startdir}/src/suhosin-patch-${pkgver}-${_suhosinver}.patch || return 1
 
+	# cli
+	./configure ${phpconfig} \
+		--disable-cgi \
+		--with-readline \
+		--enable-pcntl \
+		--with-pear=/usr/share/pear \
+		${phpextensions} || return 1
+	make || return 1
+	make INSTALL_ROOT=${startdir}/pkg install || return 1
+
+	# fix pear path
+	sed "s|$PWD||g" -i ${startdir}/pkg/usr/{bin/pear,share/pear/pearcmd.php}
+	# cleanup
+	rm -f ${startdir}/pkg`${startdir}/pkg/usr/bin/php-config --extension-dir`/*.a
+	rm -rf ${startdir}/pkg/{.registry,.channels,.depdb*,.lock,.filemap}
+	rmdir ${startdir}/pkg/usr/include/php/include
+	# install php.ini
+	install -D -m644 ${startdir}/src/php.ini ${startdir}/pkg/etc/php/php.ini
+	install -d -m755 ${startdir}/pkg/etc/php/conf.d/
+
 	# cgi and fcgi
 	./configure ${phpconfig} \
 		--enable-fastcgi \
 		--enable-cgi \
 		--enable-discard-path \
 		--enable-force-cgi-redirect \
+		--disable-cli \
 		${phpextensions} || return 1
-
 	make || return 1
-	make INSTALL_ROOT=${startdir}/pkg install || return 1
-
-	# cleanup
-	rm -rf ${startdir}/pkg/{etc,.registry,.channels,.depdb*,.lock,.file*}
-	rm -rf ${startdir}/pkg/usr/{include,share,lib,man}
-	rm ${startdir}/pkg/usr/bin/{php,phpize,php-config,pecl,pear*}
+	install -D -m755 sapi/cgi/php-cgi ${startdir}/pkg/usr/bin/php-cgi || return 1
 
 	# mod_php
-	make distclean
-	./configure ${phpconfig} --with-apxs2 ${phpextensions} || return 1
-
+	./configure ${phpconfig} \
+		--with-apxs2 \
+		--disable-cli \
+		${phpextensions} || return 1
 	make || return 1
-	install -d -m755 ${startdir}/pkg/usr/lib/apache
-	sed -i "s|-i -a -n php5|-i -n php5|g" Makefile
-	make INSTALL_ROOT=${startdir}/pkg install || return 1
-
-	# remove empty dirs
-	rmdir -p ${startdir}/pkg{/etc/httpd/conf,/usr/include/php/include}
-
-	# install php.ini
-	install -D -m644 ${startdir}/src/php.ini ${startdir}/pkg/etc/php/php.ini
-	install -d -m755 ${startdir}/pkg/etc/php/conf.d/
-
-	# fix pear path
-	sed "s|$PWD||g" -i ${startdir}/pkg/usr/{bin/pear,share/pear/pearcmd.php}
+	install -D -m644 libs/libphp5.so ${startdir}/pkg/usr/lib/apache/libphp5.so || return 1
 }
\ No newline at end of file




More information about the arch-commits mailing list