Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 497344 - >=sys-libs/newlib-2.0.0: SLOT change triggers collision with old SLOT
Summary: >=sys-libs/newlib-2.0.0: SLOT change triggers collision with old SLOT
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-07 03:01 UTC by Alex Orange
Modified: 2015-05-18 16:40 UTC (History)
0 users

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


Attachments
Results of emerge -pvu cross-arm-elf-eabi/newlib (emerge_update.txt,801 bytes, text/plain)
2014-01-08 05:31 UTC, Alex Orange
Details
Results of sudo emerge -pv =cross-arm-elf-eabi/newlib-2.0.0 =cross-arm-elf-eabi/newlib-2.1.0 (emerge_both.txt,2.02 KB, text/plain)
2014-01-08 05:32 UTC, Alex Orange
Details
Contents of /usr/local/portage/cross-arm-elf-eabi/newlib/newlib-2.0.0.ebuild (newlib-2.0.0.ebuild,1.70 KB, text/plain)
2014-01-08 05:33 UTC, Alex Orange
Details
Contents of /usr/local/portage/cross-arm-elf-eabi/newlib/newlib-2.1.0.ebuild (newlib-2.1.0.ebuild,1.74 KB, text/plain)
2014-01-08 05:33 UTC, Alex Orange
Details
Patch to newlib-2.1.0.ebuild to fix problem. (new-2.1.0.ebuild.patch,309 bytes, patch)
2014-01-20 00:18 UTC, Alex Orange
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Orange 2014-01-07 03:01:34 UTC
I've installed an arm-elf-eabi crossdev target and am now upgrading my machine (just a normal emerge -avDuN --with-bdeps y world) and it wants to install a new slot of newlib. This would be fine, except that the new slot's files are the same as the old slot's files:

 * This package will overwrite one or more files that may belong to other
 * packages (see list below). You can use a command such as `portageq
 * owners / <filename>` to identify the installed package that owns a
 * file. If portageq reports that only one package owns a file then do
 * NOT file a bug report. A bug report is only useful if it identifies at
 * least two or more packages that are known to install the same file(s).
 * If a collision occurs and you can not explain where the file came from
 * then you should simply ignore the collision since there is not enough
 * information to determine if a real problem exists. Please do NOT file
 * a bug report at http://bugs.gentoo.org unless you report exactly which
 * two packages install the same file(s). See
 * http://wiki.gentoo.org/wiki/Knowledge_Base:Blockers for tips on how to
 * solve the problem. And once again, please do NOT file a bug report
 * unless you have completely understood the above message.
 *
 * Detected file collision(s):
 *
 *      /usr/arm-elf-eabi/lib/libm.a
 *      /usr/arm-elf-eabi/lib/rdpmon.specs
 *      /usr/arm-elf-eabi/lib/libnosys.a
 *      /usr/arm-elf-eabi/lib/linux.specs
 *      /usr/arm-elf-eabi/lib/redboot-syscalls.o
 *      /usr/arm-elf-eabi/lib/libc.a
 *      /usr/arm-elf-eabi/lib/rdimon-crt0.o
 *      /usr/arm-elf-eabi/lib/redboot.ld
 *      /usr/arm-elf-eabi/lib/libgloss-linux.a
 *      /usr/arm-elf-eabi/lib/redboot.specs
 *      /usr/arm-elf-eabi/lib/libg.a
 *      /usr/arm-elf-eabi/lib/linux-crt0.o
 *      /usr/arm-elf-eabi/lib/rdimon.specs
 *      /usr/arm-elf-eabi/lib/iq80310.specs
 *      /usr/arm-elf-eabi/lib/librdpmon.a
 *      /usr/arm-elf-eabi/lib/redboot-crt0.o
 *      /usr/arm-elf-eabi/lib/rdpmon-crt0.o
 *      /usr/arm-elf-eabi/lib/crt0.o
 *      /usr/arm-elf-eabi/lib/pid.specs
 *      /usr/arm-elf-eabi/lib/librdimon.a
 *      /usr/arm-elf-eabi/include/locale.h
 *      /usr/arm-elf-eabi/include/grp.h
 *      /usr/arm-elf-eabi/include/libgen.h
 *      /usr/arm-elf-eabi/include/utime.h
 *      /usr/arm-elf-eabi/include/tar.h
 *      /usr/arm-elf-eabi/include/unistd.h
 *      /usr/arm-elf-eabi/include/assert.h
 *      /usr/arm-elf-eabi/include/argz.h
 *      /usr/arm-elf-eabi/include/ieeefp.h
 *      /usr/arm-elf-eabi/include/ctype.h
 *      /usr/arm-elf-eabi/include/stdio.h
 *      /usr/arm-elf-eabi/include/pthread.h
 *      /usr/arm-elf-eabi/include/glob.h
 *      /usr/arm-elf-eabi/include/alloca.h
 *      /usr/arm-elf-eabi/include/reent.h
 *      /usr/arm-elf-eabi/include/ar.h
 *      /usr/arm-elf-eabi/include/regdef.h
 *      /usr/arm-elf-eabi/include/iconv.h
 *      /usr/arm-elf-eabi/include/envlock.h
 *      /usr/arm-elf-eabi/include/utmp.h
 *      /usr/arm-elf-eabi/include/errno.h
 *      /usr/arm-elf-eabi/include/inttypes.h
 *      /usr/arm-elf-eabi/include/signal.h
 *      /usr/arm-elf-eabi/include/string.h
 *      /usr/arm-elf-eabi/include/getopt.h
 *      /usr/arm-elf-eabi/include/tgmath.h
 *      /usr/arm-elf-eabi/include/pwd.h
 *      /usr/arm-elf-eabi/include/termios.h
 *      /usr/arm-elf-eabi/include/fastmath.h
 *      /usr/arm-elf-eabi/include/malloc.h
 *      /usr/arm-elf-eabi/include/limits.h
 *      /usr/arm-elf-eabi/include/sched.h
 *      /usr/arm-elf-eabi/include/time.h
 *      /usr/arm-elf-eabi/include/unctrl.h
 *      /usr/arm-elf-eabi/include/stdio_ext.h
 *      /usr/arm-elf-eabi/include/langinfo.h
 *      /usr/arm-elf-eabi/include/fnmatch.h
 *      /usr/arm-elf-eabi/include/stdlib.h
 *      /usr/arm-elf-eabi/include/paths.h
 *      /usr/arm-elf-eabi/include/complex.h
 *      /usr/arm-elf-eabi/include/newlib.h
 *      /usr/arm-elf-eabi/include/strings.h
 *      /usr/arm-elf-eabi/include/dirent.h
 *      /usr/arm-elf-eabi/include/wctype.h
 *      /usr/arm-elf-eabi/include/_syslist.h
 *      /usr/arm-elf-eabi/include/math.h
 *      /usr/arm-elf-eabi/include/envz.h
 *      /usr/arm-elf-eabi/include/regex.h
 *      /usr/arm-elf-eabi/include/search.h
 *      /usr/arm-elf-eabi/include/fcntl.h
 *      /usr/arm-elf-eabi/include/wchar.h
 *      /usr/arm-elf-eabi/include/_ansi.h
 *      /usr/arm-elf-eabi/include/stdint.h
 *      /usr/arm-elf-eabi/include/wordexp.h
 *      /usr/arm-elf-eabi/include/setjmp.h
 *      /usr/arm-elf-eabi/include/sys/resource.h
 *      /usr/arm-elf-eabi/include/sys/queue.h
 *      /usr/arm-elf-eabi/include/sys/custom_file.h
 *      /usr/arm-elf-eabi/include/sys/_default_fcntl.h
 *      /usr/arm-elf-eabi/include/sys/utime.h
 *      /usr/arm-elf-eabi/include/sys/unistd.h
 *      /usr/arm-elf-eabi/include/sys/config.h
 *      /usr/arm-elf-eabi/include/sys/iconvnls.h
 *      /usr/arm-elf-eabi/include/sys/stdio.h
 *      /usr/arm-elf-eabi/include/sys/reent.h
 *      /usr/arm-elf-eabi/include/sys/timeb.h
 *      /usr/arm-elf-eabi/include/sys/errno.h
 *      /usr/arm-elf-eabi/include/sys/param.h
 *      /usr/arm-elf-eabi/include/sys/signal.h
 *      /usr/arm-elf-eabi/include/sys/string.h
 *      /usr/arm-elf-eabi/include/sys/stat.h
 *      /usr/arm-elf-eabi/include/sys/lock.h
 *      /usr/arm-elf-eabi/include/sys/cdefs.h
 *      /usr/arm-elf-eabi/include/sys/features.h
 *      /usr/arm-elf-eabi/include/sys/sched.h
 *      /usr/arm-elf-eabi/include/sys/time.h
 *      /usr/arm-elf-eabi/include/sys/wait.h
 *      /usr/arm-elf-eabi/include/sys/dirent.h
 *      /usr/arm-elf-eabi/include/sys/times.h
 *      /usr/arm-elf-eabi/include/sys/types.h
 *      /usr/arm-elf-eabi/include/sys/_types.h
 *      /usr/arm-elf-eabi/include/sys/syslimits.h
 *      /usr/arm-elf-eabi/include/sys/fcntl.h
 *      /usr/arm-elf-eabi/include/sys/file.h
 *      /usr/arm-elf-eabi/include/sys/dir.h
 *      /usr/arm-elf-eabi/include/machine/endian.h
 *      /usr/arm-elf-eabi/include/machine/ieeefp.h
 *      /usr/arm-elf-eabi/include/machine/param.h
 *      /usr/arm-elf-eabi/include/machine/termios.h
 *      /usr/arm-elf-eabi/include/machine/setjmp-dj.h
 *      /usr/arm-elf-eabi/include/machine/fastmath.h
 *      /usr/arm-elf-eabi/include/machine/malloc.h
 *      /usr/arm-elf-eabi/include/machine/time.h
 *      /usr/arm-elf-eabi/include/machine/stdlib.h
 *      /usr/arm-elf-eabi/include/machine/types.h
 *      /usr/arm-elf-eabi/include/machine/_types.h
 *      /usr/arm-elf-eabi/include/machine/_default_types.h
 *      /usr/arm-elf-eabi/include/machine/ansi.h
 *      /usr/arm-elf-eabi/include/machine/setjmp.h
 *
 * Searching all installed packages for file collisions...
 *
 * Press Ctrl-C to Stop
 *
 * cross-arm-elf-eabi/newlib-2.0.0:arm-elf-eabi::x-portage
 *      /usr/arm-elf-eabi/lib/crt0.o
 *      /usr/arm-elf-eabi/lib/iq80310.specs
 *      /usr/arm-elf-eabi/lib/libc.a
 *      /usr/arm-elf-eabi/lib/libg.a
 *      /usr/arm-elf-eabi/lib/libgloss-linux.a
 *      /usr/arm-elf-eabi/lib/libm.a
 *      /usr/arm-elf-eabi/lib/libnosys.a
 *      /usr/arm-elf-eabi/lib/librdimon.a
 *      /usr/arm-elf-eabi/lib/librdpmon.a
 *      /usr/arm-elf-eabi/lib/linux-crt0.o
 *      /usr/arm-elf-eabi/lib/linux.specs
 *      /usr/arm-elf-eabi/lib/pid.specs
 *      /usr/arm-elf-eabi/lib/rdimon-crt0.o
 *      /usr/arm-elf-eabi/lib/rdimon.specs
 *      /usr/arm-elf-eabi/lib/rdpmon-crt0.o
 *      /usr/arm-elf-eabi/lib/rdpmon.specs
 *      /usr/arm-elf-eabi/lib/redboot-crt0.o
 *      /usr/arm-elf-eabi/lib/redboot-syscalls.o
 *      /usr/arm-elf-eabi/lib/redboot.ld
 *      /usr/arm-elf-eabi/lib/redboot.specs
 *
 * Package 'cross-arm-elf-eabi/newlib-2.1.0' NOT merged due to file
 * collisions. If necessary, refer to your elog messages for the whole
 * content of the above message.

