Patchwork [7/8] gcc: remove the 64bithack patch

login
register
mail settings
Submitter Nitin A Kamble
Date March 15, 2012, 2:02 a.m.
Message ID <9152da8c4a5a72705532722a11a3bfdaa0fe4787.1331776832.git.nitin.a.kamble@intel.com>
Download mbox | patch
Permalink /patch/23373/
State New
Headers show

Comments

Nitin A Kamble - March 15, 2012, 2:02 a.m.
From: Nitin A Kamble <nitin.a.kamble@intel.com>

and bump PR

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
---
 meta/recipes-devtools/gcc/gcc-4.6.inc             |    1 -
 meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch |   68 ---------------------
 2 files changed, 0 insertions(+), 69 deletions(-)
 delete mode 100644 meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch
Richard Purdie - March 15, 2012, 8:30 a.m.
On Wed, 2012-03-14 at 19:02 -0700, nitin.a.kamble@intel.com wrote:
> From: Nitin A Kamble <nitin.a.kamble@intel.com>
> 
> and bump PR
> 
> Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
> ---
>  meta/recipes-devtools/gcc/gcc-4.6.inc             |    1 -
>  meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch |   68 ---------------------
>  2 files changed, 0 insertions(+), 69 deletions(-)
>  delete mode 100644 meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch


As far as I can tell whilst this will make multilib work on the target
device, since you've removed this patch, the actual -cross toolchains
used for multilib builds will be broken since they may or may not look
in the correct libdir?

Cheers,

Richard
Nitin A Kamble - March 15, 2012, 4:03 p.m.
> -----Original Message-----
> From: openembedded-core-bounces@lists.openembedded.org
> [mailto:openembedded-core-bounces@lists.openembedded.org] On Behalf Of
> Richard Purdie
> Sent: Thursday, March 15, 2012 1:31 AM
> To: Patches and discussions about the oe-core layer
> Subject: Re: [OE-core] [PATCH 7/8] gcc: remove the 64bithack patch
> 
> On Wed, 2012-03-14 at 19:02 -0700, nitin.a.kamble@intel.com wrote:
> > From: Nitin A Kamble <nitin.a.kamble@intel.com>
> >
> > and bump PR
> >
> > Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
> > ---
> >  meta/recipes-devtools/gcc/gcc-4.6.inc             |    1 -
> >  meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch |   68 -----------
> ----------
> >  2 files changed, 0 insertions(+), 69 deletions(-)
> >  delete mode 100644 meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch
> 
> 
> As far as I can tell whilst this will make multilib work on the target
> device, since you've removed this patch, the actual -cross toolchains
> used for multilib builds will be broken since they may or may not look
> in the correct libdir?
> 
> Cheers,
> 
> Richard
> 

Hi Richard,
  This is not an issue. do_gcc_multilib_setup() is always configuring the gcc multilib files. For cross gcc recipes it is only using DEFAULTTUNE while for target it is using DEFAULTTUNE & MULTILIB_VARIENTS. Also in my testing cross gcc recipes did not have any such issues.

Thanks,
Nitin

Patch

diff --git a/meta/recipes-devtools/gcc/gcc-4.6.inc b/meta/recipes-devtools/gcc/gcc-4.6.inc
index 99c30a6..08f2a54 100644
--- a/meta/recipes-devtools/gcc/gcc-4.6.inc
+++ b/meta/recipes-devtools/gcc/gcc-4.6.inc
@@ -59,7 +59,6 @@  SRC_URI = "svn://gcc.gnu.org/svn/gcc/branches;module=${BRANCH};proto=http \
            file://gcc-poison-system-directories.patch \
            file://gcc-poison-dir-extend.patch \
            file://gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
-	   file://64bithack.patch \
 	   file://optional_libstdc.patch \
 	   file://disable_relax_pic_calls_flag.patch \
 	   file://COLLECT_GCC_OPTIONS.patch \
diff --git a/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch b/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch
deleted file mode 100644
index d35753a..0000000
--- a/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch
+++ /dev/null
@@ -1,68 +0,0 @@ 
-Upstream-Status: Inappropriate [embedded specific]
-
-GCC has internal multilib handling code but it assumes a very specific rigid directory
-layout. The build system implementation of multilib layout is very generic and allows
-complete customisation of the library directories.
-
-This patch is a partial solution to allow any custom directories to be passed into gcc
-and handled correctly. It forces gcc to use the base_libdir (which is the current 
-directory, "."). We need to do this for each multilib that is configured as we don't
-know which compiler options may be being passed into the compiler. Since we have a compiler
-per mulitlib at this point that isn't an issue.
-
-The one problem is the target compiler is only going to work for the default multlilib at
-this point. Ideally we'd figure out which multilibs were being enabled with which paths
-and be able to patch these entries with a complete set of correct paths but this we
-don't have such code at this point. This is something the target gcc recipe should do 
-and override these platform defaults in its build config.
-
-RP 15/8/11
-
-Index: gcc-4_6-branch/gcc/config/i386/t-linux64
-===================================================================
---- gcc-4_6-branch.orig/gcc/config/i386/t-linux64	2011-06-23 15:15:29.000000000 +0100
-+++ gcc-4_6-branch/gcc/config/i386/t-linux64	2011-08-15 13:09:03.772415848 +0100
-@@ -24,8 +24,8 @@
- # MULTILIB_OSDIRNAMES according to what is found on the target.
- 
- MULTILIB_OPTIONS = m64/m32
--MULTILIB_DIRNAMES = 64 32 
--MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
-+MULTILIB_DIRNAMES = . .
-+MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
- 
- LIBGCC = stmp-multilib
- INSTALL_LIBGCC = install-multilib
-Index: gcc-4_6-branch/gcc/config/mips/t-linux64
-===================================================================
---- gcc-4_6-branch.orig/gcc/config/mips/t-linux64	2011-08-15 13:06:13.732415763 +0100
-+++ gcc-4_6-branch/gcc/config/mips/t-linux64	2011-08-15 13:09:11.452419446 +0100
-@@ -17,8 +17,8 @@
- # <http://www.gnu.org/licenses/>.
- 
- MULTILIB_OPTIONS = mabi=n32/mabi=32/mabi=64
--MULTILIB_DIRNAMES = n32 32 64
--MULTILIB_OSDIRNAMES = ../lib32 ../lib ../lib64
-+MULTILIB_DIRNAMES = . . .
-+MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
- 
- EXTRA_MULTILIB_PARTS=crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o
- 
-Index: gcc-4_6-branch/gcc/config/rs6000/t-linux64
-===================================================================
---- gcc-4_6-branch.orig/gcc/config/rs6000/t-linux64	2011-08-15 13:06:25.272415822 +0100
-+++ gcc-4_6-branch/gcc/config/rs6000/t-linux64	2011-08-15 13:09:21.062415878 +0100
-@@ -32,11 +32,11 @@
- # MULTILIB_OSDIRNAMES according to what is found on the target.
- 
- MULTILIB_OPTIONS        = m64/m32 msoft-float
--MULTILIB_DIRNAMES       = 64 32 nof
-+MULTILIB_DIRNAMES       = . . .
- MULTILIB_EXTRA_OPTS     = fPIC mstrict-align
- MULTILIB_EXCEPTIONS     = m64/msoft-float
- MULTILIB_EXCLUSIONS     = m64/!m32/msoft-float
--MULTILIB_OSDIRNAMES	= ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) nof
-+MULTILIB_OSDIRNAMES	= ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
- MULTILIB_MATCHES        = $(MULTILIB_MATCHES_FLOAT)
- 
- softfp_wrap_start := '\#ifndef __powerpc64__'