Skip to contentSkip to conversation

Bug fix for 1362

PATCH In review Yu Ke 5 participants 11 messages Aug 14, 2011 – Aug 16, 2011

lore
Share & tools
lore

Yu Ke

author
#0 lore raw

cover Bug fix for 1362

Per discussion in mailing list, This patch make gcc honouring libdir, to fix the bug 1362. it has been tested for qemux86, qemux86-64, qemuarm, qemuppc

The following changes since commit d126e22f6b3f27196144f87e22b36ebccd6dea65:
Darren Hart (1):
rt-tests: use an explicit commit ID

are available in the git repository at:

git://git.pokylinux.org/poky-contrib kyu3/bug-1362
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kyu3/bug-1362

Yu Ke (1):
gcc-cross-intermediate: revise the 64bithack.patch for multilib case

 meta/recipes-devtools/gcc/gcc-4.6.inc             |    2 +-
 meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch |   16 +++++++++-------
 2 files changed, 10 insertions(+), 8 deletions(-)
author
#1 lore raw

PATCH 1/1 gcc-cross-intermediate: revise the 64bithack.patch for multilib case

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

CC Kumar Gala <[email protected]>
CC Richard Purdie <[email protected]>
---
 meta/recipes-devtools/gcc/gcc-4.6.inc             |    2 +-
 meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch |   16 +++++++++-------
 2 files changed, 10 insertions(+), 8 deletions(-)
meta/recipes-devtools/gcc/gcc-4.6.inc +1 -1
index 0a148b4..ff8ca24 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-PR = "r7"
+PR = "r8"
 
 # Third digit in PV should be incremented after a minor release
 # happens from this branch on gcc e.g. currently its 4.6.0
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch +9 -7
index 4b846bb..c1129ca 100644
@@ -5,18 +5,20 @@ By default gcc places 64 bit libs in a lib64 directory. This makes it use
 
 RP 25/7/10
 
+revise it to honour base_libdir
+
+Yu Ke <[email protected]> Aug 13, 2011
+
 Index: gcc-4.6.0/gcc/config/i386/t-linux64
 ===================================================================
 --- gcc-4.6.0.orig/gcc/config/i386/t-linux64
 +++ gcc-4.6.0/gcc/config/i386/t-linux64
-@@ -24,8 +24,8 @@
- # MULTILIB_OSDIRNAMES according to what is found on the target.
- 
+@@ -25,7 +25,7 @@
+
  MULTILIB_OPTIONS = m64/m32
--MULTILIB_DIRNAMES = 64 32 
+ MULTILIB_DIRNAMES = 64 32 
 -MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
-+MULTILIB_DIRNAMES = . 32
-+MULTILIB_OSDIRNAMES = . $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
- 
++MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
+
  LIBGCC = stmp-multilib
  INSTALL_LIBGCC = install-multilib
Signature · 1 line
1.7.0.4
#2 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 5 lines · Yu Ke

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

I think similar patch should be done to ppc and mips as well.

Quoted 29 lines

CC: Kumar Gala <[email protected]> CC: Richard Purdie <[email protected]>

meta/recipes-devtools/gcc/gcc-4.6.inc | 2 +-
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch | 16
+++++++++------- 2 files changed, 10 insertions(+), 8 deletions(-)

(quoted diff) +0 -0

b/meta/recipes-devtools/gcc/gcc-4.6.inc index 0a148b4..ff8ca24 100644 --- a/meta/recipes-devtools/gcc/gcc-4.6.inc +++ b/meta/recipes-devtools/gcc/gcc-4.6.inc @@ -1,6 +1,6 @@ require gcc-common.inc

-PR = "r7" +PR = "r8"

# Third digit in PV should be incremented after a minor release # happens from this branch on gcc e.g. currently its 4.6.0 diff --git a/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch b/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch index 4b846bb..c1129ca 100644 --- a/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch +++ b/meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch @@ -5,18 +5,20 @@ By default gcc places 64 bit libs in a lib64 directory. This makes it use

RP 25/7/10

Quoted 16 lines

