Re: [gentoo-dev] [PATCH v2 2/3] virtualx.eclass: Make VIRTUALX_DEPEND readonly in EAPI-8
On Mittwoch, 4. August 2021 12:29:40 CEST Ulrich Mueller wrote: > > On Wed, 04 Aug 2021, Andreas Sturmlechner wrote: > > +# Standard dependencies string that is automatically added to BDEPEND > > +# (in EAPI-6: DEPEND) unless VIRTUALX_REQUIRED is set to "manual". > > +# DEPRECATED: Pre-EAPI-8 you can specify the variable BEFORE inherit > > +# to add more dependencies. > > +[[ ${EAPI} == [67] ]] || VIRTUALX_DEPEND="" > > +VIRTUALX_DEPEND+=" > > > > x11-base/xorg-server[xvfb] > > x11-apps/xhost > > > > " > > > > +[[ ${EAPI} == [67] ]] || readonly VIRTUALX_DEPEND > > I wonder about this one, because the *DEPEND variables are automatically > accumulated across eclasses and ebuild. What is the advantage of the > ebuild specifying VIRTUALX_DEPEND, instead of specifying BDEPEND > directly? > The answer is in the updated description in this patch: ebuilds/eclasses specifying VIRTUALX_REQUIRED=manual have (so far) been relying on the content of VIRTUALX_DEPEND to add the standard dependencies from within the ebuild instead of having virtualx.eclass do it for them, for whatever complex dependency situation they might have. signature.asc Description: This is a digitally signed message part.
Re: [gentoo-dev] [PATCH v2 2/3] virtualx.eclass: Make VIRTUALX_DEPEND readonly in EAPI-8
> On Wed, 04 Aug 2021, Andreas Sturmlechner wrote: > +# Standard dependencies string that is automatically added to BDEPEND > +# (in EAPI-6: DEPEND) unless VIRTUALX_REQUIRED is set to "manual". > +# DEPRECATED: Pre-EAPI-8 you can specify the variable BEFORE inherit > +# to add more dependencies. > +[[ ${EAPI} == [67] ]] || VIRTUALX_DEPEND="" > +VIRTUALX_DEPEND+=" > x11-base/xorg-server[xvfb] > x11-apps/xhost > " > +[[ ${EAPI} == [67] ]] || readonly VIRTUALX_DEPEND I wonder about this one, because the *DEPEND variables are automatically accumulated across eclasses and ebuild. What is the advantage of the ebuild specifying VIRTUALX_DEPEND, instead of specifying BDEPEND directly? Ulrich signature.asc Description: PGP signature
[gentoo-dev] [PATCH v2 2/3] virtualx.eclass: Make VIRTUALX_DEPEND readonly in EAPI-8
Any additional dependencies shall be defined inside ebuilds instead. Signed-off-by: Andreas Sturmlechner --- eclass/virtualx.eclass | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/eclass/virtualx.eclass b/eclass/virtualx.eclass index 155d611e66e..ad376c497ac 100644 --- a/eclass/virtualx.eclass +++ b/eclass/virtualx.eclass @@ -29,14 +29,18 @@ _VIRTUALX_ECLASS=1 : ${VIRTUALX_REQUIRED:=test} # @ECLASS-VARIABLE: VIRTUALX_DEPEND +# @DEFAULT_UNSET # @DESCRIPTION: -# Dep string available for use outside of eclass, in case a more -# complicated dep is needed. -# You can specify the variable BEFORE inherit to add more dependencies. -VIRTUALX_DEPEND="${VIRTUALX_DEPEND} +# Standard dependencies string that is automatically added to BDEPEND +# (in EAPI-6: DEPEND) unless VIRTUALX_REQUIRED is set to "manual". +# DEPRECATED: Pre-EAPI-8 you can specify the variable BEFORE inherit +# to add more dependencies. +[[ ${EAPI} == [67] ]] || VIRTUALX_DEPEND="" +VIRTUALX_DEPEND+=" x11-base/xorg-server[xvfb] x11-apps/xhost " +[[ ${EAPI} == [67] ]] || readonly VIRTUALX_DEPEND # @ECLASS-VARIABLE: VIRTUALX_COMMAND # @DESCRIPTION: -- 2.32.0 signature.asc Description: This is a digitally signed message part.