strace shows it modifies the category: open("/usr/portage/portage/metadata/cache/1app-accessibility/SphinxTrain-0.9.1-r1", O_RDONLY) = -1 ENOENT (No such file or directory) write(2, "\33[31;01mimlate\33[00;00m: Failed t"..., 115imlate: Failed to read keywords for app-accessibility/SphinxTrain-0.9.1-r1 ) = 115 Portage 2.0.54-r2 (default-linux/x86/2006.0, gcc-3.4.5, glibc-2.3.6-r3, 2.6.16-xenxen i686) ================================================================= System uname: 2.6.16-xenxen i686 AMD Athlon(tm) XP 2800+ Gentoo Base System version 1.6.14 dev-lang/python: 2.4.2 dev-python/pycrypto: [Not Present] dev-util/ccache: [Not Present] dev-util/confcache: [Not Present] sys-apps/sandbox: 1.2.17 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1 sys-devel/binutils: 2.16.1 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.11-r2 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-march=athlon-xp -O2 -pipe -fomit-frame-pointer -mno-tls-direct-seg-refs" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/eselect/compiler /etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon-xp -O2 -pipe -fomit-frame-pointer -mno-tls-direct-seg-refs" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig collision-protect distlocks sandbox sfperms strict" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" LANG="de_DE.UTF-8" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="x86 X alsa apache2 apm arts avi berkdb bitmap-fonts bzip2 cli crypt cups dri eds emboss encode esd expat foomaticdb fortran gdbm gif gnome gpm gstreamer gtk gtk2 im lib ipv6 isdnlog jpeg kde libg++ libwww mad mikmod motif mp3 mpeg ncurses nls nptl ogg opengl oss pam pcre pdflib perl png pppd python qt quicktime readline reflection sdl session spell spl ssl tcpd truetype truetype-fonts type1-fonts udev unicode vorbis xml xmms xorg xv zlib userland_GNU kernel_linux elibc_glibc" Unset: ASFLAGS, CTARGET, INSTALL_MASK, LC_ALL, LDFLAGS, LINGUAS, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS, PORTAGE_RSYNC_OPTS, PORTDIR_OVERLAY
Besides PORTDIR, qimlate doesn't make use of any external variables. After putting a copy of the portage tree in /usr/portage/portage I tried with PORTDIR="/usr/portage/portage" and couldn't reproduce the problem. I'm also running the same version of portage as you. Could you run `ls /usr/portage/portage/metadata/cache/` and `ls /usr/portage/portage/metadata/cache/app-accessibility` and post the results on this bug?
PORTDIR="/usr/portage/portage/" qimlate x86 # works PORTDIR="/usr/portage/portage" qimlate x86 # doesn't work
Created attachment 86879 [details, diff] portage-utils-0.1.17-pathcache.patch Lines 176-178 of qimlate.c > pathcache = (char *) xmalloc(strlen(portdir) + strlen("/metadata/cache") + 1); > strcpy(pathcache,portdir); > strcat(pathcache+strlen(portdir),"/metadata/cache/"); Here is a problem. It allocates space for "/metadata/cache" but writes more, "/metadata/cache/". Please try this patch and let me know if it fixes the problem you are having.
Created attachment 86880 [details, diff] test numpkg instead of numcat Your patch works. Thanks. Attached is a small patch to test numpkg.
(In reply to comment #4) > Attached is a small patch to test numpkg. Great, thanks. > Your patch works. Thanks. I committed my patch and your patch to CVS/gentoo-projects/portage-utils. I bumped portage-utils in portage to 0.1.17-r1.