commit:     ae70ffefbe473b4f4d0a2a69b2cec814ded13681
Author:     Benda Xu <heroxbd <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 17 16:40:14 2019 +0000
Commit:     Benda XU <heroxbd <AT> gentoo <DOT> org>
CommitDate: Sat Aug 17 16:40:14 2019 +0000
URL:        https://gitweb.gentoo.org/proj/R_overlay.git/commit/?id=ae70ffef

[USE] in the DEPEND should be extracted.

Example: tk? ( dev-lang/R[tk] ), not r[tk]?.

 roverlay/ebuild/evars.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/roverlay/ebuild/evars.py b/roverlay/ebuild/evars.py
index 6ec6a2e..c2e355d 100644
--- a/roverlay/ebuild/evars.py
+++ b/roverlay/ebuild/evars.py
@@ -96,9 +96,7 @@ class UseExpandListValue (
    RE_USENAME = re.compile (
       (
          '(?P<prefix>.*[/])?'
-         '(?P<pf>'
-            '((?P<pn>.*)(?P<pvr>[-][0-9].*([-]r[0-9]+)?))'
-         '|.*)'
+         
'(?P<pn>[^\[]*)(\[(?P<use>[^\]]*)\])?(?P<pvr>[-][0-9].*([-]r[0-9]+)?)?'
       )
    )
 
@@ -128,7 +126,7 @@ class UseExpandListValue (
       match = self.__class__.RE_USENAME.match ( dep.dep )
       if match:
          return self._get_use_key (
-            ( match.group ( "pn" ) or match.group ( "pf" ) )
+            ( match.group ( "use" ) or match.group ( "pn" ) )
          )
       else:
          raise ValueError (

Reply via email to