local-ld-multiarch
authorGNU Libc Maintainers <debian-glibc@lists.debian.org>
Tue, 4 Feb 2020 19:37:26 +0000 (19:37 +0000)
committerAurelien Jarno <aurel32@debian.org>
Tue, 4 Feb 2020 19:37:26 +0000 (19:37 +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 22c5016b7956aa16ca9fc92fe58285660cf75f00..beeda755596e734e12e3638afe0a8079ef895f20 100644 (file)
@@ -136,6 +136,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
@@ -589,6 +594,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 fa86ce2b8fc3e0021263a840a8da280b88ef7e91..b9e243b471e36c235654bb6f5a674638f1223f5a 100644 (file)
@@ -526,7 +526,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).