And yes, I know that these are only claimed by one package, but it's the second slot that's causing the problem.

Reproducible: Always

Steps to Reproduce:
1. Install arm-elf-eabi target with newlib-2.0.0
2. Upgrade to newlib-2.1.0
3.
Actual Results:  
Fails with file collisions.

Expected Results:  
Either doesn't install as a second slot (which would be just fine) or uses different filenames for the new slot.
Comment 1 SpanKY gentoo-dev 2014-01-08 03:37:04 UTC
has nothing to do with crossdev.  you can manually change the SLOT yourself, or temporarily set FEATURES to ignore collisions, or re-install the toolchain.
Comment 2 Alex Orange 2014-01-08 05:30:37 UTC
With regards to your suggestions:

1. I do not intend to unset collision-detect. This sounds like about the best way to screw up my system royally.
2. I would really really like to avoid reinstalling the toolchain from scratch because that was horrific the first time and I see no reason to believe it will be better this time.

**3**. About the SLOT: I am now even more confused because both packages have SLOT="0", shouldn't that mean that the new package should not be able to be installed alongside the old package?

I have attached the emerge results and the two relevant ebuilds. Strangely enough if I try to emerge both the package that I already have installed as well as the new package ebuild chokes, telling me that I'm trying to install two packages in the same slot. However, if I just try to upgrade the package it seems to have forgotten about this problem and wants to install the package to a new slot (at least until it gets to the install stage).


