]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
rtld-elf: link libcompiler_rt on all architectures
authorRyan Libby <rlibby@FreeBSD.org>
Mon, 28 Dec 2020 08:44:25 +0000 (00:44 -0800)
committerRyan Libby <rlibby@FreeBSD.org>
Mon, 28 Dec 2020 08:44:25 +0000 (00:44 -0800)
commit63f93c7e11e33149429ddc2831cd1683b2e7f3e1
treedae53272865b7bc05938cb80b73c3e66a97c6c3e
parent85b8932d0a9a2f3a1e8db26892e863cd8dbc0846
rtld-elf: link libcompiler_rt on all architectures

Statically link rtld-elf with libcompiler_rt on all architectures so
that we don't need to try to pick and choose the bits we need from it
for each architecture (we now leave that to the linker).  Compilers may
emit calls to support functions in this library, but because of the use
of the linker flag -nostdlib for rtld's special needs, the library is
not linked as normal.

Previously we had two different solutions.  On some architectures, we
were able to extract reimplementations of the necessary builtin
functions from our special build of libc.  On ARM, we just linked
libcompiler_rt.

This is motivated by the same issue as D26199 and D27665, but should be
a simpler solution that will apply to all architectures.

Reviewed by: arichardson, kib
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D27736
libexec/rtld-elf/Makefile
libexec/rtld-elf/arm/Makefile.inc
libexec/rtld-elf/rtld-libc/Makefile.inc