Gentoo Archives: gentoo-python

From: Mike Gilbert <floppym@g.o>
To: "Tomáš Chvátal" <tomas.chvatal@×××××.com>
Cc: python@g.o, gentoo-python <gentoo-python@l.g.o>
Subject: [gentoo-python] Re: eclass patch to fix test rdepend
Date: Fri, 29 Jun 2012 18:15:41
Message-Id: CAJ0EP437WMZkU=fuF74xtAVE2Vp6UP4aCsmoRSVKvb4q3eN+WA@mail.gmail.com
On Fri, Jun 29, 2012 at 8:04 AM, Tomáš Chvátal <tomas.chvatal@×××××.com> wrote:
> Hi guys, > > I have package that uses python only during the test phase -> test > conditional needed. > > Eclass currently adds the use conditional to depend and rdepend so I > would propose two choices > 1) detect some set of build only useflags, like the test and skip > rdepend assignment on them > > Index: python.eclass > =================================================================== > RCS file: /var/cvsroot/gentoo-x86/eclass/python.eclass,v > retrieving revision 1.155 > diff -u -b -B -r1.155 python.eclass > --- python.eclass       9 Jun 2012 10:01:19 -0000       1.155 > +++ python.eclass       29 Jun 2012 12:03:37 -0000 > @@ -247,10 +247,10 @@ > >                if [[ "${#_PYTHON_ATOMS[@]}" -gt 1 ]]; then >                        DEPEND+="${DEPEND:+ }${USE_flag}${USE_flag:+? > ( }|| ( ${_PYTHON_ATOMS[@]} )${USE_flag:+ )}" > -                       RDEPEND+="${RDEPEND:+ > }${USE_flag}${USE_flag:+? ( }|| ( ${_PYTHON_ATOMS[@]} )${USE_flag:+ > )}" > +                       [[ ${USE_flag} == test ]] || > RDEPEND+="${RDEPEND:+ }${USE_flag}${USE_flag:+? ( }|| ( > ${_PYTHON_ATOMS[@]} )${USE_flag:+ )}" >                else >                        DEPEND+="${DEPEND:+ }${USE_flag}${USE_flag:+? > ( }${_PYTHON_ATOMS[@]}${USE_flag:+ )}" > -                       RDEPEND+="${RDEPEND:+ > }${USE_flag}${USE_flag:+? ( }${_PYTHON_ATOMS[@]}${USE_flag:+ )}" > +                       [[ ${USE_flag} == test ]] || > RDEPEND+="${RDEPEND:+ }${USE_flag}${USE_flag:+? ( > }${_PYTHON_ATOMS[@]}${USE_flag:+ )}" >                fi >        else >                die "Invalid syntax of PYTHON_DEPEND" > > > 2) provide something like PYTHON_DEPEND_ONLY variable. > > You write the patch. > > Please let me know what you guys decide to do as i have to atler my > ebuild if you decide to go with number two. > > Cheers > > Tom
Arfrever has a patch implementing PYTHON_BDEPEND (build-time only deps). Nobody has cared enough to apply it.