diff options
author | Khem Raj <raj.khem@gmail.com> | 2016-02-26 06:48:00 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-02-28 11:33:06 +0000 |
commit | 3354878d324b344f90b7fc8c02d09e0692725ff2 (patch) | |
tree | 7ca728c8619a920d67ad996a1da4f9a5b9293b0e /meta | |
parent | 7651342ac11c0edd638e81e64067b03192b469de (diff) | |
download | poky-3354878d324b344f90b7fc8c02d09e0692725ff2.tar.gz |
mesa: Fix build on musl
It assumes __GLIBC__ where it could actually check for linux
and include non-glibc C library implementations like musl which
provide __BYTE_ORDER macros as well when computing system endianness
(From OE-Core rev: b759afa08e339126c4e8b7e2aa87ed0c9f4b5d0d)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/recipes-graphics/mesa/files/replace_glibc_check_with_linux.patch | 17 | ||||
-rw-r--r-- | meta/recipes-graphics/mesa/mesa_11.1.1.bb | 4 |
2 files changed, 20 insertions, 1 deletions
diff --git a/meta/recipes-graphics/mesa/files/replace_glibc_check_with_linux.patch b/meta/recipes-graphics/mesa/files/replace_glibc_check_with_linux.patch new file mode 100644 index 0000000000..e4461ef177 --- /dev/null +++ b/meta/recipes-graphics/mesa/files/replace_glibc_check_with_linux.patch | |||
@@ -0,0 +1,17 @@ | |||
1 | endianness check is OS wide and not specific to libc | ||
2 | |||
3 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
4 | Upstream-Status: Pending | ||
5 | Index: mesa-11.1.1/src/gallium/include/pipe/p_config.h | ||
6 | =================================================================== | ||
7 | --- mesa-11.1.1.orig/src/gallium/include/pipe/p_config.h | ||
8 | +++ mesa-11.1.1/src/gallium/include/pipe/p_config.h | ||
9 | @@ -130,7 +130,7 @@ | ||
10 | * Endian detection. | ||
11 | */ | ||
12 | |||
13 | -#ifdef __GLIBC__ | ||
14 | +#if defined(__linux__) | ||
15 | #include <endian.h> | ||
16 | |||
17 | #if __BYTE_ORDER == __LITTLE_ENDIAN | ||
diff --git a/meta/recipes-graphics/mesa/mesa_11.1.1.bb b/meta/recipes-graphics/mesa/mesa_11.1.1.bb index 5d73feb5fb..502afcfd8a 100644 --- a/meta/recipes-graphics/mesa/mesa_11.1.1.bb +++ b/meta/recipes-graphics/mesa/mesa_11.1.1.bb | |||
@@ -1,6 +1,8 @@ | |||
1 | require ${BPN}.inc | 1 | require ${BPN}.inc |
2 | 2 | ||
3 | SRC_URI = "ftp://ftp.freedesktop.org/pub/mesa/${PV}/mesa-${PV}.tar.xz" | 3 | SRC_URI = "ftp://ftp.freedesktop.org/pub/mesa/${PV}/mesa-${PV}.tar.xz \ |
4 | file://replace_glibc_check_with_linux.patch \ | ||
5 | " | ||
4 | 6 | ||
5 | SRC_URI[md5sum] = "1043dfb907beecb2a761272455960427" | 7 | SRC_URI[md5sum] = "1043dfb907beecb2a761272455960427" |
6 | SRC_URI[sha256sum] = "64db074fc514136b5fb3890111f0d50604db52f0b1e94ba3fcb0fe8668a7fd20" | 8 | SRC_URI[sha256sum] = "64db074fc514136b5fb3890111f0d50604db52f0b1e94ba3fcb0fe8668a7fd20" |