about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/mips
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv/linux/mips')
-rw-r--r--sysdeps/unix/sysv/linux/mips/configure52
-rw-r--r--sysdeps/unix/sysv/linux/mips/configure.ac34
2 files changed, 34 insertions, 52 deletions
diff --git a/sysdeps/unix/sysv/linux/mips/configure b/sysdeps/unix/sysv/linux/mips/configure
index e8b0d7b154..7fac4f423e 100644
--- a/sysdeps/unix/sysv/linux/mips/configure
+++ b/sysdeps/unix/sysv/linux/mips/configure
@@ -268,33 +268,35 @@ fi
 config_vars="$config_vars
 default-abi = ${libc_mips_abi}_${libc_mips_float}${libc_mips_nan}"
 
+case $machine in
+mips/mips64/n64/*)
+  test -n "$libc_cv_slibdir" ||
 case "$prefix" in
 /usr | /usr/)
-  # 64-bit libraries on bi-arch platforms go in /lib64 instead of /lib.
-  # Allow earlier configure scripts to handle libc_cv_slibdir, libdir,
-  # and libc_cv_localedir.
-  test -n "$libc_cv_slibdir" || \
-  case $machine in
-  mips/mips64/n64/* )
-    libc_cv_slibdir="/lib64"
-    if test "$libdir" = '${exec_prefix}/lib'; then
-      libdir='${exec_prefix}/lib64';
-      # Locale data can be shared between 32bit and 64bit libraries
-      libc_cv_localedir='${exec_prefix}/lib/locale'
-    fi
-    ;;
-  mips/mips64/n32/* )
-    libc_cv_slibdir="/lib32"
-    if test "$libdir" = '${exec_prefix}/lib'; then
-      libdir='${exec_prefix}/lib32';
-      # Locale data can be shared between 32bit and 64bit libraries
-      libc_cv_localedir='${exec_prefix}/lib/locale'
-    fi
-    ;;
-  *)
-    libc_cv_slibdir="/lib"
-    ;;
-  esac
+  libc_cv_slibdir=/lib64
+  libc_cv_rtlddir=/lib64
+  if test "$libdir" = '${exec_prefix}/lib'; then
+    libdir='${exec_prefix}/lib64';
+    # Locale data can be shared between 32-bit and 64-bit libraries.
+    libc_cv_localedir='${exec_prefix}/lib/locale'
+  fi
+  ;;
+esac
+  ;;
+mips/mips64/n32/*)
+  test -n "$libc_cv_slibdir" ||
+case "$prefix" in
+/usr | /usr/)
+  libc_cv_slibdir=/lib32
+  libc_cv_rtlddir=/lib32
+  if test "$libdir" = '${exec_prefix}/lib'; then
+    libdir='${exec_prefix}/lib32';
+    # Locale data can be shared between 32-bit and 64-bit libraries.
+    libc_cv_localedir='${exec_prefix}/lib/locale'
+  fi
+  ;;
+esac
+  ;;
 esac
 
 libc_cv_gcc_unwind_find_fde=yes
diff --git a/sysdeps/unix/sysv/linux/mips/configure.ac b/sysdeps/unix/sysv/linux/mips/configure.ac
index 7087a14a5e..c3f217a34f 100644
--- a/sysdeps/unix/sysv/linux/mips/configure.ac
+++ b/sysdeps/unix/sysv/linux/mips/configure.ac
@@ -58,33 +58,13 @@ fi
 LIBC_CONFIG_VAR([default-abi],
   [${libc_mips_abi}_${libc_mips_float}${libc_mips_nan}])
 
-case "$prefix" in
-/usr | /usr/)
-  # 64-bit libraries on bi-arch platforms go in /lib64 instead of /lib.
-  # Allow earlier configure scripts to handle libc_cv_slibdir, libdir,
-  # and libc_cv_localedir.
-  test -n "$libc_cv_slibdir" || \
-  case $machine in
-  mips/mips64/n64/* )
-    libc_cv_slibdir="/lib64"
-    if test "$libdir" = '${exec_prefix}/lib'; then
-      libdir='${exec_prefix}/lib64';
-      # Locale data can be shared between 32bit and 64bit libraries
-      libc_cv_localedir='${exec_prefix}/lib/locale'
-    fi
-    ;;
-  mips/mips64/n32/* )
-    libc_cv_slibdir="/lib32"
-    if test "$libdir" = '${exec_prefix}/lib'; then
-      libdir='${exec_prefix}/lib32';
-      # Locale data can be shared between 32bit and 64bit libraries
-      libc_cv_localedir='${exec_prefix}/lib/locale'
-    fi
-    ;;
-  *)
-    libc_cv_slibdir="/lib"
-    ;;
-  esac
+case $machine in
+mips/mips64/n64/*)
+  LIBC_SLIBDIR_RTLDDIR([lib64], [lib64])
+  ;;
+mips/mips64/n32/*)
+  LIBC_SLIBDIR_RTLDDIR([lib32], [lib32])
+  ;;
 esac
 
 libc_cv_gcc_unwind_find_fde=yes