Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 402108 Details for
Bug 547898
dev-java/java-config: make depend-java-query accept wider range of version values
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
A propoused patch to fix the issue
file_547898.txt (text/plain), 1.84 KB, created by
Fat-Zer
on 2015-04-27 12:39:56 UTC
(
hide
)
Description:
A propoused patch to fix the issue
Filename:
MIME Type:
Creator:
Fat-Zer
Created:
2015-04-27 12:39:56 UTC
Size:
1.84 KB
patch
obsolete
>--- src/java_config_2/VersionManager.py.old 2013-02-15 02:12:09.000000000 +0400 >+++ src/java_config_2/VersionManager.py 2015-04-27 15:36:02.467389500 +0300 >@@ -51,7 +51,7 @@ > """ > Used to parse dependency strings, and find the best/prefered vm to use. > """ >- atom_parser = re.compile(r"([<>=]*)virtual/(jre|jdk)[-:]([0-9\.*]+)") >+ atom_parser = re.compile(r"([<>=]*)virtual/(jre|jdk)(-([0-9\.*]+))?(:([0-9\.]+=?|=|\*))?") > virtuals_parser = re.compile(r"([<>=~]+)?java-virtuals/([\w\-\.:]+)") > package_parser = re.compile(r"([\w\-]+)/([\w\-]+)(?:\:(\d+))?") > >@@ -88,7 +88,17 @@ > > if len(matches) > 0: > for match in matches: >- matched_atoms.append(_DepSpec(equality=match[0], type=match[1], version=match[2])) >+ equality=match[0] >+ if match[3]: # if version is nonempty use it >+ ver = match[3] >+ elif match[5] and match[5] != "=" and match[5] != '*': # fallback to probe the slot value >+ ver = match[5] >+ if ver[-1] == '=': >+ ver = ver[:-1] >+ else: >+ equality='*' # match case without version in a special way >+ ver='0' >+ matched_atoms.append(_DepSpec(equality=equality, type=match[1], version=ver)) > > matched_atoms.sort() > matched_atoms.reverse() >@@ -149,7 +159,8 @@ > > #now assuming that if no operator we are > #doing an '=' comparision. Used to handle cases like virtual/jdk:1.5 >- if operator == '>=': return val >= 0 >+ if operator == '*': return True >+ elif operator == '>=': return val >= 0 > elif operator == '<=': return val <= 0 > elif operator == '>': return val > 0 > elif operator == '<': return val < 0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 547898
: 402108