Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 85066 - Portage doesn't consider symlinks in calculating collision-protect
Summary: Portage doesn't consider symlinks in calculating collision-protect
Status: RESOLVED DUPLICATE of bug 80846
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-13 04:22 UTC by Bernd Waibel
Modified: 2005-07-17 13:06 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 Bernd Waibel 2005-03-13 04:22:48 UTC
Trying to update xorg-x11 from rel. 6.8.0-r5 to 6.8.2-r1 I got again collisions with files that reside in /usr/include/X11.

This happened before when upgrading the first time from 6.7 to 6.8 release. I was told then this will happen only once and was caused by some switches in the /usr/X11R6 directory. Well this, seems not the cause. This problem is imho due to the fact, that one time the ebuilds use the /usr/X11R6 prefix, the next time they use the /usr prefix. Therefore at one time, protage checks in /usr/X11R6/include/X11 for files (in my case) and the other time it checks in /usr/include/X11, not realizing they are the same directory and one is a link to the other.

Will this issue be FINALLY fixed sometimes, or will I always need to install xorg-x11 2 times?

Furthermore, is it really necessary to publish two xorg-x11 releases within 2 days? I updated from 6.8.0-r4 to 6.8.0-r5 on friday and today I have to update to 6.8.2-r1. It's imho a waste of bandwidth to have to download the quite large archives for xorg-x11 twice within such a short timeframe. Why didn't you just wait two days longer? What was the reason of bringing out the 6.8.0-r5 release, when the 6.8.2 release will become stable only 2 days later?


Reproducible: Always
Steps to Reproduce:
1. put collision-protect in your FEATURES
2. emerge -uv --oneshot xorg-x11
3.

Actual Results:  
After compiling cleanly, the merge failed due to overriding files in
/usr/include/X11 and subdirs.

Expected Results:  
Portage should have figured out, /usr/X11R6/include/X11 and /usr/include/X11 are
both the same directories and not break the installation.


You can verify the imho broken portage in this case by doing a

qpkg -f /usr/include/X11/pixmaps/computer.xpm

and

qpkg -f /usr/X11R6/include/X11/pixmaps/computer.xpm

The first one just returns with no output, the second one gives the correct
answer, namely x11-base/xorg-x11.

Here my emerge info

Portage 2.0.51.19 (default-linux/x86/2004.3, gcc-3.3.5, glibc-2.3.4.20040808-r1,
2.6.11-ck1-ipv6m i686)
=================================================================
System uname: 2.6.11-ck1-ipv6m i686 Intel(R) Pentium(R) 4 CPU 2.40GHz
Gentoo Base System version 1.4.16
Python:              dev-lang/python-2.3.4-r1 [2.3.4 (#1, Feb 26 2005, 02:29:05)]
ccache version 2.3 [enabled]
dev-lang/python:     2.3.4-r1
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r1
sys-devel/libtool:   1.5.10-r4
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-march=pentium4 -O2 -fforce-addr -mfpmath=sse -mmmx -msse -msse2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env
/usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config
/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/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=pentium4 -O2 -fforce-addr -mfpmath=sse -mmmx -msse -msse2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig buildsyspkg candy ccache collision-protect
distlocks fixpackages nostrip sandbox sfperms strict userpriv usersandbox"
GENTOO_MIRRORS="ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo
ftp://linux.rz.ruhr-uni-bochum.de/gentoo-mirror/
ftp://ftp.uni-erlangen.de/pub/mirrors/gentoo
ftp://ftp.join.uni-muenster.de/pub/linux/distributions/gentoo
ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo
ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/
ftp://ftp.gentoo.mesh-solutions.com/gentoo/"
LANG="german"
LC_ALL="de_DE.utf8"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/mnt/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage /usr/local/portage-de"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="x86 X aalib accessibility acl acpi aim alsa apache2 arts avi
bash-completion berkdb bitmap-fonts crypt cscope cups curl dedicated doc dvd
emboss encode esd exif fam flac font-server foomaticdb fortran freetds gdbm ggi
gif gnome gpm gstreamer gtk2 hal icq jabber jack java joystick jpeg junit
kdeenablefinal libwww linguas_de mad maildir mikmod mmx mmx2 motif mp3 mpeg mpi
msn ncurses nls nptl odbc offensive oggvorbis openal opengl oscar pam pic pie
png ppds pwdb python qt quicktime readline samba sdl shared slang spell sqlite
sse ssl svg svga sysvipc tcpd tetex tiff truetype truetype-fonts type1-fonts
unicode usb videos xml xml2 xmms xprint yahoo zlib"
Unset:  ASFLAGS, CBUILD, CTARGET, LDFLAGS
Comment 1 Joshua Baergen (RETIRED) gentoo-dev 2005-03-13 13:29:17 UTC
From the changelog:

  13 Mar 2005; Donnie Berkholz <spyderous@gentoo.org>;
  xorg-x11-6.8.2-r1.ebuild:
  Stable x86. Sorry about the two upgrades in a few days thing, but the first
  was a security bug so there was some time pressure involved. I figured it's
  better to stable this sooner so we can save a compile for people who don't
  sync every day.

As for your collisions, I see the migration code within the ebuild...I'll give it a spin on my laptop so I can see what you're seeing.  Both my laptop and my desktop built 6.8.2 on a clean slate, so I'm assuming a manual unmerge-merge would avoid this, but I agree that if it's an issue then portage should handle it.
Comment 2 Joshua Baergen (RETIRED) gentoo-dev 2005-03-13 15:51:19 UTC
I think adding a call to pkg_preinst before unpacking source will fix this.  The migration routine was not being called I believe.  I'll test now and we'll see if it works.
Comment 3 Bernd Waibel 2005-03-14 05:01:24 UTC
Or how about adding an info in pkg_preinst that states about this, so one is able to exit and restart the emerge with FEATURES="-collision-protect", if all else fails? Not sure, if this will make much sense. Just an idea that suddenly pooped up.

Thanks for the pointer to ChangeLog. I missed this, as I do not always read the ChangeLogs. I do it always for kernel packages, but usually not for all packages.
Comment 4 Joshua Baergen (RETIRED) gentoo-dev 2005-03-14 17:01:30 UTC
Although understandable, if something seems weird it's a good place to look ;)

No luck.  The directory was migrated but Portage doesn't see the symlinks in ownership calculation.  Does someone more familiar with Portage know how to re-factor ownership to allow this?
Comment 5 Donnie Berkholz (RETIRED) gentoo-dev 2005-03-14 19:09:26 UTC
You're exactly right about the migration.

Incidentally, IRT the second original comment, you should've had the 6.8.0 archives saved on your machine from when you installed -r4 anyway so the only new download would've been a small patchset. If you're cleaning out distfiles of the version you currently have installed rather than just old versions, you deserve what you get.

*** This bug has been marked as a duplicate of 80846 ***