Roll flutter-auto 52/30752/2
authorJoel Winarske <joel.winarske@gmail.com>
Fri, 17 Jan 2025 20:08:02 +0000 (12:08 -0800)
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>
Tue, 21 Jan 2025 13:40:59 +0000 (13:40 +0000)
-flutter sdk 3.27.1
-remove patch for fallback; upstream has formal fix
-remove patch for asio workaround; upstream has formal fix
-update workspace-automation configs to match

Change-Id: I77ec901eca20079d0a9126182777f75bee4b6057
Signed-off-by: Joel Winarske <joel.winarske@gmail.com>
Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl/+/30775
Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
Tested-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
(cherry picked from commit 34b699256549697a6ce7a0dac3447974178770c2)
Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl/+/30752

meta-agl-flutter/conf/include/agl-flutter.inc
meta-agl-flutter/recipes-graphics/toyota/files/0001-backend-wayland_egl-Add-a-fallback-eglConfig.patch [deleted file]
meta-agl-flutter/recipes-graphics/toyota/files/0001-flutter_desktop-Remove-asio-post-call.patch [deleted file]
meta-agl-flutter/recipes-graphics/toyota/flutter-auto_aglflutter.inc
meta-agl-flutter/tools/configs/_globals.json
meta-agl-flutter/tools/configs/_repos.json

index 6d60bc4..50bb7f7 100644 (file)
@@ -1,3 +1,3 @@
 AGL_FEATURES += "agl-flutter"
 
