diff options
author | 2015-06-11 18:33:54 +0000 | |
---|---|---|
committer | 2015-06-11 18:33:54 +0000 | |
commit | a2f377831e8627a3ccb5c648e8e3f17a88515fb9 (patch) | |
tree | f92f40c7810eed57d116ec7a2302ec1956f8f440 /eclass | |
parent | adding for the needful (diff) | |
download | gentoo-2-a2f377831e8627a3ccb5c648e8e3f17a88515fb9.tar.gz gentoo-2-a2f377831e8627a3ccb5c648e8e3f17a88515fb9.tar.bz2 gentoo-2-a2f377831e8627a3ccb5c648e8e3f17a88515fb9.zip |
Use usex().
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/ChangeLog | 5 | ||||
-rw-r--r-- | eclass/qt4-build-multilib.eclass | 16 |
2 files changed, 16 insertions, 5 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog index 99ef0d625996..55f394324e44 100644 --- a/eclass/ChangeLog +++ b/eclass/ChangeLog @@ -1,6 +1,9 @@ # ChangeLog for eclass directory # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1651 2015/06/10 18:08:02 grknight Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1652 2015/06/11 18:33:54 pesa Exp $ + + 11 Jun 2015; Davide Pesavento <pesa@gentoo.org> qt4-build-multilib.eclass: + Use usex(). 10 Jun 2015; <grknight@gentoo.org> mysql-multilib.eclass: Resolve cirucular dependency for bug 551686; Make USE=cluster die early for diff --git a/eclass/qt4-build-multilib.eclass b/eclass/qt4-build-multilib.eclass index 2984489ac2bc..68971a25372f 100644 --- a/eclass/qt4-build-multilib.eclass +++ b/eclass/qt4-build-multilib.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build-multilib.eclass,v 1.19 2015/06/09 21:12:50 pesa Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build-multilib.eclass,v 1.20 2015/06/11 18:33:54 pesa Exp $ # @ECLASS: qt4-build-multilib.eclass # @MAINTAINER: @@ -368,7 +368,7 @@ qt4_multilib_src_configure() { -nomake demos # disable rpath on non-prefix (bugs 380415 and 417169) - $(use prefix || echo -no-rpath) + $(usex prefix '' -no-rpath) # verbosity of the configure and build phases -verbose $(${QT4_VERBOSE_BUILD} || echo -silent) @@ -531,22 +531,30 @@ qt4-build-multilib_pkg_postrm() { # @FUNCTION: qt_use # @USAGE: <flag> [feature] [enableval] # @DESCRIPTION: +# <flag> is the name of a flag in IUSE. +# # Outputs "-${enableval}-${feature}" if <flag> is enabled, "-no-${feature}" # otherwise. If [feature] is not specified, <flag> is used in its place. # If [enableval] is not specified, the "-${enableval}" prefix is omitted. qt_use() { - use "$1" && echo "${3:+-$3}-${2:-$1}" || echo "-no-${2:-$1}" + [[ $# -ge 1 ]] || die "${FUNCNAME}() requires at least one argument" + + usex "$1" "${3:+-$3}-${2:-$1}" "-no-${2:-$1}" } # @FUNCTION: qt_native_use # @USAGE: <flag> [feature] [enableval] # @DESCRIPTION: +# <flag> is the name of a flag in IUSE. +# # Outputs "-${enableval}-${feature}" if <flag> is enabled and we are currently # building for the native ABI, "-no-${feature}" otherwise. If [feature] is not # specified, <flag> is used in its place. If [enableval] is not specified, # the "-${enableval}" prefix is omitted. qt_native_use() { - multilib_is_native_abi && use "$1" && echo "${3:+-$3}-${2:-$1}" || echo "-no-${2:-$1}" + [[ $# -ge 1 ]] || die "${FUNCNAME}() requires at least one argument" + + multilib_is_native_abi && qt_use "$@" || echo "-no-${2:-$1}" } |