Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 408941 - app-portage/gentoolkit-0.3.0.5: euse doesn't properly detect all package atoms
Summary: app-portage/gentoolkit-0.3.0.5: euse doesn't properly detect all package atoms
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Third-Party Tools (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Portage Tools Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 346443
  Show dependency tree
 
Reported: 2012-03-20 04:05 UTC by Paul Varner (RETIRED)
Modified: 2012-05-16 22:07 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Varner (RETIRED) gentoo-dev 2012-03-20 04:05:26 UTC
From email sent to tools-portage:

# euse -p sys-fs/ntfs3g ntfsprogs
ERROR: Invalid package atom. Did you forget the leading '='?
#

# atom_re="^[<>]?=?([a-z][\da-z/-]+[a-z])(-[0-9pr._*-]+)?";echo
"sys-fs/ntfs3g" | sed -re "s/${atom_re}/\1/"
sys-fs/ntfs3g
#

# atom_re="^[<>]?=?([a-z][\da-z/-]+[a-z])(-[0-9pr._*-]+)?";echo
"sys-fs/ntfs3g" | sed -re "s/${atom_re}/\2/"
3g
#

# atom_re="^[<>]?=?([a-z][\da-z\/-]+[a-z])(-[0-9pr._*-]+)?";echo
"=sys-fs/ntfs3g-3.3.1" | sed -re "s/${atom_re}/\1/"
sys-fs/ntfs3g-3.3.1 
#

# atom_re="^[<>]?=?([a-z][\da-z\/-]+[a-z])(-[0-9pr._*-]+)?";echo
"=sys-fs/ntfs3g-3.3.1" | sed -re "s/${atom_re}/\2/"
3g-3.3.1
#
# atom_re="^[<>]?=?([a-z][0-9a-z\/-]+[a-z])(-[0-9pr._*-]+)?";echo
"=sys-fs/ntfs3g-3.3.1" | sed -re "s/${atom_re}/\1/"
sys-fs/ntfs3g

# atom_re="^[<>]?=?([a-z][0-9a-z\/-]+[a-z])(-[0-9pr._*-]+)?";echo
"=sys-fs/ntfs3g-3.3.1" | sed -re "s/${atom_re}/\2/"
-3.3.1
#

# diff -u /usr/bin/euse.bad /usr/bin/euse
--- /usr/bin/euse.bad    2012-03-14 13:59:19.053133461 +0400
+++ /usr/bin/euse    2012-03-14 13:59:57.055660607 +0400
@@ -1034,7 +1034,7 @@
 modify_package() {
     get_useflags
 
-    local atom_re="^[<>]?=?([a-z][\da-z/-]+[a-z])(-[0-9pr._*-]+)?"
+    local atom_re="^[<>]?=?([a-z][0-9a-z/-]+[a-z])(-[0-9pr._*-]+)?"
     local pkg=$(echo "${PACKAGE}" | sed -re "s/${atom_re}/\1/")
     local V=$(echo "${PACKAGE}" | sed -re "s/${atom_re}/\2/")
     local pkg_re="[<>]?=?${pkg}(-[\dpr._*-]+)?"
#

# euse -p sys-fs/ntfs3g ntfsprogs
Adding "sys-fs/ntfs3g[ntfsprogs]" use flag in "/etc/portage/package.use"
#


Best regards
Vitaly Shimansky

Patch was applied in the following commit:
http://git.overlays.gentoo.org/gitweb/?p=proj/gentoolkit.git;a=commit;h=1ec0b2f81f2186c10411240a3b590c67dc341e1b
Comment 1 Paul Varner (RETIRED) gentoo-dev 2012-05-16 22:07:27 UTC
This was released in gentoolkit-0.3.0.6