eutils.eclass: Disable eqawarn in EAPI 7.
authorUlrich Müller <ulm@gentoo.org>
Fri, 10 Aug 2018 16:36:47 +0000 (18:36 +0200)
committerUlrich Müller <ulm@gentoo.org>
Wed, 15 Aug 2018 07:05:46 +0000 (09:05 +0200)
The eqawarn command is part of EAPI 7, therefore the eclass should not
override it. Also we cannot rely on its being a shell function.

eclass/eutils.eclass

index 9b4767e1874af58b390bf2df1e77fcbb786c3a80..e5d0ebeebb0659d434da525baa7c602bb21df0c6 100644 (file)
@@ -25,19 +25,6 @@ case ${EAPI:-0} in
        ;;
 esac
 
-# @FUNCTION: eqawarn
-# @USAGE: [message]
-# @DESCRIPTION:
-# Proxy to ewarn for package managers that don't provide eqawarn and use the PM
-# implementation if available. Reuses PORTAGE_ELOG_CLASSES as set by the dev
-# profile.
-if ! declare -F eqawarn >/dev/null ; then
-       eqawarn() {
-               has qa ${PORTAGE_ELOG_CLASSES} && ewarn "$@"
-               :
-       }
-fi
-
 # @FUNCTION: emktemp
 # @USAGE: [temp dir]
 # @DESCRIPTION:
@@ -415,4 +402,23 @@ in_iuse() {
 ;;
 esac
 
+case ${EAPI:-0} in
+0|1|2|3|4|5|6)
+
+# @FUNCTION: eqawarn
+# @USAGE: [message]
+# @DESCRIPTION:
+# Proxy to ewarn for package managers that don't provide eqawarn and use the PM
+# implementation if available. Reuses PORTAGE_ELOG_CLASSES as set by the dev
+# profile.
+if ! declare -F eqawarn >/dev/null ; then
+       eqawarn() {
+               has qa ${PORTAGE_ELOG_CLASSES} && ewarn "$@"
+               :
+       }
+fi
+
+;;
+esac
+
 fi