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.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 8EEEF1581D8 for ; Wed, 4 Dec 2024 01:39:10 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9AD84E0827; Wed, 4 Dec 2024 01:39:05 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id C5F85E07EF for ; Wed, 4 Dec 2024 01:39:04 +0000 (UTC) Message-ID: <3a9b84bc-2cf0-40cf-abef-60f3d953892f@gentoo.org> Date: Wed, 4 Dec 2024 11:38:54 +1000 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-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [gentoo-dev] [PATCH] rust.eclass: add ERUST_{SLOT,TYPE} user variables To: gentoo-dev@lists.gentoo.org References: <20241203122236.1592666-2-kangie@gentoo.org> <2d6823930bf7b81f235f326d7a40482275ef7b6e.camel@gentoo.org> Content-Language: en-US From: Matt Jolly Autocrypt: addr=kangie@gentoo.org; keydata= xsFNBF6BjksBEAC1QaqF3zKOgdunRhkt9nXkdlsL1sriTBk3WSy4De6wYLjiSofGRJY5pAiH EnlD/oW+sxDQ1DQQ3jNW/xlLUKFKY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w75JFpUkAEQEAAcLBfAQYAQoAJgIbDBYhBN23wrwXzwOts4+cFlDsVI1S4FHABQJld9e9 BQkLmM9yAAoJEFDsVI1S4FHApS8P/2Dovmb516e0PcmYvVoN835cEBgUEQc0lnQAYuNRIPgI CMfNfeZTRdANzyPYYdp+VQCzj95mUt4qlY0PkEGOR1b+2bjeyqp/zAHQShft7FHpsgeRObaW lKE6q9xwUGsOoOcBsWZiwd4xvalIaBG6uczlTrSGJycTF21c35pP6o/eiQs2d/qIVBUMdAtw kefO+pYds1YoyNW2YxGLThWAqNYoThGFsfOqrvLR2HWOcFeneR+PXx2loGdrHE/D6QXpVXxk qRNPig8E68gAVX7q8eRr5+bkJBrG2QvVsc0opiW6AljCJC0gJt5nuHKOObDAmoGx2PuRppT4 +wGd1yCElUZ602Opuf2gqS2nxSypf568EIcoSMEzbJFLrAoy3MReTMoltAJVJU8sA9OXYSOg AjHg7aU/nmO8KFHIZMiW24XJ577iU48UV+u8Rpmv4y16uAhp8AI4wvkk6xa5tNcCWU1Ati6Y yrdk2hf9dD29ePUkHKKSfbewr+qZ9dRL1dUXsaGa64oOXmUALxGNNzj7V828PbWa16x3JbYi gwBNqcgATaAZgDrXMV9ynB4aU1eSNNs/1R0Ic6B7c9yWaI568V7XKldus1QclpELQ4Lu+r/F H065qJMw4LqNs4gEDgd3JzNiNC0Jy+I8mD73YSeo87mE1KOCY0f9DNaBJ+v32E+Z In-Reply-To: <2d6823930bf7b81f235f326d7a40482275ef7b6e.camel@gentoo.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Archives-Salt: a6757125-17a9-4927-88dc-9deee470c13d X-Archives-Hash: 640f5bfcc7a5cf28326a6e79813e3d35 Hi Michał, Sure. No worries - Given the trivial nature I'll update the variable before merging rather than sending a V2 unless there's other feedback that requires it. :) On 3/12/24 23:26, Michał Górny wrote: > On Tue, 2024-12-03 at 22:22 +1000, kangie@gentoo.org wrote: >> From: Matt Jolly >> >> These variables enable users (though most likely Gentoo developers) >> to override the selection of the Rust implementation by the eclass. >> >> This means that _only_ the specified ERUST_SLOT and/or ERUST_TYPE >> ('source' or 'binary') will be checked for, with the eclass `die`ing >> with "No Rust slot satisfying the package's dependencies..." if the >> selected impl is not available. >> >> These variables are intended to enable reproducing bugs and testing >> packages against specific dev-lang/rust{,-bin} packages; they must >> not be set in ebuilds. >> >> Closes: https://bugs.gentoo.org/945752 >> Signed-off-by: Matt Jolly >> --- >> eclass/rust.eclass | 49 +++++++++++++++++++++++++++++++++++++++++----- >> 1 file changed, 44 insertions(+), 5 deletions(-) >> >> diff --git a/eclass/rust.eclass b/eclass/rust.eclass >> index 71cbb4b24f8c..991a9cdb7f14 100644 >> --- a/eclass/rust.eclass >> +++ b/eclass/rust.eclass >> @@ -98,6 +98,26 @@ declare -a -g -r _RUST_SLOTS_ORDERED=( >> "1.54.0" >> ) >> >> +# == user control knobs == >> + >> +# @ECLASS_VARIABLE: ERUST_SLOT >> +# @USER_VARIABLE >> +# @DESCRIPTION: >> +# Specify the version (slot) of Rust to be used by the package. This is >> +# useful for troubleshooting and debugging purposes; If unset, the newest >> +# acceptable Rust version will be used. May be combined with ERUST_TYPE. >> +# This variable must not be set in ebuilds. >> + >> +# @ECLASS_VARIABLE: ERUST_TYPE >> +# @USER_VARIABLE >> +# @DESCRIPTION: >> +# Specify the type of Rust to be used by the package from options: >> +# 'source' or 'binary' (-bin). This is useful for troubleshooting and >> +# debugging purposes. If unset, the standard eclass logic will be used >> +# to determine the type of Rust to use (i.e. prefer source if binary >> +# is also available). May be combined with ERUST_SLOT. >> +# This variable must not be set in ebuilds. > > Could you perhaps add 'OVERRIDE' to the names, to make it clear they're > not supposed to be normally used? Just like we have > PYTHON_COMPAT_OVERRIDE in Python eclasses. >