Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 196460 - app-portage/gentoolkit-0.2.3-r1 revdep-rebuild identifies wrong packages
Summary: app-portage/gentoolkit-0.2.3-r1 revdep-rebuild identifies wrong packages
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Tools (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Portage Tools Team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks: 170220
  Show dependency tree
 
Reported: 2007-10-19 21:02 UTC by Glynn Clements
Modified: 2008-02-21 01:52 UTC (History)
1 user (show)

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


Attachments
revdep-rebuild_gentoolkit-0.2.3-r1_false_matches.patch (revdep-rebuild_gentoolkit-0.2.3-r1_false_matches.patch,669 bytes, patch)
2008-01-23 22:05 UTC, michael@smith-li.com
Details | Diff
revdep-rebuild_r453_false_matches.patch (revdep-rebuild_r453_false_matches.patch,644 bytes, patch)
2008-01-23 22:05 UTC, michael@smith-li.com
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Glynn Clements 2007-10-19 21:02:48 UTC
The "Assigning files to ebuilds" stage which generates the list of ebuilds from the list of files which are missing libraries has a bug. Specifically, simply "fgrep"ing CONTENTS files which contain the name of a broken file:

find /var/db/pkg -name CONTENTS | xargs fgrep -l -f $LLIST.3_rebuild |
sed 's:/var/db/pkg/\(.*\)/CONTENTS:\1:' > $LLIST.4_ebuilds

finds not only exact matches but also substring matches.

A concrete example: my /usr/bin/dia (from app-office/dia) is broken by a recent expat upgrade, so ~/.revdep-rebuild.3_rebuild contains a line:

obj /usr/bin/dia

The fgrep command not only matches /var/db/pkg/app-office/dia-0.95.1/CONTENTS, which has:

obj /usr/bin/dia dfc5d8300ad9138dc4fb39eb3004236a 1171745643

But also matches /var/db/pkg/dev-util/dialog-1.1.20070704/CONTENTS, as that has:

obj /usr/bin/dialog 34122ee1f5280476e0383f5ac83efcb0 1192820107


Reproducible: Always

Steps to Reproduce:




Potential fix: make a temporary copy of .3_rebuild with a space at the end of each line. Use that file for fgrep -f.
Comment 1 Glynn Clements 2007-10-20 16:54:21 UTC
Portage 2.1.3.9 (default-linux/x86/no-nptl, gcc-3.4.6, glibc-2.3.6-r5, 2.6.17.13 i686)
=================================================================
System uname: 2.6.17.13 i686 Pentium III (Coppermine)
Timestamp of tree: Sat, 20 Oct 2007 00:00:09 +0000
app-shells/bash:     3.2_p17
dev-lang/python:     2.4.4-r5
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.9-r2
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61-r1
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.24
virtual/os-headers:  2.6.22-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-g -O2 -mtune=pentium3 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/bind"
CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-g -O2 -mtune=pentium3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer noclean nostrip sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="C"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X X509 alsa apm berkdb bitmap-fonts bzip2 cli cracklib crypt doc dri eds emboss encode foomaticdb fortran gdbm gif gstreamer gtk gtk2 iconv imlib isdnlog jpeg libwww mad mbox midi mikmod motif mp3 mpeg mudflap ncurses ogg opengl openmp oss pam pcre perl png pppd python qt3 qt4 quicktime readline reflection sdl session spell spl ssl symlink tcpd tiff truetype truetype-fonts type1-fonts vorbis x86 xml xorg xv zlib" ALSA_CARDS="ens1371" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="mga"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 2 michael@smith-li.com 2008-01-23 22:05:01 UTC
Created attachment 141681 [details, diff]
revdep-rebuild_gentoolkit-0.2.3-r1_false_matches.patch

Patch for the rr in gentoolkit 0.2.3-r1.
Comment 3 michael@smith-li.com 2008-01-23 22:05:47 UTC
Created attachment 141683 [details, diff]
revdep-rebuild_r453_false_matches.patch

Patch for revision 453 in subversion.
Comment 4 Paul Varner (RETIRED) gentoo-dev 2008-02-16 21:04:52 UTC
$ svn commit -m "Apply patch to prevent false matches of object names. (Bug 196460)"
Sending        revdep-rebuild/revdep-rebuild
Transmitting file data .
Committed revision 463.
Comment 5 Paul Varner (RETIRED) gentoo-dev 2008-02-21 01:52:13 UTC
Released in gentoolkit-0.2.4_rc2