summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOle Markus With <olemarkus@gentoo.org>2010-10-30 21:41:10 +0000
committerOle Markus With <olemarkus@gentoo.org>2010-10-30 21:41:10 +0000
commit8ca293a1a2aca5bcc29980757cec1809c6459462 (patch)
treea103b7e3988391f80b91526c35388641f4397148
parentVersion bump, readd wrongly dropped ppc* keywords, readd wrongly removed mini... (diff)
downloadgentoo-2-8ca293a1a2aca5bcc29980757cec1809c6459462.tar.gz
gentoo-2-8ca293a1a2aca5bcc29980757cec1809c6459462.tar.bz2
gentoo-2-8ca293a1a2aca5bcc29980757cec1809c6459462.zip
Added cgi support to minor version slotted ebuilds and made it possible to chose which version of php.ini to use
(Portage version: 2.1.9.11/cvs/Linux x86_64)
-rw-r--r--dev-lang/php/ChangeLog8
-rw-r--r--dev-lang/php/files/eblits/pkg_postinst-v2.eblit16
-rw-r--r--dev-lang/php/files/eblits/src_install-v2.eblit14
-rw-r--r--dev-lang/php/php-5.2.14-r1.ebuild22
-rw-r--r--dev-lang/php/php-5.3.3-r2.ebuild15
5 files changed, 63 insertions, 12 deletions
diff --git a/dev-lang/php/ChangeLog b/dev-lang/php/ChangeLog
index 7307d78dc861..74d119aad786 100644
--- a/dev-lang/php/ChangeLog
+++ b/dev-lang/php/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for dev-lang/php
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/ChangeLog,v 1.428 2010/10/27 10:33:18 olemarkus Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/ChangeLog,v 1.429 2010/10/30 21:41:10 olemarkus Exp $
+
+ 30 Oct 2010; <olemarkus@gentoo.org> files/eblits/pkg_postinst-v2.eblit,
+ php-5.2.14-r1.ebuild, files/eblits/src_install-v2.eblit,
+ php-5.3.3-r2.ebuild:
+ Changed ebuild to use php.ini-development by default
+ Also made ebuilds add symlink to php-cgi if the cgi SAPI is installed
27 Oct 2010; <olemarkus@gentoo.org> files/eblits/src_install-v1.eblit,
files/eblits/src_install-v2.eblit:
diff --git a/dev-lang/php/files/eblits/pkg_postinst-v2.eblit b/dev-lang/php/files/eblits/pkg_postinst-v2.eblit
index 7f5e8274e20b..f2c2a14da09b 100644
--- a/dev-lang/php/files/eblits/pkg_postinst-v2.eblit
+++ b/dev-lang/php/files/eblits/pkg_postinst-v2.eblit
@@ -1,6 +1,6 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/files/eblits/pkg_postinst-v2.eblit,v 1.3 2010/10/19 06:20:34 olemarkus Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/files/eblits/pkg_postinst-v2.eblit,v 1.4 2010/10/30 21:41:10 olemarkus Exp $
eblit-php-pkg_postinst() {
# Output some general info to the user
@@ -12,20 +12,22 @@ eblit-php-pkg_postinst() {
# Create the symlinks for php
- local m modules="cli apache2 fpm"
+ local m modules="cli apache2 fpm cgi"
for m in $modules; do
if use $m ; then
local ci=$(eselect php show $m)
if [[ -z $ci ]]; then
eselect php set $m php${SLOT}
elif [[ $ci != "php${SLOT}" ]] ; then
- ewarn "To switch $m to use php-${SLOT}, run"
- ewarn " eselect php set $m php${SLOT}"
- ewarn
+ elog "To switch $m to use php-${SLOT}, run"
+ elog " eselect php set $m php${SLOT}"
+ elog
fi
fi
done
+
+
ewarn "You may have to recompile third-party extensions now"
ewarn "(includes every dev-php5/pecl-* package and probably others in that category)"
if ! use readline && use cli ; then
@@ -33,5 +35,9 @@ eblit-php-pkg_postinst() {
ewarn "the readline USE flag or php -a will hang"
fi
ewarn
+ ewarn "This ebuild installed a version of php.ini based on php.ini-${PHP_INI_VERSION} version."
+ ewarn "You can chose which version of php.ini to install by default by setting PHP_INI_VERSION to either"
+ ewarn "'production' or 'development' in /etc/make.conf"
+ ewarn "Both versions of php.ini can be found in /usr/share/doc/${PF}"
}
diff --git a/dev-lang/php/files/eblits/src_install-v2.eblit b/dev-lang/php/files/eblits/src_install-v2.eblit
index 91bec5ff069f..36e3675e6912 100644
--- a/dev-lang/php/files/eblits/src_install-v2.eblit
+++ b/dev-lang/php/files/eblits/src_install-v2.eblit
@@ -1,6 +1,6 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/files/eblits/src_install-v2.eblit,v 1.7 2010/10/27 10:33:18 olemarkus Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/files/eblits/src_install-v2.eblit,v 1.8 2010/10/30 21:41:10 olemarkus Exp $
eblit-php-src_install() {
# see bug #324739 for what happens when we don't have that
@@ -145,4 +145,16 @@ php_install_ini() {
newinitd "${FILESDIR}/php-fpm-r1.init" "php-fpm"
# dosym "${PHP_DESTDIR}/bin/php-fpm" "/usr/bin/php-fpm"
fi
+
+ # Install PHP ini files into /usr/share/php
+ if [[ ${SLOT} == '5.2' ]]; then
+ newdoc php.ini-dist php.ini-development
+ newdoc php.ini-recommended php.ini-production
+ fi
+
+ if [[ ${SLOT} == '5.3' ]]; then
+ dodoc php.ini-development
+ dodoc php.ini-production
+ fi
+
}
diff --git a/dev-lang/php/php-5.2.14-r1.ebuild b/dev-lang/php/php-5.2.14-r1.ebuild
index 834992e088ce..b1c9b03daf43 100644
--- a/dev-lang/php/php-5.2.14-r1.ebuild
+++ b/dev-lang/php/php-5.2.14-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/php-5.2.14-r1.ebuild,v 1.1 2010/10/08 18:25:10 olemarkus Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/php-5.2.14-r1.ebuild,v 1.2 2010/10/30 21:41:10 olemarkus Exp $
EAPI=2
@@ -78,7 +78,7 @@ IUSE="kolab"
# SAPIs and SAPI-specific USE flags (cli SAPI is default on):
IUSE="${IUSE}
${SAPIS/cli/+cli}
- threads"
+ threads force-cgi-redirect discard-path"
IUSE="${IUSE} adabas bcmath berkdb birdstep bzip2 calendar cdb cjk
crypt +ctype curl curlwrappers db2 dbase dbmaker debug doc empress
@@ -238,8 +238,24 @@ PROVIDE="virtual/php"
SLOT="$(get_version_component_range 1-2)"
S="${WORKDIR}/${PHP_P}"
+# Allow users to install production version if they want to
+# PHP 5.2 has other filenames for prod and dev versions
+
+case "${PHP_INI_VERSION}" in
+ production)
+ PHP_INI_UPSTREAM="php.ini-recommended"
+ ;;
+ development)
+ PHP_INI_UPSTREAM="php.ini-dist"
+ ;;
+ *)
+ PHP_INI_VERSION="development"
+ PHP_INI_UPSTREAM="php.ini-dist"
+ ;;
+esac
+
+
PHP_INI_FILE="php.ini"
-PHP_INI_UPSTREAM="php.ini-dist"
want_apache
diff --git a/dev-lang/php/php-5.3.3-r2.ebuild b/dev-lang/php/php-5.3.3-r2.ebuild
index d177a7f7dd88..483cdd5cc504 100644
--- a/dev-lang/php/php-5.3.3-r2.ebuild
+++ b/dev-lang/php/php-5.3.3-r2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/php-5.3.3-r2.ebuild,v 1.1 2010/10/08 18:25:10 olemarkus Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/php-5.3.3-r2.ebuild,v 1.2 2010/10/30 21:41:10 olemarkus Exp $
EAPI=2
@@ -262,8 +262,19 @@ PROVIDE="virtual/php"
SLOT="$(get_version_component_range 1-2)"
S="${WORKDIR}/${PHP_P}"
+# Allow users to install production version if they want to
+
+case "${PHP_INI_VERSION}" in
+ production|development)
+ ;;
+ *)
+ PHP_INI_VERSION="development"
+ ;;
+esac
+
+PHP_INI_UPSTREAM="php.ini-${PHP_INI_VERSION}"
PHP_INI_FILE="php.ini"
-PHP_INI_UPSTREAM="php.ini-production"
+
want_apache