local-ld-multiarch
authorGNU Libc Maintainers <debian-glibc@lists.debian.org>
Sun, 14 Jan 2018 10:24:48 +0000 (10:24 +0000)
committerAurelien Jarno <aurel32@debian.org>
Sun, 14 Jan 2018 10:24:48 +0000 (10:24 +0000)
2012-05-01  Aurelien Jarno  <aurelien@aurel32.net>

* elf/Makefile(trusted-dirs.st): Fix DL_DST_LIB computation with
two level slibdir directories.

2009-09-08  Aurelien Jarno  <aurelien@aurel32.net>

* Makeconfig: add support for multiarch compat directories.

Gbp-Pq: Topic any
Gbp-Pq: Name local-ld-multiarch.diff

Makeconfig
elf/Makefile

index 144e25462f984b6be9c90e918e966834e3dc9a38..f883a19b61717422324f676c3f5c249589689e3b 100644 (file)
@@ -151,6 +151,11 @@ libdir = $(exec_prefix)/lib
 endif
 inst_libdir = $(install_root)$(libdir)
 
+# Compat places to look for libraries
+ifndef extra_libdir
+extra_libdir = /lib:$(exec_prefix)/lib
+endif
+
 # Where to install the shared library.
 ifndef slibdir
 slibdir = $(exec_prefix)/lib
@@ -578,6 +583,10 @@ else
 default-rpath = $(libdir)
 endif
 
+ifdef extra_libdir
+default-rpath += :$(extra_libdir)
+endif
+
 ifndef link-extra-libs
 link-extra-libs = $(LDLIBS-$(@F))
 link-extra-libs-static = $(link-extra-libs)
index 26d75e6d74633d4a58fb52c9a197a6d3a3aac51d..a4de88f187fde4a8c41cc771a774fe2f06c88bd0 100644 (file)
@@ -493,7 +493,7 @@ $(objpfx)trusted-dirs.st: Makefile $(..)Makeconfig
        $(make-target-directory)
        echo "$(subst :, ,$(default-rpath) $(user-defined-trusted-dirs))"    \
        | $(AWK) -f gen-trusted-dirs.awk > ${@:st=T};
-       echo '#define DL_DST_LIB "$(notdir $(slibdir))"' >> ${@:st=T}
+       echo '#define DL_DST_LIB "$(shell echo $(slibdir) | sed 's,/,,')"' >> ${@:st=T}
        $(move-if-change) ${@:st=T} ${@:st=h}
        touch $@
 CPPFLAGS-dl-load.c = -I$(objpfx). -I$(csu-objpfx).