-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
unable to build i386 glibc: lld: error: relocation refers to a symbol in a discarded section #4926
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Oh this is a nice one, there are a few problems:
Many issues (#3340, #3287, #2256, #4927 and this one) have the same root cause in common, missing/stale files in @andrewrk the instructions on the wiki page should be updated, I don't see |
Ref by #7440 |
@andrewrk Can we make sure that we do the thing that @LemonBoy said in the comment above (#4926 (comment)) before the release of zig 0.8.0? This issue currently causes a lot of problems, as can be seen by all the linked comments in this issue. |
Hi. I'm a potential first time zig contributor. I was going to have a go at adding support for glibc-2.33 to play nicely on Arch. In doing so I was pointed towards this ticket. If someone could add a bit of color about the |
Well the first step is finding out what to copy (all the |
Is there any example of a correct set of |
Not really, ideally every file that's copied by |
So I managed to build and sync the headers as per the wiki. I've then looked at all the files in
How should I interpret that? Are these files no longer required due to changes in glibc? Do they come from elsewhere? I see that e.g. libc-modules.h is referenced in |
I was afraid that'd be the case - go through things manually until it makes sense basically. The one thing I'm a bit lost on is how libc-modules.h is created. It doesn't exist inside of my multi directory and seems to be automatically generated. I'll need to work out how to generate it properly. |
$(common-objpfx)libc-modules.h: $(common-objpfx)libc-modules.stmp; @:
$(common-objpfx)libc-modules.stmp: $(..)scripts/gen-libc-modules.awk \
$(common-objpfx)soversions.i
$(AWK) -v buildlist="$(subst -,_,$(built-modules))" -f $^ > ${@:stmp=T}
$(move-if-change) ${@:stmp=T} ${@:stmp=h}
touch $@ |
Indeed. I'm putting this on ice for a bit - spoke to @andrewrk about it briefly and it's complex enough that it'll be time better spent by someone else. Thanks for your help - I learnt a fair amount in the process either way :) |
This change was cherry-picked from an updated version of the sysdep folder contents, we're still shipping an outdated and incomplete set of files.
This change was cherry-picked from an updated version of the sysdep folder contents, we're still shipping an outdated and incomplete set of files.
This change was cherry-picked from an updated version of the sysdep folder contents, we're still shipping an outdated and incomplete set of files.
This change was cherry-picked from an updated version of the sysdep folder contents, we're still shipping an outdated and incomplete set of files.
This commit introduces tools/update_glibc.zig to update the start files for next time. Some notable changes in recent glibc: * abi-note.S has been changed to abi-note.c but we resist the change to keep it easier to compile the start files. * elf-init.c has been deleted upstream. WIP: It is unclear whether we need to conditionally include that compilation unit when targeting older glibcs. WIP: stat functions aren't working yet Closes #4926
This commit introduces tools/update_glibc.zig to update the start files for next time. Some notable changes in recent glibc: * abi-note.S has been changed to abi-note.c but we resist the change to keep it easier to compile the start files. * elf-init.c has been deleted upstream. WIP: It is unclear whether we need to conditionally include that compilation unit when targeting older glibcs. WIP: stat functions aren't working yet Closes #4926
This commit introduces tools/update_glibc.zig to update the start files for next time. Some notable changes in recent glibc: * abi-note.S has been changed to abi-note.c but we resist the change to keep it easier to compile the start files. * elf-init.c has been deleted upstream. Further testing should be done to verify that binaries against glibc omitting elf-init.c still run properly on oldel glibc linux systems. Closes #4926
I've done as you requested.
There are no more stale files. Here are updates for each of these issues:
|
The text was updated successfully, but these errors were encountered: