diff options
author | Zhai Edwin <edwin.zhai@intel.com> | 2010-07-29 12:58:59 +0800 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-07-30 14:50:30 +0100 |
commit | d9f22d402459d2e70df83df65d4acc273297426a (patch) | |
tree | bc706fed13fc59df3adccd1a5ab9f9dd7ad062a9 /meta | |
parent | da1332a7dd5432dea0fbbce90641dbd2f2803fec (diff) | |
download | poky-d9f22d402459d2e70df83df65d4acc273297426a.tar.gz |
binutils: Fixed cross-compile issue for 64b build + arm target
Incoportate RP's patch, which seems to be lost when update.
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/packages/binutils/binutils-2.20.1/binutils-libtool.patch | 67 | ||||
-rw-r--r-- | meta/packages/binutils/binutils_2.20.1.bb | 1 |
2 files changed, 68 insertions, 0 deletions
diff --git a/meta/packages/binutils/binutils-2.20.1/binutils-libtool.patch b/meta/packages/binutils/binutils-2.20.1/binutils-libtool.patch new file mode 100644 index 0000000000..61517d1d4c --- /dev/null +++ b/meta/packages/binutils/binutils-2.20.1/binutils-libtool.patch | |||
@@ -0,0 +1,67 @@ | |||
1 | This is because libdir has a trailing slash which breaks the comparision. | ||
2 | |||
3 | RP 2/1/10 | ||
4 | |||
5 | Index: binutils-2.20.1/ltmain.sh | ||
6 | =================================================================== | ||
7 | --- binutils-2.20.1.orig/ltmain.sh 2009-09-01 00:59:32.000000000 +0800 | ||
8 | +++ binutils-2.20.1/ltmain.sh 2010-07-29 09:41:14.000000000 +0800 | ||
9 | @@ -2156,8 +2156,12 @@ | ||
10 | dir="$dir$objdir" | ||
11 | |||
12 | if test -n "$relink_command"; then | ||
13 | + # Strip any trailing slash from the destination. | ||
14 | + func_stripname '' '/' "$libdir" | ||
15 | + destlibdir=$func_stripname_result | ||
16 | + | ||
17 | # Determine the prefix the user has applied to our future dir. | ||
18 | - inst_prefix_dir=`$ECHO "X$destdir" | $Xsed -e "s%$libdir\$%%"` | ||
19 | + inst_prefix_dir=`$ECHO "X$destdir" | $Xsed -e "s%$destlibdir\$%%"` | ||
20 | |||
21 | # Don't allow the user to place us outside of our expected | ||
22 | # location b/c this prevents finding dependent libraries that | ||
23 | @@ -5570,8 +5574,14 @@ | ||
24 | absdir="$abs_ladir" | ||
25 | libdir="$abs_ladir" | ||
26 | else | ||
27 | - dir="$libdir" | ||
28 | - absdir="$libdir" | ||
29 | + # Adding 'libdir' from the .la file to our library search paths | ||
30 | + # breaks crosscompilation horribly. We cheat here and don't add | ||
31 | + # it, instead adding the path where we found the .la. -CL | ||
32 | + dir="$abs_ladir" | ||
33 | + absdir="$abs_ladir" | ||
34 | + libdir="$abs_ladir" | ||
35 | + #dir="$libdir" | ||
36 | + #absdir="$libdir" | ||
37 | fi | ||
38 | test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes | ||
39 | else | ||
40 | @@ -5942,8 +5952,6 @@ | ||
41 | add="$libdir/$linklib" | ||
42 | fi | ||
43 | else | ||
44 | - # We cannot seem to hardcode it, guess we'll fake it. | ||
45 | - add_dir="-L$libdir" | ||
46 | # Try looking first in the location we're being installed to. | ||
47 | if test -n "$inst_prefix_dir"; then | ||
48 | case $libdir in | ||
49 | @@ -6089,7 +6097,17 @@ | ||
50 | fi | ||
51 | ;; | ||
52 | *) | ||
53 | - path="-L$absdir/$objdir" | ||
54 | + # OE sets installed=no in staging. We need to look in $objdir and $absdir, | ||
55 | + # preferring $objdir. RP 31/04/2008 | ||
56 | + if test -f "$absdir/$objdir/$depdepl" ; then | ||
57 | + depdepl="$absdir/$objdir/$depdepl" | ||
58 | + path="-L$absdir/$objdir" | ||
59 | + elif test -f "$absdir/$depdepl" ; then | ||
60 | + depdepl="$absdir/$depdepl" | ||
61 | + path="-L$absdir" | ||
62 | + else | ||
63 | + path="-L$absdir/$objdir" | ||
64 | + fi | ||
65 | ;; | ||
66 | esac | ||
67 | else | ||
diff --git a/meta/packages/binutils/binutils_2.20.1.bb b/meta/packages/binutils/binutils_2.20.1.bb index a533bd8bb0..88a3dec280 100644 --- a/meta/packages/binutils/binutils_2.20.1.bb +++ b/meta/packages/binutils/binutils_2.20.1.bb | |||
@@ -25,6 +25,7 @@ SRC_URI = "\ | |||
25 | file://binutils-uclibc-gas-needs-libm.patch \ | 25 | file://binutils-uclibc-gas-needs-libm.patch \ |
26 | file://binutils-x86_64_i386_biarch.patch \ | 26 | file://binutils-x86_64_i386_biarch.patch \ |
27 | file://binutils-mips-pie.patch \ | 27 | file://binutils-mips-pie.patch \ |
28 | file://binutils-libtool.patch \ | ||
28 | " | 29 | " |
29 | 30 | ||
30 | # powerpc patches | 31 | # powerpc patches |