-FLUTTER_SDK_TAG = "3.24.2"
+FLUTTER_SDK_TAG = "3.27.1"
diff --git a/meta-agl-flutter/recipes-graphics/toyota/files/0001-backend-wayland_egl-Add-a-fallback-eglConfig.patch b/meta-agl-flutter/recipes-graphics/toyota/files/0001-backend-wayland_egl-Add-a-fallback-eglConfig.patch
deleted file mode 100644 (file)
index f2195dd..0000000
+++ /dev/null
@@ -1,88 +0,0 @@
-From 372b9c4edd42b67827b75863b978091ba5cff5cd Mon Sep 17 00:00:00 2001
-From: Marius Vlad <marius.vlad@collabora.com>
-Date: Thu, 17 Oct 2024 17:25:41 +0300
-Subject: [PATCH 1/2] backend/wayland_egl: Add a fallback eglConfig
-
-This seems to aid flutter-auto at displaying an image on agl-rdp
-with software rendering, and on agl-kvm with virgl.  Makes uses of a fallback
-eGLConfig (< 24 bit) and tries to use that one rather than the default one (24-bit).
-
-Bug-AGL: SPEC-5260
-Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
----
- cmake/config_common.h.in         | 17 ++++++++++++++++-
- shell/backend/wayland_egl/egl.cc | 23 ++++++++++++++++++++---
- 2 files changed, 36 insertions(+), 4 deletions(-)
-
-diff --git a/cmake/config_common.h.in b/cmake/config_common.h.in
-index 07ce9b7..2c54c67 100644
---- a/cmake/config_common.h.in
-+++ b/cmake/config_common.h.in
-@@ -155,6 +155,21 @@ static constexpr std::array<EGLint, 27> kEglConfigAttribs = {{
-     // clang-format on
- }};
-+
-+static constexpr std::array<EGLint, 27> kEglConfigAttribsFallBack = {{
-+    // clang-format off
-+    EGL_SURFACE_TYPE, EGL_WINDOW_BIT,
-+    EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT,
-+
-+    EGL_RED_SIZE, 1,
-+    EGL_GREEN_SIZE, 1,
-+    EGL_BLUE_SIZE, 1,
-+    EGL_ALPHA_SIZE, 2,
-+    EGL_NONE // termination sentinel
-+    // clang-format on
-+}};
-+
-+
- // All vkCreate* functions take an optional allocator. For now, we select the
- // default allocator by passing in a null pointer, and we highlight the argument
- // by using the VKALLOC constant.
-@@ -181,4 +196,4 @@ constexpr struct VkAllocationCallbacks* VKALLOC = nullptr;
- #cmakedefine01 ENV32BIT
- #cmakedefine01 ENV64BIT
--#endif //CONFIG_COMMON_H_
-\ No newline at end of file
-+#endif //CONFIG_COMMON_H_
-diff --git a/shell/backend/wayland_egl/egl.cc b/shell/backend/wayland_egl/egl.cc
-index 99555d6..70164ba 100644
---- a/shell/backend/wayland_egl/egl.cc
-+++ b/shell/backend/wayland_egl/egl.cc
-@@ -62,11 +62,28 @@ Egl::Egl(void* native_display, int buffer_size, bool debug)
-       break;
-     }
-   }
--  free(configs);
-   if (m_config == nullptr) {
--    spdlog::critical("did not find config with buffer size {}", m_buffer_size);
--    assert(false);
-+    // try with the fallback one
-+    spdlog::critical("Could not use default EGLConfig trying with fallback.");
-+    ret = eglChooseConfig(m_dpy, kEglConfigAttribsFallBack.data(), configs,
-+                          count, &n);
-+    assert(ret && n >= 1);
-+
-+    for (EGLint i = 0; i < n; i++) {
-+      eglGetConfigAttrib(m_dpy, configs[i], EGL_BUFFER_SIZE, &size);
-+      SPDLOG_DEBUG("Buffer size for config {} is {}", i, size);
-+      if (m_buffer_size <= size) {
-+        memcpy(&m_config, &configs[i], sizeof(EGLConfig));
-+        break;
-+      }
-+    }
-+    if (m_config == nullptr) {
-+      spdlog::critical("did not find config with buffer size {}",
-+                       m_buffer_size);
-+      assert(false);
-+    }
-   }
-+  free(configs);
-   m_context = eglCreateContext(m_dpy, m_config, EGL_NO_CONTEXT,
-                                kEglContextAttribs.data());
--- 
-2.43.0
-
diff --git a/meta-agl-flutter/recipes-graphics/toyota/files/0001-flutter_desktop-Remove-asio-post-call.patch b/meta-agl-flutter/recipes-graphics/toyota/files/0001-flutter_desktop-Remove-asio-post-call.patch
deleted file mode 100644 (file)
index f9cfea4..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-From a69dfff93b41b30ae8e237817548baf50d0c1287 Mon Sep 17 00:00:00 2001
-From: Marius Vlad <marius.vlad@collabora.com>
-Date: Thu, 24 Oct 2024 14:45:35 +0300
-Subject: [PATCH] flutter_desktop: Remove asio::post call
-
-Do not dispatch/post the key event keycode using asio::post as that
-seems to cause crashes as the messenger pointer seems to be go out of
-scope or seems to be invalid.
-
-Bug-AGL: SPEC-5272
-Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
----
- shell/platform/homescreen/flutter_desktop.cc | 65 ++++++++++----------
- 1 file changed, 31 insertions(+), 34 deletions(-)
-
-diff --git a/shell/platform/homescreen/flutter_desktop.cc b/shell/platform/homescreen/flutter_desktop.cc
-index bb5be4b..5d26dd9 100644
---- a/shell/platform/homescreen/flutter_desktop.cc
-+++ b/shell/platform/homescreen/flutter_desktop.cc
-@@ -161,40 +161,37 @@ std::future<bool> PostMessengerSendWithReply(
-     void* user_data) {
-   const auto promise(std::make_shared<std::promise<bool>>());
-   auto promise_future(promise->get_future());
--  asio::post(*messenger->GetEngine()->platform_task_runner->GetStrandContext(),
--             [&, promise, channel, message, message_size, reply, user_data]() {
--               FlutterPlatformMessageResponseHandle* response_handle = nullptr;
--               if (reply != nullptr && user_data != nullptr) {
--                 const FlutterEngineResult result =
--                     LibFlutterEngine->PlatformMessageCreateResponseHandle(
--                         messenger->GetEngine()->flutter_engine, reply,
--                         user_data, &response_handle);
--                 if (result != kSuccess) {
--                   spdlog::error("Failed to create response handle");
--                   promise->set_value(false);
--                   return;
--                 }
--               }
--
--               auto platform_message = std::make_unique<FlutterPlatformMessage>();
--               platform_message->struct_size = sizeof(FlutterPlatformMessage);
--               platform_message->channel = channel;
--               platform_message->message = message;
--               platform_message->message_size = message_size;
--               platform_message->response_handle = response_handle;
--
--               const FlutterEngineResult message_result =
--                   LibFlutterEngine->SendPlatformMessage(
--                       messenger->GetEngine()->flutter_engine,
--                       platform_message.release());
--
--               if (response_handle != nullptr) {
--                 LibFlutterEngine->PlatformMessageReleaseResponseHandle(
--                     messenger->GetEngine()->flutter_engine, response_handle);
--               }
--
--               promise->set_value(message_result == kSuccess);
--             });
-+
-+  FlutterPlatformMessageResponseHandle* response_handle = nullptr;
-+  if (reply != nullptr && user_data != nullptr) {
-+    const FlutterEngineResult result =
-+        LibFlutterEngine->PlatformMessageCreateResponseHandle(
-+            messenger->GetEngine()->flutter_engine, reply, user_data,
-+            &response_handle);
-+    if (result != kSuccess) {
-+      spdlog::error("Failed to create response handle");
-+      promise->set_value(false);
-+      return promise_future;
-+    }
-+  }
-+
-+  auto platform_message = std::make_unique<FlutterPlatformMessage>();
-+  platform_message->struct_size = sizeof(FlutterPlatformMessage);
-+  platform_message->channel = channel;
-+  platform_message->message = message;
-+  platform_message->message_size = message_size;
-+  platform_message->response_handle = response_handle;
-+
-+  const FlutterEngineResult message_result =
-+      LibFlutterEngine->SendPlatformMessage(
-+          messenger->GetEngine()->flutter_engine, platform_message.release());
-+
-+  if (response_handle != nullptr) {
-+    LibFlutterEngine->PlatformMessageReleaseResponseHandle(
-+        messenger->GetEngine()->flutter_engine, response_handle);
-+  }
-+
-+  promise->set_value(message_result == kSuccess);
-   return promise_future;
- }
--- 
-2.43.0
-
index 29c023f..0b4610c 100644 (file)
@@ -1,12 +1,4 @@
 FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
 
