# All lines beginning with `# DP:' are a description of the patch.
# DP: Description: Allow ldconfig to work on x86-64/i386 biarch systems

---
 sysdeps/unix/sysv/linux/x86_64/dl-cache.h |   21 ++++++++++++++++++++-
 1 file changed, 20 insertions(+), 1 deletion(-)

--- a/sysdeps/unix/sysv/linux/x86_64/dl-cache.h
+++ b/sysdeps/unix/sysv/linux/x86_64/dl-cache.h
@@ -27,7 +27,7 @@
       size_t len = strlen (dir);				\
       char path[len + 4];					\
       memcpy (path, dir, len + 1);				\
-      if (len >= 6 && ! memcmp (path + len - 6, "/lib64", 6))	\
+      if (len >= 6 && ! memcmp (path + len - 6, "/lib32", 6))	\
 	{							\
 	  len -= 2;						\
 	  path[len] = '\0';					\
@@ -41,7 +41,7 @@
       add_dir (path);						\
       if (len >= 4 && ! memcmp (path + len - 4, "/lib", 4))	\
 	{							\
-	  memcpy (path + len, "64", 3);				\
+	  memcpy (path + len, "32", 3);				\
 	  add_dir (path);					\
 	  memcpy (path + len, "x32", 4);				\
 	  add_dir (path);					\
