Summary: | <sys-libs/glibc-2.25: when compiling sys-apps/busybox-1.26.2-r1: Compile error: undefined reference to __mempcpy_chk | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Maciej Piechotka <uzytkownik2> |
Component: | Current packages | Assignee: | Gentoo Toolchain Maintainers <toolchain> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | candrews, chris, fsvm88, fuse809, leonchik1976, mvolaski, StormByte, whissi, xaviermiller, zoltan |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 628180 | ||
Attachments: |
Build log
Fix static mempcpy_chk. |
Description
Maciej Piechotka
2017-05-01 15:30:28 UTC
Experiencing same problem in the middle of world rebuild due to move from GCC 5.4.0-r1 to 6.3.0 I experience this bug too when compiling busybox with GCC 6.3.0. I have this bug too when compiling busybox with gcc 7.1.0 *** Bug 617828 has been marked as a duplicate of this bug. *** (In reply to Peter Levine from bug 617828 comment #1) > Maybe related to > https://sourceware.org/git/?p=glibc.git;a=commit; > h=fbe355fbd1973d6e29561084b3eaeb4bfe9d515a It indeed is. The patch in question has been added to the gentoo patchset for sys-libs/glibc-2.25 which we should keyword at some point. same problem with new profile, gcc-6.3.0 and glibc-2.24-r1 This actually blocks new installations. After uncompressing stage 3 one has to run emerge -uND world and it breaks on this error. Temporarily disabling static use flag makes it compile, but I don't know if that has bad consequences. If not, I would suggest hard masking static use flag for busybox for now. (In reply to David Carlos Manuelda from comment #9) > Temporarily disabling static use flag makes it compile, but I don't know if > that has bad consequences. If not, I would suggest hard masking static use > flag for busybox for now. As far as I understand, busybox is the default rescue shell when booting. Parts of it are copied in the initramfs at kernel/initramfs compile time. The end result is that you would end up with a non-working rescue shell at the next initramfs rebuild, because libc.so is not copied into the init image and busybox is not statically linked. As for the bug: running GCC 6.3.0 and glibc 2.24-r3 here. I see that the patch 00_all_0032-x86_64-fix-static-build-of-__memcpy_chk-for-compiler.patch is now applied, but it's not working, busybox still fails at compile time. (In reply to Fabio Scaccabarozzi from comment #10) > (In reply to David Carlos Manuelda from comment #9) > > Temporarily disabling static use flag makes it compile, but I don't know if > > that has bad consequences. If not, I would suggest hard masking static use > > flag for busybox for now. > > As far as I understand, busybox is the default rescue shell when booting. > Parts of it are copied in the initramfs at kernel/initramfs compile time. > The end result is that you would end up with a non-working rescue shell at > the next initramfs rebuild, because libc.so is not copied into the init > image and busybox is not statically linked. > > As for the bug: running GCC 6.3.0 and glibc 2.24-r3 here. I see that the > patch 00_all_0032-x86_64-fix-static-build-of-__memcpy_chk-for-compiler.patch > is now applied, but it's not working, busybox still fails at compile time. Just realized that the patch applied is for memcpy_chk, not memPcpy_chk. I have attached a patch based on the upstream one that fixes the issue (likely identical to the one applied to 2.25). I can finally compile busybox with GCC 6.4.0 and glibc-2.24-r3. Just drop it in /etc/portage/patches/sys-libs/glibc/. Can we please backport it for glibc-2.24? Or is glibc-2.25 going to be unmasked soon? Created attachment 488114 [details, diff]
Fix static mempcpy_chk.
glibc-2.25 will be stabilized soon. Fixed in 2.25 |