Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 195507 - app-portage/gentoolkit - revdep-rebuild problem with lockfile
Summary: app-portage/gentoolkit - revdep-rebuild problem with lockfile
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Tools (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage Tools Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-10-11 14:35 UTC by Jason King
Modified: 2008-02-25 18:23 UTC (History)
1 user (show)

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 Jason King 2007-10-11 14:35:27 UTC
When running another emerge at the same time as revdep-rebuild (so there's a lockfile) then revdep-rebuild calls emerge with incorrect arguments:

 * All prepared. Starting rebuild
emerge --oneshot  =waiting =for =lock =on =/var/db/.pkg.portage_lockfile =dev-db/postgresql-8.2.4-r1 =more-real-packages

Reproducible: Always

Steps to Reproduce:
Hard to reproduce, gotta get the timing right, I'm sure you can work it out.  Hopefully you can just see what's happening from the output.
Actual Results:  
 * All prepared. Starting rebuild
emerge --oneshot  =waiting =for =lock =on =/var/db/.pkg.portage_lockfile =dev-db/postgresql-8.2.4-r1 =more-real-packages
..........
Calculating dependencies \

!!! '=/var/db/.pkg.portage_lockfile' is not a valid package atom.
!!! Please check ebuild(5) for full details.
!!! (Did you specify a version but forget to prefix with '='?)



Portage 2.1.3.12 (default-linux/amd64/2007.0, gcc-4.2.2, glibc-2.6.1-r0, 2.6.19-gentoo-r5 x86_64)
=================================================================
System uname: 2.6.19-gentoo-r5 x86_64 Intel(R) Core(TM)2 CPU 6600 @ 2.40GHz
Timestamp of tree: Thu, 11 Oct 2007 11:50:01 +0000
app-shells/bash:     3.2_p17-r1
dev-java/java-config: 1.3.7, 2.1.1
dev-lang/python:     2.4.4-r4, 2.5.1-r2
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.10-r5
sys-apps/sandbox:    1.2.18.1
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.4.0-r4
sys-devel/libtool:   1.5.24
virtual/os-headers:  2.6.22-r2
ACCEPT_KEYWORDS="amd64 ~amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=nocona -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/init.d /etc/pam.d /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-O2 -march=nocona -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="ccache distlocks fixpackages metadata-transfer parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://mirror.aarnet.edu.au/pub/gentoo/ ftp://mirror.aarnet.edu.au/pub/gentoo/ ftp://ftp.planetmirror.com/pub/gentoo/ ftp://mirror.pacific.net.au/linux/Gentoo ftp://ftp.swin.edu.au/gentoo ftp://gentoo.osuosl.org/pub/gentoo/ http://public.planetmirror.com/pub/gentoo/ http://mirror.pacific.net.au/linux/Gentoo http://ftp.swin.edu.au/gentoo "
LINGUAS="en en_AU en_US en_GB"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_EXTRA_OPTS="--exclude-from /etc/portage/rsync_excludes"
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"
SYNC="rsync://rsync.au.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi aim aimextras alsa amd64 apache2 apm asf audiofile automount avi bash-completion beagle bitmap-fonts bittorrent branding bzip2 calendar cardbus ccache cddb cdr chm cli cpudetection cracklib crypt ctype cups dba dbus djvu dri dvd dvdr dvdread eds emerald encode ethereal evo examples exif expat fam fastbuild fastcgi fat ffmpeg firefox flac font-server fontconfig foomaticdb force-cgi-redirect freetds ftp galago gd gdbm gif gimp gimpprint glitz glut glx gmp gnome gphoto2 gpm gstreamer gtk gtk2 gtkhtml hal http iconv icq idea idn ieee1394 image imagemagick imap imlib innodb inode inquisitio ipod iproute2 irc irda isdnlog jabber java javascript jpeg jpeg2k kerberos lame lcms ldap ldapsam lesstif libg++ libgd libwww lighttpd logrotate mad madwifi maildir mbox md5sum memcache memlimit metar midi mikmod mime mimencode mixer mmx mng modperl modplug mozbranding mozcalendar mozdevelop mozdom mozilla moznocompose moznoirc moznomail mozsvg mozxmlterm mp3 mpeg mppe-mppc msn msnextras mssql mudflap mysql mysqli ncurses nfs nls nntp nptl nptlonly nsplugin ntfs ntlm nvidia nvtv obex offensive ogg ogre ole opengl openmp openssl oscar pam pcntl pcre pda pdf pdflib perl plotutils png posix postgres povray ppds pppd python qt qt3support qt4 quicktime rdesktop readline realmedia reflection reiser4 reiserfs rss rtc ruby samba sdl session sharedmem simplexml slang smime smtp soap sockets spell spl sqlite sqlite3 sse sse2 ssl stroke subversion svg svgz sysvipc tcpd theora threads thunderbird tidy tiff tk tokenizer truetype truetype-fonts type1-fonts udev unicode userlocales utf8 vcd vhosts vim vim-pager vim-syntax vim-with-x vorbis webdav wifi wma wma123 wmf wmp wv wxwindows xattr xine xml xml2 xmlrpc xorg xpm xscreensaver xsl xv yahoo zip zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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="evdev keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en en_AU en_US en_GB" USERLAND="GNU" VIDEO_CARDS="nvidia"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTDIR_OVERLAY
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-10-11 14:37:52 UTC
Which gentoolkit version is this about?
Comment 2 Jason King 2007-10-11 15:04:51 UTC
app-portage/gentoolkit-0.2.4_pre7
Comment 3 michael@smith-li.com 2008-01-23 05:54:25 UTC
What arguments did you pass to revdep-rebuild? It would be good to see the preceding output.

Also, please attach the .revdep-rebuild* files.

Thanks
Comment 4 Jason King 2008-01-24 09:24:44 UTC
No args to revdep-rebuild, and the .revdep-rebuild* files were deleted long ago.

The problem is just that somewhere in the revdep-rebuild it does some ebuild step which gets the "waiting for lock on /var/db/.pkg.portage_lockfile" result, and revdep-rebuild doesn't recognize this as a special case, so just parses the output as package names and proceeds with the merge.

I thought this would be pretty easy to track down, which was why I didn't attach (or keep) the .revdep-rebuild* files, sorry.
Comment 5 michael@smith-li.com 2008-01-26 01:41:58 UTC
The really serious part of this bug was fixed with a patch submitted to similar bug #205227. The truth is you should not be running revdep-rebuild while you're emerging other stuff anyway.

If you really need this thing fixed, do grep -vF 'waiting for lock' against $LIST.5_order after it gets generated in the get_build_order() function. That should fix it.
Comment 6 michael@smith-li.com 2008-02-25 18:23:09 UTC
Jason, please test and confirm this bug is fixed.