Initial path prefixes are incorrectly stripped for matching, but they should be preserved. All of the following commands match /bin directory: # qfile /bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... # qfile bla/bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... # qfile /bla/bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... # qfile bla/bla/bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... # qfile /bla/bla/bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... # qfile bla/bla/bla/bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... # qfile /bla/bla/bla/bin app-arch/bzip2 (/bin) app-arch/cpio (/bin) app-arch/gzip (/bin) app-arch/tar (/bin) ... The result of this bug is that `qfile /usr/bin` prints both packages which own /usr/bin and packages which own /bin: # qfile /usr/bin app-admin/apache-tools (/usr/bin) app-admin/eselect (/usr/bin) app-admin/sudo (/usr/bin) app-admin/syslog-ng (/usr/bin) app-arch/brotli (/usr/bin) app-arch/bzip2 (/bin) app-arch/bzip2 (/usr/bin) app-arch/cabextract (/usr/bin) app-arch/cpio (/bin) app-arch/gcab (/usr/bin) app-arch/gzip (/bin) app-arch/gzip (/usr/bin) app-arch/libarchive (/usr/bin) app-arch/p7zip (/usr/bin) app-arch/rpm2targz (/usr/bin) app-arch/tar (/bin) app-arch/unzip (/usr/bin) app-arch/xz-utils (/usr/bin) app-arch/zip (/usr/bin) ...
Question, is this behaviour new since 0.70 for you, or has it always been like this?
Ok, this is not new, and interestingly enough only hits non-Prefix systems.
For testing on Prefix system, try: cd ${EPREFIX} mkdir -p var/db/pkg/app-misc/aaa-0 echo "obj /aaa d41d8cd98f00b204e9800998ecf8427e 0" > var/db/pkg/app-misc/aaa-0/CONTENTS qfile /aaa qfile /bla/bla/aaa
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=23c09a20dfcc044343b16bfe4b5873f663a46286 commit 23c09a20dfcc044343b16bfe4b5873f663a46286 Author: Fabian Groffen <grobian@gentoo.org> AuthorDate: 2018-04-15 12:03:14 +0000 Commit: Fabian Groffen <grobian@gentoo.org> CommitDate: 2018-04-15 12:03:14 +0000 qfile: fix matching of files A bit overenthusiastic check for files in the current directory caused weird directory prefixes to be ignored. Bug: https://bugs.gentoo.org/652720 man/include/qfile-01-owners.include | 9 ++-- qfile.c | 94 ++++++++++++++++++++++--------------- 2 files changed, 60 insertions(+), 43 deletions(-)}
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=47d5c9788b9550078e17aad238fa03cabe20fd46 commit 47d5c9788b9550078e17aad238fa03cabe20fd46 Author: Fabian Groffen <grobian@gentoo.org> AuthorDate: 2018-05-18 12:27:07 +0000 Commit: Fabian Groffen <grobian@gentoo.org> CommitDate: 2018-05-18 12:27:23 +0000 app-portage/portage-utils: version bump to v0.71 Closes: https://bugs.gentoo.org/619988 Closes: https://bugs.gentoo.org/653202 Closes: https://bugs.gentoo.org/652312 Closes: https://bugs.gentoo.org/652720 Closes: https://bugs.gentoo.org/653032 Package-Manager: Portage-2.3.24, Repoman-2.3.6 app-portage/portage-utils/Manifest | 2 +- .../{portage-utils-0.65.ebuild => portage-utils-0.71.ebuild} | 8 -------- 2 files changed, 1 insertion(+), 9 deletions(-)