From 0ee6e13f7f0634bb7858dcc99222f96054f3612d Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Mon, 30 Dec 2024 12:41:51 +0100 Subject: [PATCH] x86-64: Reorder dynamic linker list in ldd script (bug 32508) Move the x86-64 loader first, before the i386 and x32 loaders. In most cases, it's the loader the script needs. This avoids an error message if the i386 loader does not work. The effect of this change to the generated ldd script looks like this: -RTLDLIST="/lib/ld-linux.so.2 /lib64/ld-linux-x86-64.so.2 /libx32/ld-linux-x32.so.2" +RTLDLIST="/lib64/ld-linux-x86-64.so.2 /lib/ld-linux.so.2 /libx32/ld-linux-x32.so.2" Reviewed-by: Sam James --- sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed b/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed index 49c0c7a3a8..ed5277e3cc 100644 --- a/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed +++ b/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed @@ -1 +1 @@ -s_^\(RTLDLIST=\)\(.*lib\)\(\|64\|x32\)\(/[^/]*\)\(-x86-64\|-x32\)\(\.so\.[0-9.]*\)[ ]*$_\1"\2\4\6 \264\4-x86-64\6 \2x32\4-x32\6"_ +s_^\(RTLDLIST=\)\(.*lib\)\(\|64\|x32\)\(/[^/]*\)\(-x86-64\|-x32\)\(\.so\.[0-9.]*\)[ ]*$_\1"\264\4-x86-64\6 \2\4\6 \2x32\4-x32\6"_