diff mbox

sparc64, s390x - find 32bit system libraries

Message ID 4C9DEAB1.9000404@ubuntu.com
State New
Headers show

Commit Message

Matthias Klose Sept. 25, 2010, 12:27 p.m. UTC
as done for x86_64 and ppc64 in
http://gcc.gnu.org/ml/gcc-patches/2007-09/msg00696.html

ok for the trunk (and 4.5)?

   Matthias

Comments

Eric Botcazou Sept. 25, 2010, 1:11 p.m. UTC | #1
> as done for x86_64 and ppc64 in
> http://gcc.gnu.org/ml/gcc-patches/2007-09/msg00696.html
>
> ok for the trunk (and 4.5)?

The SPARC bits are OK.
Andreas Krebbel Oct. 4, 2010, 4:14 p.m. UTC | #2
On Sat, Sep 25, 2010 at 02:27:29PM +0200, Matthias Klose wrote:
> as done for x86_64 and ppc64 in
> http://gcc.gnu.org/ml/gcc-patches/2007-09/msg00696.html
> 
> ok for the trunk (and 4.5)?
> 
>   Matthias

> 2010-09-25  Matthias Klose  <doko@ubuntu.com>
> 
> 	* config/sparc/t-linux64 (MULTILIB_OSDIRNAMES): Use ../lib32 as the
> 	multilib osdirname if it exists.
> 	* config/s390/t-linux64 (MULTILIB_OSDIRNAMES): Likewise.

The s390 part is ok as well.

Bye,

-Andreas-
diff mbox

Patch

2010-09-25  Matthias Klose  <doko@ubuntu.com>

	* config/sparc/t-linux64 (MULTILIB_OSDIRNAMES): Use ../lib32 as the
	multilib osdirname if it exists.
	* config/s390/t-linux64 (MULTILIB_OSDIRNAMES): Likewise.

Index: gcc/config/s390/t-linux64
===================================================================
--- gcc/config/s390/t-linux64	(revision 164618)
+++ gcc/config/s390/t-linux64	(working copy)
@@ -1,3 +1,10 @@ 
+# On Debian, Ubuntu and other derivative distributions, the 32bit libraries
+# are found in /lib32 and /usr/lib32, /lib64 and /usr/lib64 are symlinks to
+# /lib and /usr/lib, while other distributions install libraries into /lib64
+# and /usr/lib64.  The LSB does not enforce the use of /lib64 and /usr/lib64,
+# it doesn't tell anything about the 32bit libraries on those systems.  Set
+# MULTILIB_OSDIRNAMES according to what is found on the target.
+
 MULTILIB_OPTIONS = m64/m31
 MULTILIB_DIRNAMES = 64 32
-MULTILIB_OSDIRNAMES = ../lib64 ../lib
+MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
Index: gcc/config/sparc/t-linux64
===================================================================
--- gcc/config/sparc/t-linux64	(revision 164618)
+++ gcc/config/sparc/t-linux64	(working copy)
@@ -17,9 +17,16 @@ 
 # along with GCC; see the file COPYING3.  If not see
 # <http://www.gnu.org/licenses/>.
 
+# On Debian, Ubuntu and other derivative distributions, the 32bit libraries
+# are found in /lib32 and /usr/lib32, /lib64 and /usr/lib64 are symlinks to
+# /lib and /usr/lib, while other distributions install libraries into /lib64
+# and /usr/lib64.  The LSB does not enforce the use of /lib64 and /usr/lib64,
+# it doesn't tell anything about the 32bit libraries on those systems.  Set
+# MULTILIB_OSDIRNAMES according to what is found on the target.
+
 MULTILIB_OPTIONS = m64/m32
 MULTILIB_DIRNAMES = 64 32
-MULTILIB_OSDIRNAMES = ../lib64 ../lib
+MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
 
 LIBGCC = stmp-multilib
 INSTALL_LIBGCC = install-multilib