From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 3A5EF139694 for ; Fri, 24 Mar 2017 20:45:03 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 7698921C0FA; Fri, 24 Mar 2017 20:44:54 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 2CC8221C08B for ; Fri, 24 Mar 2017 20:44:54 +0000 (UTC) Received: from localhost.localdomain (d202-252.icpnet.pl [109.173.202.252]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: mgorny) by smtp.gentoo.org (Postfix) with ESMTPSA id 4B27034165C; Fri, 24 Mar 2017 20:44:52 +0000 (UTC) From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= To: gentoo-dev@lists.gentoo.org Cc: base-system@gentoo.org, =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Subject: [gentoo-dev] [PATCH] toolchain-glibc.eclass: Replace evar_* with local variables Date: Fri, 24 Mar 2017 21:44:46 +0100 Message-Id: <20170324204446.23944-1-mgorny@gentoo.org> X-Mailer: git-send-email 2.12.1 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Archives-Salt: 34ee8efc-1fd0-4c76-aae2-a2af0d73ab05 X-Archives-Hash: e08bbb740ee6943ecd0b17a7540f4a10 Use local variable to limit the scope of ABI variable override. This is a builtin bash solution that is reliable and simple, unlike the complex evar_* logic that unnecessarily pollutes global variables. --- eclass/toolchain-glibc.eclass | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/eclass/toolchain-glibc.eclass b/eclass/toolchain-glibc.eclass index d410775759df..365198303e8f 100644 --- a/eclass/toolchain-glibc.eclass +++ b/eclass/toolchain-glibc.eclass @@ -381,15 +381,13 @@ foreach_abi() { else abilist=${DEFAULT_ABI} fi - evar_push ABI - export ABI + local -x ABI for ABI in ${abilist:-default} ; do setup_env einfo "Running $1 for ABI ${ABI}" $1 : $(( ret |= $? )) done - evar_pop return ${ret} } -- 2.12.1