diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-04-26 20:36:05 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-04-30 11:37:28 +0100 |
commit | c1c9144f67108fdc6b7c62d21c9a638e38f12fb4 (patch) | |
tree | 274f2b65d863320b59e1947adc713805831fc8ee /meta | |
parent | 36361c0165e7ad6747d06362695684dba78a7854 (diff) | |
download | poky-c1c9144f67108fdc6b7c62d21c9a638e38f12fb4.tar.gz |
mesa: Fix mklibs patch to simply remove troublesome uname usage
Without this we started seeing the -mx32 flag being passed to the compiler
for things like arm builds which makes no sense.
(From OE-Core rev: 288b7a9d0e6093f85e4a1d3e34d4332b9c43b47b)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/recipes-graphics/mesa/mesa-common.inc | 2 | ||||
-rw-r--r-- | meta/recipes-graphics/mesa/mesa/mesa_fix_for_x32.patch | 54 |
2 files changed, 29 insertions, 27 deletions
diff --git a/meta/recipes-graphics/mesa/mesa-common.inc b/meta/recipes-graphics/mesa/mesa-common.inc index 2b90aed212..1c376b7733 100644 --- a/meta/recipes-graphics/mesa/mesa-common.inc +++ b/meta/recipes-graphics/mesa/mesa-common.inc | |||
@@ -12,7 +12,7 @@ SECTION = "x11" | |||
12 | LICENSE = "MIT" | 12 | LICENSE = "MIT" |
13 | LIC_FILES_CHKSUM = "file://docs/license.html;md5=7a3373c039b6b925c427755a4f779c1d" | 13 | LIC_FILES_CHKSUM = "file://docs/license.html;md5=7a3373c039b6b925c427755a4f779c1d" |
14 | 14 | ||
15 | INC_PR = "r13" | 15 | INC_PR = "r14" |
16 | PE = "2" | 16 | PE = "2" |
17 | 17 | ||
18 | 18 | ||
diff --git a/meta/recipes-graphics/mesa/mesa/mesa_fix_for_x32.patch b/meta/recipes-graphics/mesa/mesa/mesa_fix_for_x32.patch index 8994faf154..f072c34f71 100644 --- a/meta/recipes-graphics/mesa/mesa/mesa_fix_for_x32.patch +++ b/meta/recipes-graphics/mesa/mesa/mesa_fix_for_x32.patch | |||
@@ -1,38 +1,40 @@ | |||
1 | Upstream-Status: Pending | 1 | Upstream-Status: Pending |
2 | 2 | ||
3 | get correct compiler options for x32 gcc. | 3 | Using uname like this when cross compiling is a really bad idea. We |
4 | provide the correct linker flags, lets just assume we can get this | ||
5 | right ourselves. | ||
4 | 6 | ||
5 | Received this patch from H.J. Lu <hjl.tools@gmail.com> | 7 | RP 2012/04/26 |
6 | 8 | ||
7 | Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com> 2011/12/06 | 9 | Index: Mesa-7.11/bin/mklib |
8 | 10 | =================================================================== | |
9 | --- Mesa-7.11/bin/mklib.x32 2011-12-06 13:15:17.968695114 -0800 | 11 | --- Mesa-7.11.orig/bin/mklib 2012-04-26 19:43:20.729150109 +0000 |
10 | +++ Mesa-7.11/bin/mklib 2011-12-06 13:17:13.872152249 -0800 | 12 | +++ Mesa-7.11/bin/mklib 2012-04-26 20:30:22.421086163 +0000 |
11 | @@ -335,7 +335,12 @@ case $ARCH in | 13 | @@ -330,13 +330,7 @@ |
14 | ;; | ||
15 | esac | ||
16 | |||
17 | - # Check if objects are 32-bit and we're running in 64-bit | ||
18 | - # environment. If so, pass -m32 flag to linker. | ||
12 | set ${OBJECTS} | 19 | set ${OBJECTS} |
13 | ABI32=`file $1 | grep 32-bit` | 20 | - ABI32=`file $1 | grep 32-bit` |
14 | if [ "${ABI32}" -a `uname -m` = "x86_64" ] ; then | 21 | - if [ "${ABI32}" -a `uname -m` = "x86_64" ] ; then |
15 | - OPTS="-m32 ${OPTS}" | 22 | - OPTS="-m32 ${OPTS}" |
16 | + ABIX32=`file $1 | grep x86-64` | 23 | - fi |
17 | + if [ "${ABI32}" ]; then | ||
18 | + OPTS="-mx32 ${OPTS}" | ||
19 | + else | ||
20 | + OPTS="-m32 ${OPTS}" | ||
21 | + fi | ||
22 | fi | ||
23 | 24 | ||
24 | if [ "${ALTOPTS}" ] ; then | 25 | if [ "${ALTOPTS}" ] ; then |
25 | @@ -392,7 +397,12 @@ case $ARCH in | 26 | OPTS=${ALTOPTS} |
27 | @@ -387,13 +381,7 @@ | ||
28 | # exptmp is removed below | ||
29 | fi | ||
30 | |||
31 | - # Check if objects are 32-bit and we're running in 64-bit | ||
32 | - # environment. If so, pass -m32 flag to linker. | ||
26 | set ${OBJECTS} | 33 | set ${OBJECTS} |
27 | ABI32=`file $1 | grep 32-bit` | 34 | - ABI32=`file $1 | grep 32-bit` |
28 | if [ "${ABI32}" -a `uname -m` = "x86_64" ] ; then | 35 | - if [ "${ABI32}" -a `uname -m` = "x86_64" ] ; then |
29 | - OPTS="-m32 ${OPTS}" | 36 | - OPTS="-m32 ${OPTS}" |
30 | + ABIX32=`file $1 | grep x86-64` | 37 | - fi |
31 | + if [ "${ABI32}" ]; then | ||
32 | + OPTS="-mx32 ${OPTS}" | ||
33 | + else | ||
34 | + OPTS="-m32 ${OPTS}" | ||
35 | + fi | ||
36 | fi | ||
37 | if [ "${ALTOPTS}" ] ; then | 38 | if [ "${ALTOPTS}" ] ; then |
38 | OPTS=${ALTOPTS} | 39 | OPTS=${ALTOPTS} |
40 | fi | ||