commit: 65c7e1fca3a48c10f237e41528ac3c2382645ab1 Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Sun Jun 20 21:15:01 2021 +0000 Commit: David Seifert <soap <AT> gentoo <DOT> org> CommitDate: Sun Jun 20 21:15:01 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=65c7e1fc
php-ext-pecl-r3.eclass: [QA] add EAPI guard Signed-off-by: Sam James <sam <AT> gentoo.org> Signed-off-by: David Seifert <soap <AT> gentoo.org> eclass/php-ext-pecl-r3.eclass | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/eclass/php-ext-pecl-r3.eclass b/eclass/php-ext-pecl-r3.eclass index 19040a7e762..eaf20e026f9 100644 --- a/eclass/php-ext-pecl-r3.eclass +++ b/eclass/php-ext-pecl-r3.eclass @@ -5,11 +5,22 @@ # @MAINTAINER: # Gentoo PHP team <php-b...@gentoo.org> # @BLURB: A uniform way to install PECL extensions +# @SUPPORTED_EAPIS: 6 7 # @DESCRIPTION: # This eclass should be used by all dev-php/pecl-* ebuilds as a uniform # way of installing PECL extensions. For more information about PECL, # see https://pecl.php.net/ +case ${EAPI:-0} in + [67]) ;; + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; +esac + +EXPORT_FUNCTIONS src_install src_test + +if [[ -z ${_PHP_EXT_PECL_R3_ECLASS} ]] ; then +_PHP_EXT_PECL_R3_ECLASS=1 + # @ECLASS-VARIABLE: PHP_EXT_PECL_PKG # @PRE_INHERIT # @DESCRIPTION: @@ -46,8 +57,6 @@ S="${WORKDIR}/${PHP_EXT_PECL_PKG_V}" inherit php-ext-source-r3 -EXPORT_FUNCTIONS src_install src_test - if [[ -z "${PHP_EXT_PECL_FILENAME}" ]] ; then SRC_URI="https://pecl.php.net/get/${PHP_EXT_PECL_PKG_V}.tgz" else @@ -85,3 +94,5 @@ php-ext-pecl-r3_src_test() { NO_INTERACTION="yes" emake test done } + +fi