public inbox for libc-help@sourceware.org
 help / color / mirror / Atom feed
* Glibc crashes while linking
@ 2021-01-08 20:57 spaze
  2021-01-09 11:21 ` Florian Weimer
  0 siblings, 1 reply; 2+ messages in thread
From: spaze @ 2021-01-08 20:57 UTC (permalink / raw)
  To: libc-help

Hello,
I am trying to compile glibc for my personal project, and while everything was installing, an error has occured while it was linking files:

make[3]: Leaving directory '/mnt/d/akari/glibc-2.32/elf' 
gcc -B/cross-tools/bin/   -nostdlib -nostartfiles -r -o /mnt/d/akari/glibc-build/elf/librtld.os '-Wl,-(' /mnt/d/akari/glibc-build/elf/dl-allobjs.os /mnt/d/akari/glibc-build/elf/rtld-libc.a -lgcc '-Wl,-)' \
          -Wl,-Map,/mnt/d/akari/glibc-build/elf/librtld.os.map
gcc -B/cross-tools/bin/   -nostdlib -nostartfiles -shared -o /mnt/d/akari/glibc-build/elf/ld.so.new             \
          -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both -Wl,-z,defs       \
          /mnt/d/akari/glibc-build/elf/librtld.os -Wl,--version-script=/mnt/d/akari/glibc-build/ld.map          \
          -Wl,-soname=ld-linux-x86-64.so.2                      \
          -Wl,-defsym=_begin=0
/usr/bin/ld: /mnt/d/akari/glibc-build/elf/librtld.os: in function `dl_main':
/mnt/d/akari/glibc-2.32/elf/rtld.c:1785: undefined reference to `__access'
/usr/bin/ld: /mnt/d/akari/glibc-build/elf/librtld.os: in function `process_envvars':
/mnt/d/akari/glibc-2.32/elf/rtld.c:2814: undefined reference to `__GI___open64_nocancel'
/usr/bin/ld: /mnt/d/akari/glibc-2.32/elf/rtld.c:2788: undefined reference to `__access'
/usr/bin/ld: /mnt/d/akari/glibc-build/elf/librtld.os: in function `lose':
/mnt/d/akari/glibc-2.32/elf/dl-load.c:839: undefined reference to `__GI___close_nocancel'
/usr/bin/ld: /mnt/d/akari/glibc-build/elf/librtld.os: in function `open_verify':
/mnt/d/akari/glibc-2.32/elf/dl-load.c:1623: undefined reference to `__GI___open64_nocancel'
/usr/bin/ld: /mnt/d/akari/glibc-2.32/elf/dl-load.c:1636: undefined reference to `rtld_errno'
/usr/bin/ld: /mnt/d/akari/glibc-build/elf/librtld.os: relocation R_X86_64_PC32 against undefined hidden symbol `rtld_errno' can not be used when making a shared object
/usr/bin/ld: final link failed: bad value
collect2: error: ld returned 1 exit status
make[2]: *** [Makefile:566: /mnt/d/akari/glibc-build/elf/ld.so] Error 1
make[2]: Leaving directory '/mnt/d/akari/glibc-2.32/elf'
make[1]: *** [Makefile:470: elf/subdir_lib] Error 2
make[1]: Leaving directory '/mnt/d/akari/glibc-2.32'
make: *** [Makefile:9: all] Error 2

I do not know why this happened, but I can assume something is wrong with the librtld.os file.  If someone was willing to help me I would be really grateful.

Kind regards.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Glibc crashes while linking
  2021-01-08 20:57 Glibc crashes while linking spaze
@ 2021-01-09 11:21 ` Florian Weimer
  0 siblings, 0 replies; 2+ messages in thread
From: Florian Weimer @ 2021-01-09 11:21 UTC (permalink / raw)
  To: spaze--- via Libc-help; +Cc: spaze

* spaze:

> I am trying to compile glibc for my personal project, and while
> everything was installing, an error has occured while it was linking
> files:

Would you please list the commands that you used to build and install
glibc?

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-01-09 11:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-08 20:57 Glibc crashes while linking spaze
2021-01-09 11:21 ` Florian Weimer

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).