From c1636e90468ee06df161f7cceeb58864ea0bea6d Mon Sep 17 00:00:00 2001 From: Luca Longinotti Date: Sat, 13 May 2006 15:39:11 +0000 Subject: Add PHPCHECKNODIE option for the require_php_with_*use checks. --- eclass/depend.php.eclass | 54 +++++++++++++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 19 deletions(-) (limited to 'eclass') diff --git a/eclass/depend.php.eclass b/eclass/depend.php.eclass index 86502e851ccb..c917b41a8f27 100644 --- a/eclass/depend.php.eclass +++ b/eclass/depend.php.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/depend.php.eclass,v 1.14 2006/05/05 21:42:16 chtekk Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/depend.php.eclass,v 1.15 2006/05/13 15:39:11 chtekk Exp $ # # ======================================================================== # @@ -204,17 +204,25 @@ require_php_with_use() { fi done - if [[ -z ${missing_use} ]] ; then - return + if [[ -z "${missing_use}" ]] ; then + if [[ -z "${PHPCHECKNODIE}" ]] ; then + return + else + return 0 + fi fi - eerror - eerror "${PHP_PKG} needs to be re-installed with all of the following" - eerror "USE flags enabled:" - eerror - eerror " $@" - eerror - die "Missing PHP USE flags found" + if [[ -z "${PHPCHECKNODIE}" ]] ; then + eerror + eerror "${PHP_PKG} needs to be re-installed with all of the following" + eerror "USE flags enabled:" + eerror + eerror " $@" + eerror + die "Missing PHP USE flags found" + else + return 1 + fi } # Call this function from pkg_setup if your package requires PHP compiled @@ -242,17 +250,25 @@ require_php_with_any_use() { fi done - if [[ -z ${missing_use} ]] ; then - return + if [[ -z "${missing_use}" ]] ; then + if [[ -z "${PHPCHECKNODIE}" ]] ; then + return + else + return 0 + fi fi - eerror - eerror "${PHP_PKG} needs to be re-installed with any of the following" - eerror "USE flags enabled:" - eerror - eerror " $@" - eerror - die "Missing PHP USE flags found" + if [[ -z "${PHPCHECKNODIE}" ]] ; then + eerror + eerror "${PHP_PKG} needs to be re-installed with any of the following" + eerror "USE flags enabled:" + eerror + eerror " $@" + eerror + die "Missing PHP USE flags found" + else + return 1 + fi } # ======================================================================== -- cgit v1.2.3-65-gdbad