From 65c7e1fca3a48c10f237e41528ac3c2382645ab1 Mon Sep 17 00:00:00 2001 From: Sam James Date: Sun, 20 Jun 2021 23:15:01 +0200 Subject: php-ext-pecl-r3.eclass: [QA] add EAPI guard Signed-off-by: Sam James Signed-off-by: David Seifert --- eclass/php-ext-pecl-r3.eclass | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'eclass/php-ext-pecl-r3.eclass') diff --git a/eclass/php-ext-pecl-r3.eclass b/eclass/php-ext-pecl-r3.eclass index 19040a7e762b..eaf20e026f90 100644 --- a/eclass/php-ext-pecl-r3.eclass +++ b/eclass/php-ext-pecl-r3.eclass @@ -5,11 +5,22 @@ # @MAINTAINER: # Gentoo PHP team # @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 -- cgit v1.2.3-65-gdbad