From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 4CD7413877A for ; Sun, 22 Jun 2014 18:28:20 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D8740E09CC; Sun, 22 Jun 2014 18:28:19 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 723A7E09CC for ; Sun, 22 Jun 2014 18:28:19 +0000 (UTC) Received: from spoonbill.gentoo.org (spoonbill.gentoo.org [81.93.255.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id B601D33BF13 for ; Sun, 22 Jun 2014 18:28:17 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by spoonbill.gentoo.org (Postfix) with ESMTP id 49F0D18EB2 for ; Sun, 22 Jun 2014 18:28:16 +0000 (UTC) From: "Davide Pesavento" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Davide Pesavento" Message-ID: <1403461606.5a8c47c59332c1a7d63cca6878575b61ea22773f.pesa@gentoo> Subject: [gentoo-commits] proj/qt:master commit in: eclass/ X-VCS-Repository: proj/qt X-VCS-Files: eclass/qt4-build-multilib.eclass X-VCS-Directories: eclass/ X-VCS-Committer: pesa X-VCS-Committer-Name: Davide Pesavento X-VCS-Revision: 5a8c47c59332c1a7d63cca6878575b61ea22773f X-VCS-Branch: master Date: Sun, 22 Jun 2014 18:28:16 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 0fb36ce7-e6b8-455b-9f59-5756f3b8e7e8 X-Archives-Hash: f3b03daab3e4bb827ba75e6532c1fee7 commit: 5a8c47c59332c1a7d63cca6878575b61ea22773f Author: Davide Pesavento gentoo org> AuthorDate: Sun Jun 22 18:26:46 2014 +0000 Commit: Davide Pesavento gentoo org> CommitDate: Sun Jun 22 18:26:46 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/qt.git;a=commit;h=5a8c47c5 [qt4-build-multilib] Provide qt_native_use() convenience function. --- eclass/qt4-build-multilib.eclass | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/eclass/qt4-build-multilib.eclass b/eclass/qt4-build-multilib.eclass index efa501c..c4a5562 100644 --- a/eclass/qt4-build-multilib.eclass +++ b/eclass/qt4-build-multilib.eclass @@ -470,14 +470,24 @@ qt4-build-multilib_pkg_postrm() { # @FUNCTION: qt_use # @USAGE: [feature] [enableval] # @DESCRIPTION: -# This will echo "-${enableval}-${feature}" if is enabled, or -# "-no-${feature}" if it's disabled. If [feature] is not specified, -# will be used for that. If [enableval] is not specified, the -# "-${enableval}" prefix is omitted. +# Outputs "-${enableval}-${feature}" if is enabled, "-no-${feature}" +# otherwise. If [feature] is not specified, 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}" } +# @FUNCTION: qt_native_use +# @USAGE: [feature] [enableval] +# @DESCRIPTION: +# Outputs "-${enableval}-${feature}" if is enabled and we are currently +# building for the native ABI, "-no-${feature}" otherwise. If [feature] is not +# specified, 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}" +} + ###### Internal functions ######