From 1a4b7ee28bf7413af6513fb45ad0d0736048f866 Mon Sep 17 00:00:00 2001 From: Brad Bishop Date: Sun, 16 Dec 2018 17:11:34 -0800 Subject: reset upstream subtrees to yocto 2.6 Reset the following subtrees on thud HEAD: poky: 87e3a9739d meta-openembedded: 6094ae18c8 meta-security: 31dc4e7532 meta-raspberrypi: a48743dc36 meta-xilinx: c42016e2e6 Also re-apply backports that didn't make it into thud: poky: 17726d0 systemd-systemctl-native: handle Install wildcards meta-openembedded: 4321a5d libtinyxml2: update to 7.0.1 042f0a3 libcereal: Add native and nativesdk classes e23284f libcereal: Allow empty package 030e8d4 rsyslog: curl-less build with fmhttp PACKAGECONFIG 179a1b9 gtest: update to 1.8.1 Squashed OpenBMC subtree compatibility updates: meta-aspeed: Brad Bishop (1): aspeed: add yocto 2.6 compatibility meta-ibm: Brad Bishop (1): ibm: prepare for yocto 2.6 meta-ingrasys: Brad Bishop (1): ingrasys: set layer compatibility to yocto 2.6 meta-openpower: Brad Bishop (1): openpower: set layer compatibility to yocto 2.6 meta-phosphor: Brad Bishop (3): phosphor: set layer compatibility to thud phosphor: libgpg-error: drop patches phosphor: react to fitimage artifact rename Ed Tanous (4): Dropbear: upgrade options for latest upgrade yocto2.6: update openssl options busybox: remove upstream watchdog patch systemd: Rebase CONFIG_CGROUP_BPF patch Change-Id: I7b1fe71cca880d0372a82d94b5fd785323e3a9e7 Signed-off-by: Brad Bishop --- ...lkan.am-explictly-add-lib-expat-to-intel-.patch | 42 ------------------ .../0001-Simplify-wayland-scanner-lookup.patch | 39 +++++++++++++++++ .../0001-Use-wayland-scanner-in-the-path.patch | 34 --------------- ...i-Initialise-modifier-to-INVALID-for-DRI2.patch | 43 ------------------ .../0001-winsys-svga-drm-Include-sys-types.h.patch | 34 --------------- .../mesa/files/0002-hardware-gloat.patch | 51 ---------------------- .../0002-winsys-svga-drm-Include-sys-types.h.patch | 34 +++++++++++++++ ...t-LLVM-version-when-using-LLVM-Git-releas.patch | 44 +++++++++++++++++++ .../0004-Use-Python-3-to-execute-the-scripts.patch | 32 ++++++++++++++ .../0005-dri-i965-Add-missing-time.h-include.patch | 36 +++++++++++++++ ...CK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch | 37 ++++++++++++++++ .../Use-Python-3-to-execute-the-scripts.patch | 32 -------------- .../mesa/files/disable-asm-on-non-gcc.patch | 29 ------------ .../mesa/files/llvm-config-version.patch | 41 ----------------- poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb | 9 ---- poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb | 9 ++++ poky/meta/recipes-graphics/mesa/mesa.inc | 27 +++++++++--- poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb | 23 ---------- poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb | 21 +++++++++ 19 files changed, 272 insertions(+), 345 deletions(-) delete mode 100644 poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch create mode 100644 poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch create mode 100644 poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch create mode 100644 poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch create mode 100644 poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch create mode 100644 poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch create mode 100644 poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch delete mode 100644 poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch delete mode 100644 poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb create mode 100644 poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb delete mode 100644 poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb create mode 100644 poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb (limited to 'poky/meta/recipes-graphics/mesa') diff --git a/poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch b/poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch deleted file mode 100644 index f908d4655..000000000 --- a/poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 342311dbb190735b7b32ab20f81c1d8dbcfe717a Mon Sep 17 00:00:00 2001 -From: Hongxu Jia -Date: Wed, 11 Oct 2017 15:40:42 +0800 -Subject: [PATCH] Makefile.vulkan.am: explictly add lib expat to intel - libvulkan's lib depends - -While built with "-fvisibility=default" -... -|i586-oe-linux-gcc ... -fvisibility=default ... -o common/.libs/common_libintel_common_la-gen_decoder.o -... - -It triggered the failure -... -|i586-oe-linux-g++ ... common/.libs/libintel_common.a ... -o vulkan/.libs/libvulkan_intel.so -|common/.libs/libintel_common.a(common_libintel_common_la-gen_decoder.o): -|In function `start_element': -|/usr/src/debug/mesa/2_17.1.7-r0/mesa-17.1.7/src/intel/common/gen_decoder.c:371: -undefined reference to `XML_GetCurrentLineNumber' -... - -explictly add EXPAT_LIBS to intel's VULKAN_LIB_DEPS - -Upstream-Status: Accepted -https://cgit.freedesktop.org/mesa/mesa/commit/?id=05fc62d89f59ce19a18bfd4e63a09624910d6caf - -Signed-off-by: Hongxu Jia ---- - src/intel/Makefile.vulkan.am | 1 + - 1 file changed, 1 insertion(+) - -Index: mesa-17.3.6/src/intel/Makefile.vulkan.am -=================================================================== ---- mesa-17.3.6.orig/src/intel/Makefile.vulkan.am -+++ mesa-17.3.6/src/intel/Makefile.vulkan.am -@@ -144,6 +144,7 @@ VULKAN_LIB_DEPS = \ - $(LIBDRM_LIBS) \ - $(PTHREAD_LIBS) \ - $(DLOPEN_LIBS) \ -+ $(EXPAT_LIBS) \ - -lm - - if HAVE_PLATFORM_ANDROID diff --git a/poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch b/poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch new file mode 100644 index 000000000..a50d2a2ba --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch @@ -0,0 +1,39 @@ +From 7e8e0f8a8ac2425e19a2f340c9e3da9345f25940 Mon Sep 17 00:00:00 2001 +From: Jussi Kukkonen +Date: Tue, 15 Nov 2016 15:20:49 +0200 +Subject: [PATCH 1/6] Simplify wayland-scanner lookup +Organization: O.S. Systems Software LTDA. + +Don't use pkg-config to lookup the path of a binary that's in the path. + +Alternatively we'd have to prefix the path returned by pkg-config with +PKG_CONFIG_SYSROOT_DIR. + +Upstream-Status: Pending +Signed-off-by: Jussi Kukkonen +Signed-off-by: Otavio Salvador +--- + configure.ac | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 14f1af2b2f..916d0bd207 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -1825,12 +1825,7 @@ for plat in $platforms; do + PKG_CHECK_MODULES([WAYLAND_PROTOCOLS], [wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED]) + WAYLAND_PROTOCOLS_DATADIR=`$PKG_CONFIG --variable=pkgdatadir wayland-protocols` + +- PKG_CHECK_MODULES([WAYLAND_SCANNER], [wayland-scanner], +- WAYLAND_SCANNER=`$PKG_CONFIG --variable=wayland_scanner wayland-scanner`, +- WAYLAND_SCANNER='') +- if test "x$WAYLAND_SCANNER" = x; then +- AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:]) +- fi ++ AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:]) + + if test "x$WAYLAND_SCANNER" = "x:"; then + AC_MSG_ERROR([wayland-scanner is needed to compile the wayland platform]) +-- +2.18.0 + diff --git a/poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch b/poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch deleted file mode 100644 index 2444b2846..000000000 --- a/poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch +++ /dev/null @@ -1,34 +0,0 @@ -From c908f0c13ac81a3a52140f129a13b2bc997ff4ee Mon Sep 17 00:00:00 2001 -From: Jussi Kukkonen -Date: Tue, 15 Nov 2016 15:20:49 +0200 -Subject: [PATCH] Simplify wayland-scanner lookup - -Don't use pkg-config to lookup the path of a binary that's in the path. - -Alternatively we'd have to prefix the path returned by pkg-config with -PKG_CONFIG_SYSROOT_DIR. - -Upstream-Status: Pending -Signed-off-by: Jussi Kukkonen ---- - configure.ac | 7 +------ - 1 file changed, 1 insertion(+), 6 deletions(-) - -Index: mesa-17.3.6/configure.ac -=================================================================== ---- mesa-17.3.6.orig/configure.ac -+++ mesa-17.3.6/configure.ac -@@ -1694,12 +1694,7 @@ if test "x$with_platforms" = xauto; then - with_platforms=$with_egl_platforms - fi - --PKG_CHECK_MODULES([WAYLAND_SCANNER], [wayland-scanner], -- WAYLAND_SCANNER=`$PKG_CONFIG --variable=wayland_scanner wayland-scanner`, -- WAYLAND_SCANNER='') --if test "x$WAYLAND_SCANNER" = x; then -- AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:]) --fi -+AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner]) - - PKG_CHECK_EXISTS([wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED], [have_wayland_protocols=yes], [have_wayland_protocols=no]) - if test "x$have_wayland_protocols" = xyes; then diff --git a/poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch b/poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch deleted file mode 100644 index 6aba7859e..000000000 --- a/poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch +++ /dev/null @@ -1,43 +0,0 @@ -From 4cbecb61682a0ee426faaa03d824fc8fd7aef826 Mon Sep 17 00:00:00 2001 -From: Daniel Stone -Date: Mon, 2 Apr 2018 13:20:34 +0100 -Subject: [PATCH] st/dri: Initialise modifier to INVALID for DRI2 -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -When allocating a buffer for DRI2, set the modifier to INVALID to inform -the backend that we have no supplied modifiers and it should do its own -thing. The missed initialisation forced linear, even if the -implementation had made other decisions. - -This resulted in VC4 DRI2 clients failing with: - Modifier 0x0 vs. tiling (0x700000000000001) mismatch - -Signed-off-by: Daniel Stone -Reported-by: Andreas Müller -Reviewed-by: Eric Anholt -Fixes: 3f8513172ff6 ("gallium/winsys/drm: introduce modifier field to winsys_handle") - -Upstream-Status: Backport [1] - -[1] https://cgit.freedesktop.org/mesa/mesa/commit/?id=4cbecb61682a0ee426faaa03d824fc8fd7aef826 ---- - src/gallium/state_trackers/dri/dri2.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c -index 31d17d46c2..58a6757f03 100644 ---- a/src/gallium/state_trackers/dri/dri2.c -+++ b/src/gallium/state_trackers/dri/dri2.c -@@ -806,6 +806,7 @@ dri2_allocate_textures(struct dri_context *ctx, - whandle.handle = buf->name; - whandle.stride = buf->pitch; - whandle.offset = 0; -+ whandle.modifier = DRM_FORMAT_MOD_INVALID; - if (screen->can_share_buffer) - whandle.type = DRM_API_HANDLE_TYPE_SHARED; - else --- -2.14.3 - diff --git a/poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch b/poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch deleted file mode 100644 index 549b8671a..000000000 --- a/poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch +++ /dev/null @@ -1,34 +0,0 @@ -From d8750776404b1031d762966d0f551d13d2fe05a7 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Wed, 16 Aug 2017 18:58:20 -0700 -Subject: [PATCH] winsys/svga/drm: Include sys/types.h - -vmw_screen.h uses dev_t which is defines in sys/types.h -this header is required to be included for getting dev_t -definition. This issue happens on musl C library, it is hidden -on glibc since sys/types.h is included through another -system headers - -Signed-off-by: Khem Raj ---- - -Upstream-Status: Submitted - - src/gallium/winsys/svga/drm/vmw_screen.h | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/gallium/winsys/svga/drm/vmw_screen.h b/src/gallium/winsys/svga/drm/vmw_screen.h -index 0ef8e84..2eda97e 100644 ---- a/src/gallium/winsys/svga/drm/vmw_screen.h -+++ b/src/gallium/winsys/svga/drm/vmw_screen.h -@@ -41,6 +41,7 @@ - #include "svga_winsys.h" - #include "pipebuffer/pb_buffer_fenced.h" - #include -+#include - - #define VMW_GMR_POOL_SIZE (16*1024*1024) - #define VMW_QUERY_POOL_SIZE (8192) --- -2.14.1 - diff --git a/poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch b/poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch deleted file mode 100644 index 0e014dcc8..000000000 --- a/poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 00bcd599310dc7fce4fe336ffd85902429051a0c Mon Sep 17 00:00:00 2001 -From: Igor Gnatenko -Date: Sun, 20 Mar 2016 13:27:04 +0100 -Subject: [PATCH 2/4] hardware gloat - -Upstream-Status: Inappropriate [not author] -Signed-off-by: Igor Gnatenko ---- - src/gallium/drivers/llvmpipe/lp_screen.c | 7 +++++++ - src/gallium/drivers/softpipe/sp_screen.c | 7 +++++++ - 2 files changed, 14 insertions(+) - -diff --git a/src/gallium/drivers/llvmpipe/lp_screen.c b/src/gallium/drivers/llvmpipe/lp_screen.c -index 4f61de8..3b0ec77 100644 ---- a/src/gallium/drivers/llvmpipe/lp_screen.c -+++ b/src/gallium/drivers/llvmpipe/lp_screen.c -@@ -411,6 +411,13 @@ llvmpipe_is_format_supported( struct pipe_screen *_screen, - if (!format_desc) - return FALSE; - -+ if ((bind & PIPE_BIND_RENDER_TARGET) && -+ format != PIPE_FORMAT_R9G9B9E5_FLOAT && -+ format != PIPE_FORMAT_R11G11B10_FLOAT && -+ util_format_is_float(format)) { -+ return FALSE; -+ } -+ - assert(target == PIPE_BUFFER || - target == PIPE_TEXTURE_1D || - target == PIPE_TEXTURE_1D_ARRAY || -diff --git a/src/gallium/drivers/softpipe/sp_screen.c b/src/gallium/drivers/softpipe/sp_screen.c -index 031602b..c279120 100644 ---- a/src/gallium/drivers/softpipe/sp_screen.c -+++ b/src/gallium/drivers/softpipe/sp_screen.c -@@ -358,6 +358,13 @@ softpipe_is_format_supported( struct pipe_screen *screen, - if (!format_desc) - return FALSE; - -+ if ((bind & PIPE_BIND_RENDER_TARGET) && -+ format != PIPE_FORMAT_R9G9B9E5_FLOAT && -+ format != PIPE_FORMAT_R11G11B10_FLOAT && -+ util_format_is_float(format)) { -+ return FALSE; -+ } -+ - if (sample_count > 1) - return FALSE; - --- -2.7.4 - diff --git a/poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch b/poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch new file mode 100644 index 000000000..ffb3bf7a6 --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch @@ -0,0 +1,34 @@ +From 7792f228991744a0396b8bf811e281dca86165d3 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Wed, 16 Aug 2017 18:58:20 -0700 +Subject: [PATCH 2/6] winsys/svga/drm: Include sys/types.h +Organization: O.S. Systems Software LTDA. + +vmw_screen.h uses dev_t which is defines in sys/types.h +this header is required to be included for getting dev_t +definition. This issue happens on musl C library, it is hidden +on glibc since sys/types.h is included through another +system headers + +Signed-off-by: Khem Raj +Upstream-Status: Backport [7dfdfbf8c37e52e7b9b09f7d1d434edad3ebc864] +Signed-off-by: Otavio Salvador +--- + src/gallium/winsys/svga/drm/vmw_screen.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/gallium/winsys/svga/drm/vmw_screen.h b/src/gallium/winsys/svga/drm/vmw_screen.h +index f21cabb51f..4c972fdaa9 100644 +--- a/src/gallium/winsys/svga/drm/vmw_screen.h ++++ b/src/gallium/winsys/svga/drm/vmw_screen.h +@@ -41,6 +41,7 @@ + #include "svga_winsys.h" + #include "pipebuffer/pb_buffer_fenced.h" + #include ++#include + + #define VMW_GMR_POOL_SIZE (16*1024*1024) + #define VMW_QUERY_POOL_SIZE (8192) +-- +2.18.0 + diff --git a/poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch b/poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch new file mode 100644 index 000000000..5e735ca10 --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch @@ -0,0 +1,44 @@ +From 8b42fb47138f91d9378439ab716bac7701e4e326 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador +Date: Tue, 5 Jun 2018 11:11:10 -0300 +Subject: [PATCH 3/6] Properly get LLVM version when using LLVM Git releases +Organization: O.S. Systems Software LTDA. + +$ llvm-config-host --version +5.0.0git-9a5c333388c + +We need to ignore everything after 5.0.0 which is what the cut cmd is +doing + +Upstream-Status: Pending +Signed-off-by: Khem Raj +Signed-off-by: Otavio Salvador +--- + configure.ac | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 916d0bd207..dd172f1ebe 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -1090,7 +1090,7 @@ strip_unwanted_llvm_flags() { + + llvm_set_environment_variables() { + if test "x$LLVM_CONFIG" != xno; then +- LLVM_VERSION=`$LLVM_CONFIG --version | egrep -o '^[[0-9.]]+'` ++ LLVM_VERSION=`$LLVM_CONFIG --version | cut -c1-5` + LLVM_CPPFLAGS=`strip_unwanted_llvm_flags "$LLVM_CONFIG --cppflags"` + LLVM_INCLUDEDIR=`$LLVM_CONFIG --includedir` + LLVM_LIBDIR=`$LLVM_CONFIG --libdir` +@@ -2808,7 +2808,7 @@ detect_old_buggy_llvm() { + dnl ourselves. + dnl (See https://llvm.org/bugs/show_bug.cgi?id=6823) + dnl We can't use $LLVM_VERSION because it has 'svn' stripped out, +- LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version` ++ LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version | cut -c1-5` + AS_IF([test -f "$LLVM_LIBDIR/lib$LLVM_SO_NAME.$IMP_LIB_EXT"], [llvm_have_one_so=yes]) + + if test "x$llvm_have_one_so" = xyes; then +-- +2.18.0 + diff --git a/poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch b/poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch new file mode 100644 index 000000000..8953c4a18 --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch @@ -0,0 +1,32 @@ +From ebe6077a1d74e56b28249f71e8760295fa846ed2 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador +Date: Fri, 29 Dec 2017 10:27:59 -0200 +Subject: [PATCH 4/6] Use Python 3 to execute the scripts +Organization: O.S. Systems Software LTDA. + +The MESA build system uses Python 2 but as OE-Core has moved away from +it, we change it to use Python 3 instead. + +Upstream-Status: Inappropriate [ configuration ] + +Signed-off-by: Otavio Salvador +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index dd172f1ebe..40cac36ac2 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -122,7 +122,7 @@ AM_PROG_CC_C_O + AC_PROG_NM + AM_PROG_AS + AX_CHECK_GNU_MAKE +-AC_CHECK_PROGS([PYTHON2], [python2.7 python2 python]) ++AC_CHECK_PROGS([PYTHON2], [python3.5 python3 python]) + AC_PROG_SED + AC_PROG_MKDIR_P + +-- +2.18.0 + diff --git a/poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch b/poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch new file mode 100644 index 000000000..d40e7b585 --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch @@ -0,0 +1,36 @@ +From 9e0368af471af3a36e0eb526453f892598120065 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador +Date: Wed, 6 Jun 2018 09:50:35 -0300 +Subject: [PATCH 5/6] dri: i965: Add missing time.h include +Organization: O.S. Systems Software LTDA. + +This fixes a build error when using musl: + +,---- +| In file included from .../src/mesa/drivers/dri/i965/intel_upload.c:33:0: +| .../src/mesa/drivers/dri/i965/brw_bufmgr.h:132:4: error: unknown type name 'time_t' +| time_t free_time; +| ^~~~~~ +`---- + +Upstream-Status: Backport [3c288da5eec81ee58b85927df18d9194ead8f5c2] +Signed-off-by: Otavio Salvador +--- + src/mesa/drivers/dri/i965/brw_bufmgr.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/mesa/drivers/dri/i965/brw_bufmgr.h b/src/mesa/drivers/dri/i965/brw_bufmgr.h +index 68f5e0c2c8..5b60a23763 100644 +--- a/src/mesa/drivers/dri/i965/brw_bufmgr.h ++++ b/src/mesa/drivers/dri/i965/brw_bufmgr.h +@@ -37,6 +37,7 @@ + #include + #include + #include ++#include + #include "util/u_atomic.h" + #include "util/list.h" + +-- +2.18.0 + diff --git a/poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch b/poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch new file mode 100644 index 000000000..0212922c5 --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch @@ -0,0 +1,37 @@ +From 754ccf89a732fc3da6e9bc62ebd6b28686ff3d26 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador +Date: Wed, 29 Aug 2018 22:10:30 -0300 +Subject: [PATCH 6/6] use PKG_CHECK_VAR for defining WAYLAND_PROTOCOLS_DATADIR +Organization: O.S. Systems Software LTDA. + +This allows to override the wayland-protocols pkgdatadir with the +WAYLAND_PROTOCOLS_DATADIR from environment. + +pkgconfig would return an absolute path in +/usr/share/wayland-protocols +for the pkgdatadir value, which is not suitable for cross-compiling. + +Signed-off-by: Khem Raj +Upstream-Status: Pending + +Signed-off-by: Otavio Salvador +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index 40cac36ac2..728bbdcbc4 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -1823,7 +1823,7 @@ for plat in $platforms; do + PKG_CHECK_MODULES([WAYLAND_CLIENT], [wayland-client >= $WAYLAND_REQUIRED]) + PKG_CHECK_MODULES([WAYLAND_SERVER], [wayland-server >= $WAYLAND_REQUIRED]) + PKG_CHECK_MODULES([WAYLAND_PROTOCOLS], [wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED]) +- WAYLAND_PROTOCOLS_DATADIR=`$PKG_CONFIG --variable=pkgdatadir wayland-protocols` ++ PKG_CHECK_VAR([WAYLAND_PROTOCOLS_DATADIR], [wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED], pkgdatadir) + + AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:]) + +-- +2.18.0 + diff --git a/poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch b/poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch deleted file mode 100644 index 0b4aabf97..000000000 --- a/poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 18c3e684a8259a0644214f88c7ead7fa31573fd9 Mon Sep 17 00:00:00 2001 -From: Otavio Salvador -Date: Fri, 29 Dec 2017 10:27:59 -0200 -Subject: [PATCH] Use Python 3 to execute the scripts -Organization: O.S. Systems Software LTDA. - -The MESA build system uses Python 2 but as OE-Core has moved away from -it, we change it to use Python 3 instead. - -Upstream-Status: Inappropriate [ configuration ] - -Signed-off-by: Otavio Salvador ---- - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/configure.ac b/configure.ac -index b107f04c2e..055546142d 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -114,7 +114,7 @@ AC_PROG_CXX - AM_PROG_CC_C_O - AM_PROG_AS - AX_CHECK_GNU_MAKE --AC_CHECK_PROGS([PYTHON2], [python2.7 python2 python]) -+AC_CHECK_PROGS([PYTHON2], [python3.5 python3 python]) - AC_PROG_SED - AC_PROG_MKDIR_P - --- -2.15.1 - diff --git a/poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch b/poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch deleted file mode 100644 index d2d67558b..000000000 --- a/poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch +++ /dev/null @@ -1,29 +0,0 @@ -Configure checks for compiler to be gcc and then it enables asm_offsets -generation. see - -https://cgit.freedesktop.org/mesa/mesa/commit/?id=73c9b4b0e05fc66629ba250846948dc55c0e7a0d - -However, we missed the check when enabling this on cross compilation -when architecture for both host and target is x86 - -Fixes errors like -./gen_matypes > matypes.h -/bin/bash: ./gen_matypes: No such file or directory - --Khem - -Upstream-Status: Submitted - -Index: mesa-12.0.1/configure.ac -=================================================================== ---- mesa-12.0.1.orig/configure.ac -+++ mesa-12.0.1/configure.ac -@@ -732,7 +732,7 @@ test "x$enable_asm" = xno && AC_MSG_RESU - if test "x$enable_asm" = xyes -a "x$cross_compiling" = xyes; then - case "$host_cpu" in - i?86 | x86_64 | amd64) -- if test "x$host_cpu" != "x$target_cpu"; then -+ if test "x$host_cpu" != "x$target_cpu" -o "x$acv_mesa_CLANG" = xyes; then - enable_asm=no - AC_MSG_RESULT([no, cross compiling]) - fi diff --git a/poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch b/poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch deleted file mode 100644 index fd79991aa..000000000 --- a/poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch +++ /dev/null @@ -1,41 +0,0 @@ -From: Otavio Salvador -Subject: [PATCH] Properly get LLVM version when using LLVM Git releases - -$ llvm-config-host --version -5.0.0git-9a5c333388c - -We need to ignore everything after 5.0.0 which is what the cut cmd is -doing - -Upstream-Status: Pending -Signed-off-by: Khem Raj -Signed-off-by: Otavio Salvador ---- - configure.ac | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/configure.ac b/configure.ac -index a02173f244..b107f04c2e 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -995,7 +995,7 @@ strip_unwanted_llvm_flags() { - - llvm_set_environment_variables() { - if test "x$LLVM_CONFIG" != xno; then -- LLVM_VERSION=`$LLVM_CONFIG --version | egrep -o '^[[0-9.]]+'` -+ LLVM_VERSION=`$LLVM_CONFIG --version | cut -c1-5` - LLVM_CPPFLAGS=`strip_unwanted_llvm_flags "$LLVM_CONFIG --cppflags"` - LLVM_INCLUDEDIR=`$LLVM_CONFIG --includedir` - LLVM_LIBDIR=`$LLVM_CONFIG --libdir` -@@ -2644,7 +2644,7 @@ detect_old_buggy_llvm() { - dnl ourselves. - dnl (See https://llvm.org/bugs/show_bug.cgi?id=6823) - dnl We can't use $LLVM_VERSION because it has 'svn' stripped out, -- LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version` -+ LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version | cut -c1-5` - AS_IF([test -f "$LLVM_LIBDIR/lib$LLVM_SO_NAME.$IMP_LIB_EXT"], [llvm_have_one_so=yes]) - - if test "x$llvm_have_one_so" = xyes; then --- -2.15.1 - diff --git a/poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb b/poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb deleted file mode 100644 index 73267eb4f..000000000 --- a/poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb +++ /dev/null @@ -1,9 +0,0 @@ -require mesa_${PV}.bb - -SUMMARY += " (OpenGL only, no EGL/GLES)" - -PROVIDES = "virtual/libgl virtual/mesa" - -S = "${WORKDIR}/mesa-${PV}" - -PACKAGECONFIG ??= "opengl dri ${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" diff --git a/poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb b/poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb new file mode 100644 index 000000000..73267eb4f --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb @@ -0,0 +1,9 @@ +require mesa_${PV}.bb + +SUMMARY += " (OpenGL only, no EGL/GLES)" + +PROVIDES = "virtual/libgl virtual/mesa" + +S = "${WORKDIR}/mesa-${PV}" + +PACKAGECONFIG ??= "opengl dri ${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" diff --git a/poky/meta/recipes-graphics/mesa/mesa.inc b/poky/meta/recipes-graphics/mesa/mesa.inc index b501b7e72..0cc0a82de 100644 --- a/poky/meta/recipes-graphics/mesa/mesa.inc +++ b/poky/meta/recipes-graphics/mesa/mesa.inc @@ -29,12 +29,16 @@ inherit autotools pkgconfig python3native gettext distro_features_check ANY_OF_DISTRO_FEATURES = "opengl vulkan" PLATFORMS ??= "${@bb.utils.filter('PACKAGECONFIG', 'x11 wayland', d)} \ - ${@bb.utils.contains('PACKAGECONFIG', 'gbm', 'drm', '', d)}" + ${@bb.utils.contains('PACKAGECONFIG', 'gbm', 'drm', '', d)} \ + surfaceless" export LLVM_CONFIG = "${STAGING_BINDIR_NATIVE}/llvm-config${MESA_LLVM_RELEASE}" export YOCTO_ALTERNATE_EXE_PATH = "${STAGING_LIBDIR}/llvm${MESA_LLVM_RELEASE}/llvm-config" +export YOCTO_ALTERNATE_MULTILIB_NAME = "${base_libdir}" EXTRA_OECONF = "--enable-shared-glapi \ --disable-opencl \ + --enable-glx-read-only-text \ + PYTHON2=python2 \ --with-llvm-prefix=${STAGING_LIBDIR}/llvm${MESA_LLVM_RELEASE} \ --with-platforms='${PLATFORMS}'" @@ -47,7 +51,7 @@ PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'wayland vulkan', d)} \ # "gbm" requires "dri", "opengl" PACKAGECONFIG[gbm] = "--enable-gbm,--disable-gbm" -X11_DEPS = "xf86driproto glproto virtual/libx11 libxext libxxf86vm libxdamage libxfixes" +X11_DEPS = "xorgproto virtual/libx11 libxext libxxf86vm libxdamage libxfixes" # "x11" requires "opengl" PACKAGECONFIG[x11] = "--enable-glx-tls,--disable-glx,${X11_DEPS}" PACKAGECONFIG[xvmc] = "--enable-xvmc,--disable-xvmc,libxvmc" @@ -57,8 +61,8 @@ DRIDRIVERS = "swrast" DRIDRIVERS_append_x86 = ",radeon,r200,nouveau,i965,i915" DRIDRIVERS_append_x86-64 = ",radeon,r200,nouveau,i965,i915" # "dri" requires "opengl" -PACKAGECONFIG[dri] = "--enable-dri --with-dri-drivers=${DRIDRIVERS}, --disable-dri, dri2proto libdrm" -PACKAGECONFIG[dri3] = "--enable-dri3, --disable-dri3, dri3proto presentproto libxshmfence" +PACKAGECONFIG[dri] = "--enable-dri --with-dri-drivers=${DRIDRIVERS}, --disable-dri, xorgproto libdrm" +PACKAGECONFIG[dri3] = "--enable-dri3, --disable-dri3, xorgproto libxshmfence" # Vulkan drivers need dri3 enabled # radeon could be enabled as well but requires gallium-llvm with llvm >= 3.9 @@ -87,6 +91,8 @@ GALLIUMDRIVERS_LLVM33_ENABLED = "${@oe.utils.version_less_or_equal('MESA_LLVM_RE GALLIUMDRIVERS_LLVM = "r300,svga,nouveau${@',${GALLIUMDRIVERS_LLVM33}' if ${GALLIUMDRIVERS_LLVM33_ENABLED} else ''}" GALLIUMDRIVERS_append_x86 = "${@bb.utils.contains('PACKAGECONFIG', 'gallium-llvm', ',${GALLIUMDRIVERS_LLVM}', '', d)}" GALLIUMDRIVERS_append_x86-64 = "${@bb.utils.contains('PACKAGECONFIG', 'gallium-llvm', ',${GALLIUMDRIVERS_LLVM}', '', d)}" +GALLIUMDRIVERS_append_x86 = ",virgl" +GALLIUMDRIVERS_append_x86-64 = ",virgl" # keep --with-gallium-drivers separate, because when only one of gallium versions is enabled, other 2 were adding --without-gallium-drivers PACKAGECONFIG[gallium] = "--enable-texture-float --with-gallium-drivers=${GALLIUMDRIVERS}, --without-gallium-drivers" MESA_LLVM_RELEASE ?= "6.0" @@ -100,10 +106,15 @@ PACKAGECONFIG[osmesa] = "--enable-${OSMESA},--disable-${OSMESA}" PACKAGECONFIG[unwind] = "--enable-libunwind,--disable-libunwind,libunwind" +EXTRA_OECONF_remove_libc-musl = "--enable-glx-tls" +EXTRA_OECONF_append_libc-musl = " --disable-glx-tls" +EXTRA_OECONF_append_libc-musl_x86 = " --disable-asm" + # llvmpipe is slow if compiled with -fomit-frame-pointer (e.g. -O2) FULL_OPTIMIZATION_append = " -fno-omit-frame-pointer" CFLAGS_append_armv5 = " -DMISSING_64BIT_ATOMICS" +EXTRA_OEMAKE += "WAYLAND_PROTOCOLS_DATADIR=${STAGING_DATADIR}/wayland-protocols" # Remove the mesa dependency on mesa-dev, as mesa is empty RDEPENDS_${PN}-dev = "" @@ -119,7 +130,6 @@ PACKAGES =+ "libegl-mesa libegl-mesa-dev \ libgles1-mesa libgles1-mesa-dev \ libgles2-mesa libgles2-mesa-dev \ libgles3-mesa libgles3-mesa-dev \ - libwayland-egl libwayland-egl-dev \ libxatracker libxatracker-dev \ mesa-megadriver mesa-vulkan-drivers \ " @@ -134,6 +144,11 @@ do_install_append () { # it was packaged in libdricore9.1.3-1 and preventing upgrades when debian.bbclass was used rm -f ${D}${sysconfdir}/drirc chrpath --delete ${D}${libdir}/dri/*_dri.so || true + + # libwayland-egl has been moved to wayland 1.15+ + rm -f ${D}${libdir}/libwayland-egl* + rm -f ${D}${libdir}/pkgconfig/wayland-egl.pc + rmdir --ignore-fail-on-non-empty ${D}${libdir}/pkgconfig } # For the packages that make up the OpenGL interfaces, inject variables so that @@ -204,7 +219,6 @@ FILES_libgles2-mesa = "${libdir}/libGLESv2.so.*" FILES_libgl-mesa = "${libdir}/libGL.so.*" FILES_libglapi = "${libdir}/libglapi.so.*" FILES_libosmesa = "${libdir}/libOSMesa.so.*" -FILES_libwayland-egl = "${libdir}/libwayland-egl.so.*" FILES_libxatracker = "${libdir}/libxatracker.so.*" FILES_${PN}-dev = "${libdir}/pkgconfig/dri.pc ${includedir}/vulkan" @@ -216,7 +230,6 @@ FILES_libgles1-mesa-dev = "${libdir}/libGLESv1*.* ${includedir}/GLES ${libdir}/p FILES_libgles2-mesa-dev = "${libdir}/libGLESv2.* ${includedir}/GLES2 ${libdir}/pkgconfig/glesv2.pc" FILES_libgles3-mesa-dev = "${includedir}/GLES3" FILES_libosmesa-dev = "${libdir}/libOSMesa.* ${includedir}/GL/osmesa.h ${libdir}/pkgconfig/osmesa.pc" -FILES_libwayland-egl-dev = "${libdir}/pkgconfig/wayland-egl.pc ${libdir}/libwayland-egl.*" FILES_libxatracker-dev = "${libdir}/libxatracker.so ${libdir}/libxatracker.la \ ${includedir}/xa_tracker.h ${includedir}/xa_composite.h ${includedir}/xa_context.h \ ${libdir}/pkgconfig/xatracker.pc" diff --git a/poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb b/poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb deleted file mode 100644 index 2d3fd3ca3..000000000 --- a/poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb +++ /dev/null @@ -1,23 +0,0 @@ -require ${BPN}.inc - -SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \ - file://disable-asm-on-non-gcc.patch \ - file://Use-Python-3-to-execute-the-scripts.patch \ - file://0001-Use-wayland-scanner-in-the-path.patch \ - file://0002-hardware-gloat.patch \ - file://llvm-config-version.patch \ - file://0001-winsys-svga-drm-Include-sys-types.h.patch \ - file://0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch \ - file://0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch \ - " - -SRC_URI[md5sum] = "203d1a79156ab6926f2d253b377e9d9d" -SRC_URI[sha256sum] = "8f9d9bf281c48e4a8f5228816577263b4c655248dc7666e75034ab422951a6b1" - -#because we cannot rely on the fact that all apps will use pkgconfig, -#make eglplatform.h independent of MESA_EGL_NO_X11_HEADER -do_install_append() { - if ${@bb.utils.contains('PACKAGECONFIG', 'egl', 'true', 'false', d)}; then - sed -i -e 's/^#if defined(MESA_EGL_NO_X11_HEADERS)$/#if defined(MESA_EGL_NO_X11_HEADERS) || ${@bb.utils.contains('PACKAGECONFIG', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h - fi -} diff --git a/poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb b/poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb new file mode 100644 index 000000000..86d6a6bf3 --- /dev/null +++ b/poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb @@ -0,0 +1,21 @@ +require ${BPN}.inc + +SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \ + file://0001-Simplify-wayland-scanner-lookup.patch \ + file://0002-winsys-svga-drm-Include-sys-types.h.patch \ + file://0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch \ + file://0004-Use-Python-3-to-execute-the-scripts.patch \ + file://0005-dri-i965-Add-missing-time.h-include.patch \ + file://0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch \ +" + +SRC_URI[md5sum] = "2f8d2098ab478bc3907e42130577b54a" +SRC_URI[sha256sum] = "55f5778d58a710a63d6635f000535768faf7db9e8144dc0f4fd1989f936c1a83" + +#because we cannot rely on the fact that all apps will use pkgconfig, +#make eglplatform.h independent of MESA_EGL_NO_X11_HEADER +do_install_append() { + if ${@bb.utils.contains('PACKAGECONFIG', 'egl', 'true', 'false', d)}; then + sed -i -e 's/^#if defined(MESA_EGL_NO_X11_HEADERS)$/#if defined(MESA_EGL_NO_X11_HEADERS) || ${@bb.utils.contains('PACKAGECONFIG', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h + fi +} -- cgit v1.2.3