From 5950a7618a2e5c801250ef648e7070bd7a3c13e7 Mon Sep 17 00:00:00 2001 From: Michał Górny Date: Fri, 1 Jan 2016 13:38:11 +0100 Subject: scons-utils.eclass: Deprecate use_scons, ban it in EAPI 6 --- eclass/scons-utils.eclass | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'eclass') diff --git a/eclass/scons-utils.eclass b/eclass/scons-utils.eclass index fdc6af3db63a..b8051b04bf81 100644 --- a/eclass/scons-utils.eclass +++ b/eclass/scons-utils.eclass @@ -79,11 +79,15 @@ # @ECLASS-VARIABLE: USE_SCONS_TRUE # @DESCRIPTION: +# DEPRECATED: use usex instead +# # The default value for truth in scons-use() (1 by default). : ${USE_SCONS_TRUE:=1} # @ECLASS-VARIABLE: USE_SCONS_FALSE # @DESCRIPTION: +# DEPRECATED: use usex instead +# # The default value for false in scons-use() (0 by default). : ${USE_SCONS_FALSE:=0} @@ -236,6 +240,8 @@ scons_clean_makeopts() { # @FUNCTION: use_scons # @USAGE: [var-name] [var-opt-true] [var-opt-false] # @DESCRIPTION: +# DEPRECATED, EAPI 0..5 ONLY: use usex instead +# # Output a SCons parameter with value depending on the USE flag state. # If the USE flag is set, output =; otherwise # =. @@ -247,6 +253,9 @@ scons_clean_makeopts() { # If and/or are omitted, # ${USE_SCONS_TRUE} and/or ${USE_SCONS_FALSE} will be used instead. use_scons() { + [[ ${EAPI} == [012345] ]] \ + || die "${FUNCNAME} is banned in EAPI ${EAPI}, use usex instead" + local flag=${1} local varname=${2:-${flag/\!/no}} local vartrue=${3:-${USE_SCONS_TRUE}} -- cgit v1.2.3-65-gdbad