commit:     923c0abe8ef9951a2a89e487ffb897dd712ae66a
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 12 13:19:51 2021 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Fri Mar 12 15:13:26 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=923c0abe

mozcoreconf-v6.eclass: Support EAPI-7, define @SUPPORTED_EAPIS

Bug: https://bugs.gentoo.org/770280
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 eclass/mozcoreconf-v6.eclass | 23 ++++++++++++++++++-----
 1 file changed, 18 insertions(+), 5 deletions(-)

diff --git a/eclass/mozcoreconf-v6.eclass b/eclass/mozcoreconf-v6.eclass
index 0dd165db08e..95fce0f0258 100644
--- a/eclass/mozcoreconf-v6.eclass
+++ b/eclass/mozcoreconf-v6.eclass
@@ -1,9 +1,10 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 #
 # @ECLASS: mozcoreconf-v6.eclass
 # @MAINTAINER:
 # Mozilla team <mozi...@gentoo.org>
+# @SUPPORTED_EAPIS: 6 7
 # @BLURB: core options and configuration functions for mozilla
 # @DESCRIPTION:
 #
@@ -16,14 +17,26 @@
 
 if [[ ! ${_MOZCORECONF} ]]; then
 
-inherit multilib toolchain-funcs flag-o-matic python-any-r1 versionator
+inherit toolchain-funcs flag-o-matic python-any-r1
 
-IUSE="${IUSE} custom-cflags custom-optimization"
-
-DEPEND="virtual/pkgconfig
+BDEPEND="virtual/pkgconfig
        dev-lang/python:2.7[ncurses,sqlite,ssl,threads(+)]
        ${PYTHON_DEPS}"
 
+case "${EAPI:-0}" in
+       6)
+               inherit multilib versionator
+               DEPEND+=" ${BDEPEND}"
+               ;;
+       7)
+               ;;
+       *)
+               die "EAPI ${EAPI} is not supported, contact eclass maintainers"
+               ;;
+esac
+
+IUSE="${IUSE} custom-cflags custom-optimization"
+
 # @FUNCTION: mozconfig_annotate
 # @DESCRIPTION:
 # add an annotated line to .mozconfig

Reply via email to