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 24DD1139694 for ; Tue, 2 May 2017 21:49:38 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DA920E0E47; Tue, 2 May 2017 21:49:28 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (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 8B040E0E38 for ; Tue, 2 May 2017 21:49:28 +0000 (UTC) Received: from x51r2.ad.gaikai.biz (unknown [100.42.98.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: zmedico) by smtp.gentoo.org (Postfix) with ESMTPSA id 89C6B341683; Tue, 2 May 2017 21:49:26 +0000 (UTC) From: Zac Medico To: gentoo-dev@lists.gentoo.org Cc: python@gentoo.org, Zac Medico Subject: [gentoo-dev] [PATCH] python-utils-r1.eclass: support PYTHON_IMPLS_NO_STRICT variable Date: Tue, 2 May 2017 14:48:40 -0700 Message-Id: <20170502214840.10124-1-zmedico@gentoo.org> X-Mailer: git-send-email 2.10.2 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: a42e371d-afc0-4eaf-8621-26b82f938648 X-Archives-Hash: 283f8e6c847bf8aece1195a1ce944d1c This is intended to be set by the user when using ebuilds that may have unknown implementations in PYTHON_COMPAT. The assumption is that the ebuilds are intended to be used within multiple contexts which can involve revisions of this eclass that support different python implementations. --- eclass/python-utils-r1.eclass | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index 66a359e..1846da3 100644 --- a/eclass/python-utils-r1.eclass +++ b/eclass/python-utils-r1.eclass @@ -47,6 +47,21 @@ _PYTHON_ALL_IMPLS=( ) readonly _PYTHON_ALL_IMPLS +# @ECLASS-VARIABLE: PYTHON_IMPLS_NO_STRICT +# @DESCRIPTION: +# Tolerate unknown implementations in PYTHON_COMPAT. +# +# This is intended to be set by the user when using ebuilds that may +# have unknown implementations in PYTHON_COMPAT. The assumption is +# that the ebuilds are intended to be used within multiple contexts +# which can involve revisions of this eclass that support different +# python implementations. +# +# Example: +# @CODE +# PYTHON_IMPLS_NO_STRICT=1 +# @CODE + # @FUNCTION: _python_impl_supported # @USAGE: # @INTERNAL @@ -79,6 +94,7 @@ _python_impl_supported() { fi ;; *) + [[ -n ${PYTHON_IMPLS_NO_STRICT} ]] && return 1 die "Invalid implementation in PYTHON_COMPAT: ${impl}" esac } -- 2.10.2