SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: slackware, slackware from scratch, LFS, slackware [arm], linux Mint...
Posts: 1,564
Rep:
glibc-2.30 doesn't build with gcc-10.2.0
While trying to build glibc-2.30 with gcc-10.2.0 an error occured:
-----------------------
libc-tls.c: In function '__libc_setup_tls':
libc-tls.c:209:30: error: array subscript 1 is outside the bounds of an interior zero-length array 'struct dtv_slotinfo[0]' [-Werror=zero-length-bounds]
209 | static_slotinfo.si.slotinfo[1].map = main_map;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
In file included from ../sysdeps/x86/ldsodefs.h:64,
from ../sysdeps/gnu/ldsodefs.h:46,
from ../sysdeps/unix/sysv/linux/ldsodefs.h:25,
from libc-tls.c:21:
../sysdeps/generic/ldsodefs.h:406:7: note: while referencing 'slotinfo'
406 | } slotinfo[0];
-----------------------
As I reported this morning in the 14.2->15.0 thread, glibc-2.32 does build without problems using gcc-10.2.0. So, either the 2.30 code needs to be patched or -current needs to jump to 2.32.
Thanks. I needed this for ARM and AArch64.
Happy new year! :-)
It turns out that this patch breaks the build on ARM and isn't required because --disable-werror is a default configuration option on SlackARM. glibc should build on x86/64 without patching when you use this option.
I was looking at this happening a few days ago, and skipped patching, since I could just use Pat's glibc anyway. This is one of those things that makes recompiling things reproducibly (or a slackware from scratch) pretty much a chore. The way to get to what Pat has would be to go through the steps of old gcc > glibc 2.30 -> new gcc. If you patch glibc to make it compile, now you are compiling a different (how much?) glibc than what is in slackware.
What drmozes says of using --disable-werror actually brings you closer to the actual glibc built, as long as gcc 9.3.0 and gcc 10.2.0 didn't really diverge in code generation. If you want to be like LFS and teach/show people what slackware is like, I would actually just put the ignore in rather than patch things to compile on things like this. And I think the project makes more sense to me to base on a stable series of Slackware. But I know you only recently got started during this -current.
Also, I was looking at the bug report for glibc concerning gcc 10.2 and it looked like some patches were applied, and more were needed later for other platforms. So how would one handle multiple platforms, in a source based distro, on a platform that slackware was not initially tested on?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.