From 6c69a0f2ece7070a6b1cc353ab0df8354c6208e3 Mon Sep 17 00:00:00 2001 From: Than Ngo Date: Thu, 12 Jan 2023 11:24:53 +0100 Subject: [PATCH] update to 109.0.5414.74 --- ...0.5304.101-system-minizip-header-fix.patch | 65 --- chromium-107.0.5304.110-cstring-memset.patch | 11 - chromium-108-clang14-c++20-link-error.patch | 19 - ...ble-GlobalMediaControlsCastStartStop.patch | 20 - ...um-108-vaapi-guard-vaapivideodecoder.patch | 71 --- chromium-109-clang14-c++20-link-error.patch | 17 + ...ble-GlobalMediaControlsCastStartStop.patch | 19 + ...mium-109-ozone-wayland-vaapi-support.patch | 523 +++++++++--------- chromium-109-system-minizip-header-fix.patch | 64 +++ ...mium-84.0.4147.125-i686-fix_textrels.patch | 12 - chromium-98.0.4758.80-remoting-cstring.patch | 56 -- chromium.spec | 66 +-- clean_ffmpeg.sh | 1 - sources | 2 +- 14 files changed, 392 insertions(+), 554 deletions(-) delete mode 100644 chromium-107.0.5304.101-system-minizip-header-fix.patch delete mode 100644 chromium-107.0.5304.110-cstring-memset.patch delete mode 100644 chromium-108-clang14-c++20-link-error.patch delete mode 100644 chromium-108-disable-GlobalMediaControlsCastStartStop.patch delete mode 100644 chromium-108-vaapi-guard-vaapivideodecoder.patch create mode 100644 chromium-109-clang14-c++20-link-error.patch create mode 100644 chromium-109-disable-GlobalMediaControlsCastStartStop.patch rename chromium-108-ozone-wayland-vaapi-support.patch => chromium-109-ozone-wayland-vaapi-support.patch (81%) create mode 100644 chromium-109-system-minizip-header-fix.patch delete mode 100644 chromium-84.0.4147.125-i686-fix_textrels.patch delete mode 100644 chromium-98.0.4758.80-remoting-cstring.patch diff --git a/chromium-107.0.5304.101-system-minizip-header-fix.patch b/chromium-107.0.5304.101-system-minizip-header-fix.patch deleted file mode 100644 index 5ce7fe53..00000000 --- a/chromium-107.0.5304.101-system-minizip-header-fix.patch +++ /dev/null @@ -1,65 +0,0 @@ -diff -up chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc.system-minizip chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc ---- chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc.system-minizip 2022-11-14 11:48:36.877164150 +0100 -+++ chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc 2022-11-14 11:51:55.791949494 +0100 -@@ -27,8 +27,8 @@ limitations under the License. - #include "tensorflow_lite_support/cc/port/status_macros.h" - #include "tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h" - #include "tensorflow_lite_support/metadata/metadata_schema_generated.h" --#include "third_party/zlib/contrib/minizip/ioapi.h" --#include "third_party/zlib/contrib/minizip/unzip.h" -+#include -+#include - - namespace tflite { - namespace metadata { -diff -up chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc.system-minizip chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc ---- chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc.system-minizip 2022-11-14 11:48:36.877164150 +0100 -+++ chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc 2022-11-14 11:52:36.233736347 +0100 -@@ -26,8 +26,8 @@ limitations under the License. - #include "tensorflow_lite_support/cc/port/statusor.h" - #include "tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h" - #include "tensorflow_lite_support/metadata/metadata_schema_generated.h" --#include "third_party/zlib/contrib/minizip/ioapi.h" --#include "third_party/zlib/contrib/minizip/unzip.h" -+#include -+#include - - namespace tflite { - namespace metadata { -diff -up chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc.system-minizip chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc ---- chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc.system-minizip 2022-11-09 01:41:13.000000000 +0100 -+++ chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc 2022-11-14 11:48:36.877164150 +0100 -@@ -19,7 +19,7 @@ limitations under the License. - #include - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "contrib/minizip/ioapi.h" -+#include - - namespace tflite { - namespace metadata { -diff -up chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h.system-minizip chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h -diff -up chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc.system-minizip chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc ---- chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc.system-minizip 2022-11-14 11:48:36.877164150 +0100 -+++ chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc 2022-11-14 11:53:57.365294462 +0100 -@@ -19,7 +19,7 @@ limitations under the License. - #include - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "third_party/zlib/contrib/minizip/ioapi.h" -+#include - - namespace tflite { - namespace metadata { -diff -up chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h.system-minizip chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h ---- chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h.system-minizip 2022-11-14 11:48:36.877164150 +0100 -+++ chromium-107.0.5304.110/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h 2022-11-14 11:54:21.318756738 +0100 -@@ -19,7 +19,7 @@ limitations under the License. - #include - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "third_party/zlib/contrib/minizip/ioapi.h" -+#include - - namespace tflite { - namespace metadata { diff --git a/chromium-107.0.5304.110-cstring-memset.patch b/chromium-107.0.5304.110-cstring-memset.patch deleted file mode 100644 index 3cef5ef3..00000000 --- a/chromium-107.0.5304.110-cstring-memset.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -up chromium-107.0.5304.110/remoting/codec/video_encoder_active_map.cc.me chromium-107.0.5304.110/remoting/codec/video_encoder_active_map.cc ---- chromium-107.0.5304.110/remoting/codec/video_encoder_active_map.cc.me 2022-11-20 19:17:37.781264509 +0100 -+++ chromium-107.0.5304.110/remoting/codec/video_encoder_active_map.cc 2022-11-20 19:18:12.040865033 +0100 -@@ -6,6 +6,7 @@ - - #include - #include -+#include - - #include "base/check_op.h" - #include "third_party/webrtc/modules/desktop_capture/desktop_geometry.h" diff --git a/chromium-108-clang14-c++20-link-error.patch b/chromium-108-clang14-c++20-link-error.patch deleted file mode 100644 index 968aab25..00000000 --- a/chromium-108-clang14-c++20-link-error.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff -up chromium-108.0.5359.124/build/config/compiler/BUILD.gn.me chromium-108.0.5359.124/build/config/compiler/BUILD.gn ---- chromium-108.0.5359.124/build/config/compiler/BUILD.gn.me 2023-01-03 21:02:16.602183035 +0100 -+++ chromium-108.0.5359.124/build/config/compiler/BUILD.gn 2023-01-03 21:04:11.606320859 +0100 -@@ -589,15 +589,6 @@ config("compiler") { - if (is_clang) { - cflags_cc += [ "-fno-trigraphs" ] - } -- } else if (is_linux) { -- # TODO(crbug.com/1284275): Switch to C++20 on all platforms. -- if (is_clang) { -- cflags_cc += [ "-std=${standard_prefix}++20" ] -- } else { -- # The gcc bots are currently using GCC 9, which is not new enough to -- # support "c++20"/"gnu++20". -- cflags_cc += [ "-std=${standard_prefix}++2a" ] -- } - } else { - cflags_cc += [ "-std=${standard_prefix}++17" ] - } diff --git a/chromium-108-disable-GlobalMediaControlsCastStartStop.patch b/chromium-108-disable-GlobalMediaControlsCastStartStop.patch deleted file mode 100644 index ccf52a96..00000000 --- a/chromium-108-disable-GlobalMediaControlsCastStartStop.patch +++ /dev/null @@ -1,20 +0,0 @@ -diff -up chromium-108.0.5359.124/chrome/browser/media/router/media_router_feature.cc.me chromium-108.0.5359.124/chrome/browser/media/router/media_router_feature.cc ---- chromium-108.0.5359.124/chrome/browser/media/router/media_router_feature.cc.me 2022-12-30 13:05:24.520593426 +0100 -+++ chromium-108.0.5359.124/chrome/browser/media/router/media_router_feature.cc 2022-12-30 14:03:08.996254352 +0100 -@@ -46,16 +46,9 @@ BASE_FEATURE(kDialEnforceUrlIPAddress, - BASE_FEATURE(kMediaRemotingWithoutFullscreen, - "MediaRemotingWithoutFullscreen", - base::FEATURE_DISABLED_BY_DEFAULT); -- --#if BUILDFLAG(IS_CHROMEOS) - BASE_FEATURE(kGlobalMediaControlsCastStartStop, - "GlobalMediaControlsCastStartStop", - base::FEATURE_DISABLED_BY_DEFAULT); --#else --BASE_FEATURE(kGlobalMediaControlsCastStartStop, -- "GlobalMediaControlsCastStartStop", -- base::FEATURE_ENABLED_BY_DEFAULT); --#endif // BUILDFLAG(IS_CHROMEOS) - - #endif // !BUILDFLAG(IS_ANDROID) - diff --git a/chromium-108-vaapi-guard-vaapivideodecoder.patch b/chromium-108-vaapi-guard-vaapivideodecoder.patch deleted file mode 100644 index bf684d2a..00000000 --- a/chromium-108-vaapi-guard-vaapivideodecoder.patch +++ /dev/null @@ -1,71 +0,0 @@ -commit f8f456983cf238d0429ab63466d75357d79a32da -author Ted Meyer Thu Dec 08 21:24:37 2022 -committer Chromium LUCI CQ Thu Dec 08 21:24:37 2022 -tree ebfdab985b269b73b48322db0caa594766c9bb58 -parent cbf3167e80fd2dc3a87cdc7143dcdb1edfcb1f72 [diff] -Guard VaapiVideoDecoder behind more correct flags - -Vulkan on linux also needs the features kVulkanFromANGLE and -kDefaultANGLEVulkan to function properly. - -Additinoally, Vaapi on GL needs to be guarded behind a flag. - -Bug: 1236697 -Bug: 1394888 -Bug: 1381114 -Bug: 1383140 -Change-Id: Ifb9da84b95e71fa39c1559455f25e7efcdc083f1 -Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4088731 -Reviewed-by: Dale Curtis -Commit-Queue: Ted (Chromium) Meyer -Cr-Commit-Position: refs/heads/main@{#1081118} -diff -up chromium-108.0.5359.124/media/base/media_switches.cc.orig chromium-108.0.5359.124/media/base/media_switches.cc ---- chromium-108.0.5359.124/media/base/media_switches.cc.orig 2023-01-08 16:37:39.373874165 +0100 -+++ chromium-108.0.5359.124/media/base/media_switches.cc 2023-01-10 08:16:23.492761745 +0100 -@@ -577,6 +577,10 @@ BASE_FEATURE(kVaapiVideoDecodeLinux, - "VaapiVideoDecoder", - base::FEATURE_ENABLED_BY_DEFAULT); - -+BASE_FEATURE(kVaapiVideoDecodeLinuxGL, -+ "VaapiVideoDecodeLinuxGL", -+ base::FEATURE_DISABLED_BY_DEFAULT); -+ - BASE_FEATURE(kVaapiVideoEncodeLinux, - "VaapiVideoEncoder", - base::FEATURE_DISABLED_BY_DEFAULT); -diff -up chromium-108.0.5359.124/media/base/media_switches.h.orig chromium-108.0.5359.124/media/base/media_switches.h ---- chromium-108.0.5359.124/media/base/media_switches.h.orig 2023-01-08 16:37:39.379874227 +0100 -+++ chromium-108.0.5359.124/media/base/media_switches.h 2023-01-10 08:16:23.493761763 +0100 -@@ -216,6 +216,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseMe - MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseR16Texture); - #if BUILDFLAG(IS_LINUX) - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVideoDecodeLinux); -+MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVideoDecodeLinuxGL); - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVideoEncodeLinux); - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiIgnoreDriverChecks); - #endif // BUILDFLAG(IS_LINUX) -diff -up chromium-108.0.5359.124/media/mojo/services/gpu_mojo_media_client_cros.cc.orig chromium-108.0.5359.124/media/mojo/services/gpu_mojo_media_client_cros.cc ---- chromium-108.0.5359.124/media/mojo/services/gpu_mojo_media_client_cros.cc.orig 2023-01-10 08:16:23.493761763 +0100 -+++ chromium-108.0.5359.124/media/mojo/services/gpu_mojo_media_client_cros.cc 2023-01-10 08:21:55.617909016 +0100 -@@ -78,10 +78,19 @@ VideoDecoderType GetActualPlatformDecode - } - case VideoDecoderType::kVaapi: { - // Allow VaapiVideoDecoder on GL. -- if (gpu_preferences.gr_context_type == gpu::GrContextType::kGL) -- return VideoDecoderType::kVaapi; -+ if (gpu_preferences.gr_context_type == gpu::GrContextType::kGL) { -+ if (base::FeatureList::IsEnabled(kVaapiVideoDecodeLinuxGL)) { -+ return VideoDecoderType::kVaapi; -+ } else { -+ return VideoDecoderType::kUnknown; -+ } -+ } - if (gpu_preferences.gr_context_type != gpu::GrContextType::kVulkan) - return VideoDecoderType::kUnknown; -+ if (!base::FeatureList::IsEnabled(features::kVulkanFromANGLE)) -+ return VideoDecoderType::kUnknown; -+ if (!base::FeatureList::IsEnabled(features::kDefaultANGLEVulkan)) -+ return VideoDecoderType::kUnknown; - // If Vulkan is active, check Vulkan info if VaapiVideoDecoder is allowed. - if (!gpu_info.vulkan_info.has_value()) - return VideoDecoderType::kUnknown; diff --git a/chromium-109-clang14-c++20-link-error.patch b/chromium-109-clang14-c++20-link-error.patch new file mode 100644 index 00000000..530915cd --- /dev/null +++ b/chromium-109-clang14-c++20-link-error.patch @@ -0,0 +1,17 @@ +diff -up chromium-109.0.5414.74/build/config/compiler/BUILD.gn.link-error-clang14 chromium-109.0.5414.74/build/config/compiler/BUILD.gn +--- chromium-109.0.5414.74/build/config/compiler/BUILD.gn.link-error-clang14 2023-01-11 18:00:34.692512606 +0100 ++++ chromium-109.0.5414.74/build/config/compiler/BUILD.gn 2023-01-11 18:30:10.905410122 +0100 +@@ -601,12 +601,7 @@ config("compiler") { + cflags_cc += [ "-fno-trigraphs" ] + } + } else if (is_clang) { +- if (is_chromeos_device) { +- # TODO(crbug.com/1392471): Support C++20 in CrOS toolchain. +- cflags_cc += [ "-std=${standard_prefix}++17" ] +- } else { +- cflags_cc += [ "-std=${standard_prefix}++20" ] +- } ++ cflags_cc += [ "-std=${standard_prefix}++17" ] + } else { + # The gcc bots are currently using GCC 9, which is not new enough to + # support "c++20"/"gnu++20". diff --git a/chromium-109-disable-GlobalMediaControlsCastStartStop.patch b/chromium-109-disable-GlobalMediaControlsCastStartStop.patch new file mode 100644 index 00000000..ae492a38 --- /dev/null +++ b/chromium-109-disable-GlobalMediaControlsCastStartStop.patch @@ -0,0 +1,19 @@ +diff -up chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc.disable-GlobalMediaControlsCastStartStop chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc +--- chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc.disable-GlobalMediaControlsCastStartStop 2023-01-11 15:27:50.587737070 +0100 ++++ chromium-109.0.5414.74/chrome/browser/media/router/media_router_feature.cc 2023-01-11 15:30:35.136829951 +0100 +@@ -48,15 +48,9 @@ BASE_FEATURE(kMediaRemotingWithoutFullsc + "MediaRemotingWithoutFullscreen", + base::FEATURE_DISABLED_BY_DEFAULT); + +-#if BUILDFLAG(IS_CHROMEOS) + BASE_FEATURE(kGlobalMediaControlsCastStartStop, + "GlobalMediaControlsCastStartStop", + base::FEATURE_DISABLED_BY_DEFAULT); +-#else +-BASE_FEATURE(kGlobalMediaControlsCastStartStop, +- "GlobalMediaControlsCastStartStop", +- base::FEATURE_ENABLED_BY_DEFAULT); +-#endif // BUILDFLAG(IS_CHROMEOS) + + #endif // BUILDFLAG(IS_ANDROID) + diff --git a/chromium-108-ozone-wayland-vaapi-support.patch b/chromium-109-ozone-wayland-vaapi-support.patch similarity index 81% rename from chromium-108-ozone-wayland-vaapi-support.patch rename to chromium-109-ozone-wayland-vaapi-support.patch index d31ca8cd..6aa61314 100644 --- a/chromium-108-ozone-wayland-vaapi-support.patch +++ b/chromium-109-ozone-wayland-vaapi-support.patch @@ -18,9 +18,9 @@ on Linux. Test: VDA video playback on Linux X11 and Linux Wayland Bug: 1326754,1116701 Change-Id: I6d6bf781833a7752d23dafb2b63112c2fc81b17a -diff -up chromium-108.0.5359.124/media/gpu/args.gni.wayland-vaapi chromium-108.0.5359.124/media/gpu/args.gni ---- chromium-108.0.5359.124/media/gpu/args.gni.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/args.gni 2023-01-05 10:13:08.291403261 +0100 +diff -up chromium-109.0.5359.124/media/gpu/args.gni.wayland-vaapi chromium-109.0.5359.124/media/gpu/args.gni +--- chromium-109.0.5359.124/media/gpu/args.gni.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 ++++ chromium-109.0.5359.124/media/gpu/args.gni 2023-01-05 10:13:08.291403261 +0100 @@ -6,10 +6,14 @@ import("//build/config/chromeos/ui_mode. import("//build/config/ozone.gni") @@ -52,9 +52,9 @@ diff -up chromium-108.0.5359.124/media/gpu/args.gni.wayland-vaapi chromium-108.0 # Indicates if ChromeOS protected media support exists. This is used # to enable the CDM daemon in Chrome OS as well as support for -diff -up chromium-108.0.5359.124/media/gpu/BUILD.gn.wayland-vaapi chromium-108.0.5359.124/media/gpu/BUILD.gn ---- chromium-108.0.5359.124/media/gpu/BUILD.gn.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/BUILD.gn 2023-01-05 10:13:08.291403261 +0100 +diff -up chromium-109.0.5359.124/media/gpu/BUILD.gn.wayland-vaapi chromium-109.0.5359.124/media/gpu/BUILD.gn +--- chromium-109.0.5359.124/media/gpu/BUILD.gn.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 ++++ chromium-109.0.5359.124/media/gpu/BUILD.gn 2023-01-05 10:13:08.291403261 +0100 @@ -20,7 +20,7 @@ buildflag_header("buildflags") { "USE_VAAPI_IMAGE_CODECS=$use_vaapi_image_codecs", "USE_V4L2_CODEC=$use_v4l2_codec", @@ -64,9 +64,9 @@ diff -up chromium-108.0.5359.124/media/gpu/BUILD.gn.wayland-vaapi chromium-108.0 ] } -diff -up chromium-108.0.5359.124/media/gpu/vaapi/BUILD.gn.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/BUILD.gn ---- chromium-108.0.5359.124/media/gpu/vaapi/BUILD.gn.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/BUILD.gn 2023-01-05 10:13:08.291403261 +0100 +diff -up chromium-109.0.5359.124/media/gpu/vaapi/BUILD.gn.wayland-vaapi chromium-109.0.5359.124/media/gpu/vaapi/BUILD.gn +--- chromium-109.0.5359.124/media/gpu/vaapi/BUILD.gn.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 ++++ chromium-109.0.5359.124/media/gpu/vaapi/BUILD.gn 2023-01-05 10:13:08.291403261 +0100 @@ -17,7 +17,7 @@ assert(use_vaapi) generate_stubs("libva_stubs") { extra_header = "va_stub_header.fragment" @@ -94,128 +94,9 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/BUILD.gn.wayland-vaapi chromium deps += [ "//ui/gfx/x" ] } -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.cc.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.cc ---- chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.cc.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.cc 2023-01-05 10:32:58.616517572 +0100 -@@ -12,10 +12,10 @@ - #if defined(USE_OZONE) - #include "media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.h" - #endif // defined(USE_OZONE) --#if BUILDFLAG(USE_VAAPI_X11) -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - #include "media/gpu/vaapi/vaapi_picture_native_pixmap_angle.h" - #include "media/gpu/vaapi/vaapi_picture_tfp.h" --#endif // BUILDFLAG(USE_VAAPI_X11) -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - #if defined(USE_EGL) - #include "media/gpu/vaapi/vaapi_picture_native_pixmap_egl.h" - #endif -@@ -41,22 +41,32 @@ std::unique_ptr CreateVaap - - } // namespace - -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) -+VaapiPictureFactory::VaapiPictureFactory( -+ absl::optional may_use_vaapi_over_x11) -+ : may_use_vaapi_over_x11_(may_use_vaapi_over_x11) { -+#else - VaapiPictureFactory::VaapiPictureFactory() { -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - vaapi_impl_pairs_.insert( - std::make_pair(gl::kGLImplementationEGLGLES2, - VaapiPictureFactory::kVaapiImplementationDrm)); --#if BUILDFLAG(USE_VAAPI_X11) -- vaapi_impl_pairs_.insert( -- std::make_pair(gl::kGLImplementationEGLANGLE, -- VaapiPictureFactory::kVaapiImplementationAngle)); -- vaapi_impl_pairs_.insert( -- std::make_pair(gl::kGLImplementationDesktopGL, -- VaapiPictureFactory::kVaapiImplementationX11)); --#elif defined(USE_OZONE) -+ -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) -+ CHECK(may_use_vaapi_over_x11_.has_value()); -+ if (may_use_vaapi_over_x11_.value()) { -+ vaapi_impl_pairs_.insert( -+ std::make_pair(gl::kGLImplementationEGLANGLE, -+ VaapiPictureFactory::kVaapiImplementationAngle)); -+ vaapi_impl_pairs_.insert( -+ std::make_pair(gl::kGLImplementationDesktopGL, -+ VaapiPictureFactory::kVaapiImplementationX11)); -+ } -+#else - vaapi_impl_pairs_.insert( - std::make_pair(gl::kGLImplementationEGLANGLE, - VaapiPictureFactory::kVaapiImplementationDrm)); --#endif -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - - DeterminePictureCreationAndDownloadingMechanism(); - } -@@ -97,19 +107,19 @@ VaapiPictureFactory::GetVaapiImplementat - } - - uint32_t VaapiPictureFactory::GetGLTextureTarget() { --#if BUILDFLAG(USE_VAAPI_X11) -- return GL_TEXTURE_2D; --#else -+#if BUILDFLAG(IS_CHROMEOS) - return GL_TEXTURE_EXTERNAL_OES; --#endif -+#else -+ return GL_TEXTURE_2D; -+#endif // BUILDFLAG(IS_CHROMEOS) - } - - gfx::BufferFormat VaapiPictureFactory::GetBufferFormat() { --#if BUILDFLAG(USE_VAAPI_X11) -- return gfx::BufferFormat::RGBX_8888; --#else -+#if BUILDFLAG(IS_CHROMEOS) - return gfx::BufferFormat::YUV_420_BIPLANAR; --#endif -+#else -+ return gfx::BufferFormat::RGBX_8888; -+#endif // BUILDFLAG(IS_CHROMEOS) - } - - void VaapiPictureFactory::DeterminePictureCreationAndDownloadingMechanism() { -@@ -117,25 +127,30 @@ void VaapiPictureFactory::DeterminePictu - #if defined(USE_OZONE) - // We can be called without GL initialized, which is valid if we use Ozone. - case kVaapiImplementationNone: -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) -+ DCHECK(may_use_vaapi_over_x11_.value_or(false)); -+#endif - create_picture_cb_ = base::BindRepeating( - &CreateVaapiPictureNativeImpl); - needs_vpp_for_downloading_ = true; - break; - #endif // defined(USE_OZONE) --#if BUILDFLAG(USE_VAAPI_X11) -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - case kVaapiImplementationX11: -+ DCHECK(may_use_vaapi_over_x11_.value_or(false)); - create_picture_cb_ = - base::BindRepeating(&CreateVaapiPictureNativeImpl); - // Neither VaapiTFPPicture or VaapiPictureNativePixmapAngle needs the VPP. - needs_vpp_for_downloading_ = false; - break; - case kVaapiImplementationAngle: -+ DCHECK(may_use_vaapi_over_x11_.value_or(false)); - create_picture_cb_ = base::BindRepeating( - &CreateVaapiPictureNativeImpl); - // Neither VaapiTFPPicture or VaapiPictureNativePixmapAngle needs the VPP. - needs_vpp_for_downloading_ = false; - break; --#endif // BUILDFLAG(USE_VAAPI_X11) -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - case kVaapiImplementationDrm: - #if defined(USE_OZONE) - create_picture_cb_ = base::BindRepeating( -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h ---- chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h 2023-01-05 10:13:08.291403261 +0100 +diff -up chromium-109.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h.wayland-vaapi chromium-109.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h +--- chromium-109.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 ++++ chromium-109.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h 2023-01-05 10:13:08.291403261 +0100 @@ -36,7 +36,11 @@ class MEDIA_GPU_EXPORT VaapiPictureFacto kVaapiImplementationAngle, }; @@ -240,10 +121,9 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_factory.h.wayland }; } // namespace media -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.cc.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.cc -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc ---- chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc.wayland-vaapi 2023-01-05 10:13:08.290403251 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc 2023-01-05 10:13:08.292403271 +0100 +diff -up chromium-109.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc.wayland-vaapi chromium-109.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc +--- chromium-109.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc.wayland-vaapi 2023-01-05 10:13:08.290403251 +0100 ++++ chromium-109.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator.cc 2023-01-05 10:13:08.292403271 +0100 @@ -184,7 +184,12 @@ bool VaapiVideoDecodeAccelerator::Initia Client* client) { DCHECK(task_runner_->BelongsToCurrentThread()); @@ -266,10 +146,107 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator. // The IMPORT mode is used for Android on Chrome OS, so this doesn't apply // here. DCHECK_NE(output_mode_, VideoDecodeAccelerator::Config::OutputMode::IMPORT); -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc ---- chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc 2023-01-05 10:38:15.176631507 +0100 -@@ -38,6 +38,11 @@ struct TestParams { +diff -up chromium-109.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h.wayland-vaapi chromium-109.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h +--- chromium-109.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 ++++ chromium-109.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h 2023-01-05 10:13:08.292403271 +0100 +@@ -36,9 +36,9 @@ + #include "third_party/abseil-cpp/absl/types/optional.h" + #include "ui/gfx/geometry/size.h" + +-#if BUILDFLAG(USE_VAAPI_X11) ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + #include "ui/gfx/x/xproto.h" // nogncheck +-#endif // BUILDFLAG(USE_VAAPI_X11) ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + + namespace gfx { + enum class BufferFormat; +@@ -186,6 +186,16 @@ class MEDIA_GPU_EXPORT VaapiWrapper + VaapiWrapper(const VaapiWrapper&) = delete; + VaapiWrapper& operator=(const VaapiWrapper&) = delete; + ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) ++ // Returns true if VaapiWrapper instances may use VA-API over X11 and false ++ // otherwise (VA-API over DRM will be used). If this returns absl::nullopt, ++ // it's because it was not possible to determine how VA-API may be used. This ++ // should only be called after PreSandboxInitialization() (which is assumed to ++ // be called only once during the GPU process startup) and is safe to call ++ // from any thread. Additionally, this should always return the same value. ++ static absl::optional MayUseVaapiOverX11(); ++#endif ++ + // Returns the supported SVC scalability modes for specified profile. + static std::vector GetSupportedScalabilityModes( + VideoCodecProfile media_profile, +@@ -439,13 +449,13 @@ class MEDIA_GPU_EXPORT VaapiWrapper + VASurfaceID va_surface_id, + const std::vector>& va_buffers); + +-#if BUILDFLAG(USE_VAAPI_X11) ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + // Put data from |va_surface_id| into |x_pixmap| of size + // |dest_size|, converting/scaling to it. + [[nodiscard]] bool PutSurfaceIntoPixmap(VASurfaceID va_surface_id, + x11::Pixmap x_pixmap, + gfx::Size dest_size); +-#endif // BUILDFLAG(USE_VAAPI_X11) ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + + // Creates a ScopedVAImage from a VASurface |va_surface_id| and map it into + // memory with the given |format| and |size|. If |format| is not equal to the +diff -up chromium-109.0.5359.124/media/gpu/vaapi/va_stub_header.fragment.wayland-vaapi chromium-109.0.5359.124/media/gpu/vaapi/va_stub_header.fragment +--- chromium-109.0.5359.124/media/gpu/vaapi/va_stub_header.fragment.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 ++++ chromium-109.0.5359.124/media/gpu/vaapi/va_stub_header.fragment 2023-01-05 10:13:08.291403261 +0100 +@@ -7,8 +7,8 @@ extern "C" { + + #include + #include +-#if BUILDFLAG(USE_VAAPI_X11) ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + #include +-#endif // BUILDFLAG(USE_VAAPI_X11) ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + + } +diff -up chromium-109.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc.wayland-vaapi chromium-109.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc +--- chromium-109.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc.wayland-vaapi 2022-12-14 01:40:14.000000000 +0100 ++++ chromium-109.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc 2023-01-05 10:13:08.292403271 +0100 +@@ -196,7 +196,7 @@ class OzonePlatformX11 : public OzonePla + properties->app_modal_dialogs_use_event_blocker = true; + properties->fetch_buffer_formats_for_gmb_on_gpu = true; + #if BUILDFLAG(IS_LINUX) +- properties->supports_vaapi = true; ++ properties->supports_vaapi_x11 = true; + #endif + + initialised = true; +diff -up chromium-109.0.5359.124/ui/ozone/public/ozone_platform.h.wayland-vaapi chromium-109.0.5359.124/ui/ozone/public/ozone_platform.h +--- chromium-109.0.5359.124/ui/ozone/public/ozone_platform.h.wayland-vaapi 2022-12-14 01:40:14.000000000 +0100 ++++ chromium-109.0.5359.124/ui/ozone/public/ozone_platform.h 2023-01-05 10:13:08.293403281 +0100 +@@ -145,12 +145,13 @@ class COMPONENT_EXPORT(OZONE) OzonePlatf + bool fetch_buffer_formats_for_gmb_on_gpu = false; + + #if BUILDFLAG(IS_LINUX) +- // TODO(crbug.com/1116701): add vaapi support for other Ozone platforms on +- // Linux. At the moment, VA-API Linux implementation supports only X11 +- // backend. This implementation must be refactored to support Ozone +- // properly. As a temporary solution, VA-API on Linux checks if vaapi is +- // supported (which implicitly means that it is Ozone/X11). +- bool supports_vaapi = false; ++ // VA-API supports different display backends. ++ // See https://github.com/intel/libva/blob/master/va/va_backend.h ++ // ++ // VA/DRM and VA/X11 are used by Chromium at the moment. All Ozone platforms ++ // support VA/DRM by default. `supports_vaapi_x11` indicates if VA/X11 ++ // supported; it is true only on Ozone/X11 platform. ++ bool supports_vaapi_x11 = false; + #endif + + // Indicates that the platform allows client applications to manipulate +diff -up chromium-109.0.5414.74/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc.orig chromium-109.0.5414.74/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc +--- chromium-109.0.5414.74/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc.orig 2023-01-04 20:20:18.000000000 +0100 ++++ chromium-109.0.5414.74/media/gpu/vaapi/vaapi_video_decode_accelerator_unittest.cc 2023-01-11 14:31:01.033496121 +0100 +@@ -39,6 +39,11 @@ struct TestParams { bool decode_using_client_picture_buffers; }; @@ -281,7 +258,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_ constexpr int32_t kBitstreamId = 123; constexpr size_t kInputSize = 256; -@@ -130,7 +135,13 @@ class MockVaapiPicture : public VaapiPic +@@ -131,7 +136,13 @@ class MockVaapiPicture : public VaapiPic class MockVaapiPictureFactory : public VaapiPictureFactory { public: @@ -295,7 +272,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_ ~MockVaapiPictureFactory() override = default; MOCK_METHOD3(MockCreateVaapiPicture, -@@ -164,7 +175,12 @@ class VaapiVideoDecodeAcceleratorTest : +@@ -165,7 +176,12 @@ class VaapiVideoDecodeAcceleratorTest : bool can_bind_to_sampler) { return true; })), decoder_thread_("VaapiVideoDecodeAcceleratorTestThread"), mock_decoder_(new ::testing::StrictMock), @@ -308,7 +285,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_ mock_vaapi_wrapper_(new MockVaapiWrapper(VaapiWrapper::kDecode)), mock_vpp_vaapi_wrapper_(new MockVaapiWrapper(VaapiWrapper::kDecode)), weak_ptr_factory_(this) { -@@ -420,14 +436,16 @@ TEST_P(VaapiVideoDecodeAcceleratorTest, +@@ -421,14 +437,16 @@ TEST_P(VaapiVideoDecodeAcceleratorTest, mock_vaapi_picture_factory_->GetVaapiImplementation( gl::kGLImplementationEGLGLES2)); @@ -319,7 +296,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_ - EXPECT_EQ(VaapiPictureFactory::kVaapiImplementationX11, - mock_vaapi_picture_factory_->GetVaapiImplementation( - gl::kGLImplementationDesktopGL)); --#elif defined(USE_OZONE) +-#elif BUILDFLAG(IS_OZONE) +#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + if (kMayUseVaapiOverX11) { + EXPECT_EQ(VaapiPictureFactory::kVaapiImplementationAngle, @@ -333,9 +310,128 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_video_decode_accelerator_ EXPECT_EQ(VaapiPictureFactory::kVaapiImplementationDrm, mock_vaapi_picture_factory_->GetVaapiImplementation( gl::kGLImplementationEGLANGLE)); -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc ---- chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc 2023-01-05 10:41:41.595648227 +0100 +diff -up chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_factory.cc.orig chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_factory.cc +--- chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_factory.cc.orig 2023-01-04 20:20:18.000000000 +0100 ++++ chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_factory.cc 2023-01-11 14:45:36.405506479 +0100 +@@ -13,10 +13,10 @@ + #if BUILDFLAG(IS_OZONE) + #include "media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.h" + #endif // BUILDFLAG(IS_OZONE) +-#if BUILDFLAG(USE_VAAPI_X11) ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + #include "media/gpu/vaapi/vaapi_picture_native_pixmap_angle.h" + #include "media/gpu/vaapi/vaapi_picture_tfp.h" +-#endif // BUILDFLAG(USE_VAAPI_X11) ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + #if defined(USE_EGL) + #include "media/gpu/vaapi/vaapi_picture_native_pixmap_egl.h" + #endif +@@ -42,22 +42,32 @@ + + } // namespace + ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) ++VaapiPictureFactory::VaapiPictureFactory( ++ absl::optional may_use_vaapi_over_x11) ++ : may_use_vaapi_over_x11_(may_use_vaapi_over_x11) { ++#else + VaapiPictureFactory::VaapiPictureFactory() { ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + vaapi_impl_pairs_.insert( + std::make_pair(gl::kGLImplementationEGLGLES2, + VaapiPictureFactory::kVaapiImplementationDrm)); +-#if BUILDFLAG(USE_VAAPI_X11) +- vaapi_impl_pairs_.insert( +- std::make_pair(gl::kGLImplementationEGLANGLE, +- VaapiPictureFactory::kVaapiImplementationAngle)); +- vaapi_impl_pairs_.insert( +- std::make_pair(gl::kGLImplementationDesktopGL, +- VaapiPictureFactory::kVaapiImplementationX11)); +-#elif BUILDFLAG(IS_OZONE) ++ ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) ++ CHECK(may_use_vaapi_over_x11_.has_value()); ++ if (may_use_vaapi_over_x11_.value()) { ++ vaapi_impl_pairs_.insert( ++ std::make_pair(gl::kGLImplementationEGLANGLE, ++ VaapiPictureFactory::kVaapiImplementationAngle)); ++ vaapi_impl_pairs_.insert( ++ std::make_pair(gl::kGLImplementationDesktopGL, ++ VaapiPictureFactory::kVaapiImplementationX11)); ++ } ++#else + vaapi_impl_pairs_.insert( + std::make_pair(gl::kGLImplementationEGLANGLE, + VaapiPictureFactory::kVaapiImplementationDrm)); +-#endif ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + + DeterminePictureCreationAndDownloadingMechanism(); + } +@@ -98,19 +108,19 @@ + } + + uint32_t VaapiPictureFactory::GetGLTextureTarget() { +-#if BUILDFLAG(USE_VAAPI_X11) +- return GL_TEXTURE_2D; +-#else ++#if BUILDFLAG(IS_CHROMEOS) + return GL_TEXTURE_EXTERNAL_OES; +-#endif ++#else ++ return GL_TEXTURE_2D; ++#endif // BUILDFLAG(IS_CHROMEOS) + } + + gfx::BufferFormat VaapiPictureFactory::GetBufferFormat() { +-#if BUILDFLAG(USE_VAAPI_X11) +- return gfx::BufferFormat::RGBX_8888; +-#else ++#if BUILDFLAG(IS_CHROMEOS) + return gfx::BufferFormat::YUV_420_BIPLANAR; +-#endif ++#else ++ return gfx::BufferFormat::RGBX_8888; ++#endif // BUILDFLAG(IS_CHROMEOS) + } + + void VaapiPictureFactory::DeterminePictureCreationAndDownloadingMechanism() { +@@ -118,25 +128,30 @@ + #if BUILDFLAG(IS_OZONE) + // We can be called without GL initialized, which is valid if we use Ozone. + case kVaapiImplementationNone: ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) ++ DCHECK(may_use_vaapi_over_x11_.value_or(false)); ++#endif + create_picture_cb_ = base::BindRepeating( + &CreateVaapiPictureNativeImpl); + needs_vpp_for_downloading_ = true; + break; + #endif // BUILDFLAG(IS_OZONE) +-#if BUILDFLAG(USE_VAAPI_X11) ++#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + case kVaapiImplementationX11: ++ DCHECK(may_use_vaapi_over_x11_.value_or(false)); + create_picture_cb_ = + base::BindRepeating(&CreateVaapiPictureNativeImpl); + // Neither VaapiTFPPicture or VaapiPictureNativePixmapAngle needs the VPP. + needs_vpp_for_downloading_ = false; + break; + case kVaapiImplementationAngle: ++ DCHECK(may_use_vaapi_over_x11_.value_or(false)); + create_picture_cb_ = base::BindRepeating( + &CreateVaapiPictureNativeImpl); + // Neither VaapiTFPPicture or VaapiPictureNativePixmapAngle needs the VPP. + needs_vpp_for_downloading_ = false; + break; +-#endif // BUILDFLAG(USE_VAAPI_X11) ++#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) + case kVaapiImplementationDrm: + #if BUILDFLAG(IS_OZONE) + create_picture_cb_ = base::BindRepeating( +diff -up chromium-109.0.5414.74/media/gpu/vaapi/vaapi_wrapper.cc.orig chromium-109.0.5414.74/media/gpu/vaapi/vaapi_wrapper.cc +--- chromium-109.0.5414.74/media/gpu/vaapi/vaapi_wrapper.cc.orig 2023-01-04 20:20:18.000000000 +0100 ++++ chromium-109.0.5414.74/media/gpu/vaapi/vaapi_wrapper.cc 2023-01-11 15:08:02.721768243 +0100 @@ -62,7 +62,7 @@ #include "ui/gl/gl_bindings.h" #include "ui/gl/gl_implementation.h" @@ -345,16 +441,16 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi typedef XID Drawable; extern "C" { -@@ -70,7 +70,7 @@ extern "C" { +@@ -70,7 +70,7 @@ } #include "ui/gfx/x/connection.h" // nogncheck -#endif // BUILDFLAG(USE_VAAPI_X11) +#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - #if defined(USE_OZONE) + #if BUILDFLAG(IS_OZONE) #include "ui/ozone/public/ozone_platform.h" -@@ -84,14 +84,14 @@ using media_gpu_vaapi::kModuleVa_prot; +@@ -84,14 +84,14 @@ using media_gpu_vaapi::kModuleVa; using media_gpu_vaapi::kModuleVa_drm; @@ -373,7 +469,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi using media_gpu_vaapi::IsVa_drmInitialized; using media_gpu_vaapi::StubPathMap; -@@ -668,6 +668,12 @@ class VADisplayState { +@@ -668,6 +668,12 @@ void SetDrmFd(base::PlatformFile fd) { drm_fd_.reset(HANDLE_EINTR(dup(fd))); } @@ -386,7 +482,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi private: friend class base::NoDestructor; -@@ -690,6 +696,13 @@ class VADisplayState { +@@ -690,6 +696,13 @@ // Drm fd used to obtain access to the driver interface by VA. base::ScopedFD drm_fd_; @@ -400,7 +496,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi // The VADisplay handle. Valid between Initialize() and Deinitialize(). VADisplay va_display_; -@@ -708,6 +721,15 @@ VADisplayState* VADisplayState::Get() { +@@ -708,6 +721,15 @@ // static void VADisplayState::PreSandboxInitialization() { @@ -416,11 +512,11 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi constexpr char kRenderNodeFilePattern[] = "/dev/dri/renderD%d"; // This loop ends on either the first card that does not exist or the first // render node that is not vgem. -@@ -740,20 +762,18 @@ VADisplayState::VADisplayState() +@@ -740,20 +762,18 @@ bool VADisplayState::Initialize() { base::AutoLock auto_lock(va_lock_); --#if defined(USE_OZONE) && BUILDFLAG(IS_LINUX) +-#if BUILDFLAG(IS_OZONE) && BUILDFLAG(IS_LINUX) - // TODO(crbug.com/1116701): add vaapi support for other Ozone platforms on - // Linux. See comment in OzonePlatform::PlatformProperties::supports_vaapi - // for more details. This will also require revisiting everything that's @@ -445,7 +541,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi #endif if (!libraries_initialized) return false; -@@ -768,7 +788,7 @@ bool VADisplayState::Initialize() { +@@ -768,7 +788,7 @@ return success; } @@ -454,7 +550,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi absl::optional GetVADisplayStateX11(const base::ScopedFD& drm_fd) { switch (gl::GetGLImplementation()) { -@@ -796,13 +816,19 @@ absl::optional GetVADisplaySt +@@ -796,13 +816,19 @@ } } @@ -475,7 +571,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi return vaGetDisplayDRM(drm_fd.get()); default: LOG(WARNING) << "VAAPI video acceleration not available for " -@@ -812,18 +838,23 @@ absl::optional GetVADisplaySt +@@ -812,18 +838,23 @@ } } @@ -509,7 +605,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi va_display_ = *display; if (!vaDisplayIsValid(va_display_)) { -@@ -1656,6 +1687,13 @@ scoped_refptr VaapiWrapper +@@ -1656,6 +1687,13 @@ enforce_sequence_affinity); } @@ -523,7 +619,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi // static std::vector VaapiWrapper::GetSupportedScalabilityModes( VideoCodecProfile media_profile, -@@ -2665,12 +2703,13 @@ bool VaapiWrapper::MapAndCopyAndExecute( +@@ -2665,12 +2703,13 @@ return Execute_Locked(va_surface_id, va_buffer_ids); } @@ -538,7 +634,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi base::AutoLockMaybe auto_lock(va_lock_.get()); VAStatus va_res = vaSyncSurface(va_display_, va_surface_id); -@@ -2684,7 +2723,7 @@ bool VaapiWrapper::PutSurfaceIntoPixmap( +@@ -2684,7 +2723,7 @@ VA_SUCCESS_OR_RETURN(va_res, VaapiFunctions::kVAPutSurface, false); return true; } @@ -547,7 +643,7 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi std::unique_ptr VaapiWrapper::CreateVaImage( VASurfaceID va_surface_id, -@@ -3086,7 +3125,7 @@ void VaapiWrapper::PreSandboxInitializat +@@ -3086,7 +3125,7 @@ paths[kModuleVa].push_back(std::string("libva.so.") + va_suffix); paths[kModuleVa_drm].push_back(std::string("libva-drm.so.") + va_suffix); @@ -556,100 +652,15 @@ diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.cc.wayland-vaapi paths[kModuleVa_x11].push_back(std::string("libva-x11.so.") + va_suffix); #endif #if BUILDFLAG(IS_CHROMEOS_ASH) -diff -up chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h ---- chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h.wayland-vaapi 2022-12-14 01:39:53.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/vaapi_wrapper.h 2023-01-05 10:13:08.292403271 +0100 -@@ -36,9 +36,9 @@ - #include "third_party/abseil-cpp/absl/types/optional.h" - #include "ui/gfx/geometry/size.h" - --#if BUILDFLAG(USE_VAAPI_X11) -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - #include "ui/gfx/x/xproto.h" // nogncheck --#endif // BUILDFLAG(USE_VAAPI_X11) -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - - namespace gfx { - enum class BufferFormat; -@@ -186,6 +186,16 @@ class MEDIA_GPU_EXPORT VaapiWrapper - VaapiWrapper(const VaapiWrapper&) = delete; - VaapiWrapper& operator=(const VaapiWrapper&) = delete; - -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) -+ // Returns true if VaapiWrapper instances may use VA-API over X11 and false -+ // otherwise (VA-API over DRM will be used). If this returns absl::nullopt, -+ // it's because it was not possible to determine how VA-API may be used. This -+ // should only be called after PreSandboxInitialization() (which is assumed to -+ // be called only once during the GPU process startup) and is safe to call -+ // from any thread. Additionally, this should always return the same value. -+ static absl::optional MayUseVaapiOverX11(); -+#endif -+ - // Returns the supported SVC scalability modes for specified profile. - static std::vector GetSupportedScalabilityModes( - VideoCodecProfile media_profile, -@@ -439,13 +449,13 @@ class MEDIA_GPU_EXPORT VaapiWrapper - VASurfaceID va_surface_id, - const std::vector>& va_buffers); - --#if BUILDFLAG(USE_VAAPI_X11) -+#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - // Put data from |va_surface_id| into |x_pixmap| of size - // |dest_size|, converting/scaling to it. - [[nodiscard]] bool PutSurfaceIntoPixmap(VASurfaceID va_surface_id, - x11::Pixmap x_pixmap, - gfx::Size dest_size); --#endif // BUILDFLAG(USE_VAAPI_X11) -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - - // Creates a ScopedVAImage from a VASurface |va_surface_id| and map it into - // memory with the given |format| and |size|. If |format| is not equal to the -diff -up chromium-108.0.5359.124/media/gpu/vaapi/va_stub_header.fragment.wayland-vaapi chromium-108.0.5359.124/media/gpu/vaapi/va_stub_header.fragment ---- chromium-108.0.5359.124/media/gpu/vaapi/va_stub_header.fragment.wayland-vaapi 2022-12-14 01:39:52.000000000 +0100 -+++ chromium-108.0.5359.124/media/gpu/vaapi/va_stub_header.fragment 2023-01-05 10:13:08.291403261 +0100 -@@ -7,8 +7,8 @@ extern "C" { - - #include - #include +diff -up chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.cc.orig chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.cc +--- chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.cc.orig 2023-01-11 20:45:17.347940426 +0100 ++++ chromium-109.0.5414.74/media/gpu/vaapi/vaapi_picture_native_pixmap_ozone.cc 2023-01-11 20:45:58.314670752 +0100 +@@ -109,7 +109,7 @@ + ui::OzonePlatform* platform = ui::OzonePlatform::GetInstance(); + ui::SurfaceFactoryOzone* factory = platform->GetSurfaceFactoryOzone(); + gfx::BufferUsage buffer_usage = gfx::BufferUsage::SCANOUT_VDA_WRITE; -#if BUILDFLAG(USE_VAAPI_X11) +#if BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - #include --#endif // BUILDFLAG(USE_VAAPI_X11) -+#endif // BUILDFLAG(SUPPORT_VAAPI_OVER_X11) - - } -diff -up chromium-108.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc.wayland-vaapi chromium-108.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc ---- chromium-108.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc.wayland-vaapi 2022-12-14 01:40:14.000000000 +0100 -+++ chromium-108.0.5359.124/ui/ozone/platform/x11/ozone_platform_x11.cc 2023-01-05 10:13:08.292403271 +0100 -@@ -196,7 +196,7 @@ class OzonePlatformX11 : public OzonePla - properties->app_modal_dialogs_use_event_blocker = true; - properties->fetch_buffer_formats_for_gmb_on_gpu = true; - #if BUILDFLAG(IS_LINUX) -- properties->supports_vaapi = true; -+ properties->supports_vaapi_x11 = true; - #endif - - initialised = true; -diff -up chromium-108.0.5359.124/ui/ozone/public/ozone_platform.h.wayland-vaapi chromium-108.0.5359.124/ui/ozone/public/ozone_platform.h ---- chromium-108.0.5359.124/ui/ozone/public/ozone_platform.h.wayland-vaapi 2022-12-14 01:40:14.000000000 +0100 -+++ chromium-108.0.5359.124/ui/ozone/public/ozone_platform.h 2023-01-05 10:13:08.293403281 +0100 -@@ -145,12 +145,13 @@ class COMPONENT_EXPORT(OZONE) OzonePlatf - bool fetch_buffer_formats_for_gmb_on_gpu = false; - - #if BUILDFLAG(IS_LINUX) -- // TODO(crbug.com/1116701): add vaapi support for other Ozone platforms on -- // Linux. At the moment, VA-API Linux implementation supports only X11 -- // backend. This implementation must be refactored to support Ozone -- // properly. As a temporary solution, VA-API on Linux checks if vaapi is -- // supported (which implicitly means that it is Ozone/X11). -- bool supports_vaapi = false; -+ // VA-API supports different display backends. -+ // See https://github.com/intel/libva/blob/master/va/va_backend.h -+ // -+ // VA/DRM and VA/X11 are used by Chromium at the moment. All Ozone platforms -+ // support VA/DRM by default. `supports_vaapi_x11` indicates if VA/X11 -+ // supported; it is true only on Ozone/X11 platform. -+ bool supports_vaapi_x11 = false; - #endif - - // Indicates that the platform allows client applications to manipulate + // The 'VaapiVideoDecodeAccelerator' requires the VPP to download the decoded + // frame from the internal surface to the allocated native pixmap. + // 'SCANOUT_VDA_WRITE' is used for 'YUV_420_BIPLANAR' on ChromeOS; For Linux, diff --git a/chromium-109-system-minizip-header-fix.patch b/chromium-109-system-minizip-header-fix.patch new file mode 100644 index 00000000..f17c7fad --- /dev/null +++ b/chromium-109-system-minizip-header-fix.patch @@ -0,0 +1,64 @@ +diff -up chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc.system-minizip chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc +--- chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc.system-minizip 2023-01-04 20:20:37.000000000 +0100 ++++ chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc 2023-01-08 15:48:08.654793086 +0100 +@@ -27,8 +27,8 @@ limitations under the License. + #include "tensorflow_lite_support/cc/port/status_macros.h" + #include "tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h" + #include "tensorflow_lite_support/metadata/metadata_schema_generated.h" +-#include "third_party/zlib/contrib/minizip/ioapi.h" +-#include "third_party/zlib/contrib/minizip/unzip.h" ++#include ++#include + + namespace tflite { + namespace metadata { +diff -up chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc.system-minizip chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc +--- chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc.system-minizip 2023-01-04 20:20:37.000000000 +0100 ++++ chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc 2023-01-08 15:48:08.655793097 +0100 +@@ -26,8 +26,8 @@ limitations under the License. + #include "tensorflow_lite_support/cc/port/statusor.h" + #include "tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h" + #include "tensorflow_lite_support/metadata/metadata_schema_generated.h" +-#include "third_party/zlib/contrib/minizip/ioapi.h" +-#include "third_party/zlib/contrib/minizip/unzip.h" ++#include ++#include + + namespace tflite { + namespace metadata { +diff -up chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc.system-minizip chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc +--- chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc.system-minizip 2023-01-08 15:48:08.655793097 +0100 ++++ chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc 2023-01-08 15:53:17.498329640 +0100 +@@ -19,7 +19,7 @@ limitations under the License. + #include + + #include "absl/strings/string_view.h" // from @com_google_absl +-#include "third_party/zlib/contrib/minizip/ioapi.h" ++#include + + namespace tflite { + namespace metadata { +diff -up chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc.system-minizip chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc +--- chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc.system-minizip 2023-01-04 20:20:37.000000000 +0100 ++++ chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc 2023-01-08 15:48:08.655793097 +0100 +@@ -19,7 +19,7 @@ limitations under the License. + #include + + #include "absl/strings/string_view.h" // from @com_google_absl +-#include "third_party/zlib/contrib/minizip/ioapi.h" ++#include + + namespace tflite { + namespace metadata { +diff -up chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h.system-minizip chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h +--- chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h.system-minizip 2023-01-04 20:20:37.000000000 +0100 ++++ chromium-109.0.5414.74/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h 2023-01-08 15:48:08.655793097 +0100 +@@ -19,7 +19,7 @@ limitations under the License. + #include + + #include "absl/strings/string_view.h" // from @com_google_absl +-#include "third_party/zlib/contrib/minizip/ioapi.h" ++#include + + namespace tflite { + namespace metadata { diff --git a/chromium-84.0.4147.125-i686-fix_textrels.patch b/chromium-84.0.4147.125-i686-fix_textrels.patch deleted file mode 100644 index e0fd5ec3..00000000 --- a/chromium-84.0.4147.125-i686-fix_textrels.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up chromium-84.0.4147.125/third_party/ffmpeg/BUILD.gn.i686-textrels chromium-84.0.4147.125/third_party/ffmpeg/BUILD.gn ---- chromium-84.0.4147.125/third_party/ffmpeg/BUILD.gn.i686-textrels 2020-08-17 09:33:53.153653741 -0400 -+++ chromium-84.0.4147.125/third_party/ffmpeg/BUILD.gn 2020-08-17 09:34:25.099564669 -0400 -@@ -68,7 +68,7 @@ if (has_nasm_deps) { - } - - # See comments on fix_textrels config. -- if (use_lld && current_cpu == "x86" && !is_win) { -+ if (current_cpu == "x86" && !is_win) { - all_dependent_configs = [ ":fix_textrels" ] - } - } diff --git a/chromium-98.0.4758.80-remoting-cstring.patch b/chromium-98.0.4758.80-remoting-cstring.patch deleted file mode 100644 index 5c969211..00000000 --- a/chromium-98.0.4758.80-remoting-cstring.patch +++ /dev/null @@ -1,56 +0,0 @@ -diff -up chromium-98.0.4758.80/remoting/base/util.cc.remoting-cstring chromium-98.0.4758.80/remoting/base/util.cc ---- chromium-98.0.4758.80/remoting/base/util.cc.remoting-cstring 2022-02-01 00:41:54.000000000 +0000 -+++ chromium-98.0.4758.80/remoting/base/util.cc 2022-02-02 15:55:01.352340901 +0000 -@@ -4,6 +4,7 @@ - - #include "remoting/base/util.h" - -+#include - #include - - #include "base/logging.h" -diff -up chromium-98.0.4758.80/remoting/client/display/gl_helpers.cc.remoting-cstring chromium-98.0.4758.80/remoting/client/display/gl_helpers.cc ---- chromium-98.0.4758.80/remoting/client/display/gl_helpers.cc.remoting-cstring 2022-02-01 00:41:54.000000000 +0000 -+++ chromium-98.0.4758.80/remoting/client/display/gl_helpers.cc 2022-02-02 15:55:01.353340854 +0000 -@@ -5,6 +5,7 @@ - #include "remoting/client/display/gl_helpers.h" - - #include "base/logging.h" -+#include - - namespace remoting { - -diff -up chromium-98.0.4758.80/remoting/host/fake_mouse_cursor_monitor.cc.remoting-cstring chromium-98.0.4758.80/remoting/host/fake_mouse_cursor_monitor.cc ---- chromium-98.0.4758.80/remoting/host/fake_mouse_cursor_monitor.cc.remoting-cstring 2022-02-01 00:41:54.000000000 +0000 -+++ chromium-98.0.4758.80/remoting/host/fake_mouse_cursor_monitor.cc 2022-02-02 15:55:01.353340854 +0000 -@@ -4,6 +4,7 @@ - - #include "remoting/host/fake_mouse_cursor_monitor.h" - -+#include - #include - - #include "base/check.h" -diff -up chromium-98.0.4758.80/remoting/host/host_config_unittest.cc.remoting-cstring chromium-98.0.4758.80/remoting/host/host_config_unittest.cc ---- chromium-98.0.4758.80/remoting/host/host_config_unittest.cc.remoting-cstring 2022-02-02 15:55:01.353340854 +0000 -+++ chromium-98.0.4758.80/remoting/host/host_config_unittest.cc 2022-02-02 15:57:20.295794172 +0000 -@@ -10,6 +10,7 @@ - #include "base/values.h" - #include "testing/gtest/include/gtest/gtest.h" - #include "third_party/abseil-cpp/absl/types/optional.h" -+#include - - namespace remoting { - -diff -up chromium-98.0.4758.80/remoting/host/host_secret.cc.remoting-cstring chromium-98.0.4758.80/remoting/host/host_secret.cc ---- chromium-98.0.4758.80/remoting/host/host_secret.cc.remoting-cstring 2022-02-01 00:41:54.000000000 +0000 -+++ chromium-98.0.4758.80/remoting/host/host_secret.cc 2022-02-02 15:55:01.353340854 +0000 -@@ -6,7 +6,7 @@ - - #include - --#include -+#include - - #include "base/rand_util.h" - #include "base/strings/string_number_conversions.h" diff --git a/chromium.spec b/chromium.spec index 54fa7903..02b5f3d8 100644 --- a/chromium.spec +++ b/chromium.spec @@ -7,13 +7,13 @@ %endif %global numjobs 10 -%ifarch aarch64 i686 +%ifarch aarch64 %global numjobs 8 %endif # This flag is so I can build things very fast on a giant system. # Enabling this in koji causes aarch64 builds to timeout indefinitely. -%global use_all_cpus 0 +%global use_all_cpus 1 %if %{use_all_cpus} %global numjobs %{_smp_build_ncpus} @@ -30,7 +30,7 @@ ninja -j %{numjobs} -C '%1' '%2' # enable|disable headless client build -%global build_headless 1 +%global build_headless 0 # enable|disable chrome-remote-desktop build %global build_remoting 0 @@ -111,14 +111,9 @@ # enable system brotli %global bundlebrotli 0 -%if 0 # Chromium's fork of ICU is now something we can't unbundle. # This is left here to ease the change if that ever switches. -BuildRequires: libicu-devel >= 5.4 -%global bundleicu 0 -%else %global bundleicu 1 -%endif %global bundlere2 1 @@ -215,8 +210,8 @@ BuildRequires: libicu-devel >= 5.4 %endif Name: chromium%{chromium_channel} -Version: 108.0.5359.124 -Release: 5%{?dist} +Version: 109.0.5414.74 +Release: 1%{?dist} Summary: A WebKit (Blink) powered web browser that Google doesn't want you to use Url: http://www.chromium.org/Home License: BSD and LGPLv2+ and ASL 2.0 and IJG and MIT and GPLv2+ and ISC and OpenSSL and (MPLv1.1 or GPLv2 or LGPLv2) @@ -256,38 +251,32 @@ Patch11: chromium-93.0.4577.63-py3-bootstrap.patch Patch12: chromium-101.0.4951.41-fedora-user-agent.patch # Needs to be submitted.. -Patch51: chromium-96.0.4664.45-gcc-remoting-constexpr.patch +Patch51: chromium-96.0.4664.45-gcc-remoting-constexpr.patch # https://gitweb.gentoo.org/repo/gentoo.git/tree/www-client/chromium/files/chromium-unbundle-zlib.patch -Patch52: chromium-81.0.4044.92-unbundle-zlib.patch +Patch52: chromium-81.0.4044.92-unbundle-zlib.patch # ../../third_party/perfetto/include/perfetto/base/task_runner.h:48:55: error: 'uint32_t' has not been declared -Patch56: chromium-96.0.4664.45-missing-cstdint-header.patch +Patch56: chromium-96.0.4664.45-missing-cstdint-header.patch # Missing (thanks c++17) -Patch57: chromium-96.0.4664.45-missing-cstring.patch +Patch57: chromium-96.0.4664.45-missing-cstring.patch # https://github.com/stha09/chromium-patches/blob/master/chromium-103-VirtualCursor-std-layout.patch -Patch59: chromium-103-VirtualCursor-std-layout.patch +Patch59: chromium-103-VirtualCursor-std-layout.patch # Fix headers to look for system paths when we are using system minizip -Patch61: chromium-107.0.5304.101-system-minizip-header-fix.patch +Patch61: chromium-109-system-minizip-header-fix.patch # Update bundled copy of wayland-client-core.h -Patch62: chromium-105.0.5195.52-update-wayland-client-core.patch +Patch62: chromium-105.0.5195.52-update-wayland-client-core.patch # Fix issue where closure_compiler thinks java is only allowed in android builds # https://bugs.chromium.org/p/chromium/issues/detail?id=1192875 -Patch65: chromium-91.0.4472.77-java-only-allowed-in-android-builds.patch - -# Fix missing cstring in remoting code -Patch67: chromium-98.0.4758.80-remoting-cstring.patch - -# Apply fix_textrels hack for i686 (even without lld) -Patch68: chromium-84.0.4147.125-i686-fix_textrels.patch +Patch65: chromium-91.0.4472.77-java-only-allowed-in-android-builds.patch # Update rjsmin to 1.2.0 -Patch69: chromium-103.0.5060.53-update-rjsmin-to-1.2.0.patch +Patch69: chromium-103.0.5060.53-update-rjsmin-to-1.2.0.patch # Update six to 1.16.0 Patch70: chromium-105.0.5195.52-python-six-1.16.0.patch @@ -318,7 +307,7 @@ Patch89: chromium-108-system-brotli.patch # disable GlobalMediaControlsCastStartStop to avoid crash # when using the address bar media player button -Patch90: chromium-108-disable-GlobalMediaControlsCastStartStop.patch +Patch90: chromium-109-disable-GlobalMediaControlsCastStartStop.patch # patch for using system opus Patch91: chromium-108-system-opus.patch @@ -361,9 +350,6 @@ Patch107: chromium-99.0.4844.51-el7-extra-operator==.patch # AARCH64 neon symbols need to be prefixed too to prevent multiple definition issue at linktime Patch110: chromium-90.0.4430.93-epel8-aarch64-libpng16-symbol-prefixes.patch -# memset was not declared in this scope -Patch113: chromium-107.0.5304.110-cstring-memset.patch - # system ffmpeg Patch114: chromium-107-ffmpeg-duration.patch Patch115: chromium-107-proprietary-codecs.patch @@ -374,7 +360,7 @@ Patch117: chromium-108-ffmpeg-revert-new-channel-layout-api.patch # clang =< 14 and C++20, linker errors std::u16string # build failure on rhel and fedora 36 -Patch120: chromium-108-clang14-c++20-link-error.patch +Patch120: chromium-109-clang14-c++20-link-error.patch # enable Qt Patch121: chromium-108-enable-allowqt.patch @@ -383,8 +369,7 @@ Patch121: chromium-108-enable-allowqt.patch # Upstream turned VAAPI on in Linux in 86 Patch202: chromium-104.0.5112.101-enable-hardware-accelerated-mjpeg.patch Patch205: chromium-86.0.4240.75-fix-vaapi-on-intel.patch -Patch206: chromium-108-ozone-wayland-vaapi-support.patch -Patch207: chromium-108-vaapi-guard-vaapivideodecoder.patch +Patch206: chromium-109-ozone-wayland-vaapi-support.patch # Apply these patches to work around EPEL8 issues Patch300: chromium-99.0.4844.51-rhel8-force-disable-use_gnome_keyring.patch @@ -624,6 +609,10 @@ BuildRequires: python3-devel BuildRequires: python3-zipp BuildRequires: python3-simplejson +%if 0%{?rhel} <= 8 +BuildRequires: python3-dataclasses +%endif + %if ! 0%{?bundlepylibs} %if 0%{?fedora} || 0%{?rhel} >= 8 BuildRequires: python3-beautifulsoup4 @@ -647,10 +636,6 @@ BuildRequires: re2-devel >= 20160401 BuildRequires: brotli-devel %endif -%if ! %{bundleopus} -BuildRequires: opus-devel -%endif - BuildRequires: speech-dispatcher-devel BuildRequires: yasm BuildRequires: zlib-devel @@ -975,8 +960,6 @@ udev. %endif %patch65 -p1 -b .java-only-allowed -%patch67 -p1 -b .remoting-cstring -%patch68 -p1 -b .i686-textrels %patch69 -p1 -b .update-rjsmin-to-1.2.0 %patch70 -p1 -b .update-six-to-1.16.0 %patch80 -p1 -b .EnumTable-crash @@ -1009,8 +992,6 @@ udev. %patch12 -p1 -b .fedora-user-agent %endif -%patch113 -p1 -b .memset - %if ! 0%{?bundleffmpegfree} %patch114 -p1 -b .system-ffmppeg %patch115 -p1 -b .prop-codecs @@ -1044,7 +1025,6 @@ udev. %patch202 -p1 -b .accel-mjpeg %patch205 -p1 -b .vaapi-intel-fix %patch206 -p1 -b .wayland-vaapi -%patch207 -p1 -b .guard-vaapiVideoDecoder %endif %if 0%{?use_qt} @@ -1272,7 +1252,6 @@ CHROMIUM_CORE_GN_DEFINES+=' use_custom_libcxx=false' CHROMIUM_CORE_GN_DEFINES+=' use_kerberos=true' CHROMIUM_CORE_GN_DEFINES+=' target_os="linux"' CHROMIUM_CORE_GN_DEFINES+=' current_os="linux"' -CHROMIUM_CORE_GN_DEFINES+=' use_allocator="none"' CHROMIUM_CORE_GN_DEFINES+=' enable_vr=false' CHROMIUM_CORE_GN_DEFINES+=' build_dawn_tests=false' CHROMIUM_CORE_GN_DEFINES+=' enable_iterator_debugging=false' @@ -1776,6 +1755,9 @@ getent group chrome-remote-desktop >/dev/null || groupadd -r chrome-remote-deskt %{chromium_path}/chromedriver %changelog +* Wed Jan 11 2023 Than Ngo - 109.0.5414.74-1 +- update to 109.0.5414.74 + * Tue Jan 10 2023 Than Ngo - 108.0.5359.124-5 - enable qt backend for el >= 9 and fedora >= 35 - drop i686 diff --git a/clean_ffmpeg.sh b/clean_ffmpeg.sh index 00353811..21f43f13 100755 --- a/clean_ffmpeg.sh +++ b/clean_ffmpeg.sh @@ -122,7 +122,6 @@ header_files=" libavcodec/x86/inline_asm.h \ libavcodec/mpegutils.h \ libavcodec/mpegvideo.h \ libavcodec/mpegvideodata.h \ - libavcodec/mpegvideodsp.h \ libavcodec/mpegvideoencdsp.h \ libavcodec/options_table.h \ libavcodec/opusdsp.h \ diff --git a/sources b/sources index adb7c774..82a7d2d7 100644 --- a/sources +++ b/sources @@ -19,4 +19,4 @@ SHA512 (NotoSansSymbols2-Regular.ttf) = 2644b42c3fdccfe12395f9b61553aced169a0f1d SHA512 (NotoSansTibetan-Regular.ttf) = fb5a48fcaea80eebe7d692f6fcf00d59d47658a358d0ec8e046fc559873f88bd595b2da474d2826abd9e9305f3741c69058d867b1e6048f37fe7d71b5d3af36a SHA512 (node-v16.17.0-linux-x64.tar.xz) = aedfeeb71420a7fbcb07fbc4c5d2ba74ffe4f88c15998809346a84148132ec866dbae4e848531a2a77ca41413f442e1046f981d4f188bdf667faf88069aa28cd SHA512 (node-v16.17.0-linux-arm64.tar.xz) = ae4aabc2389779c9e1b4a15622cae3ba50e0c313ca3d7a1dc7b2344df06ade1f303d6a75b941d37e2a0ef368cf047c862a822a893684494f55446afd6ab0610e -SHA512 (chromium-108.0.5359.124-clean.tar.xz) = a47fb046b5be2f26f65f467a20fe300a86542bebf3d7e8d8a6064458bf4cfcc0243a1f5212755d1d4121b79f79bc2d3b61d7918431daef26538f0755608e444b +SHA512 (chromium-109.0.5414.74-clean.tar.xz) = 620836f27aeffa828f3ff434aa08025979bd98699288a14783a68e7f905d117ec7d2feec82c34c05dee1659c1e2a4c7bec1e279a34ff25b66246083364a5d12e