From patchwork Wed Feb 16 20:32:18 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 83400 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 4EFD2B70E3 for ; Thu, 17 Feb 2011 07:32:28 +1100 (EST) Received: (qmail 21810 invoked by alias); 16 Feb 2011 20:32:26 -0000 Received: (qmail 21799 invoked by uid 22791); 16 Feb 2011 20:32:25 -0000 X-SWARE-Spam-Status: No, hits=-1.3 required=5.0 tests=AWL, BAYES_00, NO_DNS_FOR_FROM, TW_IB, TW_UX, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mga09.intel.com (HELO mga09.intel.com) (134.134.136.24) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 16 Feb 2011 20:32:20 +0000 Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga102.jf.intel.com with ESMTP; 16 Feb 2011 12:32:19 -0800 X-ExtLoop1: 1 Received: from gnu-6.sc.intel.com ([10.3.194.135]) by orsmga001.jf.intel.com with ESMTP; 16 Feb 2011 12:32:19 -0800 Received: by gnu-6.sc.intel.com (Postfix, from userid 500) id DEA86180D83; Wed, 16 Feb 2011 12:32:18 -0800 (PST) Date: Wed, 16 Feb 2011 12:32:18 -0800 From: "H.J. Lu" To: gcc-patches@gcc.gnu.org Subject: [x32] Change x32 library path to libx32 Message-ID: <20110216203218.GA4689@intel.com> Reply-To: "H.J. Lu" MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hi, I checked in this patch to change x32 LIBPATH_SUFFIX to x32, per x32 psABI draft verion 0.2: https://sites.google.com/site/x32abi/ H.J. --- From f2b64f76a345eba08d660f095d749284e0b59d3e Mon Sep 17 00:00:00 2001 From: H.J. Lu Date: Wed, 16 Feb 2011 11:03:45 -0800 Subject: [PATCH 3/4] Change x32 library path to libx32. --- gcc/ChangeLog.x32 | 7 +++++++ gcc/config/i386/linux64.h | 2 +- gcc/config/i386/t-linuxx32 | 31 ++++++++++++++++++++++++++++--- 3 files changed, 36 insertions(+), 4 deletions(-) diff --git a/gcc/ChangeLog.x32 b/gcc/ChangeLog.x32 index 3a7e980..4219032 100644 --- a/gcc/ChangeLog.x32 +++ b/gcc/ChangeLog.x32 @@ -1,5 +1,12 @@ 2011-02-16 H.J. Lu + * config/i386/linux64.h (GLIBC_DYNAMIC_LINKERX32): Update + ld.so path. + + * config/i386/t-linuxx32: Change x32 library path to libx32. + +2011-02-16 H.J. Lu + PR target/47766 * config/i386/i386.md (PTR): New. (stack_protect_set: Check TARGET_LP64 instead of TARGET_64BIT. diff --git a/gcc/config/i386/linux64.h b/gcc/config/i386/linux64.h index 0855cb7..bf5be73 100644 --- a/gcc/config/i386/linux64.h +++ b/gcc/config/i386/linux64.h @@ -61,7 +61,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2" #define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2" -#define GLIBC_DYNAMIC_LINKERX32 "/lib32/ld-linux-x32.so.2" +#define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2" #if TARGET_64BIT_DEFAULT #define SPEC_32 "m32" diff --git a/gcc/config/i386/t-linuxx32 b/gcc/config/i386/t-linuxx32 index a4741e1..92acf91 100644 --- a/gcc/config/i386/t-linuxx32 +++ b/gcc/config/i386/t-linuxx32 @@ -1,13 +1,38 @@ +# Copyright (C) 2011 Free Software Foundation, Inc. +# +# This file is part of GCC. +# +# GCC is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3, or (at your option) +# any later version. +# +# GCC is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GCC; see the file COPYING3. If not see +# . + +# 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. + # To support i386, x86-64 and x32 libraries, the directory structrue # should be: # # /lib has i386 libraries. # /lib64 has x86-64 libraries. -# /lib32 has x32 libraries. - +# /libx32 has x32 libraries. +# MULTILIB_OPTIONS = m64/m32/mx32 MULTILIB_DIRNAMES = 64 32 x32 -MULTILIB_OSDIRNAMES = ../lib64 ../lib ../lib32 +MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) ../libx32 LIBGCC = stmp-multilib INSTALL_LIBGCC = install-multilib