glibc/SOURCES/glibc-rh2023420-7.patch
2021-12-24 04:19:29 +00:00

42 lines
1.4 KiB
Diff

commit 2e75604f8337fa4332977f72a8f6726309679edf
Author: Florian Weimer <fweimer@redhat.com>
Date: Fri Dec 10 16:06:36 2021 +0100
elf: Install a symbolic link to ld.so as /usr/bin/ld.so
This makes ld.so features such as --preload, --audit,
and --list-diagnostics more accessible to end users because they
do not need to know the ABI name of the dynamic loader.
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Conflicts:
elf/Makefile
(versioned shared objects downstream)
diff --git a/elf/Makefile b/elf/Makefile
index b3e8ab2792608de7..c552aff350c2faac 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -99,7 +99,7 @@ endif
ifeq (yes,$(build-shared))
extra-objs = $(all-rtld-routines:%=%.os) soinit.os sofini.os interp.os
generated += librtld.os dl-allobjs.os ld.so ldd
-install-others = $(inst_rtlddir)/$(rtld-installed-name)
+install-others = $(inst_rtlddir)/$(rtld-installed-name) $(inst_bindir)/ld.so
install-bin-script = ldd
endif
@@ -622,6 +622,11 @@ $(inst_rtlddir)/$(rtld-installed-name): \
$(make-target-directory)
$(make-shlib-link)
+# Creates the relative /usr/bin/ld.so symbolic link.
+$(inst_bindir)/ld.so: $(inst_rtlddir)/$(rtld-installed-name)
+ $(make-target-directory)
+ $(make-link)
+
# Special target called by parent to install just the dynamic linker.
.PHONY: ldso_install
ldso_install: $(inst_rtlddir)/$(rtld-installed-name)