I would have to say that this seems to either be a bug with crossdev or portage however and not a problem with newlib. You have offered no reason for me to believe that this is not a crossdev issue. I have also offered no reason to suggest it is specifically a problem with crossdev, however I don't believe it's a problem with newlib.
Comment 3 Alex Orange 2014-01-08 05:31:22 UTC
Created attachment 367350 [details]
Results of emerge -pvu cross-arm-elf-eabi/newlib
Comment 4 Alex Orange 2014-01-08 05:32:14 UTC
Created attachment 367352 [details]
Results of sudo emerge -pv =cross-arm-elf-eabi/newlib-2.0.0 =cross-arm-elf-eabi/newlib-2.1.0
Comment 5 Alex Orange 2014-01-08 05:33:26 UTC
Created attachment 367354 [details]
Contents of /usr/local/portage/cross-arm-elf-eabi/newlib/newlib-2.0.0.ebuild
Comment 6 Alex Orange 2014-01-08 05:33:39 UTC
Created attachment 367356 [details]
Contents of /usr/local/portage/cross-arm-elf-eabi/newlib/newlib-2.1.0.ebuild
Comment 7 Alex Orange 2014-01-08 05:35:31 UTC
P.S. I also don't understand the new title. I get that you're trying to make it newlib's problem but what do you mean by "SLOT change"? I see not "change".
Comment 8 SpanKY gentoo-dev 2014-01-08 06:57:04 UTC
from your own logs:

 * cross-arm-elf-eabi/newlib-2.0.0:arm-elf-eabi::x-portage
