public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug build/26260] New: undefined reference to `_Unwind_Resume'
@ 2020-07-17 20:07 sourceware@le-garrec.fr
2020-07-17 20:08 ` [Bug build/26260] " sourceware@le-garrec.fr
2020-07-17 20:48 ` joseph at codesourcery dot com
0 siblings, 2 replies; 3+ messages in thread
From: sourceware@le-garrec.fr @ 2020-07-17 20:07 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=26260
Bug ID: 26260
Summary: undefined reference to `_Unwind_Resume'
Product: glibc
Version: 2.31
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: build
Assignee: unassigned at sourceware dot org
Reporter: sourceware@le-garrec.fr
CC: carlos at redhat dot com
Target Milestone: ---
I can't build glibc if gcc was built with -O0 option. I open a bug in the GCC
project (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96217) but they told me
the problem was in glibc.
The glibc log says :
/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld.bfd:
/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/32/libgcc.a(_divdi3.o): in function
`__divdi3':
/var/tmp/portage/sys-devel/gcc-10.1.0-r2/work/gcc-10.1.0/libgcc/libgcc2.c:1246:
undefined reference to `_Unwind_Resume'
/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld.bfd:
/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/32/libgcc.a(_divdi3.o):(.data.rel.local.DW.ref.__gcc_personality_v0[DW.ref.__gcc_personality_v0]+0x0):
undefined reference to `__gcc_personality_v0'
/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld.bfd:
/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/32/libgcc.a(_moddi3.o): in function
`__moddi3':
/var/tmp/portage/sys-devel/gcc-10.1.0-r2/work/gcc-10.1.0/libgcc/libgcc2.c:1269:
undefined reference to `_Unwind_Resume'
The solution is to make a change in Makeconfig :
from
gnulib = -lgcc $(gnulib-arch)
to
gnulib = -lgcc -lgcc_eh $(gnulib-arch)
What do you think of this change ? Do you think that glibc should supports -O0
compilation ?
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug build/26260] undefined reference to `_Unwind_Resume'
2020-07-17 20:07 [Bug build/26260] New: undefined reference to `_Unwind_Resume' sourceware@le-garrec.fr
@ 2020-07-17 20:08 ` sourceware@le-garrec.fr
2020-07-17 20:48 ` joseph at codesourcery dot com
1 sibling, 0 replies; 3+ messages in thread
From: sourceware@le-garrec.fr @ 2020-07-17 20:08 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=26260
LE GARREC Vincent <sourceware@le-garrec.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |sourceware@le-garrec.fr
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug build/26260] undefined reference to `_Unwind_Resume'
2020-07-17 20:07 [Bug build/26260] New: undefined reference to `_Unwind_Resume' sourceware@le-garrec.fr
2020-07-17 20:08 ` [Bug build/26260] " sourceware@le-garrec.fr
@ 2020-07-17 20:48 ` joseph at codesourcery dot com
1 sibling, 0 replies; 3+ messages in thread
From: joseph at codesourcery dot com @ 2020-07-17 20:48 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=26260
--- Comment #1 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
Linking libc with libgcc_eh is not correct. See the four-paragraph
comment on the definitions of libunwind, gnulib and related variables for
an explanation. There are various requirements on libgcc and the GCC
build process to avoid such circular dependencies and to ensure that a
stripped glibc binary built with an inhibit_libc GCC is identical to one
built following a longer sequence of alternating GCC and glibc builds.
It seems you've found another such requirement: libgcc must not be built
in a way that introduces references to EH symbols in the code statically
linked into shared libc.
glibc does not itself support being built with -O0 either. It would be
desirable to do so, but there might still be requirements in that case for
some individual files or functions to be compiled with optimization.
Likewise, even if a libgcc mostly built with -O0 works for building glibc,
it seems optimization might be required for building some files therein.
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-07-17 20:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-17 20:07 [Bug build/26260] New: undefined reference to `_Unwind_Resume' sourceware@le-garrec.fr
2020-07-17 20:08 ` [Bug build/26260] " sourceware@le-garrec.fr
2020-07-17 20:48 ` joseph at codesourcery dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).