+revise it to honour base_libdir + +Yu Ke <[email protected]> Aug 13, 2011 + Index: gcc-4.6.0/gcc/config/i386/t-linux64
===================================================================
--- gcc-4.6.0.orig/gcc/config/i386/t-linux64 +++ gcc-4.6.0/gcc/config/i386/t-linux64 -@@ -24,8 +24,8 @@ - # MULTILIB_OSDIRNAMES according to what is found on the target. - +@@ -25,7 +25,7 @@ + MULTILIB_OPTIONS = m64/m32 --MULTILIB_DIRNAMES = 64 32 + MULTILIB_DIRNAMES = 64 32 -MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) -+MULTILIB_DIRNAMES = . 32 -+MULTILIB_OSDIRNAMES = . $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)
- ++MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) + LIBGCC = stmp-multilib INSTALL_LIBGCC = install-multilib

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEYEARECAAYFAk5H51YACgkQuwUzVZGdMxQ8jgCfXo7MQSziJZqLCMjxgsakiac4 2UoAn3BoazvtV+hlGkGhMCBk9sOGuvYg
=emFC
-----END PGP SIGNATURE-----

#3 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

Quoted 11 lines · Khem Raj

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 5 lines · Yu Ke

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

I think similar patch should be done to ppc and mips as well.

According to Kumar, current ppc works just fine in multilib 64bit case. so ppc may not need this kind of patch. I am not sure how is mips. Since i am not familar with mips, i'd like to leave it to other mips expert.

Regards
Ke

#4 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 8 lines · Yu Ke
Quoted 7 lines · Khem Raj

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1

Quoted 4 lines · Yu Ke

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

Quoted 9 lines
Quoted 3 lines
Quoted 1 line

so this patch fix this issue by making gcc honour the libdir.

I think similar patch should be done to ppc and mips as well.

According to Kumar, current ppc works just fine in multilib 64bit case. so ppc may not need this kind of patch. I am not sure how is mips. Since i am not familar with mips, i'd like to leave it to other mips expert.

I guess since mips multilib is not yet there and /lib is used by o32 abi even in multilib case things would be simple for mips. Would using gcc defaults for x86_64 work ? It might break backward compatibility in non multilib case

Quoted 1 line

Regards Ke

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEUEARECAAYFAk5JQCAACgkQuwUzVZGdMxQdLwCY1ijPd8bFknmc8OLI9/OUVTZf FACfToqH6QXmIRNIuZkIAkYHSSiFaro=
=pfvK
-----END PGP SIGNATURE-----

#5 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

In reply to Yu Ke

Op 14 aug. 2011, om 15:32 heeft Yu Ke het volgende geschreven:

Quoted 6 lines

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

Quoted 7 lines
CC Kumar Gala <[email protected]>
CC Richard Purdie <[email protected]>

---
meta/recipes-devtools/gcc/gcc-4.6.inc | 2 +-
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch | 16 +++++++++-------

wouldn't gcc 4.5 need a similar change?

#6 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

Quoted 12 lines · Koen Kooi

Op 14 aug. 2011, om 15:32 heeft Yu Ke het volgende geschreven:

Quoted 9 lines

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

CC Kumar Gala<[email protected]>
CC Richard Purdie<[email protected]>
Quoted 6 lines
Quoted 4 lines

---
meta/recipes-devtools/gcc/gcc-4.6.inc | 2 +-
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch | 16 +++++++++-------

wouldn't gcc 4.5 need a similar change?

yes, gcc 4.5 should also has this change. I will sent out another patch for this.

just curious question, what is gcc 4.5 for, since gcc 4.6 is already there?

Regards
Ke

#7 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

Quoted 18 lines · Yu Ke
Quoted 17 lines · Koen Kooi

Op 14 aug. 2011, om 15:32 heeft Yu Ke het volgende geschreven:

Quoted 13 lines

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

CC Kumar Gala<[email protected]>
CC Richard Purdie<[email protected]>

---
meta/recipes-devtools/gcc/gcc-4.6.inc | 2 +-
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch | 16 +++++++++-------

Quoted 4 lines
Quoted 1 line

wouldn't gcc 4.5 need a similar change?

yes, gcc 4.5 should also has this change. I will sent out another patch for this.

Please take a look at:

http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=rpurdie/ml4&id=4de8e0e9c286ff64f1b7fd2e695fe2d62fdadfbd