[ebuild   R   *] cross-arm-elf-eabi/newlib-2.0.0:0::x-portage [2.0.0:arm-elf-eabi::x-portage] USE="nls unicode -threads" 0 kB

so clearly your currently installed newlib does not have a SLOT=0, it has "arm-elf-eabi"
Comment 9 Alex Orange 2014-01-08 07:22:22 UTC
I don't follow, I looked in the newlib-2.0.0.ebuild file and it says SLOT="0". Where are you getting "arm-elf-eabi" from? I thought all slots had to be numeric, but honestly I don't know much about slots except that they allow you to install two versions of the same package.
Comment 10 Alex Orange 2014-01-08 07:42:48 UTC
Okay, I've done some more research and I think I've found the problem. Looking at the cvs history it appears that the change made to newlib-2.0.0 changed the SLOT of an existing package (http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/sys-libs/newlib/newlib-2.0.0.ebuild?r1=1.1&r2=1.2). Now is it just me or is that an incorrect thing to do. My understanding is that there should at least be a -r1 type bump and likely in this case it would have to block anything using the old SLOT convention (basically <2.0.0-r1). Then the 2.1.0 would have to block the same things. Again, I don't really know very well what I'm talking about, just speculating based on other things I've seen done.
Comment 11 SpanKY gentoo-dev 2014-01-11 14:51:10 UTC
(In reply to Alex Orange from comment #10)

no revbump would have helped.  you'd be in the same exact spot.

a blocker might have helped, but i can't reproduce here.  portage will migrate the content for me when the SLOT changes.
Comment 12 Alex Orange 2014-01-11 21:35:35 UTC
What do you mean "migrate the content"?

Also, I was suggesting that it would need to be a rev-bump + blocker to solve the issue. I was just saying that it seems like to be kosher that it would need a rev-bump for a change like this. Though I want to point out that I don't know that for sure.
Comment 13 SpanKY gentoo-dev 2014-01-15 21:46:27 UTC
as i said, the revbump wouldn't help at all.  portage doesn't care what the -r# is as the SLOT values are different.

portage-2.2.8 for me had no problem replacing newlib-2.0.0:${CHOST} with newlib-2.0.0:0.  not sure why.

i'm not sure a blocker is even feasible as it needs to block all values where SLOT is not 0.
Comment 14 Alex Orange 2014-01-18 13:48:53 UTC
Yes, but if you consider anything <2.0.0-r1 to be suspect (as possibly being in slot other then 0) then you can just block them. Assuming everything >=2.0.0-r1 is restricted to slot 0 then you've assured that everything not in slot 0 is removed.

I'm going to reopen this in hopes that whoever handles newlib looks at this problem.
Comment 15 Alex Orange 2014-01-20 00:18:08 UTC
Created attachment 368200 [details, diff]
Patch to newlib-2.1.0.ebuild to fix problem.

This fixes the issue for me, and I believe it would be an improvement on what is there right now.
Comment 16 SpanKY gentoo-dev 2015-05-18 16:40:28 UTC
should be all set now in the tree; thanks for the report!

Commit message: Add a blocker against older SLOTs to help with upgrades
http://sources.gentoo.org/sys-libs/newlib/newlib-2.2.0.ebuild?r1=1.3&r2=1.4