-EGLCONFIG_FALLBACK = "${@bb.utils.contains_any('AGL_FEATURES', 'agl-rdp agl-kvm-guest', '', 'file://0001-backend-wayland_egl-Add-a-fallback-eglConfig.patch', d)}"
 SRC_URI:append:use-nxp-bsp = " file://0001-Disable-on_frame_base_surface-wl_surface_commit.patch"
-SRC_URI:append = " ${EGLCONFIG_FALLBACK}"
 
-# necessary to avoid crashing flutter-auto when a key keyboard event is emitted
-SRC_URI:append = " file://0001-flutter_desktop-Remove-asio-post-call.patch"
-
-# Disable WIP webview plugin on 32-bit ARM platforms for now, as build
-# failures have been seen on qemuarm and beaglebone.
-PACKAGECONFIG:remove:arm = "webview_flutter_view"
index 1830c8d..0418e62 100644 (file)
@@ -1,5 +1,5 @@
 {
-    "flutter-version": "3.24.1",
+    "flutter-version": "3.27.1",
     "github_token": "",
     "cookie_file": ""
 }
index 5fb8aa0..8fcac4b 100644 (file)
@@ -1,12 +1,12 @@
 [
     {
         "uri": "https://github.com/toyota-connected/ivi-homescreen.git",
-        "rev": "e87c1797f838e20f0a4c1af309541d63986058ca",
+        "rev": "2341312e5118a9b96a3f0e7c13a2813b4a7e779c",
         "branch": "v2.0"
     },
     {
         "uri": "https://github.com/toyota-connected/ivi-homescreen-plugins.git",
-        "rev": "41d00635f89c064aa32f2cef3147c59b8f61694f",
+        "rev": "f2a7336c34ed4720742a42245b84de56729d56e3",
         "branch": "v2.0"
     },
     {