I've updated the patch header and ensured that whichever compiler options are used, the compiler works as expected and also applied this to mips and pcc.

Could you also please open a bug about target gcc multilib as mentioned in the patch header (targeted at post 1.1).

Quoted 1 line

just curious question, what is gcc 4.5 for, since gcc 4.6 is already there?

Some people are still using gcc 4.5 for various reasons. It is getting to the point we should probably move that to meta-oe though?

Cheers,

Richard

#8 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

Quoted 19 lines · Richard Purdie
Quoted 18 lines · Yu Ke
Quoted 17 lines · Koen Kooi

Op 14 aug. 2011, om 15:32 heeft Yu Ke het volgende geschreven:

Quoted 13 lines

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

CC Kumar Gala<[email protected]>
CC Richard Purdie<[email protected]>

---
meta/recipes-devtools/gcc/gcc-4.6.inc | 2 +-
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch | 16 +++++++++-------

Quoted 8 lines
Quoted 4 lines
Quoted 1 line

wouldn't gcc 4.5 need a similar change?

yes, gcc 4.5 should also has this change. I will sent out another patch for this.

Please take a look at:

http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=rpurdie/ml4&id=4de8e0e9c286ff64f1b7fd2e695fe2d62fdadfbd

Thanks. it is more comprehensive. just a small issue, the parentheses looks mismatching in

++MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir) ../$(shell basename $(base_libdir)

Quoted 7 lines

I've updated the patch header and ensured that whichever compiler options are used, the compiler works as expected and also applied this to mips and pcc.

Could you also please open a bug about target gcc multilib as mentioned in the patch header (targeted at post 1.1).

done. http://bugzilla.yoctoproject.org/show_bug.cgi?id=1369

Quoted 16 lines
Quoted 2 lines

just curious question, what is gcc 4.5 for, since gcc 4.6 is already there?

Some people are still using gcc 4.5 for various reasons. It is getting to the point we should probably move that to meta-oe though?

Cheers,

Richard

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core

#9 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

Quoted 27 lines · Yu Ke
Quoted 26 lines · Richard Purdie
Quoted 18 lines · Yu Ke
Quoted 17 lines · Koen Kooi

Op 14 aug. 2011, om 15:32 heeft Yu Ke het volgende geschreven:

Quoted 13 lines

current gcc-cross-intermediate has build failure in qemux86-64 lib64 multilib case. the reason is that it still use lib instead of lib64 while do_install use the libdir i.e. lib64

so this patch fix this issue by making gcc honour the libdir.

CC Kumar Gala<[email protected]>
CC Richard Purdie<[email protected]>

---
meta/recipes-devtools/gcc/gcc-4.6.inc | 2 +-
meta/recipes-devtools/gcc/gcc-4.6/64bithack.patch | 16 +++++++++-------

Quoted 4 lines
Quoted 1 line

wouldn't gcc 4.5 need a similar change?

yes, gcc 4.5 should also has this change. I will sent out another patch for this.

Please take a look at:

Quoted 7 lines
Quoted 1 line

http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=rpurdie/ml4&id=4de8e0e9c286ff64f1b7fd2e695fe2d62fdadfbd

Thanks. it is more comprehensive. just a small issue, the parentheses looks mismatching in

++MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir) ../$(shell basename $(base_libdir)

Right, I've just noticed my test build was failing and that is likely why :)

Quoted 8 lines
Quoted 6 lines

I've updated the patch header and ensured that whichever compiler options are used, the compiler works as expected and also applied this to mips and pcc.

Could you also please open a bug about target gcc multilib as mentioned in the patch header (targeted at post 1.1).

done. http://bugzilla.yoctoproject.org/show_bug.cgi?id=1369

Great, thanks.

Cheers,

Richard

#10 lore raw

Re: [PATCH 1/1] gcc-cross-intermediate: revise the 64bithack.patch for multilib case

In reply to Richard Purdie
Quoted 6 lines · Richard Purdie
Quoted 1 line

just curious question, what is gcc 4.5 for, since gcc 4.6 is already there?

Some people are still using gcc 4.5 for various reasons. It is getting to the point we should probably move that to meta-oe though?

meta-oe already has recipes for gcc 4.5 so may be removing them from oe-core and letting people who want to use 4.5
use meta-oe