diff options
Diffstat (limited to 'www/chromium/files')
1292 files changed, 12249 insertions, 9502 deletions
diff --git a/www/chromium/files/patch-BUILD.gn b/www/chromium/files/patch-BUILD.gn index e599afc55ff6..54c68fcb2332 100644 --- a/www/chromium/files/patch-BUILD.gn +++ b/www/chromium/files/patch-BUILD.gn @@ -1,6 +1,6 @@ ---- BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ BUILD.gn -@@ -64,7 +64,7 @@ declare_args() { +@@ -71,7 +71,7 @@ declare_args() { root_extra_deps = [] } @@ -9,7 +9,7 @@ # An official (maximally optimized!) component (optimized for build times) # build doesn't make sense and usually doesn't work. assert(!is_component_build) -@@ -96,7 +96,6 @@ group("gn_all") { +@@ -103,7 +103,6 @@ group("gn_all") { "//codelabs", "//components:components_unittests", "//components/gwp_asan:gwp_asan_unittests", @@ -17,7 +17,7 @@ "//net:net_unittests", "//sandbox:sandbox_unittests", "//services:services_unittests", -@@ -427,7 +426,7 @@ group("gn_all") { +@@ -448,7 +447,7 @@ group("gn_all") { } } @@ -26,64 +26,73 @@ deps += [ "//third_party/breakpad:breakpad_unittests", "//third_party/breakpad:core-2-minidump", -@@ -627,6 +626,15 @@ group("gn_all") { +@@ -635,6 +634,15 @@ group("gn_all") { } } + if (is_bsd) { + deps -= [ -+ "//third_party/breakpad:dump_syms($host_toolchain)", -+ "//third_party/breakpad:microdump_stackwalk($host_toolchain)", -+ "//third_party/breakpad:minidump_dump($host_toolchain)", -+ "//third_party/breakpad:minidump_stackwalk($host_toolchain)", ++ "//third_party/breakpad:dump_syms($host_system_allocator_toolchain)", ++ "//third_party/breakpad:microdump_stackwalk($host_system_allocator_toolchain)", ++ "//third_party/breakpad:minidump_dump($host_system_allocator_toolchain)", ++ "//third_party/breakpad:minidump_stackwalk($host_system_allocator_toolchain)", + ] + } + if (is_mac) { deps += [ - "//third_party/breakpad:dump_syms", -@@ -673,7 +681,7 @@ group("gn_all") { - host_os == "win") { - deps += [ "//chrome/test/mini_installer:mini_installer_tests" ] + "//third_party/breakpad:dump_syms($host_system_allocator_toolchain)", +@@ -683,7 +691,7 @@ group("gn_all") { } -- } else if (!is_android && !is_ios && !is_fuchsia) { -+ } else if (!is_android && !is_ios && !is_fuchsia && !is_bsd) { - deps += [ "//third_party/breakpad:symupload($host_toolchain)" ] } -@@ -1094,7 +1102,7 @@ if (use_blink && !is_cronet_build) { +- if (!is_fuchsia) { ++ if (!is_fuchsia && !is_bsd) { + # The official builders use this binary from the default toolchain's + # output directory after building in order to upload the symbols of that + # binary. They build the binary like `ninja symupload` which requires the +@@ -718,7 +726,7 @@ group("gn_all") { + ] + } + +- if (is_mac || is_win || is_android || is_linux || is_chromeos) { ++ if (!is_bsd && (is_mac || is_win || is_android || is_linux || is_chromeos)) { + deps += [ + "//third_party/crashpad/crashpad:crashpad_tests", + "//third_party/crashpad/crashpad/handler:crashpad_handler", +@@ -1127,7 +1135,7 @@ if (use_blink && !is_cronet_build) { + "//third_party/blink/public:all_blink", ] - } -- if (!is_chromeos_ash && !is_ios && !is_fuchsia && !is_android && !is_castos) { -+ if (!is_chromeos_ash && !is_ios && !is_fuchsia && !is_android && !is_castos && !is_bsd) { - script_test("chrome_wpt_tests") { - script = "//third_party/blink/tools/run_wpt_tests.py" - args = [ -@@ -1185,7 +1193,7 @@ if (use_blink && !is_cronet_build) { +- if (!is_chromeos && !is_ios && !is_fuchsia && !is_android && !is_castos) { ++ if (!is_chromeos && !is_ios && !is_fuchsia && !is_android && !is_castos && !is_bsd) { + deps += [ + ":chrome_wpt_tests", + ":headless_shell_wpt", +@@ -1274,7 +1282,7 @@ if (use_blink && !is_cronet_build) { data_deps += [ "//content/web_test:web_test_common_mojom_js_data_deps" ] } - if (!is_win && !is_android) { + if (!is_win && !is_android && !is_bsd) { - data_deps += - [ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ] - } -@@ -1194,7 +1202,7 @@ if (use_blink && !is_cronet_build) { - data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ] + # Using the default toolchain for this tool, as it's run during tests not + # during the build. This places a symlink in the root_build_dir for scrips + # to use. +@@ -1288,7 +1296,7 @@ if (use_blink && !is_cronet_build) { + data_deps += [ "//third_party/breakpad:dump_syms" ] } - if (is_linux || is_chromeos) { + if ((is_linux && !is_bsd) || is_chromeos) { - data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ] - } - -@@ -1654,7 +1662,7 @@ group("chromium_builder_perf") { + # Using the default toolchain for this tool, as it's run during tests not + # during the build. This places a symlink in the root_build_dir for scrips + # to use. +@@ -1742,7 +1750,7 @@ group("chromium_builder_perf") { data_deps += [ "//chrome/test:performance_browser_tests" ] } - if (!is_win) { + if (!is_win && !is_bsd) { - data_deps += - [ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ] + data_deps += [ "//third_party/breakpad:minidump_stackwalk($host_system_allocator_toolchain)" ] } + } diff --git a/www/chromium/files/patch-apps_ui_views_app__window__frame__view.cc b/www/chromium/files/patch-apps_ui_views_app__window__frame__view.cc index d675abdb9186..b79b6d026cd5 100644 --- a/www/chromium/files/patch-apps_ui_views_app__window__frame__view.cc +++ b/www/chromium/files/patch-apps_ui_views_app__window__frame__view.cc @@ -1,11 +1,11 @@ ---- apps/ui/views/app_window_frame_view.cc.orig 2024-01-30 07:53:34 UTC +--- apps/ui/views/app_window_frame_view.cc.orig 2025-04-04 08:52:13 UTC +++ apps/ui/views/app_window_frame_view.cc -@@ -148,7 +148,7 @@ gfx::Rect AppWindowFrameView::GetWindowBoundsForClient +@@ -146,7 +146,7 @@ gfx::Rect AppWindowFrameView::GetBoundsForClientView() + gfx::Rect AppWindowFrameView::GetWindowBoundsForClientBounds( + const gfx::Rect& client_bounds) const { gfx::Rect window_bounds = client_bounds; - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Get the difference between the widget's client area bounds and window // bounds, and grow |window_bounds| by that amount. gfx::Insets native_frame_insets = diff --git a/www/chromium/files/patch-ash_display_mirror__window__controller.cc b/www/chromium/files/patch-ash_display_mirror__window__controller.cc index a737f68789ff..c5461906602e 100644 --- a/www/chromium/files/patch-ash_display_mirror__window__controller.cc +++ b/www/chromium/files/patch-ash_display_mirror__window__controller.cc @@ -1,6 +1,6 @@ ---- ash/display/mirror_window_controller.cc.orig 2023-09-13 12:11:42 UTC +--- ash/display/mirror_window_controller.cc.orig 2024-11-14 07:57:23 UTC +++ ash/display/mirror_window_controller.cc -@@ -294,7 +294,11 @@ void MirrorWindowController::UpdateWindow( +@@ -295,7 +295,11 @@ void MirrorWindowController::UpdateWindow( if (!base::Contains(display_info_list, iter->first, &display::ManagedDisplayInfo::id)) { CloseAndDeleteHost(iter->second, true); diff --git a/www/chromium/files/patch-base_BUILD.gn b/www/chromium/files/patch-base_BUILD.gn index 111ebfe4e412..8b460ebbffe1 100644 --- a/www/chromium/files/patch-base_BUILD.gn +++ b/www/chromium/files/patch-base_BUILD.gn @@ -1,15 +1,6 @@ ---- base/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- base/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ base/BUILD.gn -@@ -200,7 +200,7 @@ buildflag_header("ios_cronet_buildflags") { - flags = [ "CRONET_BUILD=$is_cronet_build" ] - } - --enable_message_pump_epoll = is_linux || is_chromeos || is_android -+enable_message_pump_epoll = (is_linux || is_chromeos || is_android) && !is_bsd - buildflag_header("message_pump_buildflags") { - header = "message_pump_buildflags.h" - header_dir = "base/message_loop" -@@ -1131,11 +1131,23 @@ component("base") { +@@ -1107,11 +1107,26 @@ component("base") { # Needed for <atomic> if using newer C++ library than sysroot, except if # building inside the cros_sdk environment - use host_toolchain as a # more robust check for this. @@ -21,7 +12,10 @@ + # *BSD needs libkvm + if (is_bsd) { -+ libs += [ "kvm" ] ++ libs += [ ++ "kvm", ++ "epoll-shim", ++ ] + } + + if (is_freebsd) { @@ -34,7 +28,7 @@ if (use_allocator_shim) { if (is_apple) { sources += [ "allocator/early_zone_registration_apple.h" ] -@@ -1155,7 +1167,7 @@ component("base") { +@@ -1131,7 +1146,7 @@ component("base") { # Allow more direct string conversions on platforms with native utf8 # strings @@ -43,7 +37,7 @@ defines += [ "SYSTEM_NATIVE_UTF8" ] } -@@ -2113,6 +2125,22 @@ component("base") { +@@ -2172,6 +2187,22 @@ component("base") { ] } @@ -66,7 +60,7 @@ # iOS if (is_ios) { sources += [ -@@ -2249,6 +2277,33 @@ component("base") { +@@ -2340,6 +2371,33 @@ component("base") { } } @@ -100,16 +94,16 @@ if (use_blink) { sources += [ "files/file_path_watcher.cc", -@@ -2259,7 +2314,7 @@ component("base") { - } +@@ -2735,7 +2793,7 @@ buildflag_header("protected_memory_buildflags") { + header = "protected_memory_buildflags.h" + header_dir = "base/memory" - if (dep_libevent) { -- deps += [ "//third_party/libevent" ] -+ public_deps += [ "//third_party/libevent" ] - } +- protected_memory_enabled = !is_component_build && is_clang && ++ protected_memory_enabled = !is_openbsd && !is_component_build && is_clang && + (is_win || is_linux || is_android || is_mac) - if (use_libevent) { -@@ -3072,7 +3127,7 @@ if (is_apple) { + flags = [ "PROTECTED_MEMORY_ENABLED=$protected_memory_enabled" ] +@@ -3242,7 +3300,7 @@ if (is_apple) { } } @@ -118,7 +112,7 @@ # This test must compile with -fstack-protector-all source_set("stack_canary_linux_unittests") { testonly = true -@@ -3716,7 +3771,7 @@ test("base_unittests") { +@@ -3931,7 +3989,7 @@ test("base_unittests") { ] } @@ -127,7 +121,7 @@ sources += [ "debug/proc_maps_linux_unittest.cc", "files/scoped_file_linux_unittest.cc", -@@ -3743,7 +3798,7 @@ test("base_unittests") { +@@ -3959,7 +4017,7 @@ test("base_unittests") { "posix/file_descriptor_shuffle_unittest.cc", "posix/unix_domain_socket_unittest.cc", ] @@ -136,7 +130,7 @@ sources += [ "profiler/stack_base_address_posix_unittest.cc", "profiler/stack_copier_signal_unittest.cc", -@@ -3754,7 +3809,7 @@ test("base_unittests") { +@@ -3970,7 +4028,7 @@ test("base_unittests") { # Allow more direct string conversions on platforms with native utf8 # strings @@ -145,8 +139,8 @@ defines += [ "SYSTEM_NATIVE_UTF8" ] } -@@ -4022,7 +4077,7 @@ test("base_unittests") { - } +@@ -4158,7 +4216,7 @@ test("base_unittests") { + deps += [ ":base_profiler_test_support_library" ] } - if (is_fuchsia || is_linux || is_chromeos) { diff --git a/www/chromium/files/patch-base_allocator_dispatcher_tls.h b/www/chromium/files/patch-base_allocator_dispatcher_tls.h index 4846c23803fd..e9673222f13b 100644 --- a/www/chromium/files/patch-base_allocator_dispatcher_tls.h +++ b/www/chromium/files/patch-base_allocator_dispatcher_tls.h @@ -1,6 +1,6 @@ ---- base/allocator/dispatcher/tls.h.orig 2024-04-19 13:02:56 UTC +--- base/allocator/dispatcher/tls.h.orig 2025-02-19 07:43:18 UTC +++ base/allocator/dispatcher/tls.h -@@ -76,7 +76,7 @@ struct BASE_EXPORT MMapAllocator { +@@ -81,7 +81,7 @@ struct BASE_EXPORT MMapAllocator { constexpr static size_t AllocationChunkSize = 16384; #elif BUILDFLAG(IS_ANDROID) && defined(ARCH_CPU_64_BITS) constexpr static size_t AllocationChunkSize = 16384; diff --git a/www/chromium/files/patch-base_allocator_partition__alloc__features.cc b/www/chromium/files/patch-base_allocator_partition__alloc__features.cc new file mode 100644 index 000000000000..57c523f43129 --- /dev/null +++ b/www/chromium/files/patch-base_allocator_partition__alloc__features.cc @@ -0,0 +1,11 @@ +--- base/allocator/partition_alloc_features.cc.orig 2025-05-28 14:55:43 UTC ++++ base/allocator/partition_alloc_features.cc +@@ -164,7 +164,7 @@ BASE_FEATURE(kPartitionAllocEventuallyZeroFreedMemory, + // disabled elsewhere (for now). Does not apply to Windows. + BASE_FEATURE(kPartitionAllocFewerMemoryRegions, + "PartitionAllocFewerMemoryRegions", +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + FEATURE_ENABLED_BY_DEFAULT); + #else + FEATURE_DISABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_partition__alloc.gni b/www/chromium/files/patch-base_allocator_partition__allocator_partition__alloc.gni index d9e57c421e1a..f279b52b32c6 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_partition__alloc.gni +++ b/www/chromium/files/patch-base_allocator_partition__allocator_partition__alloc.gni @@ -1,20 +1,29 @@ ---- base/allocator/partition_allocator/partition_alloc.gni.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/partition_alloc.gni.orig 2025-07-02 06:08:04 UTC +++ base/allocator/partition_allocator/partition_alloc.gni -@@ -33,7 +33,7 @@ if (is_nacl) { - use_large_empty_slot_span_ring = is_mac +@@ -91,7 +91,7 @@ if (is_nacl) { + # TODO(crbug.com/329199197): Clean this up when experiments are complete. + use_large_empty_slot_span_ring = true - has_memory_tagging = -- current_cpu == "arm64" && is_clang && !is_asan && (is_linux || is_android) -+ current_cpu == "arm64" && is_clang && !is_asan && !is_bsd && (is_linux || is_android) +-has_memory_tagging = current_cpu == "arm64" && is_clang && !is_asan && ++has_memory_tagging = current_cpu == "arm64" && is_clang && !is_asan && !is_bsd && + !is_hwasan && (is_linux || is_android) declare_args() { - # Causes all the allocations to be routed via allocator_shim.cc. Usually, @@ -351,7 +351,7 @@ declare_args() { - # dependencies that use partition_allocator are compiled in AOSP against a - # version of glibc that does not include pkeys syscall numbers. - enable_pkeys = -- (is_linux || is_chromeos) && target_cpu == "x64" && !is_cronet_build -+ !is_bsd && (is_linux || is_chromeos) && target_cpu == "x64" && !is_cronet_build + declare_args() { + # Shadow metadata is still under development and only supports Linux + # for now. +- enable_shadow_metadata = is_linux && has_64_bit_pointers ++ enable_shadow_metadata = !is_bsd && is_linux && has_64_bit_pointers + } + + declare_args() { +@@ -494,7 +494,7 @@ assert(!use_asan_backup_ref_ptr || use_raw_ptr_hookabl + # dependencies that use partition_allocator are compiled in AOSP against a + # version of glibc that does not include pkeys syscall numbers. + is_pkeys_available = +- (is_linux || is_chromeos) && current_cpu == "x64" && !is_cronet_build ++ !is_bsd && (is_linux || is_chromeos) && current_cpu == "x64" && !is_cronet_build + declare_args() { + enable_pkeys = is_pkeys_available } - assert(!enable_pkeys || ((is_linux || is_chromeos) && target_cpu == "x64"), - "Pkeys are only supported on x64 linux and ChromeOS") diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_BUILD.gn b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_BUILD.gn index 6c1f761e5029..4e4d827927f3 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_BUILD.gn +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_BUILD.gn @@ -1,7 +1,7 @@ ---- base/allocator/partition_allocator/src/partition_alloc/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ base/allocator/partition_allocator/src/partition_alloc/BUILD.gn -@@ -851,7 +851,7 @@ if (is_clang_or_gcc) { - configs -= [ "//build/config/compiler:enable_arc" ] +@@ -892,7 +892,7 @@ if (is_clang_or_gcc) { + configs -= [ partition_alloc_enable_arc_config ] } } - if (is_chromeos || is_linux) { diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_address__space__randomization.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_address__space__randomization.h index 76b0580b3f89..a91fb1bc8acf 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_address__space__randomization.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_address__space__randomization.h @@ -1,20 +1,20 @@ ---- base/allocator/partition_allocator/src/partition_alloc/address_space_randomization.h.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/address_space_randomization.h.orig 2024-07-30 11:12:21 UTC +++ base/allocator/partition_allocator/src/partition_alloc/address_space_randomization.h @@ -38,7 +38,7 @@ AslrMask(uintptr_t bits) { - #if defined(ARCH_CPU_64_BITS) + #if PA_BUILDFLAG(PA_ARCH_CPU_64_BITS) - #if defined(MEMORY_TOOL_REPLACES_ALLOCATOR) -+ #if defined(MEMORY_TOOL_REPLACES_ALLOCATOR) && !BUILDFLAG(IS_BSD) ++ #if defined(MEMORY_TOOL_REPLACES_ALLOCATOR) && !PA_BUILDFLAG(IS_BSD) // We shouldn't allocate system pages at all for sanitizer builds. However, // we do, and if random hint addresses interfere with address ranges -@@ -128,7 +128,7 @@ AslrMask(uintptr_t bits) { +@@ -125,7 +125,7 @@ AslrMask(uintptr_t bits) { return AslrAddress(0x20000000ULL); } - -- #elif BUILDFLAG(IS_LINUX) -+ #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #elif PA_BUILDFLAG(PA_ARCH_CPU_ARM64) +- #if PA_BUILDFLAG(IS_LINUX) ++ #if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_BSD) // Linux on arm64 can use 39, 42, 48, or 52-bit user space, depending on // page size and number of levels of translation pages used. We use diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator.h index 2b8e04c5b547..027b2c44fd46 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator.h @@ -1,11 +1,11 @@ ---- base/allocator/partition_allocator/src/partition_alloc/page_allocator.h.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/page_allocator.h.orig 2024-08-26 12:06:38 UTC +++ base/allocator/partition_allocator/src/partition_alloc/page_allocator.h -@@ -259,7 +259,7 @@ bool DecommitAndZeroSystemPages(void* address, +@@ -269,7 +269,7 @@ bool DecommitAndZeroSystemPages(void* address, // recommitted. Do not assume that this will not change over time. constexpr PA_COMPONENT_EXPORT( PARTITION_ALLOC) bool DecommittedMemoryIsAlwaysZeroed() { --#if BUILDFLAG(IS_APPLE) -+#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_APPLE) ++#if PA_BUILDFLAG(IS_APPLE) || PA_BUILDFLAG(IS_BSD) return false; #else return true; diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__constants.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__constants.h index e3693583741a..9253c611d00c 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__constants.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__constants.h @@ -1,11 +1,13 @@ ---- base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h.orig 2025-02-19 07:43:18 UTC +++ base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h -@@ -26,7 +26,7 @@ +@@ -26,8 +26,8 @@ #define PAGE_ALLOCATOR_CONSTANTS_DECLARE_CONSTEXPR __attribute__((const)) - #elif (BUILDFLAG(IS_ANDROID) && defined(ARCH_CPU_64_BITS)) || \ -- (BUILDFLAG(IS_LINUX) && defined(ARCH_CPU_ARM64)) -+ ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(ARCH_CPU_ARM64)) + #elif (PA_BUILDFLAG(IS_ANDROID) && PA_BUILDFLAG(PA_ARCH_CPU_64_BITS)) || \ +- (PA_BUILDFLAG(IS_LINUX) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64)) || \ +- (PA_BUILDFLAG(IS_LINUX) && PA_BUILDFLAG(PA_ARCH_CPU_PPC64)) ++ ((PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_BSD)) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64)) || \ ++ ((PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_BSD)) && PA_BUILDFLAG(PA_ARCH_CPU_PPC64)) // This should work for all POSIX (if needed), but currently all other // supported OS/architecture combinations use either hard-coded values // (such as x86) or have means to determine these values without needing diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.cc new file mode 100644 index 000000000000..05c2b846c157 --- /dev/null +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.cc @@ -0,0 +1,11 @@ +--- base/allocator/partition_allocator/src/partition_alloc/page_allocator_internals_posix.cc.orig 2025-01-15 09:18:26 UTC ++++ base/allocator/partition_allocator/src/partition_alloc/page_allocator_internals_posix.cc +@@ -39,7 +39,7 @@ uint32_t SecTaskGetCodeSignStatus(SecTaskRef task) API + + #if PA_BUILDFLAG(HAS_MEMORY_TAGGING) || \ + (defined(__ARM_FEATURE_BTI_DEFAULT) && (__ARM_FEATURE_BTI_DEFAULT == 1) && \ +- __has_include(<sys/ifunc.h>)) ++ __has_include(<sys/ifunc.h>) && !PA_BUILDFLAG(IS_BSD)) + struct __ifunc_arg_t; + + #include "partition_alloc/aarch64_support.h" diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.h index 3f74e4127498..3fba15f04c89 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_page__allocator__internals__posix.h @@ -1,12 +1,12 @@ ---- base/allocator/partition_allocator/src/partition_alloc/page_allocator_internals_posix.h.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/page_allocator_internals_posix.h.orig 2025-05-28 14:55:43 UTC +++ base/allocator/partition_allocator/src/partition_alloc/page_allocator_internals_posix.h -@@ -411,8 +411,12 @@ bool TryRecommitSystemPagesInternal( +@@ -317,8 +317,12 @@ bool TryRecommitSystemPagesInternal( void DiscardSystemPagesInternal(uintptr_t address, size_t length) { void* ptr = reinterpret_cast<void*>(address); --#if BUILDFLAG(IS_APPLE) -+#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) -+#if BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_APPLE) ++#if PA_BUILDFLAG(IS_APPLE) || PA_BUILDFLAG(IS_BSD) ++#if PA_BUILDFLAG(IS_BSD) + int ret = madvise(ptr, length, MADV_FREE); +#else int ret = madvise(ptr, length, MADV_FREE_REUSABLE); diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_proc__maps__linux.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_proc__maps__linux.cc new file mode 100644 index 000000000000..f8aa0f73aaae --- /dev/null +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_proc__maps__linux.cc @@ -0,0 +1,11 @@ +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/debug/proc_maps_linux.cc.orig 2025-07-02 06:08:04 UTC ++++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/debug/proc_maps_linux.cc +@@ -15,7 +15,7 @@ + #include "partition_alloc/partition_alloc_check.h" + + #if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) || \ +- PA_BUILDFLAG(IS_ANDROID) ++ PA_BUILDFLAG(IS_ANDROID) || PA_BUILDFLAG(IS_BSD) + #include <inttypes.h> + #endif + diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_stack__trace__posix.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_stack__trace__posix.cc index d3aa9f9ef802..dc95a41a0378 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_stack__trace__posix.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_debug_stack__trace__posix.cc @@ -1,16 +1,16 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/debug/stack_trace_posix.cc.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/debug/stack_trace_posix.cc.orig 2024-07-30 11:12:21 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/debug/stack_trace_posix.cc @@ -13,11 +13,11 @@ #include "partition_alloc/partition_alloc_base/posix/eintr_wrapper.h" #include "partition_alloc/partition_alloc_base/strings/safe_sprintf.h" --#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_APPLE) -+#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_BSD) +-#if !PA_BUILDFLAG(IS_ANDROID) && !PA_BUILDFLAG(IS_APPLE) ++#if !PA_BUILDFLAG(IS_ANDROID) && !PA_BUILDFLAG(IS_APPLE) && !PA_BUILDFLAG(IS_BSD) #include <link.h> // For ElfW() macro. #endif --#if BUILDFLAG(IS_APPLE) -+#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_APPLE) ++#if PA_BUILDFLAG(IS_APPLE) || PA_BUILDFLAG(IS_BSD) #include <dlfcn.h> #endif @@ -18,17 +18,17 @@ namespace { --#if !BUILDFLAG(IS_APPLE) -+#if !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_BSD) +-#if !PA_BUILDFLAG(IS_APPLE) ++#if !PA_BUILDFLAG(IS_APPLE) && !PA_BUILDFLAG(IS_BSD) // On Android the 'open' function has two versions: // int open(const char *pathname, int flags); @@ -369,7 +369,7 @@ void PrintStackTraceInternal(const void** trace, size_ } - #endif // !BUILDFLAG(IS_APPLE) + #endif // !PA_BUILDFLAG(IS_APPLE) --#if BUILDFLAG(IS_APPLE) -+#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_APPLE) ++#if PA_BUILDFLAG(IS_APPLE) || PA_BUILDFLAG(IS_BSD) // Since /proc/self/maps is not available, use dladdr() to obtain module // names and offsets inside the modules from the given addresses. void PrintStackTraceInternal(const void* const* trace, size_t size) { diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_rand__util__posix.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_rand__util__posix.cc index e9d1cc9df848..e24b29f35988 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_rand__util__posix.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_rand__util__posix.cc @@ -1,10 +1,10 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/rand_util_posix.cc.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/rand_util_posix.cc.orig 2024-07-30 11:12:21 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/rand_util_posix.cc @@ -102,6 +102,10 @@ void RandBytes(void* output, size_t output_length) { if (getentropy(output, output_length) == 0) { return; } -+#elif BUILDFLAG(IS_BSD) ++#elif PA_BUILDFLAG(IS_BSD) + if (getentropy(output, output_length) == 0) { + return; + } diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread.h index 4fa07f52d169..10a2c6a426b3 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread.h @@ -1,11 +1,11 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread.h.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread.h.orig 2024-07-30 11:12:21 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread.h @@ -37,6 +37,8 @@ typedef DWORD PlatformThreadId; typedef zx_handle_t PlatformThreadId; - #elif BUILDFLAG(IS_APPLE) + #elif PA_BUILDFLAG(IS_APPLE) typedef mach_port_t PlatformThreadId; -+#elif BUILDFLAG(IS_BSD) ++#elif PA_BUILDFLAG(IS_BSD) +typedef uint64_t PlatformThreadId; - #elif BUILDFLAG(IS_POSIX) + #elif PA_BUILDFLAG(IS_POSIX) typedef pid_t PlatformThreadId; #endif diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__internal__posix.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__internal__posix.h index d84248567e0d..0fc3aad100bb 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__internal__posix.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__internal__posix.h @@ -1,11 +1,11 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread_internal_posix.h.orig 2023-12-10 06:10:27 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread_internal_posix.h.orig 2024-07-30 11:12:21 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread_internal_posix.h @@ -10,7 +10,7 @@ namespace partition_alloc::internal::base::internal { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) ++#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) || PA_BUILDFLAG(IS_BSD) // Current thread id is cached in thread local storage for performance reasons. // In some rare cases it's important to invalidate that cache explicitly (e.g. // after going through clone() syscall which does not call pthread_atfork() diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__posix.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__posix.cc index b311bc492836..d9bac77867cb 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__posix.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__base_threading_platform__thread__posix.cc @@ -1,11 +1,11 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread_posix.cc.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread_posix.cc.orig 2025-05-05 10:57:53 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_base/threading/platform_thread_posix.cc @@ -18,7 +18,7 @@ #include "partition_alloc/partition_alloc_base/logging.h" #include "partition_alloc/partition_alloc_base/threading/platform_thread_internal_posix.h" --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) ++#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) || PA_BUILDFLAG(IS_BSD) #include <sys/syscall.h> #include <atomic> #endif diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__config.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__config.h index 0bdfb80dfa47..e4cfcf24bd5c 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__config.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__config.h @@ -1,20 +1,20 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_config.h.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_config.h.orig 2025-07-02 06:08:04 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_config.h -@@ -251,7 +251,7 @@ constexpr bool kUseLazyCommit = false; - // On these platforms, lock all the partitions before fork(), and unlock after. +@@ -164,7 +164,7 @@ constexpr bool kUseLazyCommit = false; // This may be required on more platforms in the future. - #define PA_CONFIG_HAS_ATFORK_HANDLER() \ -- (BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) -+ (BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) + #define PA_CONFIG_HAS_ATFORK_HANDLER() \ + (PA_BUILDFLAG(IS_APPLE) || PA_BUILDFLAG(IS_LINUX) || \ +- PA_BUILDFLAG(IS_CHROMEOS)) ++ PA_BUILDFLAG(IS_CHROMEOS) || PA_BUILDFLAG(IS_BSD)) - // PartitionAlloc uses PartitionRootEnumerator to acquire all - // PartitionRoots at BeforeFork and to release at AfterFork. -@@ -299,7 +299,7 @@ constexpr bool kUseLazyCommit = false; + // Enable shadow metadata. // +@@ -227,7 +227,7 @@ constexpr bool kUseLazyCommit = false; // Also enabled on ARM64 macOS and iOS, as the 16kiB pages on this platform lead // to larger slot spans. --#if BUILDFLAG(IS_LINUX) || (BUILDFLAG(IS_APPLE) && defined(ARCH_CPU_ARM64)) -+#if BUILDFLAG(IS_LINUX) || (BUILDFLAG(IS_APPLE) && defined(ARCH_CPU_ARM64)) || BUILDFLAG(IS_BSD) + #if PA_BUILDFLAG(IS_LINUX) || \ +- (PA_BUILDFLAG(IS_APPLE) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64)) ++ (PA_BUILDFLAG(IS_APPLE) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64)) || PA_BUILDFLAG(IS_BSD) #define PA_CONFIG_PREFER_SMALLER_SLOT_SPANS() 1 #else #define PA_CONFIG_PREFER_SMALLER_SLOT_SPANS() 0 diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__constants.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__constants.h index 5214c122b0c5..870385c2cbc6 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__constants.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__constants.h @@ -1,11 +1,20 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_constants.h.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_constants.h.orig 2025-07-02 06:08:04 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_constants.h -@@ -313,7 +313,7 @@ constexpr size_t kNumPools = kMaxPoolHandle - 1; +@@ -308,7 +308,7 @@ PA_DEFINE_OPERATORS_FOR_FLAGS(PoolHandleMask); // 8GB for each of the glued pools). - #if BUILDFLAG(HAS_64_BIT_POINTERS) - #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) || \ -- BUILDFLAG(ENABLE_POINTER_COMPRESSION) -+ BUILDFLAG(ENABLE_POINTER_COMPRESSION) || BUILDFLAG(IS_BSD) + #if PA_BUILDFLAG(HAS_64_BIT_POINTERS) + #if PA_BUILDFLAG(IS_ANDROID) || PA_BUILDFLAG(IS_IOS) || \ +- PA_BUILDFLAG(ENABLE_POINTER_COMPRESSION) ++ PA_BUILDFLAG(ENABLE_POINTER_COMPRESSION) || PA_BUILDFLAG(IS_BSD) constexpr size_t kPoolMaxSize = 8 * kGiB; #else constexpr size_t kPoolMaxSize = 16 * kGiB; +@@ -392,7 +392,7 @@ PA_ALWAYS_INLINE constexpr size_t MaxDirectMapped() { + // TODO(casey.smalley@arm.com): under 64k pages we can end up in a situation + // where a normal slot span will be large enough to contain multiple items, + // but the address will go over the final partition page after being aligned. +-#if PA_BUILDFLAG(IS_LINUX) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64) ++#if (PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_BSD)) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64) + constexpr size_t kMaxSupportedAlignment = kSuperPageSize / 4; + #else + constexpr size_t kMaxSupportedAlignment = kSuperPageSize / 2; diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__forward.h b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__forward.h index f6a75c332ad9..a643336a705f 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__forward.h +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__alloc__forward.h @@ -1,16 +1,16 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_forward.h.orig 2023-12-10 06:10:27 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_alloc_forward.h.orig 2025-07-02 06:08:04 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_alloc_forward.h -@@ -28,9 +28,13 @@ namespace internal { +@@ -29,9 +29,13 @@ namespace internal { // the second one 16. We could technically return something different for // malloc() and operator new(), but this would complicate things, and most of // our allocations are presumably coming from operator new() anyway. +#if defined(__i386__) && defined(OS_FREEBSD) +constexpr size_t kAlignment = 8; +#else - constexpr size_t kAlignment = + constexpr inline size_t kAlignment = std::max(alignof(max_align_t), static_cast<size_t>(__STDCPP_DEFAULT_NEW_ALIGNMENT__)); +#endif + static_assert(base::bits::HasSingleBit(kAlignment), + "Alignment must be power of two."); static_assert(kAlignment <= 16, - "PartitionAlloc doesn't support a fundamental alignment larger " - "than 16 bytes."); diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__root.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__root.cc index d5d4496bfa86..1516d9efd50d 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__root.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_partition__root.cc @@ -1,29 +1,29 @@ ---- base/allocator/partition_allocator/src/partition_alloc/partition_root.cc.orig 2024-04-19 13:02:56 UTC +--- base/allocator/partition_allocator/src/partition_alloc/partition_root.cc.orig 2025-07-02 06:08:04 UTC +++ base/allocator/partition_allocator/src/partition_alloc/partition_root.cc -@@ -47,7 +47,7 @@ +@@ -45,7 +45,7 @@ #include "wow64apiset.h" #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) ++#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) || PA_BUILDFLAG(IS_BSD) #include <pthread.h> - #endif - -@@ -279,7 +279,7 @@ void PartitionAllocMallocInitOnce() { + #if PA_CONFIG(ENABLE_SHADOW_METADATA) + #include <sys/mman.h> +@@ -298,7 +298,7 @@ void PartitionAllocMallocInitOnce() { return; } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) ++#if PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_CHROMEOS) || PA_BUILDFLAG(IS_BSD) // When fork() is called, only the current thread continues to execute in the // child process. If the lock is held, but *not* by this thread when fork() is // called, we have a deadlock. -@@ -950,7 +950,7 @@ void PartitionRoot::Init(PartitionOptions opts) { +@@ -1110,7 +1110,7 @@ void PartitionRoot::Init(PartitionOptions opts) { // apple OSes. PA_CHECK((internal::SystemPageSize() == (size_t{1} << 12)) || (internal::SystemPageSize() == (size_t{1} << 14))); --#elif BUILDFLAG(IS_LINUX) && defined(ARCH_CPU_ARM64) -+#elif (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(ARCH_CPU_ARM64) +-#elif PA_BUILDFLAG(IS_LINUX) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64) ++#elif (PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_BSD)) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64) // Check runtime pagesize. Though the code is currently the same, it is - // not merged with the IS_APPLE case above as a 1 << 16 case needs to be - // added here in the future, to allow 64 kiB pagesize. That is only + // not merged with the IS_APPLE case above as a 1 << 16 case is only + // supported on Linux on AArch64. diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_spinning__mutex.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_spinning__mutex.cc index aacc03277192..43924605b160 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_spinning__mutex.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_spinning__mutex.cc @@ -1,6 +1,6 @@ ---- base/allocator/partition_allocator/src/partition_alloc/spinning_mutex.cc.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/spinning_mutex.cc.orig 2025-05-28 14:55:43 UTC +++ base/allocator/partition_allocator/src/partition_alloc/spinning_mutex.cc -@@ -17,7 +17,16 @@ +@@ -19,7 +19,16 @@ #endif #if PA_CONFIG(HAS_LINUX_KERNEL) @@ -17,37 +17,20 @@ #include <sys/syscall.h> #include <unistd.h> -@@ -109,8 +118,16 @@ void SpinningMutex::FutexWait() { - // |kLockedContended| anymore. Note that even without spurious wakeups, the - // value of |state_| is not guaranteed when this returns, as another thread - // may get the lock before we get to run. +@@ -92,8 +101,16 @@ PA_ALWAYS_INLINE long FutexSyscall(volatile void* ftx, + int saved_errno = errno; + errno = 0; + +#if defined(OS_FREEBSD) -+ int err = _umtx_op(&state_, UMTX_OP_WAIT_UINT_PRIVATE, ++ long retval = _umtx_op(&state_, UMTX_OP_WAIT_UINT_PRIVATE, + kLockedContended, nullptr, nullptr); +#elif defined(OS_OPENBSD) -+ int err = futex(reinterpret_cast<volatile unsigned int *>(&state_), FUTEX_WAIT | FUTEX_PRIVATE_FLAG, ++ long retval = futex(reinterpret_cast<volatile unsigned int *>(&state_), FUTEX_WAIT | FUTEX_PRIVATE_FLAG, + kLockedContended, nullptr, nullptr); +#else - int err = syscall(SYS_futex, &state_, FUTEX_WAIT | FUTEX_PRIVATE_FLAG, - kLockedContended, nullptr, nullptr, 0); -+#endif - - if (err) { - // These are programming error, check them. -@@ -122,8 +139,16 @@ void SpinningMutex::FutexWait() { - - void SpinningMutex::FutexWake() { - int saved_errno = errno; -+#if defined(OS_FREEBSD) -+ long retval = _umtx_op(&state_, UMTX_OP_WAKE_PRIVATE, -+ 1 /* wake up a single waiter */, nullptr, nullptr); -+#elif defined(OS_OPENBSD) -+ long retval = futex(reinterpret_cast<volatile unsigned int *>(&state_), FUTEX_WAKE | FUTEX_PRIVATE_FLAG, -+ 1 /* wake up a single waiter */, nullptr, nullptr); -+#else - long retval = syscall(SYS_futex, &state_, FUTEX_WAKE | FUTEX_PRIVATE_FLAG, - 1 /* wake up a single waiter */, nullptr, nullptr, 0); + long retval = syscall(SYS_futex, ftx, op | FUTEX_PRIVATE_FLAG, value, nullptr, + nullptr, 0); +#endif - PA_CHECK(retval != -1); - errno = saved_errno; - } + if (retval == -1) { + // These are programming errors, check them. + PA_DCHECK((errno != EPERM) || (errno != EACCES) || (errno != EINVAL) || diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_starscan_stack_stack.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_stack_stack.cc index 55e38ef752fd..9663a41a0c99 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_starscan_stack_stack.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_stack_stack.cc @@ -1,14 +1,14 @@ ---- base/allocator/partition_allocator/src/partition_alloc/starscan/stack/stack.cc.orig 2023-12-10 06:10:27 UTC -+++ base/allocator/partition_allocator/src/partition_alloc/starscan/stack/stack.cc +--- base/allocator/partition_allocator/src/partition_alloc/stack/stack.cc.orig 2024-07-30 11:12:21 UTC ++++ base/allocator/partition_allocator/src/partition_alloc/stack/stack.cc @@ -18,6 +18,10 @@ #include <pthread.h> #endif -+#if BUILDFLAG(IS_BSD) ++#if PA_BUILDFLAG(IS_BSD) +#include <pthread_np.h> +#endif + - #if defined(LIBC_GLIBC) + #if PA_BUILDFLAG(PA_LIBC_GLIBC) extern "C" void* __libc_stack_end; #endif @@ -48,6 +52,36 @@ void* GetStackTop() { @@ -17,7 +17,7 @@ return pthread_get_stackaddr_np(pthread_self()); +} + -+#elif defined(OS_OPENBSD) ++#elif PA_BUILDFLAG(IS_OPENBSD) + +void* GetStackTop() { + stack_t ss; @@ -26,7 +26,7 @@ + return reinterpret_cast<uint8_t*>(ss.ss_sp); +} + -+#elif defined(OS_FREEBSD) ++#elif PA_BUILDFLAG(IS_FREEBSD) + +void* GetStackTop() { + pthread_attr_t attr; @@ -47,4 +47,4 @@ + return nullptr; } - #elif BUILDFLAG(IS_POSIX) || BUILDFLAG(IS_FUCHSIA) + #elif PA_BUILDFLAG(IS_POSIX) || PA_BUILDFLAG(IS_FUCHSIA) diff --git a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_thread__isolation_pkey.cc b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_thread__isolation_pkey.cc index eb1225a8f769..ece8431f1d85 100644 --- a/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_thread__isolation_pkey.cc +++ b/www/chromium/files/patch-base_allocator_partition__allocator_src_partition__alloc_thread__isolation_pkey.cc @@ -1,11 +1,11 @@ ---- base/allocator/partition_allocator/src/partition_alloc/thread_isolation/pkey.cc.orig 2024-02-23 21:04:38 UTC +--- base/allocator/partition_allocator/src/partition_alloc/thread_isolation/pkey.cc.orig 2024-07-30 11:12:21 UTC +++ base/allocator/partition_allocator/src/partition_alloc/thread_isolation/pkey.cc @@ -16,7 +16,7 @@ #include "partition_alloc/partition_alloc_check.h" #include "partition_alloc/thread_isolation/thread_isolation.h" --#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) -+#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) +-#if !PA_BUILDFLAG(IS_LINUX) && !PA_BUILDFLAG(IS_CHROMEOS) ++#if !PA_BUILDFLAG(IS_LINUX) && !PA_BUILDFLAG(IS_CHROMEOS) && !PA_BUILDFLAG(IS_BSD) #error "This pkey code is currently only supported on Linux and ChromeOS" #endif diff --git a/www/chromium/files/patch-base_atomicops.h b/www/chromium/files/patch-base_atomicops.h index e1539b9876bf..bc93807b8582 100644 --- a/www/chromium/files/patch-base_atomicops.h +++ b/www/chromium/files/patch-base_atomicops.h @@ -1,6 +1,6 @@ ---- base/atomicops.h.orig 2023-04-05 11:05:06 UTC +--- base/atomicops.h.orig 2025-02-19 07:43:18 UTC +++ base/atomicops.h -@@ -71,7 +71,11 @@ typedef intptr_t Atomic64; +@@ -74,7 +74,11 @@ typedef intptr_t Atomic64; // Use AtomicWord for a machine-sized pointer. It will use the Atomic32 or // Atomic64 routines below, depending on your architecture. diff --git a/www/chromium/files/patch-base_base__paths__posix.cc b/www/chromium/files/patch-base_base__paths__posix.cc index c343f2e93b3c..f320895761af 100644 --- a/www/chromium/files/patch-base_base__paths__posix.cc +++ b/www/chromium/files/patch-base_base__paths__posix.cc @@ -1,4 +1,4 @@ ---- base/base_paths_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/base_paths_posix.cc.orig 2025-02-19 07:43:18 UTC +++ base/base_paths_posix.cc @@ -15,6 +15,7 @@ #include <ostream> @@ -23,27 +23,26 @@ #elif BUILDFLAG(IS_SOLARIS) || BUILDFLAG(IS_AIX) #include <stdlib.h> #endif -@@ -48,8 +53,7 @@ bool PathProviderPosix(int key, FilePath* result) { +@@ -47,8 +52,7 @@ bool PathProviderPosix(int key, FilePath* result) { *result = bin_dir; return true; #elif BUILDFLAG(IS_FREEBSD) -- int name[] = { CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, -1 }; +- int name[] = {CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, -1}; - std::optional<std::string> bin_dir = StringSysctl(name, std::size(name)); + std::optional<std::string> bin_dir = StringSysctl({ CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, -1 }); if (!bin_dir.has_value() || bin_dir.value().length() <= 1) { NOTREACHED() << "Unable to resolve path."; - return false; -@@ -65,13 +69,65 @@ bool PathProviderPosix(int key, FilePath* result) { + } +@@ -62,14 +66,65 @@ bool PathProviderPosix(int key, FilePath* result) { *result = FilePath(bin_dir); return true; #elif BUILDFLAG(IS_OPENBSD) || BUILDFLAG(IS_AIX) - // There is currently no way to get the executable path on OpenBSD - char* cpath; -- if ((cpath = getenv("CHROME_EXE_PATH")) != NULL) +- if ((cpath = getenv("CHROME_EXE_PATH")) != NULL) { - *result = FilePath(cpath); -- else +- } else { - *result = FilePath("/usr/local/chrome/chrome"); -- return true; + char *cpath; +#if !BUILDFLAG(IS_AIX) + struct kinfo_file *files; @@ -71,7 +70,8 @@ + *result = FilePath(retval); + VLOG(1) << "PathProviderPosix (sandbox) result: " << retval; + goto out; -+ } + } +- return true; + + if ((kd = kvm_openfiles(NULL, NULL, NULL, (int)KVM_NO_FILES, errbuf)) == NULL) + goto out; diff --git a/www/chromium/files/patch-base_compiler__specific.h b/www/chromium/files/patch-base_compiler__specific.h index 32086eb84483..2b9c67c377df 100644 --- a/www/chromium/files/patch-base_compiler__specific.h +++ b/www/chromium/files/patch-base_compiler__specific.h @@ -1,11 +1,10 @@ ---- base/compiler_specific.h.orig 2024-02-23 21:04:38 UTC +--- base/compiler_specific.h.orig 2025-07-02 06:08:04 UTC +++ base/compiler_specific.h -@@ -316,7 +316,7 @@ - // - // In some cases it's desirable to remove this, e.g. on hot functions, or if - // we have purposely changed the reference canary. --#if defined(COMPILER_GCC) || defined(__clang__) -+#if (defined(COMPILER_GCC) || defined(__clang__)) && !defined(__OpenBSD__) && !defined(__FreeBSD__) - #if HAS_ATTRIBUTE(__no_stack_protector__) - #define NO_STACK_PROTECTOR __attribute__((__no_stack_protector__)) +@@ -733,6 +733,7 @@ inline constexpr bool AnalyzerAssumeTrue(bool arg) { + #if __has_cpp_attribute(clang::preserve_most) && \ + (defined(ARCH_CPU_ARM64) || defined(ARCH_CPU_X86_64)) && \ + !defined(COMPONENT_BUILD) && \ ++ !BUILDFLAG(IS_OPENBSD) && \ + !(BUILDFLAG(IS_WIN) && defined(ARCH_CPU_ARM64)) + #define PRESERVE_MOST [[clang::preserve_most]] #else diff --git a/www/chromium/files/patch-base_debug_debugger__posix.cc b/www/chromium/files/patch-base_debug_debugger__posix.cc index 58341a527cf1..b91499e6710a 100644 --- a/www/chromium/files/patch-base_debug_debugger__posix.cc +++ b/www/chromium/files/patch-base_debug_debugger__posix.cc @@ -1,6 +1,6 @@ ---- base/debug/debugger_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/debug/debugger_posix.cc.orig 2025-07-02 06:08:04 UTC +++ base/debug/debugger_posix.cc -@@ -36,6 +36,10 @@ +@@ -38,6 +38,10 @@ #include <sys/sysctl.h> #endif @@ -11,7 +11,7 @@ #if BUILDFLAG(IS_FREEBSD) #include <sys/user.h> #endif -@@ -95,32 +99,51 @@ bool BeingDebugged() { +@@ -96,33 +100,52 @@ bool BeingDebugged() { // Caution: struct kinfo_proc is marked __APPLE_API_UNSTABLE. The source and // binary interfaces may change. @@ -24,8 +24,9 @@ +#endif #if BUILDFLAG(IS_OPENBSD) - if (sysctl(mib, std::size(mib), NULL, &info_size, NULL, 0) < 0) + if (sysctl(mib, std::size(mib), NULL, &info_size, NULL, 0) < 0) { return -1; + } - mib[5] = (info_size / sizeof(struct kinfo_proc)); + mib[5] = static_cast<int>((info_size / sizeof(struct kinfo_proc))); diff --git a/www/chromium/files/patch-base_debug_elf__reader.cc b/www/chromium/files/patch-base_debug_elf__reader.cc index b585334b9528..3c9b50fe69c5 100644 --- a/www/chromium/files/patch-base_debug_elf__reader.cc +++ b/www/chromium/files/patch-base_debug_elf__reader.cc @@ -1,6 +1,6 @@ ---- base/debug/elf_reader.cc.orig 2024-04-19 13:02:56 UTC +--- base/debug/elf_reader.cc.orig 2025-03-05 08:14:56 UTC +++ base/debug/elf_reader.cc -@@ -45,6 +45,10 @@ using Xword = Elf64_Xword; +@@ -49,6 +49,10 @@ using Xword = Elf64_Xword; constexpr char kGnuNoteName[] = "GNU"; diff --git a/www/chromium/files/patch-base_debug_proc__maps__linux.cc b/www/chromium/files/patch-base_debug_proc__maps__linux.cc index 4ed7cb701ed6..540972716569 100644 --- a/www/chromium/files/patch-base_debug_proc__maps__linux.cc +++ b/www/chromium/files/patch-base_debug_proc__maps__linux.cc @@ -1,6 +1,6 @@ ---- base/debug/proc_maps_linux.cc.orig 2022-02-28 16:54:41 UTC +--- base/debug/proc_maps_linux.cc.orig 2025-02-19 07:43:18 UTC +++ base/debug/proc_maps_linux.cc -@@ -13,7 +13,7 @@ +@@ -22,7 +22,7 @@ #include "base/strings/string_split.h" #include "build/build_config.h" diff --git a/www/chromium/files/patch-base_debug_stack__trace.cc b/www/chromium/files/patch-base_debug_stack__trace.cc index 729c3ad3e29a..a998229de3c5 100644 --- a/www/chromium/files/patch-base_debug_stack__trace.cc +++ b/www/chromium/files/patch-base_debug_stack__trace.cc @@ -1,6 +1,6 @@ ---- base/debug/stack_trace.cc.orig 2024-04-19 13:02:56 UTC +--- base/debug/stack_trace.cc.orig 2025-04-04 08:52:13 UTC +++ base/debug/stack_trace.cc -@@ -247,7 +247,7 @@ bool StackTrace::WillSymbolizeToStreamForTesting() { +@@ -268,7 +268,7 @@ bool StackTrace::WillSymbolizeToStreamForTesting() { // Symbols are not expected to be reliable when gn args specifies // symbol_level=0. return false; @@ -9,16 +9,26 @@ // StackTrace::OutputToStream() is not implemented under uclibc, nor AIX. // See https://crbug.com/706728 return false; -@@ -291,7 +291,7 @@ std::string StackTrace::ToString() const { +@@ -321,7 +321,9 @@ void StackTrace::OutputToStreamWithPrefix(std::ostream + } + return; + } ++#if !BUILDFLAG(IS_BSD) + OutputToStreamWithPrefixImpl(os, prefix_string); ++#endif } - std::string StackTrace::ToStringWithPrefix(const char* prefix_string) const { + + std::string StackTrace::ToString() const { +@@ -330,7 +332,7 @@ std::string StackTrace::ToString() const { + + std::string StackTrace::ToStringWithPrefix(cstring_view prefix_string) const { std::stringstream stream; -#if !defined(__UCLIBC__) && !defined(_AIX) +#if !defined(__UCLIBC__) && !defined(_AIX) && !BUILDFLAG(IS_BSD) - if (ShouldSuppressOutput()) { - return "Backtrace suppressed."; - } -@@ -301,7 +301,7 @@ std::string StackTrace::ToStringWithPrefix(const char* + OutputToStreamWithPrefix(&stream, prefix_string); + #endif + return stream.str(); +@@ -354,7 +356,7 @@ bool StackTrace::ShouldSuppressOutput() { } std::ostream& operator<<(std::ostream& os, const StackTrace& s) { diff --git a/www/chromium/files/patch-base_debug_stack__trace__posix.cc b/www/chromium/files/patch-base_debug_stack__trace__posix.cc index 7707da34bdff..d9d357a06731 100644 --- a/www/chromium/files/patch-base_debug_stack__trace__posix.cc +++ b/www/chromium/files/patch-base_debug_stack__trace__posix.cc @@ -1,6 +1,6 @@ ---- base/debug/stack_trace_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/debug/stack_trace_posix.cc.orig 2025-03-05 08:14:56 UTC +++ base/debug/stack_trace_posix.cc -@@ -41,7 +41,7 @@ +@@ -51,7 +51,7 @@ // execinfo.h and backtrace(3) are really only present in glibc and in macOS // libc. #if BUILDFLAG(IS_APPLE) || \ @@ -9,7 +9,7 @@ #define HAVE_BACKTRACE #include <execinfo.h> #endif -@@ -59,8 +59,10 @@ +@@ -69,8 +69,10 @@ #include <AvailabilityMacros.h> #endif @@ -21,7 +21,7 @@ #include "base/debug/proc_maps_linux.h" #endif -@@ -301,7 +303,7 @@ void PrintToStderr(const char* output) { +@@ -329,7 +331,7 @@ void PrintToStderr(const char* output) { std::ignore = HANDLE_EINTR(write(STDERR_FILENO, output, strlen(output))); } @@ -30,7 +30,7 @@ void AlarmSignalHandler(int signal, siginfo_t* info, void* void_context) { // We have seen rare cases on AMD linux where the default signal handler // either does not run or a thread (Probably an AMD driver thread) prevents -@@ -318,7 +320,11 @@ void AlarmSignalHandler(int signal, siginfo_t* info, v +@@ -346,7 +348,11 @@ void AlarmSignalHandler(int signal, siginfo_t* info, v "Warning: Default signal handler failed to terminate process.\n"); PrintToStderr("Calling exit_group() directly to prevent timeout.\n"); // See: https://man7.org/linux/man-pages/man2/exit_group.2.html @@ -42,7 +42,7 @@ } #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || // BUILDFLAG(IS_CHROMEOS) -@@ -535,7 +541,7 @@ void StackDumpSignalHandler(int signal, siginfo_t* inf +@@ -552,7 +558,7 @@ void StackDumpSignalHandler(int signal, siginfo_t* inf _exit(EXIT_FAILURE); } @@ -51,7 +51,7 @@ // Set an alarm to trigger in case the default handler does not terminate // the process. See 'AlarmSignalHandler' for more details. struct sigaction action; -@@ -560,6 +566,7 @@ void StackDumpSignalHandler(int signal, siginfo_t* inf +@@ -577,6 +583,7 @@ void StackDumpSignalHandler(int signal, siginfo_t* inf // signals that do not re-raise autonomously), such as signals delivered via // kill() and asynchronous hardware faults such as SEGV_MTEAERR, which would // otherwise be lost when re-raising the signal via raise(). @@ -59,7 +59,7 @@ long retval = syscall(SYS_rt_tgsigqueueinfo, getpid(), syscall(SYS_gettid), info->si_signo, info); if (retval == 0) { -@@ -574,6 +581,7 @@ void StackDumpSignalHandler(int signal, siginfo_t* inf +@@ -591,6 +598,7 @@ void StackDumpSignalHandler(int signal, siginfo_t* inf if (errno != EPERM) { _exit(EXIT_FAILURE); } @@ -67,7 +67,7 @@ #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || // BUILDFLAG(IS_CHROMEOS) -@@ -763,6 +771,7 @@ class SandboxSymbolizeHelper { +@@ -783,6 +791,7 @@ class SandboxSymbolizeHelper { return -1; } @@ -75,7 +75,7 @@ // This class is copied from // third_party/crashpad/crashpad/util/linux/scoped_pr_set_dumpable.h. // It aims at ensuring the process is dumpable before opening /proc/self/mem. -@@ -855,11 +864,15 @@ class SandboxSymbolizeHelper { +@@ -875,11 +884,15 @@ class SandboxSymbolizeHelper { r.base = cur_base; } } @@ -91,7 +91,7 @@ // Reads /proc/self/maps. std::string contents; if (!ReadProcMaps(&contents)) { -@@ -877,6 +890,7 @@ class SandboxSymbolizeHelper { +@@ -897,6 +910,7 @@ class SandboxSymbolizeHelper { is_initialized_ = true; return true; diff --git a/www/chromium/files/patch-base_files_dir__reader__linux.h b/www/chromium/files/patch-base_files_dir__reader__linux.h index 91bc1897532e..be86558f0c8b 100644 --- a/www/chromium/files/patch-base_files_dir__reader__linux.h +++ b/www/chromium/files/patch-base_files_dir__reader__linux.h @@ -1,6 +1,6 @@ ---- base/files/dir_reader_linux.h.orig 2022-08-31 12:19:35 UTC +--- base/files/dir_reader_linux.h.orig 2025-02-19 07:43:18 UTC +++ base/files/dir_reader_linux.h -@@ -16,10 +16,16 @@ +@@ -21,10 +21,16 @@ #include "base/logging.h" #include "base/posix/eintr_wrapper.h" @@ -15,25 +15,25 @@ +typedef struct dirent linux_dirent; +#else struct linux_dirent { - uint64_t d_ino; - int64_t d_off; -@@ -27,6 +33,7 @@ struct linux_dirent { - unsigned char d_type; - char d_name[0]; + uint64_t d_ino; + int64_t d_off; +@@ -32,6 +38,7 @@ struct linux_dirent { + unsigned char d_type; + char d_name[0]; }; +#endif class DirReaderLinux { public: -@@ -61,7 +68,11 @@ class DirReaderLinux { - if (offset_ != size_) +@@ -66,7 +73,11 @@ class DirReaderLinux { return true; + } +#if BUILDFLAG(IS_BSD) + const int r = getdents(fd_, reinterpret_cast<char *>(buf_), sizeof(buf_)); +#else const long r = syscall(__NR_getdents64, fd_, buf_, sizeof(buf_)); +#endif - if (r == 0) + if (r == 0) { return false; - if (r < 0) { + } diff --git a/www/chromium/files/patch-base_files_drive__info.h b/www/chromium/files/patch-base_files_drive__info.h new file mode 100644 index 000000000000..3d642f1fc84c --- /dev/null +++ b/www/chromium/files/patch-base_files_drive__info.h @@ -0,0 +1,11 @@ +--- base/files/drive_info.h.orig 2025-05-28 14:55:43 UTC ++++ base/files/drive_info.h +@@ -48,7 +48,7 @@ struct BASE_EXPORT DriveInfo { + std::optional<bool> has_seek_penalty; + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Whether the drive is a "removable" drive. + // + // In macOS's IOKit API, a drive is "removable" if "the media is removable diff --git a/www/chromium/files/patch-base_files_drive__info__posix.cc b/www/chromium/files/patch-base_files_drive__info__posix.cc new file mode 100644 index 000000000000..70b23409738d --- /dev/null +++ b/www/chromium/files/patch-base_files_drive__info__posix.cc @@ -0,0 +1,11 @@ +--- base/files/drive_info_posix.cc.orig 2025-03-05 08:14:56 UTC ++++ base/files/drive_info_posix.cc +@@ -24,7 +24,7 @@ namespace base { + + std::optional<DriveInfo> GetFileDriveInfo(const FilePath& file_path) { + DriveInfo drive_info; +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + drive_info.has_seek_penalty = false; + return drive_info; + #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-base_files_file__path__watcher__unittest.cc b/www/chromium/files/patch-base_files_file__path__watcher__unittest.cc index 614e7b82492d..dc5237479bba 100644 --- a/www/chromium/files/patch-base_files_file__path__watcher__unittest.cc +++ b/www/chromium/files/patch-base_files_file__path__watcher__unittest.cc @@ -1,6 +1,6 @@ ---- base/files/file_path_watcher_unittest.cc.orig 2024-02-23 21:04:38 UTC +--- base/files/file_path_watcher_unittest.cc.orig 2024-07-30 11:12:21 UTC +++ base/files/file_path_watcher_unittest.cc -@@ -847,7 +847,7 @@ TEST_F(FilePathWatcherTest, WatchDirectory) { +@@ -902,7 +902,7 @@ TEST_F(FilePathWatcherTest, WatchDirectory) { } delegate.RunUntilEventsMatch(event_expecter); @@ -8,8 +8,8 @@ +#if !BUILDFLAG(IS_APPLE) && BUILDFLAG(IS_BSD) ASSERT_TRUE(WriteFile(file1, "content v2")); // Mac implementation does not detect files modified in a directory. - // TODO(https://crbug.com/1432064): Expect that no events are fired on Mac. -@@ -1783,7 +1783,7 @@ namespace { + // TODO(crbug.com/40263777): Expect that no events are fired on Mac. +@@ -1848,7 +1848,7 @@ namespace { enum Permission { Read, Write, Execute }; @@ -18,7 +18,7 @@ bool ChangeFilePermissions(const FilePath& path, Permission perm, bool allow) { struct stat stat_buf; -@@ -1817,7 +1817,7 @@ bool ChangeFilePermissions(const FilePath& path, Permi +@@ -1882,7 +1882,7 @@ bool ChangeFilePermissions(const FilePath& path, Permi } // namespace diff --git a/www/chromium/files/patch-base_files_file__util__posix.cc b/www/chromium/files/patch-base_files_file__util__posix.cc index e0a0c9cadd49..eadece532674 100644 --- a/www/chromium/files/patch-base_files_file__util__posix.cc +++ b/www/chromium/files/patch-base_files_file__util__posix.cc @@ -1,53 +1,48 @@ ---- base/files/file_util_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/files/file_util_posix.cc.orig 2025-05-05 10:57:53 UTC +++ base/files/file_util_posix.cc -@@ -816,33 +816,34 @@ bool CreateDirectoryAndGetError(const FilePath& full_p - File::Error* error) { +@@ -934,6 +934,7 @@ bool CreateNewTempDirectory(const FilePath::StringType + bool CreateDirectoryAndGetError(const FilePath& full_path, File::Error* error) { ScopedBlockingCall scoped_blocking_call( FROM_HERE, BlockingType::MAY_BLOCK); // For call to mkdir(). + const FilePath kFileSystemRoot("/"); - std::vector<FilePath> subpaths; - // Collect a list of all parent directories. + // Avoid checking subdirs if directory already exists. + if (DirectoryExists(full_path)) { +@@ -943,8 +944,8 @@ bool CreateDirectoryAndGetError(const FilePath& full_p + // Collect a list of all missing directories. + std::vector<FilePath> missing_subpaths({full_path}); FilePath last_path = full_path; -- subpaths.push_back(full_path); -+ if (full_path != kFileSystemRoot) -+ subpaths.push_back(full_path); - for (FilePath path = full_path.DirName(); -- path.value() != last_path.value(); path = path.DirName()) { -+ (path.value() != last_path.value() && +- for (FilePath path = full_path.DirName(); path.value() != last_path.value(); +- path = path.DirName()) { ++ for (FilePath path = full_path.DirName(); (path.value() != last_path.value() && + (path != kFileSystemRoot)); path = path.DirName()) { - subpaths.push_back(path); - last_path = path; - } + if (DirectoryExists(path)) { + break; + } +@@ -962,21 +963,14 @@ bool CreateDirectoryAndGetError(const FilePath& full_p + } + #endif // BUILDFLAG(IS_CHROMEOS) - // Iterate through the parents and create the missing ones. - for (const FilePath& subpath : base::Reversed(subpaths)) { -- if (DirectoryExists(subpath)) -- continue; -- if (mkdir(subpath.value().c_str(), 0700) == 0) +- if (mkdir(subpath.value().c_str(), mode) == 0) { - continue; +- } - // Mkdir failed, but it might have failed with EEXIST, or some other error - // due to the directory appearing out of thin air. This can occur if - // two processes are trying to create the same file system tree at the same - // time. Check to see if it exists and make sure it is a directory. - int saved_errno = errno; - if (!DirectoryExists(subpath)) { -- if (error) -- *error = File::OSErrorToFileError(saved_errno); +- if (error) { ++ if ((mkdir(subpath.value().c_str(), mode) == -1) && ++ ((full_path != subpath) ? (errno != ENOENT) : (-1))) { ++ int saved_errno = errno; ++ if (error) + *error = File::OSErrorToFileError(saved_errno); +- } - errno = saved_errno; -- return false; -+ if (!PathExists(subpath)) { -+ if ((mkdir(subpath.value().c_str(), 0700) == -1) && -+ ((full_path != subpath) ? (errno != ENOENT) : (-1))) { -+ int saved_errno = errno; -+ if (error) -+ *error = File::OSErrorToFileError(saved_errno); -+ return false; -+ } -+ } else if (!DirectoryExists(subpath)) { -+ if (error) -+ *error = File::OSErrorToFileError(ENOTDIR); -+ return false; + return false; } ++ errno = 0; } return true; + } diff --git a/www/chromium/files/patch-base_files_file__util__unittest.cc b/www/chromium/files/patch-base_files_file__util__unittest.cc index 8fbc0fce70ab..a0fc114b60bc 100644 --- a/www/chromium/files/patch-base_files_file__util__unittest.cc +++ b/www/chromium/files/patch-base_files_file__util__unittest.cc @@ -1,6 +1,6 @@ ---- base/files/file_util_unittest.cc.orig 2024-04-19 13:02:56 UTC +--- base/files/file_util_unittest.cc.orig 2025-04-04 08:52:13 UTC +++ base/files/file_util_unittest.cc -@@ -3870,7 +3870,7 @@ TEST_F(FileUtilTest, ReadFileToStringWithNamedPipe) { +@@ -3920,7 +3920,7 @@ TEST_F(FileUtilTest, ReadFileToStringWithNamedPipe) { } #endif // BUILDFLAG(IS_WIN) @@ -9,7 +9,27 @@ TEST_F(FileUtilTest, ReadFileToStringWithProcFileSystem) { FilePath file_path("/proc/cpuinfo"); std::string data = "temp"; -@@ -4651,7 +4651,7 @@ TEST(FileUtilMultiThreadedTest, MultiThreadedTempFiles +@@ -4505,6 +4505,19 @@ TEST_F(FileUtilTest, CreateDirectoryOnlyCheckMissingSu + + #endif // BUILDFLAG(IS_ANDROID) + ++#if BUILDFLAG(IS_OPENBSD) ++TEST_F(FileUtilTest, CreateDirectoryInUnveiledPath) { ++ FilePath dir = PathService::CheckedGet(DIR_GEN_TEST_DATA_ROOT); ++ dir = dir.Append(FILE_PATH_LITERAL("base")); ++ dir = dir.Append(FILE_PATH_LITERAL("test")); ++ dir = dir.Append(FILE_PATH_LITERAL("unveil")); ++ unveil(dir.value().c_str(), "rwc"); ++ EXPECT_TRUE(CreateDirectory(dir)); ++ dir = dir.Append(FILE_PATH_LITERAL("test")); ++ EXPECT_FALSE(CreateDirectory(dir)); ++} ++#endif ++ + #if BUILDFLAG(IS_WIN) && BUILDFLAG(GOOGLE_CHROME_BRANDING) && \ + defined(ARCH_CPU_32_BITS) + // TODO(crbug.com/327582285): Re-enable these tests. They may be failing due to +@@ -4671,7 +4684,7 @@ TEST(FileUtilMultiThreadedTest, MultiThreadedTempFiles NULL); #else size_t bytes_written = diff --git a/www/chromium/files/patch-base_files_scoped__file.cc b/www/chromium/files/patch-base_files_scoped__file.cc index 350c73cc76e7..1ea60790510a 100644 --- a/www/chromium/files/patch-base_files_scoped__file.cc +++ b/www/chromium/files/patch-base_files_scoped__file.cc @@ -1,6 +1,6 @@ ---- base/files/scoped_file.cc.orig 2022-02-28 16:54:41 UTC +--- base/files/scoped_file.cc.orig 2024-07-30 11:12:21 UTC +++ base/files/scoped_file.cc -@@ -31,7 +31,7 @@ void ScopedFDCloseTraits::Free(int fd) { +@@ -32,7 +32,7 @@ void ScopedFDCloseTraits::Free(int fd) { int ret = IGNORE_EINTR(close(fd)); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_APPLE) || \ diff --git a/www/chromium/files/patch-base_functional_unretained__traits.h b/www/chromium/files/patch-base_functional_unretained__traits.h index 7f6a6a8d660a..c8bba80c4ca7 100644 --- a/www/chromium/files/patch-base_functional_unretained__traits.h +++ b/www/chromium/files/patch-base_functional_unretained__traits.h @@ -1,6 +1,6 @@ ---- base/functional/unretained_traits.h.orig 2024-03-22 08:19:40 UTC +--- base/functional/unretained_traits.h.orig 2025-02-19 07:43:18 UTC +++ base/functional/unretained_traits.h -@@ -93,7 +93,7 @@ struct SupportsUnretainedImpl { +@@ -90,7 +90,7 @@ struct SupportsUnretainedImpl { // official builds, and then in non-test code as well. #if defined(FORCE_UNRETAINED_COMPLETENESS_CHECKS_FOR_TESTS) || \ (!defined(UNIT_TEST) && !defined(OFFICIAL_BUILD) && \ diff --git a/www/chromium/files/patch-base_i18n_icu__util.cc b/www/chromium/files/patch-base_i18n_icu__util.cc index 1143a76baf9d..bc89b666a1e1 100644 --- a/www/chromium/files/patch-base_i18n_icu__util.cc +++ b/www/chromium/files/patch-base_i18n_icu__util.cc @@ -1,6 +1,6 @@ ---- base/i18n/icu_util.cc.orig 2024-03-22 08:19:40 UTC +--- base/i18n/icu_util.cc.orig 2025-05-05 10:57:53 UTC +++ base/i18n/icu_util.cc -@@ -52,7 +52,7 @@ +@@ -53,7 +53,7 @@ #include "third_party/icu/source/common/unicode/unistr.h" #endif @@ -9,7 +9,7 @@ BUILDFLAG(IS_CHROMEOS) || (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CASTOS)) #include "third_party/icu/source/i18n/unicode/timezone.h" #endif -@@ -328,7 +328,7 @@ void InitializeIcuTimeZone() { +@@ -329,7 +329,7 @@ void InitializeIcuTimeZone() { FuchsiaIntlProfileWatcher::GetPrimaryTimeZoneIdForIcuInitialization(); icu::TimeZone::adoptDefault( icu::TimeZone::createTimeZone(icu::UnicodeString::fromUTF8(zone_id))); diff --git a/www/chromium/files/patch-base_linux__util.cc b/www/chromium/files/patch-base_linux__util.cc index ed2de441c529..53a96952eaf4 100644 --- a/www/chromium/files/patch-base_linux__util.cc +++ b/www/chromium/files/patch-base_linux__util.cc @@ -1,21 +1,13 @@ ---- base/linux_util.cc.orig 2023-12-10 06:10:27 UTC +--- base/linux_util.cc.orig 2025-04-04 08:52:13 UTC +++ base/linux_util.cc -@@ -15,6 +15,7 @@ - - #include <iomanip> - #include <memory> -+#include <sstream> - - #include "base/base_export.h" - #include "base/files/dir_reader_posix.h" -@@ -153,10 +154,14 @@ void SetLinuxDistro(const std::string& distro) { +@@ -163,10 +163,14 @@ void SetLinuxDistro(const std::string& distro) { } bool GetThreadsForProcess(pid_t pid, std::vector<pid_t>* tids) { +#if BUILDFLAG(IS_BSD) + return false; +#else - // 25 > strlen("/proc//task") + strlen(std::to_string(INT_MAX)) + 1 = 22 + // 25 > strlen("/proc//task") + strlen(base::NumberToString(INT_MAX)) + 1 = 22 char buf[25]; strings::SafeSPrintf(buf, "/proc/%d/task", pid); return GetThreadsFromProcessDir(buf, tids); diff --git a/www/chromium/files/patch-base_logging__unittest.cc b/www/chromium/files/patch-base_logging__unittest.cc index fda45153671e..cf5196d922d0 100644 --- a/www/chromium/files/patch-base_logging__unittest.cc +++ b/www/chromium/files/patch-base_logging__unittest.cc @@ -1,6 +1,6 @@ ---- base/logging_unittest.cc.orig 2024-01-30 07:53:34 UTC +--- base/logging_unittest.cc.orig 2025-05-05 10:57:53 UTC +++ base/logging_unittest.cc -@@ -32,7 +32,7 @@ +@@ -40,7 +40,7 @@ #include "base/posix/eintr_wrapper.h" #endif // BUILDFLAG(IS_POSIX) @@ -9,7 +9,7 @@ #include <ucontext.h> #endif -@@ -570,14 +570,18 @@ void CheckCrashTestSighandler(int, siginfo_t* info, vo +@@ -586,14 +586,18 @@ void CheckCrashTestSighandler(int, siginfo_t* info, vo // need the arch-specific boilerplate below, which is inspired by breakpad. // At the same time, on OSX, ucontext.h is deprecated but si_addr works fine. uintptr_t crash_addr = 0; diff --git a/www/chromium/files/patch-base_memory_discardable__memory.cc b/www/chromium/files/patch-base_memory_discardable__memory.cc index bd043476fc97..436cbb4e3852 100644 --- a/www/chromium/files/patch-base_memory_discardable__memory.cc +++ b/www/chromium/files/patch-base_memory_discardable__memory.cc @@ -1,4 +1,4 @@ ---- base/memory/discardable_memory.cc.orig 2022-11-30 08:12:58 UTC +--- base/memory/discardable_memory.cc.orig 2025-03-05 08:14:56 UTC +++ base/memory/discardable_memory.cc @@ -26,7 +26,7 @@ BASE_FEATURE(kMadvFreeDiscardableMemory, base::FEATURE_DISABLED_BY_DEFAULT); @@ -9,7 +9,7 @@ BASE_FEATURE(kDiscardableMemoryBackingTrial, "DiscardableMemoryBackingTrial", base::FEATURE_DISABLED_BY_DEFAULT); -@@ -52,7 +52,7 @@ const base::FeatureParam<DiscardableMemoryTrialGroup> +@@ -44,7 +44,7 @@ BASE_FEATURE_ENUM_PARAM(DiscardableMemoryTrialGroup, namespace { @@ -18,7 +18,7 @@ DiscardableMemoryBacking GetBackingForFieldTrial() { DiscardableMemoryTrialGroup trial_group = -@@ -71,7 +71,7 @@ DiscardableMemoryBacking GetBackingForFieldTrial() { +@@ -63,7 +63,7 @@ DiscardableMemoryBacking GetBackingForFieldTrial() { } // namespace @@ -27,7 +27,7 @@ // Probe capabilities of this device to determine whether we should participate // in the discardable memory backing trial. -@@ -101,7 +101,7 @@ DiscardableMemory::DiscardableMemory() = default; +@@ -95,7 +95,7 @@ DiscardableMemory::DiscardableMemory() = default; DiscardableMemory::~DiscardableMemory() = default; DiscardableMemoryBacking GetDiscardableMemoryBacking() { diff --git a/www/chromium/files/patch-base_memory_discardable__memory__internal.h b/www/chromium/files/patch-base_memory_discardable__memory__internal.h index 13bef7210432..58344b53528d 100644 --- a/www/chromium/files/patch-base_memory_discardable__memory__internal.h +++ b/www/chromium/files/patch-base_memory_discardable__memory__internal.h @@ -1,6 +1,6 @@ ---- base/memory/discardable_memory_internal.h.orig 2022-02-28 16:54:41 UTC +--- base/memory/discardable_memory_internal.h.orig 2024-09-30 07:45:04 UTC +++ base/memory/discardable_memory_internal.h -@@ -10,7 +10,7 @@ +@@ -12,7 +12,7 @@ #include "base/metrics/field_trial_params.h" #include "build/build_config.h" diff --git a/www/chromium/files/patch-base_memory_madv__free__discardable__memory__posix.cc b/www/chromium/files/patch-base_memory_madv__free__discardable__memory__posix.cc index f6675773b436..f71dae216868 100644 --- a/www/chromium/files/patch-base_memory_madv__free__discardable__memory__posix.cc +++ b/www/chromium/files/patch-base_memory_madv__free__discardable__memory__posix.cc @@ -1,6 +1,6 @@ ---- base/memory/madv_free_discardable_memory_posix.cc.orig 2023-05-31 08:12:17 UTC +--- base/memory/madv_free_discardable_memory_posix.cc.orig 2025-02-19 07:43:18 UTC +++ base/memory/madv_free_discardable_memory_posix.cc -@@ -306,6 +306,10 @@ void MadvFreeDiscardableMemoryPosix::SetKeepMemoryForT +@@ -305,6 +305,10 @@ void MadvFreeDiscardableMemoryPosix::SetKeepMemoryForT bool MadvFreeDiscardableMemoryPosix::IsResident() const { DFAKE_SCOPED_RECURSIVE_LOCK(thread_collision_warner_); @@ -12,7 +12,7 @@ std::vector<char> vec(allocated_pages_); #else @@ -321,6 +325,7 @@ bool MadvFreeDiscardableMemoryPosix::IsResident() cons - return false; + } } return true; +#endif diff --git a/www/chromium/files/patch-base_memory_platform__shared__memory__region.h b/www/chromium/files/patch-base_memory_platform__shared__memory__region.h index 98090190472b..5b98ac1a8aca 100644 --- a/www/chromium/files/patch-base_memory_platform__shared__memory__region.h +++ b/www/chromium/files/patch-base_memory_platform__shared__memory__region.h @@ -1,6 +1,6 @@ ---- base/memory/platform_shared_memory_region.h.orig 2024-04-19 13:02:56 UTC +--- base/memory/platform_shared_memory_region.h.orig 2025-07-02 06:08:04 UTC +++ base/memory/platform_shared_memory_region.h -@@ -17,7 +17,7 @@ +@@ -19,7 +19,7 @@ #include "base/unguessable_token.h" #include "build/build_config.h" @@ -9,7 +9,7 @@ namespace content { class SandboxIPCHandler; } -@@ -84,7 +84,7 @@ class BASE_EXPORT PlatformSharedMemoryRegion { +@@ -86,7 +86,7 @@ class BASE_EXPORT PlatformSharedMemoryRegion { kMaxValue = GET_SHMEM_TEMP_DIR_FAILURE }; @@ -18,7 +18,16 @@ // Structure to limit access to executable region creation. struct ExecutableRegion { private: -@@ -216,7 +216,7 @@ class BASE_EXPORT PlatformSharedMemoryRegion { +@@ -125,7 +125,7 @@ class BASE_EXPORT PlatformSharedMemoryRegion { + #if BUILDFLAG(IS_FUCHSIA) + kNotVmo, + #endif +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + kFcntlFailed, + kReadOnlyFdNotReadOnly, + kUnexpectedReadOnlyFd, +@@ -256,7 +256,7 @@ class BASE_EXPORT PlatformSharedMemoryRegion { CheckPlatformHandlePermissionsCorrespondToMode); static PlatformSharedMemoryRegion Create(Mode mode, size_t size diff --git a/www/chromium/files/patch-base_memory_platform__shared__memory__region__posix.cc b/www/chromium/files/patch-base_memory_platform__shared__memory__region__posix.cc index 8cba2dd98b4d..9b0d02ebffa8 100644 --- a/www/chromium/files/patch-base_memory_platform__shared__memory__region__posix.cc +++ b/www/chromium/files/patch-base_memory_platform__shared__memory__region__posix.cc @@ -1,6 +1,6 @@ ---- base/memory/platform_shared_memory_region_posix.cc.orig 2023-02-08 09:03:45 UTC +--- base/memory/platform_shared_memory_region_posix.cc.orig 2025-07-02 06:08:04 UTC +++ base/memory/platform_shared_memory_region_posix.cc -@@ -55,7 +55,7 @@ bool CheckFDAccessMode(int fd, int expected_mode) { +@@ -61,7 +61,7 @@ std::optional<FDAccessModeError> CheckFDAccessMode(int } // namespace @@ -9,7 +9,7 @@ // static ScopedFD PlatformSharedMemoryRegion::ExecutableRegion::CreateFD(size_t size) { PlatformSharedMemoryRegion region = -@@ -168,7 +168,7 @@ bool PlatformSharedMemoryRegion::ConvertToUnsafe() { +@@ -186,7 +186,7 @@ bool PlatformSharedMemoryRegion::ConvertToUnsafe() { // static PlatformSharedMemoryRegion PlatformSharedMemoryRegion::Create(Mode mode, size_t size @@ -18,7 +18,7 @@ , bool executable #endif -@@ -197,7 +197,7 @@ PlatformSharedMemoryRegion PlatformSharedMemoryRegion: +@@ -215,7 +215,7 @@ PlatformSharedMemoryRegion PlatformSharedMemoryRegion: // flag. FilePath directory; if (!GetShmemTempDir( diff --git a/www/chromium/files/patch-base_memory_protected__memory.h b/www/chromium/files/patch-base_memory_protected__memory.h new file mode 100644 index 000000000000..ebe910dfe1b6 --- /dev/null +++ b/www/chromium/files/patch-base_memory_protected__memory.h @@ -0,0 +1,44 @@ +--- base/memory/protected_memory.h.orig 2025-01-15 09:18:26 UTC ++++ base/memory/protected_memory.h +@@ -120,12 +120,12 @@ __declspec(selectany) char __stop_protected_memory; + + #define DECLARE_PROTECTED_DATA constinit + #define DEFINE_PROTECTED_DATA constinit __declspec(allocate("prot$mem")) +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + // This value is used to align the writers variable. That variable needs to be + // aligned to ensure that the protected memory section starts on a page + // boundary. + #if (PA_BUILDFLAG(IS_ANDROID) && PA_BUILDFLAG(PA_ARCH_CPU_64_BITS)) || \ +- (PA_BUILDFLAG(IS_LINUX) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64)) ++ ((PA_BUILDFLAG(IS_LINUX) || PA_BUILDFLAG(IS_BSD)) && PA_BUILDFLAG(PA_ARCH_CPU_ARM64)) + // arm64 supports 4kb, 16kb, and 64kb pages. Set to the largest of 64kb as that + // will guarantee the section is page aligned regardless of the choice. + inline constexpr int kProtectedMemoryAlignment = 65536; +@@ -340,7 +340,7 @@ class BASE_EXPORT AutoWritableMemoryBase { + // where an attacker could overwrite it with a large value and invoke code + // that constructs and destructs an AutoWritableMemory. After such a call + // protected memory would still be set writable because writers > 0. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + // On Linux, the protected memory section is not automatically page aligned. + // This means that attempts to reset the protected memory region to readonly + // will set some of the preceding section that is on the same page readonly +@@ -354,7 +354,7 @@ class BASE_EXPORT AutoWritableMemoryBase { + #endif + static inline size_t writers GUARDED_BY(writers_lock()) = 0; + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + // On Linux, there is no guarantee the section following the protected + // memory section is page aligned. This can result in attempts to change + // the access permissions of the end of the protected memory section +@@ -412,7 +412,7 @@ class BASE_EXPORT AutoWritableMemoryInitializer + // the variable to something large before the section was read-only. + WriterData::writers = 0; + CHECK(SetProtectedSectionReadOnly()); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + // Set the protected_memory_section_buffer to true to ensure the buffer + // section is created. If a variable is declared but not used the memory + // section won't be created. diff --git a/www/chromium/files/patch-base_memory_protected__memory__posix.cc b/www/chromium/files/patch-base_memory_protected__memory__posix.cc new file mode 100644 index 000000000000..fb7b02a3db9f --- /dev/null +++ b/www/chromium/files/patch-base_memory_protected__memory__posix.cc @@ -0,0 +1,20 @@ +--- base/memory/protected_memory_posix.cc.orig 2024-10-22 08:31:56 UTC ++++ base/memory/protected_memory_posix.cc +@@ -6,7 +6,7 @@ + + #include <sys/mman.h> + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + #include <sys/resource.h> + #endif // BUILDFLAG(IS_LINUX) + +@@ -34,7 +34,7 @@ bool SetMemory(void* start, void* end, int prot) { + } // namespace + + namespace internal { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + void CheckMemoryReadOnly(const void* ptr) { + const uintptr_t page_start = + bits::AlignDown(reinterpret_cast<uintptr_t>(ptr), GetPageSize()); diff --git a/www/chromium/files/patch-base_message__loop_message__pump__epoll.cc b/www/chromium/files/patch-base_message__loop_message__pump__epoll.cc new file mode 100644 index 000000000000..3e769273a4b1 --- /dev/null +++ b/www/chromium/files/patch-base_message__loop_message__pump__epoll.cc @@ -0,0 +1,11 @@ +--- base/message_loop/message_pump_epoll.cc.orig 2025-03-05 08:14:56 UTC ++++ base/message_loop/message_pump_epoll.cc +@@ -47,7 +47,7 @@ std::atomic_bool g_use_batched_version = false; + std::atomic_bool g_use_poll = false; + + constexpr std::pair<uint32_t, short int> kEpollToPollEvents[] = { +- {EPOLLIN, POLLIN}, {EPOLLOUT, POLLOUT}, {EPOLLRDHUP, POLLRDHUP}, ++ {EPOLLIN, POLLIN}, {EPOLLOUT, POLLOUT}, + {EPOLLPRI, POLLPRI}, {EPOLLERR, POLLERR}, {EPOLLHUP, POLLHUP}}; + + void SetEventsForPoll(const uint32_t epoll_events, struct pollfd* poll_entry) { diff --git a/www/chromium/files/patch-base_message__loop_message__pump__epoll.h b/www/chromium/files/patch-base_message__loop_message__pump__epoll.h new file mode 100644 index 000000000000..c6398cdd54e8 --- /dev/null +++ b/www/chromium/files/patch-base_message__loop_message__pump__epoll.h @@ -0,0 +1,14 @@ +--- base/message_loop/message_pump_epoll.h.orig 2024-10-22 08:31:56 UTC ++++ base/message_loop/message_pump_epoll.h +@@ -51,7 +51,11 @@ namespace base { + // every call, don't do it when we have too many FDs. + BASE_FEATURE(kUsePollForMessagePumpEpoll, + "UsePollForMessagePumpEpoll", ++#if BUILDFLAG(IS_BSD) ++ base::FEATURE_ENABLED_BY_DEFAULT); ++#else + base::FEATURE_DISABLED_BY_DEFAULT); ++#endif + + // A MessagePump implementation suitable for I/O message loops on Linux-based + // systems with epoll API support. diff --git a/www/chromium/files/patch-base_message__loop_message__pump__glib.cc b/www/chromium/files/patch-base_message__loop_message__pump__glib.cc index 6734d01e8bf0..2015eb9d2b24 100644 --- a/www/chromium/files/patch-base_message__loop_message__pump__glib.cc +++ b/www/chromium/files/patch-base_message__loop_message__pump__glib.cc @@ -1,4 +1,4 @@ ---- base/message_loop/message_pump_glib.cc.orig 2022-08-31 12:19:35 UTC +--- base/message_loop/message_pump_glib.cc.orig 2025-04-04 08:52:13 UTC +++ base/message_loop/message_pump_glib.cc @@ -8,6 +8,11 @@ #include <glib.h> @@ -12,7 +12,7 @@ #include "base/logging.h" #include "base/memory/raw_ptr.h" #include "base/notreached.h" -@@ -51,9 +56,13 @@ int GetTimeIntervalMilliseconds(TimeTicks next_task_ti +@@ -52,9 +57,13 @@ int GetTimeIntervalMilliseconds(TimeTicks next_task_ti } bool RunningOnMainThread() { @@ -20,7 +20,7 @@ + return pthread_main_np(); +#else auto pid = getpid(); - auto tid = PlatformThread::CurrentId(); + auto tid = PlatformThread::CurrentId().raw(); return pid > 0 && tid > 0 && pid == tid; +#endif } diff --git a/www/chromium/files/patch-base_native__library__posix.cc b/www/chromium/files/patch-base_native__library__posix.cc index c2b8d0e5e970..c6991b4f66ef 100644 --- a/www/chromium/files/patch-base_native__library__posix.cc +++ b/www/chromium/files/patch-base_native__library__posix.cc @@ -1,6 +1,6 @@ ---- base/native_library_posix.cc.orig 2022-05-19 14:06:27 UTC +--- base/native_library_posix.cc.orig 2024-08-26 12:06:38 UTC +++ base/native_library_posix.cc -@@ -33,7 +33,7 @@ NativeLibrary LoadNativeLibraryWithOptions(const FileP +@@ -34,7 +34,7 @@ NativeLibrary LoadNativeLibraryWithOptions(const FileP // http://crbug.com/17943, http://crbug.com/17557, http://crbug.com/36892, // and http://crbug.com/40794. int flags = RTLD_LAZY; diff --git a/www/chromium/files/patch-base_native__library__unittest.cc b/www/chromium/files/patch-base_native__library__unittest.cc index 6e6c27253205..ff83c343cf95 100644 --- a/www/chromium/files/patch-base_native__library__unittest.cc +++ b/www/chromium/files/patch-base_native__library__unittest.cc @@ -1,6 +1,6 @@ ---- base/native_library_unittest.cc.orig 2024-03-22 08:19:40 UTC +--- base/native_library_unittest.cc.orig 2024-10-22 08:31:56 UTC +++ base/native_library_unittest.cc -@@ -133,7 +133,7 @@ TEST(NativeLibraryTest, LoadLibrary) { +@@ -135,7 +135,7 @@ TEST(NativeLibraryTest, LoadLibrary) { // versions with respect to symbol resolution scope. // TSan and MSan error out on RTLD_DEEPBIND, https://crbug.com/705255 #if !BUILDFLAG(IS_ANDROID) && !defined(THREAD_SANITIZER) && \ diff --git a/www/chromium/files/patch-base_posix_file__descriptor__shuffle.h b/www/chromium/files/patch-base_posix_file__descriptor__shuffle.h new file mode 100644 index 000000000000..f763069a2370 --- /dev/null +++ b/www/chromium/files/patch-base_posix_file__descriptor__shuffle.h @@ -0,0 +1,11 @@ +--- base/posix/file_descriptor_shuffle.h.orig 2024-10-22 08:31:56 UTC ++++ base/posix/file_descriptor_shuffle.h +@@ -26,6 +26,8 @@ + #include "base/base_export.h" + #include "base/compiler_specific.h" + ++#undef close ++ + namespace base { + + // A Delegate which performs the actions required to perform an injective diff --git a/www/chromium/files/patch-base_posix_unix__domain__socket.cc b/www/chromium/files/patch-base_posix_unix__domain__socket.cc index 3f38e80838c5..a773bacd01a9 100644 --- a/www/chromium/files/patch-base_posix_unix__domain__socket.cc +++ b/www/chromium/files/patch-base_posix_unix__domain__socket.cc @@ -1,6 +1,6 @@ ---- base/posix/unix_domain_socket.cc.orig 2024-04-19 13:02:56 UTC +--- base/posix/unix_domain_socket.cc.orig 2025-02-19 07:43:18 UTC +++ base/posix/unix_domain_socket.cc -@@ -51,7 +51,7 @@ bool CreateSocketPair(ScopedFD* one, ScopedFD* two) { +@@ -47,7 +47,7 @@ bool CreateSocketPair(ScopedFD* one, ScopedFD* two) { // static bool UnixDomainSocket::EnableReceiveProcessId(int fd) { @@ -9,7 +9,7 @@ const int enable = 1; return setsockopt(fd, SOL_SOCKET, SO_PASSCRED, &enable, sizeof(enable)) == 0; #else -@@ -77,7 +77,7 @@ bool UnixDomainSocket::SendMsg(int fd, +@@ -73,7 +73,7 @@ bool UnixDomainSocket::SendMsg(int fd, struct cmsghdr* cmsg; msg.msg_control = control_buffer; @@ -18,7 +18,7 @@ msg.msg_controllen = checked_cast<socklen_t>(control_len); #else msg.msg_controllen = control_len; -@@ -85,7 +85,7 @@ bool UnixDomainSocket::SendMsg(int fd, +@@ -81,7 +81,7 @@ bool UnixDomainSocket::SendMsg(int fd, cmsg = CMSG_FIRSTHDR(&msg); cmsg->cmsg_level = SOL_SOCKET; cmsg->cmsg_type = SCM_RIGHTS; @@ -27,7 +27,7 @@ cmsg->cmsg_len = checked_cast<u_int>(CMSG_LEN(sizeof(int) * fds.size())); #else cmsg->cmsg_len = CMSG_LEN(sizeof(int) * fds.size()); -@@ -149,7 +149,7 @@ ssize_t UnixDomainSocket::RecvMsgWithFlags(int fd, +@@ -133,7 +133,7 @@ ssize_t UnixDomainSocket::RecvMsgWithFlags(int fd, const size_t kControlBufferSize = CMSG_SPACE(sizeof(int) * kMaxFileDescriptors) @@ -36,7 +36,7 @@ // macOS does not support ucred. // macOS supports xucred, but this structure is insufficient. + CMSG_SPACE(sizeof(struct ucred)) -@@ -177,7 +177,7 @@ ssize_t UnixDomainSocket::RecvMsgWithFlags(int fd, +@@ -162,7 +162,7 @@ ssize_t UnixDomainSocket::RecvMsgWithFlags(int fd, wire_fds = reinterpret_cast<int*>(CMSG_DATA(cmsg)); wire_fds_len = payload_len / sizeof(int); } @@ -45,10 +45,10 @@ // macOS does not support SCM_CREDENTIALS. if (cmsg->cmsg_level == SOL_SOCKET && cmsg->cmsg_type == SCM_CREDENTIALS) { -@@ -211,6 +211,9 @@ ssize_t UnixDomainSocket::RecvMsgWithFlags(int fd, - socklen_t pid_size = sizeof(pid); - if (getsockopt(fd, SOL_LOCAL, LOCAL_PEERPID, &pid, &pid_size) != 0) +@@ -199,6 +199,9 @@ ssize_t UnixDomainSocket::RecvMsgWithFlags(int fd, + if (getsockopt(fd, SOL_LOCAL, LOCAL_PEERPID, &pid, &pid_size) != 0) { pid = -1; + } +#elif BUILDFLAG(IS_BSD) + NOTIMPLEMENTED(); + pid = -1; diff --git a/www/chromium/files/patch-base_posix_unix__domain__socket__unittest.cc b/www/chromium/files/patch-base_posix_unix__domain__socket__unittest.cc index 6d36a5d31542..c0912994822b 100644 --- a/www/chromium/files/patch-base_posix_unix__domain__socket__unittest.cc +++ b/www/chromium/files/patch-base_posix_unix__domain__socket__unittest.cc @@ -1,6 +1,6 @@ ---- base/posix/unix_domain_socket_unittest.cc.orig 2023-03-09 06:31:50 UTC +--- base/posix/unix_domain_socket_unittest.cc.orig 2024-06-17 12:56:06 UTC +++ base/posix/unix_domain_socket_unittest.cc -@@ -10,6 +10,8 @@ +@@ -15,6 +15,8 @@ #include <sys/types.h> #include <unistd.h> diff --git a/www/chromium/files/patch-base_process_internal__linux.h b/www/chromium/files/patch-base_process_internal__linux.h index e324410eccaa..fa154978ba86 100644 --- a/www/chromium/files/patch-base_process_internal__linux.h +++ b/www/chromium/files/patch-base_process_internal__linux.h @@ -1,6 +1,6 @@ ---- base/process/internal_linux.h.orig 2024-04-19 13:02:56 UTC +--- base/process/internal_linux.h.orig 2025-07-02 06:08:04 UTC +++ base/process/internal_linux.h -@@ -138,6 +138,9 @@ TimeDelta ClockTicksToTimeDelta(int64_t clock_ticks); +@@ -146,6 +146,9 @@ TimeDelta ClockTicksToTimeDelta(int64_t clock_ticks); // arguments to the lambda. template <typename Lambda> void ForEachProcessTask(base::ProcessHandle process, Lambda&& lambda) { @@ -10,7 +10,7 @@ // Iterate through the different threads tracked in /proc/<pid>/task. FilePath fd_path = GetProcPidDir(process).Append("task"); -@@ -157,6 +160,7 @@ void ForEachProcessTask(base::ProcessHandle process, L +@@ -169,6 +172,7 @@ void ForEachProcessTask(base::ProcessHandle process, L FilePath task_path = fd_path.Append(tid_str); lambda(tid, task_path); } diff --git a/www/chromium/files/patch-base_process_kill.h b/www/chromium/files/patch-base_process_kill.h index 36e7c6deb10a..0b18ba432f9e 100644 --- a/www/chromium/files/patch-base_process_kill.h +++ b/www/chromium/files/patch-base_process_kill.h @@ -1,8 +1,8 @@ ---- base/process/kill.h.orig 2024-02-23 21:04:38 UTC +--- base/process/kill.h.orig 2025-02-19 07:43:18 UTC +++ base/process/kill.h -@@ -121,7 +121,7 @@ BASE_EXPORT TerminationStatus GetTerminationStatus(Pro - BASE_EXPORT TerminationStatus GetKnownDeadTerminationStatus( - ProcessHandle handle, int* exit_code); +@@ -123,7 +123,7 @@ BASE_EXPORT TerminationStatus GetTerminationStatus(Pro + BASE_EXPORT TerminationStatus + GetKnownDeadTerminationStatus(ProcessHandle handle, int* exit_code); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-base_process_kill__posix.cc b/www/chromium/files/patch-base_process_kill__posix.cc index 3f2e75bf15be..d5d3c7a3e5f4 100644 --- a/www/chromium/files/patch-base_process_kill__posix.cc +++ b/www/chromium/files/patch-base_process_kill__posix.cc @@ -1,6 +1,6 @@ ---- base/process/kill_posix.cc.orig 2023-04-05 11:05:06 UTC +--- base/process/kill_posix.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/kill_posix.cc -@@ -157,7 +157,7 @@ void EnsureProcessTerminated(Process process) { +@@ -161,7 +161,7 @@ void EnsureProcessTerminated(Process process) { 0, new BackgroundReaper(std::move(process), Seconds(2))); } diff --git a/www/chromium/files/patch-base_process_launch.h b/www/chromium/files/patch-base_process_launch.h index c94015969722..077ee0ab0d0f 100644 --- a/www/chromium/files/patch-base_process_launch.h +++ b/www/chromium/files/patch-base_process_launch.h @@ -1,6 +1,6 @@ ---- base/process/launch.h.orig 2023-04-28 17:01:32 UTC +--- base/process/launch.h.orig 2025-05-28 14:55:43 UTC +++ base/process/launch.h -@@ -200,7 +200,7 @@ struct BASE_EXPORT LaunchOptions { +@@ -245,7 +245,7 @@ struct BASE_EXPORT LaunchOptions { bool clear_environment = false; #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_POSIX) || BUILDFLAG(IS_FUCHSIA) diff --git a/www/chromium/files/patch-base_process_launch__posix.cc b/www/chromium/files/patch-base_process_launch__posix.cc index eae1fdd9a2af..7421bfc19c8e 100644 --- a/www/chromium/files/patch-base_process_launch__posix.cc +++ b/www/chromium/files/patch-base_process_launch__posix.cc @@ -1,6 +1,6 @@ ---- base/process/launch_posix.cc.orig 2024-02-23 21:04:38 UTC +--- base/process/launch_posix.cc.orig 2025-04-04 08:52:13 UTC +++ base/process/launch_posix.cc -@@ -61,6 +61,9 @@ +@@ -62,6 +62,9 @@ #error "macOS should use launch_mac.cc" #endif diff --git a/www/chromium/files/patch-base_process_memory__linux.cc b/www/chromium/files/patch-base_process_memory__linux.cc index 52e97d5d62fa..1917ac874445 100644 --- a/www/chromium/files/patch-base_process_memory__linux.cc +++ b/www/chromium/files/patch-base_process_memory__linux.cc @@ -1,4 +1,4 @@ ---- base/process/memory_linux.cc.orig 2024-01-30 07:53:34 UTC +--- base/process/memory_linux.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/memory_linux.cc @@ -28,6 +28,7 @@ void __libc_free(void*); @@ -8,7 +8,7 @@ namespace { void ReleaseReservationOrTerminate() { -@@ -37,12 +38,14 @@ void ReleaseReservationOrTerminate() { +@@ -38,12 +39,14 @@ void ReleaseReservationOrTerminate() { } } // namespace @@ -23,8 +23,8 @@ // Set the new-out of memory handler. std::set_new_handler(&ReleaseReservationOrTerminate); // If we're using glibc's allocator, the above functions will override -@@ -51,8 +54,10 @@ void EnableTerminationOnOutOfMemory() { - #if BUILDFLAG(USE_ALLOCATOR_SHIM) +@@ -52,8 +55,10 @@ void EnableTerminationOnOutOfMemory() { + #if PA_BUILDFLAG(USE_ALLOCATOR_SHIM) allocator_shim::SetCallNewHandlerOnMallocFailure(true); #endif +#endif @@ -34,11 +34,11 @@ // ScopedAllowBlocking() has private constructor and it can only be used in // friend classes/functions. Declaring a class is easier in this situation to // avoid adding more dependency to thread_restrictions.h because of the -@@ -112,6 +117,7 @@ bool AdjustOOMScoreHelper::AdjustOOMScore(ProcessId pr +@@ -111,6 +116,7 @@ bool AdjustOOMScoreHelper::AdjustOOMScore(ProcessId pr bool AdjustOOMScore(ProcessId process, int score) { return AdjustOOMScoreHelper::AdjustOOMScore(process, score); } +#endif bool UncheckedMalloc(size_t size, void** result) { - #if BUILDFLAG(USE_ALLOCATOR_SHIM) + #if PA_BUILDFLAG(USE_ALLOCATOR_SHIM) diff --git a/www/chromium/files/patch-base_process_process__handle__freebsd.cc b/www/chromium/files/patch-base_process_process__handle__freebsd.cc index 57803265ff52..1e055cdbfd37 100644 --- a/www/chromium/files/patch-base_process_process__handle__freebsd.cc +++ b/www/chromium/files/patch-base_process_process__handle__freebsd.cc @@ -1,4 +1,4 @@ ---- base/process/process_handle_freebsd.cc.orig 2024-04-19 13:02:56 UTC +--- base/process/process_handle_freebsd.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_handle_freebsd.cc @@ -3,6 +3,7 @@ // found in the LICENSE file. @@ -14,12 +14,12 @@ struct kinfo_proc info; - size_t length; + size_t length = sizeof(struct kinfo_proc); - int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process }; + int mib[] = {CTL_KERN, KERN_PROC, KERN_PROC_PID, process}; - if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) + if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) { + return -1; + + if (length < sizeof(struct kinfo_proc)) return -1; + } - return info.ki_ppid; diff --git a/www/chromium/files/patch-base_process_process__handle__openbsd.cc b/www/chromium/files/patch-base_process_process__handle__openbsd.cc index 56d1d3d4223b..053a17e70c8f 100644 --- a/www/chromium/files/patch-base_process_process__handle__openbsd.cc +++ b/www/chromium/files/patch-base_process_process__handle__openbsd.cc @@ -1,6 +1,6 @@ ---- base/process/process_handle_openbsd.cc.orig 2024-04-19 13:02:56 UTC +--- base/process/process_handle_openbsd.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_handle_openbsd.cc -@@ -3,48 +3,112 @@ +@@ -3,17 +3,25 @@ // found in the LICENSE file. #include "base/process/process_handle.h" @@ -24,25 +24,26 @@ + struct kinfo_proc *info; size_t length; + pid_t ppid; - int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process, - sizeof(struct kinfo_proc), 0 }; - - if (sysctl(mib, std::size(mib), NULL, &length, NULL, 0) < 0) + int mib[] = { + CTL_KERN, KERN_PROC, KERN_PROC_PID, process, sizeof(struct kinfo_proc), + 0}; +@@ -22,37 +30,87 @@ ProcessId GetParentProcessId(ProcessHandle process) { return -1; + } - mib[5] = (length / sizeof(struct kinfo_proc)); + info = (struct kinfo_proc *)malloc(length); -- if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) +- if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) { - return -1; + mib[5] = static_cast<int>((length / sizeof(struct kinfo_proc))); - -- return info.p_ppid; ++ + if (sysctl(mib, std::size(mib), info, &length, NULL, 0) < 0) { + ppid = -1; + goto out; -+ } -+ + } + +- return info.p_ppid; + ppid = info->p_ppid; + +out: @@ -58,24 +59,17 @@ + char **retvalargs, *cpath, retval[PATH_MAX]; + int cnt; size_t len; -- int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process, -- sizeof(struct kinfo_proc), 0 }; +- int mib[] = { +- CTL_KERN, KERN_PROC, KERN_PROC_PID, process, sizeof(struct kinfo_proc), +- 0}; + char *tokens[2]; + struct stat sb; + FilePath result; -- if (sysctl(mib, std::size(mib), NULL, &len, NULL, 0) == -1) -- return FilePath(); -- mib[5] = (len / sizeof(struct kinfo_proc)); -- if (sysctl(mib, std::size(mib), &kp, &len, NULL, 0) < 0) +- if (sysctl(mib, std::size(mib), NULL, &len, NULL, 0) == -1) { - return FilePath(); -- if ((kp.p_flag & P_SYSTEM) != 0) -- return FilePath(); -- if (strcmp(kp.p_comm, "chrome") == 0) -- return FilePath(kp.p_comm); + int mib[] = { CTL_KERN, KERN_PROC_ARGS, process, KERN_PROC_ARGV }; - -- return FilePath(); ++ + if ((cpath = getenv("CHROME_EXE_PATH")) != NULL) + result = FilePath(cpath); + else @@ -125,8 +119,19 @@ + result = FilePath(retval); + } + } -+ } -+ + } +- mib[5] = (len / sizeof(struct kinfo_proc)); +- if (sysctl(mib, std::size(mib), &kp, &len, NULL, 0) < 0) { +- return FilePath(); +- } +- if ((kp.p_flag & P_SYSTEM) != 0) { +- return FilePath(); +- } +- if (strcmp(kp.p_comm, "chrome") == 0) { +- return FilePath(kp.p_comm); +- } + +- return FilePath(); + return result; } diff --git a/www/chromium/files/patch-base_process_process__iterator__freebsd.cc b/www/chromium/files/patch-base_process_process__iterator__freebsd.cc index 1745deea52e7..36a9532f5fa5 100644 --- a/www/chromium/files/patch-base_process_process__iterator__freebsd.cc +++ b/www/chromium/files/patch-base_process_process__iterator__freebsd.cc @@ -1,11 +1,11 @@ ---- base/process/process_iterator_freebsd.cc.orig 2023-04-05 11:05:06 UTC +--- base/process/process_iterator_freebsd.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_iterator_freebsd.cc @@ -18,7 +18,7 @@ namespace base { ProcessIterator::ProcessIterator(const ProcessFilter* filter) : filter_(filter) { -- int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_UID, getuid() }; -+ int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_UID, (int) getuid() }; +- int mib[] = {CTL_KERN, KERN_PROC, KERN_PROC_UID, getuid()}; ++ int mib[] = {CTL_KERN, KERN_PROC, KERN_PROC_UID, (int) getuid()}; bool done = false; int try_num = 1; @@ -23,19 +23,20 @@ } else { // Got the list, just make sure we're sized exactly right - size_t num_of_kinfo_proc = len / sizeof(struct kinfo_proc); -+ num_of_kinfo_proc = len / sizeof(struct kinfo_proc); ++ num_of_kinfo_proc = len / sizeof(struct kinfo_proc); kinfo_procs_.resize(num_of_kinfo_proc); done = true; } -@@ -68,18 +68,13 @@ bool ProcessIterator::CheckForNextProcess() { +@@ -68,19 +68,14 @@ bool ProcessIterator::CheckForNextProcess() { for (; index_of_kinfo_proc_ < kinfo_procs_.size(); ++index_of_kinfo_proc_) { size_t length; struct kinfo_proc kinfo = kinfo_procs_[index_of_kinfo_proc_]; -- int mib[] = { CTL_KERN, KERN_PROC_ARGS, kinfo.ki_pid }; +- int mib[] = {CTL_KERN, KERN_PROC_ARGS, kinfo.ki_pid}; + int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_ARGS, kinfo.ki_pid }; - if ((kinfo.ki_pid > 0) && (kinfo.ki_stat == SZOMB)) + if ((kinfo.ki_pid > 0) && (kinfo.ki_stat == SZOMB)) { continue; + } - length = 0; - if (sysctl(mib, std::size(mib), NULL, &length, NULL, 0) < 0) { diff --git a/www/chromium/files/patch-base_process_process__iterator__openbsd.cc b/www/chromium/files/patch-base_process_process__iterator__openbsd.cc index a9b99ed7e795..b275b2b6ced1 100644 --- a/www/chromium/files/patch-base_process_process__iterator__openbsd.cc +++ b/www/chromium/files/patch-base_process_process__iterator__openbsd.cc @@ -1,4 +1,4 @@ ---- base/process/process_iterator_openbsd.cc.orig 2023-04-05 11:05:06 UTC +--- base/process/process_iterator_openbsd.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_iterator_openbsd.cc @@ -6,6 +6,9 @@ @@ -10,13 +10,14 @@ #include <sys/sysctl.h> #include "base/logging.h" -@@ -16,12 +19,13 @@ namespace base { - +@@ -17,12 +20,13 @@ namespace base { ProcessIterator::ProcessIterator(const ProcessFilter* filter) : filter_(filter) { -- int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_UID, getuid(), -+ int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_UID, static_cast<int>(getuid()), - sizeof(struct kinfo_proc), 0 }; + int mib[] = { +- CTL_KERN, KERN_PROC, KERN_PROC_UID, getuid(), sizeof(struct kinfo_proc), +- 0}; ++ CTL_KERN, KERN_PROC, KERN_PROC_UID, static_cast<int>(getuid()), ++ sizeof(struct kinfo_proc), 0 }; bool done = false; int try_num = 1; @@ -25,7 +26,7 @@ do { size_t len = 0; -@@ -30,7 +34,7 @@ ProcessIterator::ProcessIterator(const ProcessFilter* +@@ -31,7 +35,7 @@ ProcessIterator::ProcessIterator(const ProcessFilter* kinfo_procs_.resize(0); done = true; } else { @@ -34,7 +35,7 @@ // Leave some spare room for process table growth (more could show up // between when we check and now) num_of_kinfo_proc += 16; -@@ -46,7 +50,7 @@ ProcessIterator::ProcessIterator(const ProcessFilter* +@@ -47,7 +51,7 @@ ProcessIterator::ProcessIterator(const ProcessFilter* } } else { // Got the list, just make sure we're sized exactly right diff --git a/www/chromium/files/patch-base_process_process__metrics.cc b/www/chromium/files/patch-base_process_process__metrics.cc index 97fd27ed293a..486883bcb987 100644 --- a/www/chromium/files/patch-base_process_process__metrics.cc +++ b/www/chromium/files/patch-base_process_process__metrics.cc @@ -1,4 +1,4 @@ ---- base/process/process_metrics.cc.orig 2024-04-19 13:02:56 UTC +--- base/process/process_metrics.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_metrics.cc @@ -17,7 +17,7 @@ namespace base { namespace { @@ -35,9 +35,9 @@ double ProcessMetrics::GetPlatformIndependentCPUUsage( TimeDelta cumulative_cpu) { TimeTicks time = TimeTicks::Now(); -@@ -130,10 +129,9 @@ std::optional<double> ProcessMetrics::GetPlatformIndep - } - return GetPlatformIndependentCPUUsage(cpu_usage.value()); +@@ -130,10 +129,9 @@ ProcessMetrics::GetPlatformIndependentCPUUsage() { + return GetPlatformIndependentCPUUsage(cpu_usage); + }); } -#endif diff --git a/www/chromium/files/patch-base_process_process__metrics.h b/www/chromium/files/patch-base_process_process__metrics.h index 3bc7936f205c..07463e92edbf 100644 --- a/www/chromium/files/patch-base_process_process__metrics.h +++ b/www/chromium/files/patch-base_process_process__metrics.h @@ -1,6 +1,6 @@ ---- base/process/process_metrics.h.orig 2024-04-19 13:02:56 UTC +--- base/process/process_metrics.h.orig 2025-02-19 07:43:18 UTC +++ base/process/process_metrics.h -@@ -38,7 +38,7 @@ +@@ -39,7 +39,7 @@ #endif #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ @@ -9,7 +9,7 @@ #include <string> #include <utility> #include <vector> -@@ -48,7 +48,7 @@ +@@ -49,7 +49,7 @@ namespace base { @@ -18,17 +18,8 @@ // Minor and major page fault counts since the process creation. // Both counts are process-wide, and exclude child processes. // -@@ -103,7 +103,7 @@ class BASE_EXPORT ProcessMetrics { - // convenience wrapper for CreateProcessMetrics(). - static std::unique_ptr<ProcessMetrics> CreateCurrentProcessMetrics(); - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - // Resident Set Size is a Linux/Android specific memory concept. Do not - // attempt to extend this to other platforms. - BASE_EXPORT size_t GetResidentSetSize() const; -@@ -137,7 +137,7 @@ class BASE_EXPORT ProcessMetrics { - [[nodiscard]] std::optional<TimeDelta> GetCumulativeCPUUsage(); +@@ -179,7 +179,7 @@ class BASE_EXPORT ProcessMetrics { + base::expected<TimeDelta, ProcessCPUUsageError> GetCumulativeCPUUsage(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ - BUILDFLAG(IS_AIX) @@ -36,16 +27,16 @@ // Emits the cumulative CPU usage for all currently active threads since they // were started into the output parameter (replacing its current contents). // Threads that have already terminated will not be reported. Thus, the sum of -@@ -182,7 +182,7 @@ class BASE_EXPORT ProcessMetrics { +@@ -224,7 +224,7 @@ class BASE_EXPORT ProcessMetrics { int GetOpenFdSoftLimit() const; #endif // BUILDFLAG(IS_POSIX) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - // Bytes of swap as reported by /proc/[pid]/status. - uint64_t GetVmSwapBytes() const; - -@@ -203,7 +203,7 @@ class BASE_EXPORT ProcessMetrics { + // Minor and major page fault count as reported by /proc/[pid]/stat. + // Returns true for success. + bool GetPageFaultCounts(PageFaultCounts* counts) const; +@@ -242,7 +242,7 @@ class BASE_EXPORT ProcessMetrics { #endif // !BUILDFLAG(IS_MAC) #if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -54,7 +45,7 @@ int CalculateIdleWakeupsPerSecond(uint64_t absolute_idle_wakeups); #endif #if BUILDFLAG(IS_APPLE) -@@ -225,12 +225,10 @@ class BASE_EXPORT ProcessMetrics { +@@ -264,12 +264,10 @@ class BASE_EXPORT ProcessMetrics { // Used to store the previous times and CPU usage counts so we can // compute the CPU usage between calls. TimeTicks last_cpu_time_; @@ -68,7 +59,7 @@ // Same thing for idle wakeups. TimeTicks last_idle_wakeups_time_; uint64_t last_absolute_idle_wakeups_; -@@ -271,7 +269,7 @@ BASE_EXPORT void IncreaseFdLimitTo(unsigned int max_de +@@ -310,7 +308,7 @@ BASE_EXPORT void IncreaseFdLimitTo(unsigned int max_de #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_AIX) || \ @@ -77,7 +68,7 @@ // Data about system-wide memory consumption. Values are in KB. Available on // Windows, Mac, Linux, Android and Chrome OS. // -@@ -306,7 +304,7 @@ struct BASE_EXPORT SystemMemoryInfoKB { +@@ -345,7 +343,7 @@ struct BASE_EXPORT SystemMemoryInfoKB { #endif #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ @@ -86,7 +77,7 @@ // This provides an estimate of available memory as described here: // https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=34e431b0ae398fc54ea69ff85ec700722c9da773 // NOTE: this is ONLY valid in kernels 3.14 and up. Its value will always -@@ -321,7 +319,7 @@ struct BASE_EXPORT SystemMemoryInfoKB { +@@ -360,7 +358,7 @@ struct BASE_EXPORT SystemMemoryInfoKB { #endif #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -95,7 +86,7 @@ int buffers = 0; int cached = 0; int active_anon = 0; -@@ -358,7 +356,7 @@ BASE_EXPORT bool GetSystemMemoryInfo(SystemMemoryInfoK +@@ -397,7 +395,7 @@ BASE_EXPORT bool GetSystemMemoryInfo(SystemMemoryInfoK // BUILDFLAG(IS_FUCHSIA) #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ @@ -104,7 +95,7 @@ // Parse the data found in /proc/<pid>/stat and return the sum of the // CPU-related ticks. Returns -1 on parse error. // Exposed for testing. -@@ -552,7 +550,7 @@ class BASE_EXPORT SystemMetrics { +@@ -591,7 +589,7 @@ class BASE_EXPORT SystemMetrics { FRIEND_TEST_ALL_PREFIXES(SystemMetricsTest, SystemMetrics); size_t committed_memory_; diff --git a/www/chromium/files/patch-base_process_process__metrics__freebsd.cc b/www/chromium/files/patch-base_process_process__metrics__freebsd.cc index b1034b768cb5..d3f664f95e5a 100644 --- a/www/chromium/files/patch-base_process_process__metrics__freebsd.cc +++ b/www/chromium/files/patch-base_process_process__metrics__freebsd.cc @@ -1,6 +1,6 @@ ---- base/process/process_metrics_freebsd.cc.orig 2024-04-20 08:27:55 UTC +--- base/process/process_metrics_freebsd.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_metrics_freebsd.cc -@@ -3,42 +3,57 @@ +@@ -3,41 +3,92 @@ // found in the LICENSE file. #include "base/process/process_metrics.h" @@ -26,8 +26,7 @@ + int pageshift = 0; -ProcessMetrics::ProcessMetrics(ProcessHandle process) -- : process_(process), -- last_cpu_(0) {} +- : process_(process), last_cpu_(0) {} + while (pagesize > 1) { + pageshift++; + pagesize >>= 1; @@ -45,36 +44,70 @@ return WrapUnique(new ProcessMetrics(process)); } --std::optional<double> ProcessMetrics::GetPlatformIndependentCPUUsage() { -+std::optional<TimeDelta> ProcessMetrics::GetCumulativeCPUUsage() { - struct kinfo_proc info; +-base::expected<double, ProcessCPUUsageError> +-ProcessMetrics::GetPlatformIndependentCPUUsage() { +- struct kinfo_proc info; - int mib[] = {CTL_KERN, KERN_PROC, KERN_PROC_PID, process_}; - size_t length = sizeof(info); ++base::expected<ProcessMemoryInfo, ProcessUsageError> ++ProcessMetrics::GetMemoryInfo() const { ++ ProcessMemoryInfo memory_info; ++ kvm_t *kd = kvm_open(nullptr, "/dev/null", nullptr, O_RDONLY, "kvm_open"); ++ struct kinfo_proc *pp; ++ int nproc; + +- if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) { +- return base::unexpected(ProcessCPUUsageError::kSystemError); ++ if (kd == nullptr) { ++ return base::unexpected(ProcessUsageError::kSystemError); + } + +- return base::ok(double{info.ki_pctcpu} / FSCALE * 100.0); ++ if ((pp = kvm_getprocs(kd, KERN_PROC_PID, process_, &nproc)) == nullptr) { ++ kvm_close(kd); ++ return base::unexpected(ProcessUsageError::kProcessNotFound); ++ } ++ ++ if (nproc > 0) { ++ memory_info.resident_set_bytes = pp->ki_rssize << GetPageShift(); ++ } else { ++ kvm_close(kd); ++ return base::unexpected(ProcessUsageError::kProcessNotFound); ++ } ++ ++ kvm_close(kd); ++ return memory_info; + } + + base::expected<TimeDelta, ProcessCPUUsageError> + ProcessMetrics::GetCumulativeCPUUsage() { +- NOTREACHED(); ++ struct kinfo_proc info; + size_t length = sizeof(struct kinfo_proc); + struct timeval tv; - ++ + int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process_ }; + - if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) -- return std::nullopt; -+ return std::optional(TimeDelta()); - -- return std::optional(double{info.ki_pctcpu} / FSCALE * 100.0); -+ return std::optional(Microseconds(info.ki_runtime)); ++ if (process_ == 0) { ++ return base::unexpected(ProcessCPUUsageError::kSystemError); ++ } ++ ++ if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) { ++ return base::unexpected(ProcessCPUUsageError::kSystemError); ++ } ++ ++ if (length == 0) { ++ return base::unexpected(ProcessCPUUsageError::kProcessNotFound); ++ } ++ ++ return base::ok(Microseconds(info.ki_runtime)); } --std::optional<TimeDelta> ProcessMetrics::GetCumulativeCPUUsage() { -- NOTREACHED(); -- return std::nullopt; --} -- size_t GetSystemCommitCharge() { - int mib[2], pagesize; - unsigned long mem_total, mem_free, mem_inactive; -@@ -60,6 +75,230 @@ size_t GetSystemCommitCharge() { +@@ -64,6 +115,176 @@ size_t GetSystemCommitCharge() { pagesize = getpagesize(); - return mem_total - (mem_free*pagesize) - (mem_inactive*pagesize); + return mem_total - (mem_free * pagesize) - (mem_inactive * pagesize); +} + +int64_t GetNumberOfThreads(ProcessHandle process) { @@ -157,60 +190,6 @@ + return total_count; +} + -+size_t ProcessMetrics::GetResidentSetSize() const { -+ kvm_t *kd = kvm_open(nullptr, "/dev/null", nullptr, O_RDONLY, "kvm_open"); -+ -+ if (kd == nullptr) -+ return 0; -+ -+ struct kinfo_proc *pp; -+ int nproc; -+ -+ if ((pp = kvm_getprocs(kd, KERN_PROC_PID, process_, &nproc)) == nullptr) { -+ kvm_close(kd); -+ return 0; -+ } -+ -+ size_t rss; -+ -+ if (nproc > 0) { -+ rss = pp->ki_rssize << GetPageShift(); -+ } else { -+ rss = 0; -+ } -+ -+ kvm_close(kd); -+ return rss; -+} -+ -+uint64_t ProcessMetrics::GetVmSwapBytes() const { -+ kvm_t *kd = kvm_open(nullptr, "/dev/null", nullptr, O_RDONLY, "kvm_open"); -+ -+ if (kd == nullptr) -+ return 0; -+ -+ struct kinfo_proc *pp; -+ int nproc; -+ -+ if ((pp = kvm_getprocs(kd, KERN_PROC_PID, process_, &nproc)) == nullptr) { -+ kvm_close(kd); -+ return 0; -+ } -+ -+ size_t swrss; -+ -+ if (nproc > 0) { -+ swrss = pp->ki_swrss > pp->ki_rssize -+ ? (pp->ki_swrss - pp->ki_rssize) << GetPageShift() -+ : 0; -+ } else { -+ swrss = 0; -+ } -+ -+ kvm_close(kd); -+ return swrss; -+} -+ +int ProcessMetrics::GetIdleWakeupsPerSecond() { + NOTIMPLEMENTED(); + return 0; diff --git a/www/chromium/files/patch-base_process_process__metrics__openbsd.cc b/www/chromium/files/patch-base_process_process__metrics__openbsd.cc index 00db4dd3406c..5bb5b1da2134 100644 --- a/www/chromium/files/patch-base_process_process__metrics__openbsd.cc +++ b/www/chromium/files/patch-base_process_process__metrics__openbsd.cc @@ -1,6 +1,6 @@ ---- base/process/process_metrics_openbsd.cc.orig 2024-04-19 13:02:56 UTC +--- base/process/process_metrics_openbsd.cc.orig 2025-02-25 07:06:47 UTC +++ base/process/process_metrics_openbsd.cc -@@ -6,73 +6,49 @@ +@@ -6,73 +6,85 @@ #include <stddef.h> #include <stdint.h> @@ -8,11 +8,11 @@ #include <sys/param.h> #include <sys/sysctl.h> +#include <sys/vmmeter.h> - #include <optional> +#include <kvm.h> + #include "base/memory/ptr_util.h" + #include "base/types/expected.h" +#include "base/values.h" +#include "base/notreached.h" @@ -21,119 +21,128 @@ -namespace { +ProcessMetrics::ProcessMetrics(ProcessHandle process) : process_(process) {} --static std::optional<int> GetProcessCPU(pid_t pid) { -+std::optional<TimeDelta> ProcessMetrics::GetCumulativeCPUUsage() { +-base::expected<int, ProcessCPUUsageError> GetProcessCPU(pid_t pid) { ++base::expected<ProcessMemoryInfo, ProcessUsageError> ++ProcessMetrics::GetMemoryInfo() const { ++ ProcessMemoryInfo memory_info; struct kinfo_proc info; - size_t length; -- int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, pid, -- sizeof(struct kinfo_proc), 0 }; +- int mib[] = { +- CTL_KERN, KERN_PROC, KERN_PROC_PID, pid, sizeof(struct kinfo_proc), 0}; + size_t length = sizeof(struct kinfo_proc); -+ struct timeval tv; - if (sysctl(mib, std::size(mib), NULL, &length, NULL, 0) < 0) { -- return std::nullopt; -- } +- return base::unexpected(ProcessCPUUsageError::kSystemError); + int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process_, + sizeof(struct kinfo_proc), 1 }; ++ ++ if (process_ == 0) { ++ return base::unexpected(ProcessUsageError::kSystemError); + } - mib[5] = (length / sizeof(struct kinfo_proc)); - if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) { -- return std::nullopt; -+ return std::optional(TimeDelta()); +- return base::unexpected(ProcessCPUUsageError::kSystemError); ++ return base::unexpected(ProcessUsageError::kSystemError); } -- return std::optional(info.p_pctcpu); -+ tv.tv_sec = info.p_rtime_sec; -+ tv.tv_usec = info.p_rtime_usec; -+ -+ return std::optional(Microseconds(TimeValToMicroseconds(tv))); - } +- return base::ok(info.p_pctcpu); +-} ++ if (length == 0) { ++ return base::unexpected(ProcessUsageError::kProcessNotFound); ++ } -} // namespace -- - // static - std::unique_ptr<ProcessMetrics> ProcessMetrics::CreateProcessMetrics( - ProcessHandle process) { - return WrapUnique(new ProcessMetrics(process)); ++ memory_info.resident_set_bytes = ++ checked_cast<uint64_t>(info.p_vm_rssize * getpagesize()); + +-// static +-std::unique_ptr<ProcessMetrics> ProcessMetrics::CreateProcessMetrics( +- ProcessHandle process) { +- return WrapUnique(new ProcessMetrics(process)); ++ return memory_info; } --std::optional<double> ProcessMetrics::GetPlatformIndependentCPUUsage() { +-base::expected<double, ProcessCPUUsageError> +-ProcessMetrics::GetPlatformIndependentCPUUsage() { - TimeTicks time = TimeTicks::Now(); -- ++base::expected<TimeDelta, ProcessCPUUsageError> ++ProcessMetrics::GetCumulativeCPUUsage() { ++ struct kinfo_proc info; ++ size_t length = sizeof(struct kinfo_proc); ++ struct timeval tv; + - if (last_cpu_time_.is_zero()) { - // First call, just set the last values. - last_cpu_time_ = time; -- return std::optional(0.0); -- } -- -- const std::optional<int> cpu = GetProcessCPU(process_); +- return base::ok(0.0); ++ int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process_, ++ sizeof(struct kinfo_proc), 1 }; ++ ++ if (process_ == 0) { ++ return base::unexpected(ProcessCPUUsageError::kSystemError); + } + +- const base::expected<int, ProcessCPUUsageError> cpu = GetProcessCPU(process_); - if (!cpu.has_value()) { -- return std::nullopt; -- } -- +- return base::unexpected(cpu.error()); ++ if (sysctl(mib, std::size(mib), &info, &length, NULL, 0) < 0) { ++ return base::unexpected(ProcessCPUUsageError::kSystemError); + } + - last_cpu_time_ = time; -- return std::optional(double{cpu.value()} / FSCALE * 100.0); --} -- --std::optional<TimeDelta> ProcessMetrics::GetCumulativeCPUUsage() { +- return base::ok(double{cpu.value()} / FSCALE * 100.0); ++ if (length == 0) { ++ return base::unexpected(ProcessCPUUsageError::kProcessNotFound); ++ } ++ ++ tv.tv_sec = info.p_rtime_sec; ++ tv.tv_usec = info.p_rtime_usec; ++ ++ return base::ok(Microseconds(TimeValToMicroseconds(tv))); + } + +-base::expected<TimeDelta, ProcessCPUUsageError> +-ProcessMetrics::GetCumulativeCPUUsage() { - NOTREACHED(); -- return std::nullopt; --} -- ++// static ++std::unique_ptr<ProcessMetrics> ProcessMetrics::CreateProcessMetrics( ++ ProcessHandle process) { ++ return WrapUnique(new ProcessMetrics(process)); + } + -ProcessMetrics::ProcessMetrics(ProcessHandle process) -- : process_(process), -- last_cpu_(0) {} +- : process_(process), last_cpu_(0) {} - size_t GetSystemCommitCharge() { - int mib[] = { CTL_VM, VM_METER }; + int mib[] = {CTL_VM, VM_METER}; - int pagesize; + size_t pagesize; struct vmtotal vmtotal; unsigned long mem_total, mem_free, mem_inactive; size_t len = sizeof(vmtotal); -@@ -84,9 +60,136 @@ size_t GetSystemCommitCharge() { +@@ -85,9 +97,115 @@ size_t GetSystemCommitCharge() { mem_free = vmtotal.t_free; mem_inactive = vmtotal.t_vm - vmtotal.t_avm; - pagesize = getpagesize(); + pagesize = checked_cast<size_t>(getpagesize()); - return mem_total - (mem_free*pagesize) - (mem_inactive*pagesize); + return mem_total - (mem_free * pagesize) - (mem_inactive * pagesize); +} + +int ProcessMetrics::GetOpenFdCount() const { -+#if 0 -+ struct kinfo_file *files; -+ kvm_t *kd = NULL; -+ int total_count = 0; -+ char errbuf[_POSIX2_LINE_MAX]; -+ -+ if ((kd = kvm_openfiles(NULL, NULL, NULL, KVM_NO_FILES, errbuf)) == NULL) -+ goto out; -+ -+ if ((files = kvm_getfiles(kd, KERN_FILE_BYPID, process_, -+ sizeof(struct kinfo_file), &total_count)) == NULL) { -+ total_count = 0; -+ goto out; -+ } -+ -+ kvm_close(kd); -+ -+out: -+ return total_count; -+#endif -+ return getdtablecount(); ++ return (process_ == getpid()) ? getdtablecount() : -1; +} + +int ProcessMetrics::GetOpenFdSoftLimit() const { + return getdtablesize(); -+// return GetMaxFds(); +} + -+uint64_t ProcessMetrics::GetVmSwapBytes() const { ++bool ProcessMetrics::GetPageFaultCounts(PageFaultCounts* counts) const { + NOTIMPLEMENTED(); -+ return 0; ++ return false; +} + +bool GetSystemMemoryInfo(SystemMemoryInfoKB* meminfo) { @@ -163,14 +172,14 @@ + res.Set("available", available); + res.Set("buffers", buffers); + res.Set("cached", cached); -+ res.Set("active_anon", active_anon); ++ res.Set("active_anon", active_anon); + res.Set("inactive_anon", inactive_anon); + res.Set("active_file", active_file); + res.Set("inactive_file", inactive_file); + res.Set("swap_total", swap_total); + res.Set("swap_free", swap_free); + res.Set("swap_used", swap_total - swap_free); -+ res.Set("dirty", dirty); ++ res.Set("dirty", dirty); + res.Set("reclaimable", reclaimable); + + NOTIMPLEMENTED(); @@ -187,7 +196,7 @@ + NOTIMPLEMENTED(); + + return res; -+} ++} + +SystemDiskInfo::SystemDiskInfo() { + reads = 0; @@ -209,7 +218,7 @@ + +Value::Dict SystemDiskInfo::ToDict() const { + Value::Dict res; -+ ++ + // Write out uint64_t variables as doubles. + // Note: this may discard some precision, but for JS there's no other option. + res.Set("reads", static_cast<double>(reads)); diff --git a/www/chromium/files/patch-base_process_process__metrics__posix.cc b/www/chromium/files/patch-base_process_process__metrics__posix.cc index c7759118bacb..6a0960d865cf 100644 --- a/www/chromium/files/patch-base_process_process__metrics__posix.cc +++ b/www/chromium/files/patch-base_process_process__metrics__posix.cc @@ -1,4 +1,4 @@ ---- base/process/process_metrics_posix.cc.orig 2023-07-16 15:47:57 UTC +--- base/process/process_metrics_posix.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_metrics_posix.cc @@ -21,6 +21,8 @@ @@ -9,7 +9,7 @@ #else #include <malloc.h> #endif -@@ -134,7 +136,7 @@ size_t ProcessMetrics::GetMallocUsage() { +@@ -136,7 +138,7 @@ size_t ProcessMetrics::GetMallocUsage() { return stats.size_in_use; #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) return GetMallocUsageMallinfo(); diff --git a/www/chromium/files/patch-base_process_process__metrics__unittest.cc b/www/chromium/files/patch-base_process_process__metrics__unittest.cc index ec3a90134860..b09047e6138c 100644 --- a/www/chromium/files/patch-base_process_process__metrics__unittest.cc +++ b/www/chromium/files/patch-base_process_process__metrics__unittest.cc @@ -1,9 +1,9 @@ ---- base/process/process_metrics_unittest.cc.orig 2024-04-19 13:02:56 UTC +--- base/process/process_metrics_unittest.cc.orig 2025-04-04 08:52:13 UTC +++ base/process/process_metrics_unittest.cc -@@ -56,7 +56,8 @@ +@@ -61,7 +61,8 @@ + #endif - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) || \ + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ - BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_APPLE) + BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_APPLE) || \ + BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-base_process_process__posix.cc b/www/chromium/files/patch-base_process_process__posix.cc index bd6418d952c0..7f022ca00cbb 100644 --- a/www/chromium/files/patch-base_process_process__posix.cc +++ b/www/chromium/files/patch-base_process_process__posix.cc @@ -1,6 +1,6 @@ ---- base/process/process_posix.cc.orig 2023-09-13 12:11:42 UTC +--- base/process/process_posix.cc.orig 2025-07-02 06:08:04 UTC +++ base/process/process_posix.cc -@@ -23,10 +23,15 @@ +@@ -25,10 +25,15 @@ #include "base/trace_event/base_tracing.h" #include "build/build_config.h" @@ -17,16 +17,16 @@ #if BUILDFLAG(CLANG_PROFILING) #include "base/test/clang_profiling.h" #endif -@@ -93,7 +98,7 @@ bool WaitpidWithTimeout(base::ProcessHandle handle, - return ret_pid > 0; +@@ -104,7 +109,7 @@ bool WaitpidWithTimeout(base::ProcessHandle handle, } + #endif -#if BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) // Using kqueue on Mac so that we can wait on non-child processes. // We can't use kqueues on child processes because we need to reap // our own children using wait. -@@ -198,7 +203,7 @@ bool WaitForExitWithTimeoutImpl(base::ProcessHandle ha +@@ -387,7 +392,7 @@ bool Process::WaitForExitWithTimeoutImpl(base::Process const bool exited = (parent_pid < 0); if (!exited && parent_pid != our_pid) { @@ -35,7 +35,7 @@ // On Mac we can wait on non child processes. return WaitForSingleNonChildProcess(handle, timeout); #else -@@ -387,7 +392,56 @@ void Process::Exited(int exit_code) const { +@@ -424,7 +429,56 @@ void Process::Exited(int exit_code) const { int Process::GetOSPriority() const { DCHECK(IsValid()); diff --git a/www/chromium/files/patch-base_process_process__unittest.cc b/www/chromium/files/patch-base_process_process__unittest.cc index 5a13d8c56a58..1050135f3158 100644 --- a/www/chromium/files/patch-base_process_process__unittest.cc +++ b/www/chromium/files/patch-base_process_process__unittest.cc @@ -1,6 +1,6 @@ ---- base/process/process_unittest.cc.orig 2024-03-22 08:19:40 UTC +--- base/process/process_unittest.cc.orig 2025-02-19 07:43:18 UTC +++ base/process/process_unittest.cc -@@ -199,7 +199,7 @@ TEST_F(ProcessTest, CreationTimeOtherProcess) { +@@ -202,7 +202,7 @@ TEST_F(ProcessTest, CreationTimeOtherProcess) { // was spawned and a time recorded after it was spawned. However, since the // base::Time and process creation clocks don't match, tolerate some error. constexpr base::TimeDelta kTolerance = diff --git a/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.cc b/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.cc index c7f79e3181fd..ac5d1fb806b4 100644 --- a/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.cc +++ b/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.cc @@ -1,4 +1,4 @@ ---- base/profiler/sampling_profiler_thread_token.cc.orig 2024-04-19 13:02:56 UTC +--- base/profiler/sampling_profiler_thread_token.cc.orig 2025-04-04 08:52:13 UTC +++ base/profiler/sampling_profiler_thread_token.cc @@ -6,7 +6,7 @@ @@ -11,7 +11,7 @@ #include "base/profiler/stack_base_address_posix.h" @@ -18,7 +18,7 @@ SamplingProfilerThreadToken GetSamplingProfilerCurrent PlatformThreadId id = PlatformThread::CurrentId(); - #if BUILDFLAG(IS_ANDROID) + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_APPLE) return {id, pthread_self()}; -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.h b/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.h index 9b96bc31d25b..d63b2aefb971 100644 --- a/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.h +++ b/www/chromium/files/patch-base_profiler_sampling__profiler__thread__token.h @@ -1,8 +1,8 @@ ---- base/profiler/sampling_profiler_thread_token.h.orig 2024-04-19 13:02:56 UTC +--- base/profiler/sampling_profiler_thread_token.h.orig 2025-04-04 08:52:13 UTC +++ base/profiler/sampling_profiler_thread_token.h @@ -13,7 +13,7 @@ - #if BUILDFLAG(IS_ANDROID) + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_APPLE) #include <pthread.h> -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) @@ -11,7 +11,7 @@ @@ -27,7 +27,7 @@ struct SamplingProfilerThreadToken { PlatformThreadId id; - #if BUILDFLAG(IS_ANDROID) + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_APPLE) pthread_t pthread_id; -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-base_profiler_stack__base__address__posix.cc b/www/chromium/files/patch-base_profiler_stack__base__address__posix.cc index 0804cf56fe6f..11ce03e2ac9a 100644 --- a/www/chromium/files/patch-base_profiler_stack__base__address__posix.cc +++ b/www/chromium/files/patch-base_profiler_stack__base__address__posix.cc @@ -1,6 +1,6 @@ ---- base/profiler/stack_base_address_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/profiler/stack_base_address_posix.cc.orig 2025-05-05 10:57:53 UTC +++ base/profiler/stack_base_address_posix.cc -@@ -17,6 +17,10 @@ +@@ -18,6 +18,10 @@ #include "base/files/scoped_file.h" #endif @@ -11,7 +11,7 @@ #if BUILDFLAG(IS_CHROMEOS) extern "C" void* __libc_stack_end; #endif -@@ -45,7 +49,21 @@ std::optional<uintptr_t> GetAndroidMainThreadStackBase +@@ -49,7 +53,21 @@ std::optional<uintptr_t> GetAndroidMainThreadStackBase #if !BUILDFLAG(IS_LINUX) uintptr_t GetThreadStackBaseAddressImpl(pthread_t pthread_id) { @@ -33,7 +33,7 @@ // pthread_getattr_np will crash on ChromeOS & Linux if we are in the sandbox // and pthread_id refers to a different thread, due to the use of // sched_getaffinity(). -@@ -58,12 +76,14 @@ uintptr_t GetThreadStackBaseAddressImpl(pthread_t pthr +@@ -62,12 +80,14 @@ uintptr_t GetThreadStackBaseAddressImpl(pthread_t pthr << logging::SystemErrorCodeToString(result); // See crbug.com/617730 for limitations of this approach on Linux-like // systems. @@ -48,12 +48,12 @@ const uintptr_t base_address = reinterpret_cast<uintptr_t>(address) + size; return base_address; } -@@ -80,7 +100,7 @@ std::optional<uintptr_t> GetThreadStackBaseAddress(Pla +@@ -84,7 +104,7 @@ std::optional<uintptr_t> GetThreadStackBaseAddress(Pla // trying to work around the problem. return std::nullopt; #else -- const bool is_main_thread = id == GetCurrentProcId(); -+ const bool is_main_thread = id == checked_cast<PlatformThreadId>(GetCurrentProcId()); +- const bool is_main_thread = id.raw() == GetCurrentProcId(); ++ const bool is_main_thread = id.raw() == (checked_cast<uint64_t>(GetCurrentProcId())); if (is_main_thread) { #if BUILDFLAG(IS_ANDROID) // The implementation of pthread_getattr_np() in Bionic reads proc/self/maps diff --git a/www/chromium/files/patch-base_profiler_stack__sampling__profiler__test__util.cc b/www/chromium/files/patch-base_profiler_stack__sampling__profiler__test__util.cc index 9779c7b34427..c8ce97140751 100644 --- a/www/chromium/files/patch-base_profiler_stack__sampling__profiler__test__util.cc +++ b/www/chromium/files/patch-base_profiler_stack__sampling__profiler__test__util.cc @@ -1,6 +1,6 @@ ---- base/profiler/stack_sampling_profiler_test_util.cc.orig 2024-04-19 13:02:56 UTC +--- base/profiler/stack_sampling_profiler_test_util.cc.orig 2025-03-05 08:14:56 UTC +++ base/profiler/stack_sampling_profiler_test_util.cc -@@ -37,7 +37,7 @@ +@@ -50,7 +50,7 @@ // Fortunately, it provides _alloca, which functions identically. #include <malloc.h> #define alloca _alloca diff --git a/www/chromium/files/patch-base_profiler_stack__sampling__profiler__unittest.cc b/www/chromium/files/patch-base_profiler_stack__sampling__profiler__unittest.cc index e2957f5e2403..79d00d56fd99 100644 --- a/www/chromium/files/patch-base_profiler_stack__sampling__profiler__unittest.cc +++ b/www/chromium/files/patch-base_profiler_stack__sampling__profiler__unittest.cc @@ -1,9 +1,9 @@ ---- base/profiler/stack_sampling_profiler_unittest.cc.orig 2024-03-22 08:19:40 UTC +--- base/profiler/stack_sampling_profiler_unittest.cc.orig 2025-04-04 08:52:13 UTC +++ base/profiler/stack_sampling_profiler_unittest.cc -@@ -42,7 +42,7 @@ +@@ -47,7 +47,7 @@ + #include <intrin.h> #include <malloc.h> - #include <windows.h> -#else +#elif !BUILDFLAG(IS_BSD) #include <alloca.h> diff --git a/www/chromium/files/patch-base_profiler_thread__delegate__posix.cc b/www/chromium/files/patch-base_profiler_thread__delegate__posix.cc index 3bbeceda7a02..251aa5482549 100644 --- a/www/chromium/files/patch-base_profiler_thread__delegate__posix.cc +++ b/www/chromium/files/patch-base_profiler_thread__delegate__posix.cc @@ -1,6 +1,6 @@ ---- base/profiler/thread_delegate_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/profiler/thread_delegate_posix.cc.orig 2025-04-04 08:52:13 UTC +++ base/profiler/thread_delegate_posix.cc -@@ -14,7 +14,7 @@ +@@ -15,7 +15,7 @@ #include "base/process/process_handle.h" #include "build/build_config.h" @@ -9,7 +9,7 @@ #include "base/profiler/stack_base_address_posix.h" #endif -@@ -23,7 +23,7 @@ namespace base { +@@ -24,7 +24,7 @@ namespace base { std::unique_ptr<ThreadDelegatePosix> ThreadDelegatePosix::Create( SamplingProfilerThreadToken thread_token) { std::optional<uintptr_t> base_address; diff --git a/www/chromium/files/patch-base_rand__util.h b/www/chromium/files/patch-base_rand__util.h index 49fb9cdeae61..239d6d1782af 100644 --- a/www/chromium/files/patch-base_rand__util.h +++ b/www/chromium/files/patch-base_rand__util.h @@ -1,6 +1,6 @@ ---- base/rand_util.h.orig 2024-02-23 21:04:38 UTC +--- base/rand_util.h.orig 2025-05-05 10:57:53 UTC +++ base/rand_util.h -@@ -149,7 +149,7 @@ void RandomShuffle(Itr first, Itr last) { +@@ -213,7 +213,7 @@ void RandomShuffle(Itr first, Itr last) { std::shuffle(first, last, RandomBitGenerator()); } diff --git a/www/chromium/files/patch-base_rand__util__posix.cc b/www/chromium/files/patch-base_rand__util__posix.cc index 1b2a99d867ab..2fdaf4b8cc62 100644 --- a/www/chromium/files/patch-base_rand__util__posix.cc +++ b/www/chromium/files/patch-base_rand__util__posix.cc @@ -1,6 +1,6 @@ ---- base/rand_util_posix.cc.orig 2024-03-22 08:19:40 UTC +--- base/rand_util_posix.cc.orig 2025-05-05 10:57:53 UTC +++ base/rand_util_posix.cc -@@ -23,7 +23,7 @@ +@@ -29,7 +29,7 @@ #include "base/time/time.h" #include "build/build_config.h" @@ -8,8 +8,8 @@ +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && !BUILDFLAG(IS_NACL) && !BUILDFLAG(IS_BSD) #include "third_party/lss/linux_syscall_support.h" #elif BUILDFLAG(IS_MAC) - // TODO(crbug.com/995996): Waiting for this header to appear in the iOS SDK. -@@ -40,6 +40,7 @@ namespace base { + // TODO(crbug.com/40641285): Waiting for this header to appear in the iOS SDK. +@@ -45,6 +45,7 @@ namespace base { namespace { @@ -17,7 +17,7 @@ #if BUILDFLAG(IS_AIX) // AIX has no 64-bit support for O_CLOEXEC. static constexpr int kOpenFlags = O_RDONLY; -@@ -64,10 +65,11 @@ class URandomFd { +@@ -69,10 +70,11 @@ class URandomFd { private: const int fd_; }; @@ -27,18 +27,18 @@ BUILDFLAG(IS_ANDROID)) && \ - !BUILDFLAG(IS_NACL) + !BUILDFLAG(IS_NACL) && !BUILDFLAG(IS_BSD) - // TODO(pasko): Unify reading kernel version numbers in: - // mojo/core/channel_linux.cc - // chrome/browser/android/seccomp_support_detector.cc -@@ -177,6 +179,7 @@ bool UseBoringSSLForRandBytes() { + + bool KernelSupportsGetRandom() { + return base::SysInfo::KernelVersionNumber::Current() >= +@@ -129,6 +131,7 @@ bool UseBoringSSLForRandBytes() { namespace { - void RandBytes(span<uint8_t> output, bool avoid_allocation) { + void RandBytesInternal(span<uint8_t> output, bool avoid_allocation) { +#if !BUILDFLAG(IS_BSD) #if !BUILDFLAG(IS_NACL) // The BoringSSL experiment takes priority over everything else. if (!avoid_allocation && internal::UseBoringSSLForRandBytes()) { -@@ -215,6 +218,9 @@ void RandBytes(span<uint8_t> output, bool avoid_alloca +@@ -163,6 +166,9 @@ void RandBytesInternal(span<uint8_t> output, bool avoi const int urandom_fd = GetUrandomFD(); const bool success = ReadFromFD(urandom_fd, as_writable_chars(output)); CHECK(success); @@ -48,8 +48,8 @@ } } // namespace -@@ -239,9 +245,11 @@ void RandBytes(void* output, size_t output_length) { - RandBytes(make_span(static_cast<uint8_t*>(output), output_length)); +@@ -182,9 +188,11 @@ void RandBytes(span<uint8_t> output) { + RandBytesInternal(output, /*avoid_allocation=*/false); } +#if !BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-base_strings_safe__sprintf__unittest.cc b/www/chromium/files/patch-base_strings_safe__sprintf__unittest.cc index bc70a714257b..2ab08a15c315 100644 --- a/www/chromium/files/patch-base_strings_safe__sprintf__unittest.cc +++ b/www/chromium/files/patch-base_strings_safe__sprintf__unittest.cc @@ -1,6 +1,6 @@ ---- base/strings/safe_sprintf_unittest.cc.orig 2023-03-09 06:31:50 UTC +--- base/strings/safe_sprintf_unittest.cc.orig 2025-05-28 14:55:43 UTC +++ base/strings/safe_sprintf_unittest.cc -@@ -733,6 +733,7 @@ TEST(SafeSPrintfTest, EmbeddedNul) { +@@ -746,6 +746,7 @@ TEST(SafeSPrintfTest, EmbeddedNul) { #endif } @@ -8,7 +8,7 @@ TEST(SafeSPrintfTest, EmitNULL) { char buf[40]; #if defined(__GNUC__) -@@ -749,6 +750,7 @@ TEST(SafeSPrintfTest, EmitNULL) { +@@ -762,6 +763,7 @@ TEST(SafeSPrintfTest, EmitNULL) { #pragma GCC diagnostic pop #endif } diff --git a/www/chromium/files/patch-base_synchronization_cancelable__event.h b/www/chromium/files/patch-base_synchronization_cancelable__event.h new file mode 100644 index 000000000000..bad15aaabf28 --- /dev/null +++ b/www/chromium/files/patch-base_synchronization_cancelable__event.h @@ -0,0 +1,20 @@ +--- base/synchronization/cancelable_event.h.orig 2025-02-19 07:43:18 UTC ++++ base/synchronization/cancelable_event.h +@@ -11,7 +11,7 @@ + + #if BUILDFLAG(IS_WIN) + #include <windows.h> +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include <semaphore.h> + #else + #include "base/synchronization/waitable_event.h" +@@ -49,7 +49,7 @@ class BASE_EXPORT CancelableEvent { + + #if BUILDFLAG(IS_WIN) + using NativeHandle = HANDLE; +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + using NativeHandle = sem_t; + #else + using NativeHandle = WaitableEvent; diff --git a/www/chromium/files/patch-base_synchronization_lock__impl.h b/www/chromium/files/patch-base_synchronization_lock__impl.h index 6559c634202b..c00c584359ff 100644 --- a/www/chromium/files/patch-base_synchronization_lock__impl.h +++ b/www/chromium/files/patch-base_synchronization_lock__impl.h @@ -1,6 +1,6 @@ ---- base/synchronization/lock_impl.h.orig 2024-04-19 13:02:56 UTC +--- base/synchronization/lock_impl.h.orig 2025-05-05 10:57:53 UTC +++ base/synchronization/lock_impl.h -@@ -107,6 +107,10 @@ void LockImpl::Unlock() { +@@ -110,6 +110,10 @@ void LockImpl::Unlock() { } #elif BUILDFLAG(IS_POSIX) || BUILDFLAG(IS_FUCHSIA) @@ -11,7 +11,7 @@ #if DCHECK_IS_ON() BASE_EXPORT void dcheck_trylock_result(int rv); -@@ -127,6 +131,9 @@ void LockImpl::Unlock() { +@@ -130,6 +134,9 @@ void LockImpl::Unlock() { dcheck_unlock_result(rv); #endif } diff --git a/www/chromium/files/patch-base_syslog__logging.cc b/www/chromium/files/patch-base_syslog__logging.cc index 3cf333be003d..f41d9e4dced1 100644 --- a/www/chromium/files/patch-base_syslog__logging.cc +++ b/www/chromium/files/patch-base_syslog__logging.cc @@ -1,4 +1,4 @@ ---- base/syslog_logging.cc.orig 2024-03-22 08:19:40 UTC +--- base/syslog_logging.cc.orig 2025-02-19 07:43:18 UTC +++ base/syslog_logging.cc @@ -17,7 +17,7 @@ #include "base/strings/string_util.h" @@ -9,10 +9,10 @@ // <syslog.h> defines LOG_INFO, LOG_WARNING macros that could conflict with // base::LOG_INFO, base::LOG_WARNING. #include <syslog.h> -@@ -149,7 +149,7 @@ EventLogMessage::~EventLogMessage() { - - if (user_sid != nullptr) +@@ -151,7 +151,7 @@ EventLogMessage::~EventLogMessage() { + if (user_sid != nullptr) { ::LocalFree(user_sid); + } -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) const char kEventSource[] = "chrome"; diff --git a/www/chromium/files/patch-base_system_sys__info.cc b/www/chromium/files/patch-base_system_sys__info.cc index 99d66657e417..42c21c63cf1c 100644 --- a/www/chromium/files/patch-base_system_sys__info.cc +++ b/www/chromium/files/patch-base_system_sys__info.cc @@ -1,6 +1,6 @@ ---- base/system/sys_info.cc.orig 2023-12-10 06:10:27 UTC +--- base/system/sys_info.cc.orig 2025-03-05 08:14:56 UTC +++ base/system/sys_info.cc -@@ -225,7 +225,7 @@ std::string SysInfo::HardwareModelName() { +@@ -224,7 +224,7 @@ std::string SysInfo::SocManufacturer() { #endif void SysInfo::GetHardwareInfo(base::OnceCallback<void(HardwareInfo)> callback) { diff --git a/www/chromium/files/patch-base_system_sys__info.h b/www/chromium/files/patch-base_system_sys__info.h index b7ab4e2fdd19..4da2a17d13d6 100644 --- a/www/chromium/files/patch-base_system_sys__info.h +++ b/www/chromium/files/patch-base_system_sys__info.h @@ -1,6 +1,6 @@ ---- base/system/sys_info.h.orig 2024-04-19 13:02:56 UTC +--- base/system/sys_info.h.orig 2025-05-05 10:57:53 UTC +++ base/system/sys_info.h -@@ -322,6 +322,8 @@ class BASE_EXPORT SysInfo { +@@ -355,6 +355,8 @@ class BASE_EXPORT SysInfo { static void ResetCpuSecurityMitigationsEnabledForTesting(); #endif @@ -9,7 +9,7 @@ private: friend class test::ScopedAmountOfPhysicalMemoryOverride; FRIEND_TEST_ALL_PREFIXES(SysInfoTest, AmountOfAvailablePhysicalMemory); -@@ -334,7 +336,7 @@ class BASE_EXPORT SysInfo { +@@ -367,7 +369,7 @@ class BASE_EXPORT SysInfo { static HardwareInfo GetHardwareInfoSync(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ diff --git a/www/chromium/files/patch-base_system_sys__info__freebsd.cc b/www/chromium/files/patch-base_system_sys__info__freebsd.cc index 81e026100278..52441554330f 100644 --- a/www/chromium/files/patch-base_system_sys__info__freebsd.cc +++ b/www/chromium/files/patch-base_system_sys__info__freebsd.cc @@ -1,6 +1,6 @@ ---- base/system/sys_info_freebsd.cc.orig 2022-09-01 17:22:07 UTC +--- base/system/sys_info_freebsd.cc.orig 2024-10-22 08:31:56 UTC +++ base/system/sys_info_freebsd.cc -@@ -9,30 +9,106 @@ +@@ -9,28 +9,103 @@ #include <sys/sysctl.h> #include "base/notreached.h" @@ -21,7 +21,7 @@ + } + return ncpu; +} -+ ++ +uint64_t SysInfo::AmountOfPhysicalMemoryImpl() { + int pages, page_size, r = 0; size_t size = sizeof(pages); @@ -31,12 +31,11 @@ + + if (r == 0) + r = sysctlbyname("vm.stats.vm.v_page_count", &pages, &size, NULL, 0); -+ if (r == 0) ++ if (r == 0) + r = sysctlbyname("vm.stats.vm.v_page_size", &page_size, &size, NULL, 0); + + if (r == -1) { NOTREACHED(); - return 0; } - return static_cast<int64_t>(pages) * page_size; + @@ -48,7 +47,7 @@ + unsigned int pgfree, pginact, pgcache; + size_t size = sizeof(page_size); + size_t szpg = sizeof(pgfree); -+ ++ + if (r == 0) + r = sysctlbyname("vm.stats.vm.v_page_size", &page_size, &size, NULL, 0); + if (r == 0) @@ -94,9 +93,7 @@ + if (sysctlbyname("kern.ipc.shmmax", &limit, &size, NULL, 0) < 0) { NOTREACHED(); - return 0; } -+ return static_cast<uint64_t>(limit); +} + diff --git a/www/chromium/files/patch-base_system_sys__info__openbsd.cc b/www/chromium/files/patch-base_system_sys__info__openbsd.cc index 0821a62e1fdb..098611853d93 100644 --- a/www/chromium/files/patch-base_system_sys__info__openbsd.cc +++ b/www/chromium/files/patch-base_system_sys__info__openbsd.cc @@ -1,14 +1,6 @@ ---- base/system/sys_info_openbsd.cc.orig 2024-02-23 21:04:38 UTC +--- base/system/sys_info_openbsd.cc.orig 2025-02-19 07:43:18 UTC +++ base/system/sys_info_openbsd.cc -@@ -3,7 +3,6 @@ - // found in the LICENSE file. - - #include "base/system/sys_info.h" -- - #include <stddef.h> - #include <stdint.h> - #include <sys/param.h> -@@ -12,6 +11,7 @@ +@@ -12,6 +12,7 @@ #include "base/notreached.h" #include "base/posix/sysctl.h" @@ -16,7 +8,7 @@ namespace { -@@ -27,9 +27,14 @@ uint64_t AmountOfMemory(int pages_name) { +@@ -28,9 +29,14 @@ uint64_t AmountOfMemory(int pages_name) { namespace base { @@ -32,7 +24,7 @@ int ncpu; size_t size = sizeof(ncpu); if (sysctl(mib, std::size(mib), &ncpu, &size, NULL, 0) < 0) { -@@ -41,10 +46,26 @@ int SysInfo::NumberOfProcessors() { +@@ -41,10 +47,26 @@ int SysInfo::NumberOfProcessors() { // static uint64_t SysInfo::AmountOfPhysicalMemoryImpl() { @@ -47,12 +39,12 @@ +std::string SysInfo::CPUModelName() { + int mib[] = {CTL_HW, HW_MODEL}; + size_t len = std::size(cpumodel); -+ ++ + if (cpumodel[0] == '\0') { + if (sysctl(mib, std::size(mib), cpumodel, &len, NULL, 0) < 0) + return std::string(); + } -+ ++ + return std::string(cpumodel, len - 1); +} + @@ -60,7 +52,7 @@ uint64_t SysInfo::AmountOfAvailablePhysicalMemoryImpl() { // We should add inactive file-backed memory also but there is no such // information from OpenBSD unfortunately. -@@ -56,16 +77,28 @@ uint64_t SysInfo::MaxSharedMemorySize() { +@@ -56,15 +78,27 @@ uint64_t SysInfo::MaxSharedMemorySize() { int mib[] = {CTL_KERN, KERN_SHMINFO, KERN_SHMINFO_SHMMAX}; size_t limit; size_t size = sizeof(limit); @@ -69,7 +61,6 @@ + goto out; if (sysctl(mib, std::size(mib), &limit, &size, NULL, 0) < 0) { NOTREACHED(); - return 0; } - return static_cast<uint64_t>(limit); + shmmax = static_cast<uint64_t>(limit); diff --git a/www/chromium/files/patch-base_system_sys__info__posix.cc b/www/chromium/files/patch-base_system_sys__info__posix.cc index 377a5e6c709e..e229baa6f240 100644 --- a/www/chromium/files/patch-base_system_sys__info__posix.cc +++ b/www/chromium/files/patch-base_system_sys__info__posix.cc @@ -1,6 +1,6 @@ ---- base/system/sys_info_posix.cc.orig 2024-03-22 08:19:40 UTC +--- base/system/sys_info_posix.cc.orig 2025-05-05 10:57:53 UTC +++ base/system/sys_info_posix.cc -@@ -118,7 +118,7 @@ bool GetDiskSpaceInfo(const base::FilePath& path, +@@ -143,7 +143,7 @@ void GetKernelVersionNumbers(int32_t* major_version, namespace base { @@ -9,7 +9,7 @@ // static int SysInfo::NumberOfProcessors() { #if BUILDFLAG(IS_MAC) -@@ -175,7 +175,7 @@ int SysInfo::NumberOfProcessors() { +@@ -199,7 +199,7 @@ int SysInfo::NumberOfProcessors() { return cached_num_cpus; } @@ -18,7 +18,7 @@ // static uint64_t SysInfo::AmountOfVirtualMemory() { -@@ -265,6 +265,8 @@ std::string SysInfo::OperatingSystemArchitecture() { +@@ -285,6 +285,8 @@ std::string SysInfo::OperatingSystemArchitecture() { arch = "x86"; } else if (arch == "amd64") { arch = "x86_64"; diff --git a/www/chromium/files/patch-base_system_sys__info__unittest.cc b/www/chromium/files/patch-base_system_sys__info__unittest.cc index 694323db9a18..e783d88c4a07 100644 --- a/www/chromium/files/patch-base_system_sys__info__unittest.cc +++ b/www/chromium/files/patch-base_system_sys__info__unittest.cc @@ -1,6 +1,6 @@ ---- base/system/sys_info_unittest.cc.orig 2024-04-19 13:02:56 UTC +--- base/system/sys_info_unittest.cc.orig 2024-08-26 12:06:38 UTC +++ base/system/sys_info_unittest.cc -@@ -264,12 +264,16 @@ TEST_F(SysInfoTest, GetHardwareInfo) { +@@ -265,12 +265,16 @@ TEST_F(SysInfoTest, GetHardwareInfo) { EXPECT_TRUE(IsStringUTF8(hardware_info->model)); bool empty_result_expected = #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN) || \ diff --git a/www/chromium/files/patch-base_task_thread__pool_environment__config__unittest.cc b/www/chromium/files/patch-base_task_thread__pool_environment__config__unittest.cc index abb639bc986d..785c54eb3ae6 100644 --- a/www/chromium/files/patch-base_task_thread__pool_environment__config__unittest.cc +++ b/www/chromium/files/patch-base_task_thread__pool_environment__config__unittest.cc @@ -1,11 +1,20 @@ ---- base/task/thread_pool/environment_config_unittest.cc.orig 2022-08-31 12:19:35 UTC +--- base/task/thread_pool/environment_config_unittest.cc.orig 2025-05-05 10:57:53 UTC +++ base/task/thread_pool/environment_config_unittest.cc -@@ -15,7 +15,7 @@ TEST(ThreadPoolEnvironmentConfig, CanUseBackgroundPrio - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) - EXPECT_TRUE(CanUseBackgroundThreadTypeForWorkerThread()); - #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || \ +@@ -21,7 +21,7 @@ TEST(ThreadPoolEnvironmentConfig, CanUseBackgroundPrio + base::FeatureList::IsEnabled( + FeatureControllingBackgroundPriorityWorkerThreads())); + #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_NACL) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_NACL) || BUILDFLAG(IS_BSD) EXPECT_FALSE(CanUseBackgroundThreadTypeForWorkerThread()); #else #error Platform doesn't match any block +@@ -30,7 +30,7 @@ TEST(ThreadPoolEnvironmentConfig, CanUseBackgroundPrio + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_ANDROID) + EXPECT_TRUE(CanUseUtilityThreadTypeForWorkerThread()); + #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_NACL) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_NACL) || BUILDFLAG(IS_BSD) + EXPECT_FALSE(CanUseUtilityThreadTypeForWorkerThread()); + #else + #error Platform doesn't match any block diff --git a/www/chromium/files/patch-base_test_launcher_test__launcher.cc b/www/chromium/files/patch-base_test_launcher_test__launcher.cc index 2e91e2f920e1..235bf52bd415 100644 --- a/www/chromium/files/patch-base_test_launcher_test__launcher.cc +++ b/www/chromium/files/patch-base_test_launcher_test__launcher.cc @@ -1,6 +1,6 @@ ---- base/test/launcher/test_launcher.cc.orig 2024-01-30 07:53:34 UTC +--- base/test/launcher/test_launcher.cc.orig 2025-04-04 08:52:13 UTC +++ base/test/launcher/test_launcher.cc -@@ -69,6 +69,7 @@ +@@ -73,6 +73,7 @@ #include "testing/gtest/include/gtest/gtest.h" #if BUILDFLAG(IS_POSIX) diff --git a/www/chromium/files/patch-base_test_test__file__util__linux.cc b/www/chromium/files/patch-base_test_test__file__util__linux.cc index f064d0c19cae..8b96dde81baf 100644 --- a/www/chromium/files/patch-base_test_test__file__util__linux.cc +++ b/www/chromium/files/patch-base_test_test__file__util__linux.cc @@ -1,12 +1,13 @@ ---- base/test/test_file_util_linux.cc.orig 2023-09-13 12:11:42 UTC +--- base/test/test_file_util_linux.cc.orig 2025-02-19 07:43:18 UTC +++ base/test/test_file_util_linux.cc -@@ -54,8 +54,10 @@ bool EvictFileFromSystemCache(const FilePath& file) { - return false; - if (fdatasync(fd.get()) != 0) +@@ -56,9 +56,11 @@ bool EvictFileFromSystemCache(const FilePath& file) { + if (fdatasync(fd.get()) != 0) { return false; + } +#if !BUILDFLAG(IS_BSD) - if (posix_fadvise(fd.get(), 0, 0, POSIX_FADV_DONTNEED) != 0) + if (posix_fadvise(fd.get(), 0, 0, POSIX_FADV_DONTNEED) != 0) { return false; + } +#endif return true; } diff --git a/www/chromium/files/patch-base_test_test__file__util__posix.cc b/www/chromium/files/patch-base_test_test__file__util__posix.cc index 044e4903e8b6..5eb9327a367b 100644 --- a/www/chromium/files/patch-base_test_test__file__util__posix.cc +++ b/www/chromium/files/patch-base_test_test__file__util__posix.cc @@ -1,6 +1,6 @@ ---- base/test/test_file_util_posix.cc.orig 2024-03-22 08:19:40 UTC +--- base/test/test_file_util_posix.cc.orig 2025-02-19 07:43:18 UTC +++ base/test/test_file_util_posix.cc -@@ -89,7 +89,7 @@ void SyncPageCacheToDisk() { +@@ -93,7 +93,7 @@ void SyncPageCacheToDisk() { } #if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_APPLE) && \ diff --git a/www/chromium/files/patch-base_threading_hang__watcher.cc b/www/chromium/files/patch-base_threading_hang__watcher.cc deleted file mode 100644 index a32aef72b4d9..000000000000 --- a/www/chromium/files/patch-base_threading_hang__watcher.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- base/threading/hang_watcher.cc.orig 2024-03-22 08:19:40 UTC -+++ base/threading/hang_watcher.cc -@@ -332,7 +332,7 @@ void HangWatcher::InitializeOnMainThread(ProcessType p - - bool enable_hang_watcher = base::FeatureList::IsEnabled(kEnableHangWatcher); - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && !BUILDFLAG(IS_BSD) - if (is_zygote_child) { - enable_hang_watcher = - enable_hang_watcher && diff --git a/www/chromium/files/patch-base_threading_platform__thread.h b/www/chromium/files/patch-base_threading_platform__thread.h index 27a45b8c27e2..03d6d6a1e5e4 100644 --- a/www/chromium/files/patch-base_threading_platform__thread.h +++ b/www/chromium/files/patch-base_threading_platform__thread.h @@ -1,11 +1,11 @@ ---- base/threading/platform_thread.h.orig 2024-04-19 13:02:56 UTC +--- base/threading/platform_thread.h.orig 2025-04-04 08:52:13 UTC +++ base/threading/platform_thread.h -@@ -46,6 +46,8 @@ typedef DWORD PlatformThreadId; - typedef zx_koid_t PlatformThreadId; +@@ -55,6 +55,8 @@ class BASE_EXPORT PlatformThreadId { + using UnderlyingType = zx_koid_t; #elif BUILDFLAG(IS_APPLE) - typedef mach_port_t PlatformThreadId; + using UnderlyingType = uint64_t; +#elif BUILDFLAG(IS_BSD) -+typedef uint64_t PlatformThreadId; ++ using UnderlyingType = uint64_t; #elif BUILDFLAG(IS_POSIX) - typedef pid_t PlatformThreadId; + using UnderlyingType = pid_t; #endif diff --git a/www/chromium/files/patch-base_threading_platform__thread__internal__posix.cc b/www/chromium/files/patch-base_threading_platform__thread__internal__posix.cc index 87a3c8373eb5..3ac11735f210 100644 --- a/www/chromium/files/patch-base_threading_platform__thread__internal__posix.cc +++ b/www/chromium/files/patch-base_threading_platform__thread__internal__posix.cc @@ -1,6 +1,6 @@ ---- base/threading/platform_thread_internal_posix.cc.orig 2024-03-22 08:19:40 UTC +--- base/threading/platform_thread_internal_posix.cc.orig 2025-03-05 08:14:56 UTC +++ base/threading/platform_thread_internal_posix.cc -@@ -42,7 +42,7 @@ ThreadPriorityForTest NiceValueToThreadPriorityForTest +@@ -41,7 +41,7 @@ ThreadPriorityForTest NiceValueToThreadPriorityForTest } int GetCurrentThreadNiceValue() { diff --git a/www/chromium/files/patch-base_threading_platform__thread__posix.cc b/www/chromium/files/patch-base_threading_platform__thread__posix.cc index eaa3272483dc..b8d88430f0d4 100644 --- a/www/chromium/files/patch-base_threading_platform__thread__posix.cc +++ b/www/chromium/files/patch-base_threading_platform__thread__posix.cc @@ -1,13 +1,12 @@ ---- base/threading/platform_thread_posix.cc.orig 2024-04-19 13:02:56 UTC +--- base/threading/platform_thread_posix.cc.orig 2025-04-04 08:52:13 UTC +++ base/threading/platform_thread_posix.cc -@@ -78,12 +78,12 @@ void* ThreadFunc(void* params) { - if (!thread_params->joinable) +@@ -79,11 +79,11 @@ void* ThreadFunc(void* params) { base::DisallowSingleton(); + } --#if BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && BUILDFLAG(USE_STARSCAN) -+#if BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && BUILDFLAG(USE_STARSCAN) && !BUILDFLAG(IS_BSD) - partition_alloc::internal::PCScan::NotifyThreadCreated( - partition_alloc::internal::GetStackPointer()); +-#if PA_BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) ++#if PA_BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && !BUILDFLAG(IS_BSD) + partition_alloc::internal::StackTopRegistry::Get().NotifyThreadCreated(); #endif -#if !BUILDFLAG(IS_NACL) @@ -15,16 +14,16 @@ #if BUILDFLAG(IS_APPLE) PlatformThread::SetCurrentThreadRealtimePeriodValue( delegate->GetRealtimePeriod()); -@@ -267,6 +267,8 @@ PlatformThreadId PlatformThreadBase::CurrentId() { - return reinterpret_cast<int32_t>(pthread_self()); +@@ -272,6 +272,8 @@ PlatformThreadId PlatformThreadBase::CurrentId() { + return PlatformThreadId(reinterpret_cast<int32_t>(pthread_self())); #elif BUILDFLAG(IS_POSIX) && BUILDFLAG(IS_AIX) - return pthread_self(); + return PlatformThreadId(pthread_self()); +#elif BUILDFLAG(IS_BSD) -+ return reinterpret_cast<uint64_t>(pthread_self()); ++ return PlatformThreadId(reinterpret_cast<uint64_t>(pthread_self())); #elif BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_AIX) - return reinterpret_cast<int64_t>(pthread_self()); + return PlatformThreadId(reinterpret_cast<int64_t>(pthread_self())); #endif -@@ -357,7 +359,7 @@ void PlatformThreadBase::Detach(PlatformThreadHandle t +@@ -365,7 +367,7 @@ void PlatformThreadBase::Detach(PlatformThreadHandle t // static bool PlatformThreadBase::CanChangeThreadType(ThreadType from, ThreadType to) { @@ -33,7 +32,7 @@ return false; #else if (from >= to) { -@@ -378,6 +380,9 @@ void SetCurrentThreadTypeImpl(ThreadType thread_type, +@@ -386,6 +388,9 @@ void SetCurrentThreadTypeImpl(ThreadType thread_type, MessagePumpType pump_type_hint) { #if BUILDFLAG(IS_NACL) NOTIMPLEMENTED(); @@ -41,9 +40,9 @@ +#elif BUILDFLAG(IS_BSD) + NOTIMPLEMENTED(); #else - if (internal::SetCurrentThreadTypeForPlatform(thread_type, pump_type_hint)) + if (internal::SetCurrentThreadTypeForPlatform(thread_type, pump_type_hint)) { return; -@@ -400,7 +405,7 @@ void SetCurrentThreadTypeImpl(ThreadType thread_type, +@@ -409,7 +414,7 @@ void SetCurrentThreadTypeImpl(ThreadType thread_type, // static ThreadPriorityForTest PlatformThreadBase::GetCurrentThreadPriorityForTest() { diff --git a/www/chromium/files/patch-base_threading_platform__thread__unittest.cc b/www/chromium/files/patch-base_threading_platform__thread__unittest.cc index 0ca9042b35b8..f0791854a0e8 100644 --- a/www/chromium/files/patch-base_threading_platform__thread__unittest.cc +++ b/www/chromium/files/patch-base_threading_platform__thread__unittest.cc @@ -1,6 +1,6 @@ ---- base/threading/platform_thread_unittest.cc.orig 2023-11-03 10:09:45 UTC +--- base/threading/platform_thread_unittest.cc.orig 2025-07-02 06:08:04 UTC +++ base/threading/platform_thread_unittest.cc -@@ -32,7 +32,7 @@ +@@ -36,7 +36,7 @@ #include "base/time/time.h" #endif @@ -9,7 +9,7 @@ #include <pthread.h> #include <sys/syscall.h> #include <sys/types.h> -@@ -423,7 +423,7 @@ TEST(PlatformThreadTest, +@@ -369,7 +369,7 @@ TEST(PlatformThreadTest, // and hardcodes what we know. Please inform scheduler-dev@chromium.org if this // proprerty changes for a given platform. TEST(PlatformThreadTest, CanChangeThreadType) { @@ -18,7 +18,7 @@ // On Ubuntu, RLIMIT_NICE and RLIMIT_RTPRIO are 0 by default, so we won't be // able to increase priority to any level unless we are root (euid == 0). bool kCanIncreasePriority = false; -@@ -706,12 +706,16 @@ INSTANTIATE_TEST_SUITE_P( +@@ -606,12 +606,16 @@ INSTANTIATE_TEST_SUITE_P( #endif // BUILDFLAG(IS_APPLE) @@ -29,9 +29,9 @@ bool IsTidCacheCorrect() { +#if BUILDFLAG(IS_BSD) -+ return PlatformThread::CurrentId() == reinterpret_cast<int64_t>(pthread_self()); ++ return PlatformThread::CurrentId().raw() == reinterpret_cast<int64_t>(pthread_self()); +#else - return PlatformThread::CurrentId() == syscall(__NR_gettid); + return PlatformThread::CurrentId().raw() == syscall(__NR_gettid); +#endif } diff --git a/www/chromium/files/patch-base_time_time__now__posix.cc b/www/chromium/files/patch-base_time_time__now__posix.cc new file mode 100644 index 000000000000..965e6c4e02c9 --- /dev/null +++ b/www/chromium/files/patch-base_time_time__now__posix.cc @@ -0,0 +1,11 @@ +--- base/time/time_now_posix.cc.orig 2025-01-15 09:18:26 UTC ++++ base/time/time_now_posix.cc +@@ -27,7 +27,7 @@ + #endif + + // NaCl doesn't support CLOCK_MONOTONIC_COARSE. +-#if BUILDFLAG(IS_NACL) ++#if BUILDFLAG(IS_NACL) || BUILDFLAG(IS_BSD) + #define TIMETICKS_LOW_RESOLUTION_CLOCK CLOCK_MONOTONIC + #else + #define TIMETICKS_LOW_RESOLUTION_CLOCK CLOCK_MONOTONIC_COARSE diff --git a/www/chromium/files/patch-base_trace__event_malloc__dump__provider.cc b/www/chromium/files/patch-base_trace__event_malloc__dump__provider.cc index f5a71b0579e1..d16f0a13265a 100644 --- a/www/chromium/files/patch-base_trace__event_malloc__dump__provider.cc +++ b/www/chromium/files/patch-base_trace__event_malloc__dump__provider.cc @@ -1,6 +1,6 @@ ---- base/trace_event/malloc_dump_provider.cc.orig 2024-04-19 13:02:56 UTC +--- base/trace_event/malloc_dump_provider.cc.orig 2025-07-02 06:08:04 UTC +++ base/trace_event/malloc_dump_provider.cc -@@ -24,6 +24,8 @@ +@@ -31,6 +31,8 @@ #if BUILDFLAG(IS_APPLE) #include <malloc/malloc.h> @@ -9,16 +9,16 @@ #else #include <malloc.h> #endif -@@ -181,7 +183,7 @@ void ReportAppleAllocStats(size_t* total_virtual_size, +@@ -180,7 +182,7 @@ void ReportAppleAllocStats(size_t* total_virtual_size, - #if (BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && BUILDFLAG(IS_ANDROID)) || \ - (!BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && !BUILDFLAG(IS_WIN) && \ + #if (PA_BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && BUILDFLAG(IS_ANDROID)) || \ + (!PA_BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC) && !BUILDFLAG(IS_WIN) && \ - !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_FUCHSIA)) + !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_BSD)) void ReportMallinfoStats(ProcessMemoryDump* pmd, size_t* total_virtual_size, size_t* resident_size, -@@ -366,6 +368,9 @@ bool MallocDumpProvider::OnMemoryDump(const MemoryDump +@@ -367,6 +369,9 @@ bool MallocDumpProvider::OnMemoryDump(const MemoryDump &allocated_objects_count); #elif BUILDFLAG(IS_FUCHSIA) // TODO(fuchsia): Port, see https://crbug.com/706592. diff --git a/www/chromium/files/patch-base_trace__event_memory__dump__manager.cc b/www/chromium/files/patch-base_trace__event_memory__dump__manager.cc index f1f228e38e7b..586f720f01cb 100644 --- a/www/chromium/files/patch-base_trace__event_memory__dump__manager.cc +++ b/www/chromium/files/patch-base_trace__event_memory__dump__manager.cc @@ -1,6 +1,6 @@ ---- base/trace_event/memory_dump_manager.cc.orig 2022-03-25 21:59:56 UTC +--- base/trace_event/memory_dump_manager.cc.orig 2025-03-05 08:14:56 UTC +++ base/trace_event/memory_dump_manager.cc -@@ -82,7 +82,7 @@ const char* const MemoryDumpManager::kSystemAllocatorP +@@ -78,7 +78,7 @@ const char* const MemoryDumpManager::kSystemAllocatorP #if defined(MALLOC_MEMORY_TRACING_SUPPORTED) MallocDumpProvider::kAllocatedObjects; #else diff --git a/www/chromium/files/patch-base_trace__event_process__memory__dump.cc b/www/chromium/files/patch-base_trace__event_process__memory__dump.cc index c27d7848a4e2..4bb28bf4429c 100644 --- a/www/chromium/files/patch-base_trace__event_process__memory__dump.cc +++ b/www/chromium/files/patch-base_trace__event_process__memory__dump.cc @@ -1,20 +1,20 @@ ---- base/trace_event/process_memory_dump.cc.orig 2024-04-19 13:02:56 UTC +--- base/trace_event/process_memory_dump.cc.orig 2025-03-05 08:14:56 UTC +++ base/trace_event/process_memory_dump.cc -@@ -113,7 +113,7 @@ std::optional<size_t> ProcessMemoryDump::CountResident +@@ -119,7 +119,7 @@ std::optional<size_t> ProcessMemoryDump::CountResident #if BUILDFLAG(IS_WIN) - std::unique_ptr<PSAPI_WORKING_SET_EX_INFORMATION[]> vec( - new PSAPI_WORKING_SET_EX_INFORMATION[max_vec_size]); + auto vec = + base::HeapArray<PSAPI_WORKING_SET_EX_INFORMATION>::WithSize(max_vec_size); -#elif BUILDFLAG(IS_APPLE) +#elif BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) - std::unique_ptr<char[]> vec(new char[max_vec_size]); + auto vec = base::HeapArray<char>::WithSize(max_vec_size); #elif BUILDFLAG(IS_POSIX) || BUILDFLAG(IS_FUCHSIA) - std::unique_ptr<unsigned char[]> vec(new unsigned char[max_vec_size]); -@@ -135,7 +135,7 @@ std::optional<size_t> ProcessMemoryDump::CountResident - - for (size_t i = 0; i < page_count; i++) + auto vec = base::HeapArray<unsigned char>::WithSize(max_vec_size); +@@ -143,7 +143,7 @@ std::optional<size_t> ProcessMemoryDump::CountResident + for (size_t i = 0; i < page_count; i++) { resident_page_count += vec[i].VirtualAttributes.Valid; + } -#elif BUILDFLAG(IS_FUCHSIA) +#elif BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/851760): Implement counting resident bytes. + // TODO(crbug.com/42050620): Implement counting resident bytes. // For now, log and avoid unused variable warnings. NOTIMPLEMENTED_LOG_ONCE(); diff --git a/www/chromium/files/patch-base_tracing_trace__time.cc b/www/chromium/files/patch-base_tracing_trace__time.cc index 36c6113518f4..2040b12690a7 100644 --- a/www/chromium/files/patch-base_tracing_trace__time.cc +++ b/www/chromium/files/patch-base_tracing_trace__time.cc @@ -1,6 +1,6 @@ ---- base/tracing/trace_time.cc.orig 2022-02-28 16:54:41 UTC +--- base/tracing/trace_time.cc.orig 2025-03-05 08:14:56 UTC +++ base/tracing/trace_time.cc -@@ -8,13 +8,17 @@ +@@ -8,12 +8,16 @@ #include "build/build_config.h" #include "third_party/perfetto/include/perfetto/base/time.h" @@ -8,8 +8,7 @@ +#define CLOCK_BOOTTIME CLOCK_UPTIME +#endif + - namespace base { - namespace tracing { + namespace base::tracing { int64_t TraceBootTicksNow() { // On Windows and Mac, TRACE_TIME_TICKS_NOW() behaves like boottime already. @@ -18,11 +17,4 @@ + BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) struct timespec ts; int res = clock_gettime(CLOCK_BOOTTIME, &ts); - if (res != -1) -@@ -24,4 +28,4 @@ int64_t TraceBootTicksNow() { - } - - } // namespace tracing --} // namespace base -\ No newline at end of file -+} // namespace base + if (res != -1) { diff --git a/www/chromium/files/patch-build_config_BUILD.gn b/www/chromium/files/patch-build_config_BUILD.gn index 2722052c9507..84a0fde9befa 100644 --- a/www/chromium/files/patch-build_config_BUILD.gn +++ b/www/chromium/files/patch-build_config_BUILD.gn @@ -1,6 +1,6 @@ ---- build/config/BUILD.gn.orig 2023-08-17 07:33:31 UTC +--- build/config/BUILD.gn.orig 2025-01-15 09:18:26 UTC +++ build/config/BUILD.gn -@@ -214,6 +214,10 @@ config("default_libs") { +@@ -215,6 +215,10 @@ config("default_libs") { # Targets should choose to explicitly link frameworks they require. Since # linking can have run-time side effects, nothing should be listed here. libs = [] diff --git a/www/chromium/files/patch-build_config_BUILDCONFIG.gn b/www/chromium/files/patch-build_config_BUILDCONFIG.gn index 9b8cdbc413ed..3749850480a4 100644 --- a/www/chromium/files/patch-build_config_BUILDCONFIG.gn +++ b/www/chromium/files/patch-build_config_BUILDCONFIG.gn @@ -1,4 +1,4 @@ ---- build/config/BUILDCONFIG.gn.orig 2023-01-11 09:17:16 UTC +--- build/config/BUILDCONFIG.gn.orig 2025-07-02 06:08:04 UTC +++ build/config/BUILDCONFIG.gn @@ -136,7 +136,8 @@ declare_args() { is_official_build = false @@ -10,7 +10,7 @@ (current_cpu != "s390x" && current_cpu != "s390" && current_cpu != "ppc64" && current_cpu != "ppc" && current_cpu != "mips" && current_cpu != "mips64" && -@@ -225,6 +226,10 @@ if (host_toolchain == "") { +@@ -235,6 +236,10 @@ if (host_toolchain == "") { host_toolchain = "//build/toolchain/aix:$host_cpu" } else if (host_os == "zos") { host_toolchain = "//build/toolchain/zos:$host_cpu" @@ -21,16 +21,16 @@ } else { assert(false, "Unsupported host_os: $host_os") } -@@ -268,6 +273,8 @@ if (target_os == "android") { - _default_toolchain = "//build/toolchain/aix:$target_cpu" - } else if (target_os == "zos") { - _default_toolchain = "//build/toolchain/zos:$target_cpu" +@@ -284,6 +289,8 @@ if (target_os == "android") { + assert( + false, + "emscripten is not a supported target_os. It is available only as secondary toolchain.") +} else if (target_os == "openbsd" || target_os == "freebsd") { + _default_toolchain = host_toolchain } else { assert(false, "Unsupported target_os: $target_os") } -@@ -302,7 +309,11 @@ is_android = current_os == "android" +@@ -318,7 +325,11 @@ is_android = current_os == "android" is_chromeos = current_os == "chromeos" is_fuchsia = current_os == "fuchsia" is_ios = current_os == "ios" @@ -42,4 +42,4 @@ +is_bsd = current_os == "openbsd" || current_os == "freebsd" is_mac = current_os == "mac" is_nacl = current_os == "nacl" - is_win = current_os == "win" || current_os == "winuwp" + is_wasm = current_os == "emscripten" diff --git a/www/chromium/files/patch-build_config_clang_BUILD.gn b/www/chromium/files/patch-build_config_clang_BUILD.gn index eb48e938557e..00cd3dbbf1cb 100644 --- a/www/chromium/files/patch-build_config_clang_BUILD.gn +++ b/www/chromium/files/patch-build_config_clang_BUILD.gn @@ -1,11 +1,16 @@ ---- build/config/clang/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- build/config/clang/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ build/config/clang/BUILD.gn -@@ -203,7 +203,7 @@ template("clang_lib") { +@@ -263,7 +263,12 @@ template("clang_lib") { # Adds a dependency on the Clang runtime library clang_rt.builtins. clang_lib("compiler_builtins") { -- if (!toolchain_has_rust) { -+ if (!toolchain_has_rust || is_bsd) { - # Since there's no Rust in the toolchain, there's no concern that we'll use - # the Rust stdlib's intrinsics here. - # +- if (is_mac) { ++ if (is_bsd) { ++ # Since there's no Rust in the toolchain, there's no concern that we'll use ++ # the Rust stdlib's intrinsics here. ++ # ++ # Don't define libname which makes this target do nothing. ++ } else if (is_mac) { + libname = "osx" + } else if (is_ios) { + if (target_platform == "iphoneos") { diff --git a/www/chromium/files/patch-build_config_compiler_BUILD.gn b/www/chromium/files/patch-build_config_compiler_BUILD.gn index 8b70ade32cb0..dcf99de92f05 100644 --- a/www/chromium/files/patch-build_config_compiler_BUILD.gn +++ b/www/chromium/files/patch-build_config_compiler_BUILD.gn @@ -1,6 +1,6 @@ ---- build/config/compiler/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- build/config/compiler/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ build/config/compiler/BUILD.gn -@@ -204,7 +204,7 @@ declare_args() { +@@ -199,7 +199,7 @@ declare_args() { # This greatly reduces the size of debug builds, at the cost of # debugging information which is required by some specialized # debugging tools. @@ -9,7 +9,7 @@ } declare_args() { -@@ -268,13 +268,16 @@ config("default_include_dirs") { +@@ -256,13 +256,16 @@ config("default_include_dirs") { # Compiler instrumentation can introduce dependencies in DSOs to symbols in # the executable they are loaded into, so they are unresolved at link-time. config("no_unresolved_symbols") { @@ -27,7 +27,7 @@ } # compiler --------------------------------------------------------------------- -@@ -515,6 +518,10 @@ config("compiler") { +@@ -521,6 +524,10 @@ config("compiler") { } } @@ -37,35 +37,53 @@ + # Linux-specific compiler flags setup. # ------------------------------------ - if (use_gold) { -@@ -590,7 +597,7 @@ config("compiler") { + if (use_icf && (!is_apple || use_lld)) { +@@ -581,7 +588,7 @@ config("compiler") { ldflags += [ "-Wl,-z,keep-text-section-prefix" ] } -- if (is_clang && !is_nacl && current_os != "zos") { -+ if (is_clang && !is_nacl && current_os != "zos" && !is_bsd) { +- if (is_clang && !is_nacl) { ++ if (is_clang && !is_nacl && !is_bsd) { cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] if (save_reproducers_on_lld_crash && use_lld) { ldflags += [ -@@ -1180,7 +1187,7 @@ config("compiler_cpu_abi") { +@@ -1233,7 +1240,7 @@ config("compiler_cpu_abi") { + # simplicity we always explicitly set the architecture. + if (current_cpu == "x64") { + if (is_clang && !is_android && !is_nacl && !is_fuchsia && +- !is_chromeos_device) { ++ !is_chromeos_device && !is_bsd) { + cflags += [ "--target=x86_64-unknown-linux-gnu" ] + ldflags += [ "--target=x86_64-unknown-linux-gnu" ] + } else { +@@ -1242,7 +1249,7 @@ config("compiler_cpu_abi") { + } + cflags += [ "-msse3" ] + } else if (current_cpu == "x86") { +- if (is_clang && !is_android && !is_nacl && !is_chromeos_device) { ++ if (is_clang && !is_android && !is_nacl && !is_chromeos_device && !is_bsd) { + cflags += [ "--target=i386-unknown-linux-gnu" ] + ldflags += [ "--target=i386-unknown-linux-gnu" ] + } else { +@@ -1256,7 +1263,7 @@ config("compiler_cpu_abi") { ] } } else if (current_cpu == "arm") { -- if (is_clang && !is_android && !is_nacl && -+ if (is_clang && !is_android && !is_nacl && !is_bsd && - !(is_chromeos_lacros && is_chromeos_device)) { +- if (is_clang && !is_android && !is_nacl && !is_chromeos_device) { ++ if (is_clang && !is_android && !is_nacl && !is_chromeos_device && !is_bsd) { cflags += [ "--target=arm-linux-gnueabihf" ] ldflags += [ "--target=arm-linux-gnueabihf" ] -@@ -1195,7 +1202,7 @@ config("compiler_cpu_abi") { - cflags += [ "-mtune=$arm_tune" ] + } +@@ -1271,7 +1278,7 @@ config("compiler_cpu_abi") { } } else if (current_cpu == "arm64") { -- if (is_clang && !is_android && !is_nacl && !is_fuchsia && -+ if (is_clang && !is_android && !is_nacl && !is_fuchsia && !is_bsd && - !(is_chromeos_lacros && is_chromeos_device)) { + if (is_clang && !is_android && !is_nacl && !is_fuchsia && +- !is_chromeos_device) { ++ !is_chromeos_device && !is_bsd) { cflags += [ "--target=aarch64-linux-gnu" ] ldflags += [ "--target=aarch64-linux-gnu" ] -@@ -1530,7 +1537,7 @@ config("compiler_deterministic") { + } +@@ -1617,7 +1624,7 @@ config("compiler_deterministic") { # different build directory like "out/feature_a" and "out/feature_b" if # we build same files with same compile flag. # Other paths are already given in relative, no need to normalize them. @@ -74,44 +92,35 @@ # TODO(https://crbug.com/1231236): Use -ffile-compilation-dir= here. cflags += [ "-Xclang", -@@ -1582,7 +1589,7 @@ config("compiler_deterministic") { +@@ -1683,7 +1690,7 @@ config("compiler_deterministic") { } config("clang_revision") { -- if (is_clang && clang_base_path == default_clang_base_path) { -+ if (is_clang && !is_bsd && clang_base_path == default_clang_base_path) { - update_args = [ - "--print-revision", - "--verify-version=$clang_version", -@@ -1890,9 +1897,6 @@ config("default_warnings") { +- if (is_clang && clang_base_path == default_clang_base_path && ++ if (is_clang && !is_bsd && clang_base_path == default_clang_base_path && + current_os != "zos") { + _perform_consistency_checks = current_toolchain == default_toolchain + if (llvm_force_head_revision) { +@@ -1775,7 +1782,7 @@ config("clang_revision") { + # e.g. by setting in the the project's .gn file. + config("clang_warning_suppression") { + # Some build configs use older versions of clang that don't support WSMs +- if (!is_nacl && default_toolchain != "//build/toolchain/cros:target" && ++ if (!is_bsd && !is_nacl && default_toolchain != "//build/toolchain/cros:target" && + !llvm_android_mainline && is_clang && + clang_warning_suppression_file != "") { + from_build_root = +@@ -2134,9 +2141,6 @@ config("default_warnings") { - # TODO(crbug.com/1494809): Evaluate and possibly enable. - "-Wno-vla-extension", + # TODO(crbug.com/40284799): Fix and re-enable. + "-Wno-thread-safety-reference-return", - -- # TODO(https://crbug.com/1490607): Fix and re-enable. -- "-Wno-thread-safety-reference-return", +- # TODO(crbug.com/376641662): Fix and re-enable. +- "-Wno-nontrivial-memcall", ] cflags_cc += [ -@@ -1900,7 +1904,7 @@ config("default_warnings") { - "-Wenum-compare-conditional", - ] - -- if (!is_nacl) { -+ if (!is_nacl && !is_bsd) { - cflags_cc += [ - # TODO(https://crbug.com/1513724): Fix and re-enable. - "-Wno-c++11-narrowing-const-reference", -@@ -2089,7 +2093,7 @@ config("no_chromium_code") { - # third-party libraries. - "-Wno-c++11-narrowing", - ] -- if (!is_nacl) { -+ if (!is_nacl && !is_freebsd) { - cflags += [ - # Disabled for similar reasons as -Wunused-variable. - "-Wno-unused-but-set-variable", -@@ -2597,7 +2601,7 @@ config("afdo_optimize_size") { +@@ -2920,7 +2924,7 @@ config("afdo_optimize_size") { # There are some targeted places that AFDO regresses, so we provide a separate # config to allow AFDO to be disabled per-target. config("afdo") { @@ -120,7 +129,7 @@ cflags = [] if (clang_emit_debug_info_for_profiling) { # Add the following flags to generate debug info for profiling. -@@ -2624,7 +2628,7 @@ config("afdo") { +@@ -2947,7 +2951,7 @@ config("afdo") { cflags += [ "-Wno-backend-plugin" ] inputs = [ _clang_sample_profile ] } @@ -129,13 +138,12 @@ cflags = [ "-fauto-profile=${auto_profile_path}" ] inputs = [ auto_profile_path ] } -@@ -2788,7 +2792,8 @@ config("symbols") { - configs += [ "//build/config:compress_debug_sections" ] +@@ -3136,7 +3140,7 @@ config("symbols") { + cflags += [ "-gomit-unreferenced-methods" ] } -- if (is_clang && (!is_nacl || is_nacl_saigo) && current_os != "zos") { -+ if (is_clang && (!is_nacl || is_nacl_saigo) && current_os != "zos" && -+ !is_bsd) { +- if (is_clang && (!is_nacl || is_nacl_saigo)) { ++ if (is_clang && (!is_nacl || is_nacl_saigo) && !is_bsd) { if (is_apple) { - # TODO(https://crbug.com/1050118): Investigate missing debug info on mac. + # TODO(crbug.com/40117949): Investigate missing debug info on mac. # Make sure we don't use constructor homing on mac. diff --git a/www/chromium/files/patch-build_config_gcc_BUILD.gn b/www/chromium/files/patch-build_config_gcc_BUILD.gn new file mode 100644 index 000000000000..d2f81fde1c51 --- /dev/null +++ b/www/chromium/files/patch-build_config_gcc_BUILD.gn @@ -0,0 +1,13 @@ +--- build/config/gcc/BUILD.gn.orig 2025-01-15 09:18:26 UTC ++++ build/config/gcc/BUILD.gn +@@ -32,7 +32,9 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ if (!is_bsd) { ++ rustflags = [ "-Zdefault-visibility=hidden" ] ++ } + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { diff --git a/www/chromium/files/patch-build_config_linux_libdrm_BUILD.gn b/www/chromium/files/patch-build_config_linux_libdrm_BUILD.gn new file mode 100644 index 000000000000..feb6c3f3983f --- /dev/null +++ b/www/chromium/files/patch-build_config_linux_libdrm_BUILD.gn @@ -0,0 +1,11 @@ +--- build/config/linux/libdrm/BUILD.gn.orig 2025-01-15 09:18:26 UTC ++++ build/config/linux/libdrm/BUILD.gn +@@ -15,7 +15,7 @@ declare_args() { + } + + if (use_system_libdrm) { +- assert(!is_linux, "System libdrm is not supported in linux") ++# assert(!is_linux, "System libdrm is not supported in linux") + pkg_config("libdrm_config") { + packages = [ "libdrm" ] + } diff --git a/www/chromium/files/patch-build_config_ozone.gni b/www/chromium/files/patch-build_config_ozone.gni index 707fb6deb3d0..1510c61ec39a 100644 --- a/www/chromium/files/patch-build_config_ozone.gni +++ b/www/chromium/files/patch-build_config_ozone.gni @@ -1,9 +1,9 @@ ---- build/config/ozone.gni.orig 2023-10-11 18:22:24 UTC +--- build/config/ozone.gni.orig 2025-05-05 10:57:53 UTC +++ build/config/ozone.gni -@@ -84,7 +84,15 @@ declare_args() { - } else if (is_chromeos_lacros) { - ozone_platform = "wayland" - ozone_platform_wayland = true +@@ -80,7 +80,15 @@ declare_args() { + ozone_platform = "x11" + ozone_platform_drm = true + ozone_platform_x11 = true - } else if (is_linux) { + } else if (is_linux && !is_bsd) { + ozone_platform = "x11" diff --git a/www/chromium/files/patch-build_config_rust.gni b/www/chromium/files/patch-build_config_rust.gni index 324901afb617..b037f6e4a95b 100644 --- a/www/chromium/files/patch-build_config_rust.gni +++ b/www/chromium/files/patch-build_config_rust.gni @@ -1,13 +1,15 @@ ---- build/config/rust.gni.orig 2024-04-19 13:02:56 UTC +--- build/config/rust.gni.orig 2025-07-02 06:08:04 UTC +++ build/config/rust.gni -@@ -277,6 +277,10 @@ if (is_linux || is_chromeos) { +@@ -373,7 +373,11 @@ if (is_linux || is_chromeos) { } } +-if (toolchain_has_rust) { +if (is_bsd) { + rust_abi_target = string_replace(rust_abi_target, "linux-gnu", current_os) +} + - assert(!toolchain_has_rust || rust_abi_target != "") ++if (toolchain_has_rust && !is_bsd) { + assert(rust_abi_target != "") - # This variable is passed to the Rust libstd build. + _known_rust_target_triples_filepath = "//build/rust/known-target-triples.txt" diff --git a/www/chromium/files/patch-build_linux_unbundle_icu.gn b/www/chromium/files/patch-build_linux_unbundle_icu.gn index 8f61fffcf46b..571e7d758fad 100644 --- a/www/chromium/files/patch-build_linux_unbundle_icu.gn +++ b/www/chromium/files/patch-build_linux_unbundle_icu.gn @@ -1,4 +1,4 @@ ---- build/linux/unbundle/icu.gn.orig 2023-04-13 18:16:16 UTC +--- build/linux/unbundle/icu.gn.orig 2025-01-15 09:18:26 UTC +++ build/linux/unbundle/icu.gn @@ -17,6 +17,15 @@ config("icu_config") { "USING_SYSTEM_ICU=1", @@ -16,3 +16,28 @@ # U_EXPORT (defined in unicode/platform.h) is used to set public visibility # on classes through the U_COMMON_API and U_I18N_API macros (among others). # When linking against the system ICU library, we want its symbols to have +@@ -34,6 +43,9 @@ config("icu_config") { + # to define U_IMPORT to have the same value as U_EXPORT. For more details, + # please see: https://crbug.com/822820 + "U_IMPORT=U_EXPORT", ++ ++ # Unbreak with icu 76 where private symbols are picked up ++ "U_HIDE_DRAFT_API", + ] + } + +@@ -46,6 +58,14 @@ pkg_config("system_icuuc") { + } + + source_set("icui18n") { ++ deps = [ ":icui18n_shim" ] ++ public_configs = [ ++ ":icu_config", ++ ":system_icui18n", ++ ] ++} ++ ++source_set("icui18n_hidden_visibility") { + deps = [ ":icui18n_shim" ] + public_configs = [ + ":icu_config", diff --git a/www/chromium/files/patch-build_linux_unbundle_libevent.gn b/www/chromium/files/patch-build_linux_unbundle_libevent.gn deleted file mode 100644 index d5f276de574d..000000000000 --- a/www/chromium/files/patch-build_linux_unbundle_libevent.gn +++ /dev/null @@ -1,15 +0,0 @@ ---- build/linux/unbundle/libevent.gn.orig 2022-05-28 07:21:18 UTC -+++ build/linux/unbundle/libevent.gn -@@ -9,7 +9,12 @@ shim_headers("libevent_shim") { - headers = [ "event.h" ] - } - -+config("system_libevent") { -+ defines = [ "USE_SYSTEM_LIBEVENT=1" ] -+} -+ - source_set("libevent") { - deps = [ ":libevent_shim" ] - libs = [ "event" ] -+ public_configs = [ ":system_libevent" ] - } diff --git a/www/chromium/files/patch-build_linux_unbundle_libwebp.gn b/www/chromium/files/patch-build_linux_unbundle_libwebp.gn deleted file mode 100644 index e1ff6cffbd63..000000000000 --- a/www/chromium/files/patch-build_linux_unbundle_libwebp.gn +++ /dev/null @@ -1,27 +0,0 @@ ---- build/linux/unbundle/libwebp.gn.orig 2024-04-20 08:27:55 UTC -+++ build/linux/unbundle/libwebp.gn -@@ -22,6 +22,8 @@ shim_headers("libwebp_shim") { - "webp/mux.h", - "webp/mux_types.h", - "webp/types.h", -+ "webp/sharpyuv/sharpyuv.h", -+ "webp/sharpyuv/sharpyuv_csp.h", - ] - } - -@@ -30,6 +32,14 @@ source_set("libwebp_webp") { - public_configs = [ ":system_libwebp" ] - } - -+source_set("libwebp_sharpyuv") { -+ deps = [ ":libwebp_shim" ] -+ public_configs = [ ":system_libwebp" ] -+} -+ - group("libwebp") { -- deps = [ ":libwebp_webp" ] -+ deps = [ -+ ":libwebp_webp", -+ ":libwebp_sharpyuv", -+ ] - } diff --git a/www/chromium/files/patch-build_nocompile.gni b/www/chromium/files/patch-build_nocompile.gni new file mode 100644 index 000000000000..64296d2e06a3 --- /dev/null +++ b/www/chromium/files/patch-build_nocompile.gni @@ -0,0 +1,11 @@ +--- build/nocompile.gni.orig 2025-02-19 07:43:18 UTC ++++ build/nocompile.gni +@@ -55,7 +55,7 @@ if (is_win) { + } + + declare_args() { +- enable_nocompile_tests = is_clang && !is_nacl ++ enable_nocompile_tests = is_clang && !is_nacl && !is_bsd + } + + if (enable_nocompile_tests) { diff --git a/www/chromium/files/patch-build_rust_rust__bindgen.gni b/www/chromium/files/patch-build_rust_rust__bindgen.gni new file mode 100644 index 000000000000..38647579847e --- /dev/null +++ b/www/chromium/files/patch-build_rust_rust__bindgen.gni @@ -0,0 +1,19 @@ +--- build/rust/rust_bindgen.gni.orig 2025-01-15 09:18:26 UTC ++++ build/rust/rust_bindgen.gni +@@ -12,14 +12,14 @@ if (is_win) { + import("//build/toolchain/win/win_toolchain_data.gni") + } + +-_bindgen_path = "${rust_bindgen_root}/bin/bindgen" ++_bindgen_path = "${LOCALBASE}/bin/bindgen" + if (host_os == "win") { + _bindgen_path = "${_bindgen_path}.exe" + } + + # On Windows, the libclang.dll is beside the bindgen.exe, otherwise it is in + # ../lib. +-_libclang_path = rust_bindgen_root ++_libclang_path = "${LOCALBASE}/llvm${MODCLANG_VERSION}" + if (host_os == "win") { + _libclang_path += "/bin" + } else { diff --git a/www/chromium/files/patch-build_rust_rust__bindgen__generator.gni b/www/chromium/files/patch-build_rust_rust__bindgen__generator.gni new file mode 100644 index 000000000000..ac16ecb6e2d4 --- /dev/null +++ b/www/chromium/files/patch-build_rust_rust__bindgen__generator.gni @@ -0,0 +1,19 @@ +--- build/rust/rust_bindgen_generator.gni.orig 2025-01-15 09:18:26 UTC ++++ build/rust/rust_bindgen_generator.gni +@@ -11,14 +11,14 @@ if (is_win) { + import("//build/toolchain/win/win_toolchain_data.gni") + } + +-_bindgen_path = "${rust_bindgen_root}/bin/bindgen" ++_bindgen_path = "${LOCALBASE}/bin/bindgen" + if (host_os == "win") { + _bindgen_path = "${_bindgen_path}.exe" + } + + # On Windows, the libclang.dll is beside the bindgen.exe, otherwise it is in + # ../lib. +-_libclang_path = rust_bindgen_root ++_libclang_path = "${LOCALBASE}/llvm${MODCLANG_VERSION}" + if (host_os == "win") { + _libclang_path += "/bin" + } else { diff --git a/www/chromium/files/patch-build_rust_std_BUILD.gn b/www/chromium/files/patch-build_rust_std_BUILD.gn index 0ca959a13e47..2ec9c0453c73 100644 --- a/www/chromium/files/patch-build_rust_std_BUILD.gn +++ b/www/chromium/files/patch-build_rust_std_BUILD.gn @@ -1,6 +1,28 @@ ---- build/rust/std/BUILD.gn.orig 2024-03-22 08:19:40 UTC +--- build/rust/std/BUILD.gn.orig 2025-05-28 14:55:43 UTC +++ build/rust/std/BUILD.gn -@@ -90,7 +90,6 @@ if (toolchain_has_rust) { +@@ -50,13 +50,20 @@ if (toolchain_has_rust) { + # These are no longer present in the Windows toolchain. + stdlib_files += [ + "addr2line", +- "adler2", + "gimli", + "libc", + "memchr", + "miniz_oxide", + "object", + ] ++ ++ rust_revision_pieces = string_split(rustc_revision, " ") ++ rust_version_pieces = string_split(rust_revision_pieces[1], ".") ++ if (rust_version_pieces[1] == "85") { ++ stdlib_files += [ "adler" ] ++ } else { ++ stdlib_files += [ "adler2" ] ++ } + } + + if (toolchain_for_rust_host_build_tools) { +@@ -76,7 +83,6 @@ if (toolchain_has_rust) { # don't need to pass to the C++ linker because they're used for specialized # purposes. skip_stdlib_files = [ diff --git a/www/chromium/files/patch-build_toolchain_gcc__toolchain.gni b/www/chromium/files/patch-build_toolchain_gcc__toolchain.gni index f017ad1a10fd..8c544b43738a 100644 --- a/www/chromium/files/patch-build_toolchain_gcc__toolchain.gni +++ b/www/chromium/files/patch-build_toolchain_gcc__toolchain.gni @@ -1,6 +1,6 @@ ---- build/toolchain/gcc_toolchain.gni.orig 2024-03-22 08:19:40 UTC +--- build/toolchain/gcc_toolchain.gni.orig 2025-04-04 08:52:13 UTC +++ build/toolchain/gcc_toolchain.gni -@@ -57,6 +57,13 @@ if (enable_resource_allowlist_generation) { +@@ -56,6 +56,13 @@ if (enable_resource_allowlist_generation) { "enable_resource_allowlist_generation=true does not work for target_os=$target_os") } @@ -14,8 +14,8 @@ # This template defines a toolchain for something that works like gcc # (including clang). # -@@ -890,22 +897,12 @@ template("gcc_toolchain") { - # use_gold too. +@@ -896,22 +903,12 @@ template("gcc_toolchain") { + # actually just be doing a native compile. template("clang_toolchain") { gcc_toolchain(target_name) { - _path = "$clang_base_path/bin" diff --git a/www/chromium/files/patch-build_toolchain_toolchain.gni b/www/chromium/files/patch-build_toolchain_toolchain.gni index d4db1261df78..11f7d267813f 100644 --- a/www/chromium/files/patch-build_toolchain_toolchain.gni +++ b/www/chromium/files/patch-build_toolchain_toolchain.gni @@ -1,10 +1,10 @@ ---- build/toolchain/toolchain.gni.orig 2024-03-22 08:19:40 UTC +--- build/toolchain/toolchain.gni.orig 2025-07-02 06:08:04 UTC +++ build/toolchain/toolchain.gni -@@ -68,7 +68,7 @@ if (host_os == "mac") { +@@ -60,7 +60,7 @@ if (host_os == "mac") { host_shlib_extension = ".dylib" } else if (host_os == "win") { host_shlib_extension = ".dll" --} else if (host_os == "linux" || host_os == "aix") { +-} else if (host_os == "linux" || host_os == "aix" || host_os == "zos") { +} else if (is_posix) { host_shlib_extension = ".so" } else { diff --git a/www/chromium/files/patch-cc_BUILD.gn b/www/chromium/files/patch-cc_BUILD.gn deleted file mode 100644 index 2fede71e2bcf..000000000000 --- a/www/chromium/files/patch-cc_BUILD.gn +++ /dev/null @@ -1,19 +0,0 @@ ---- cc/BUILD.gn.orig 2024-04-19 13:02:56 UTC -+++ cc/BUILD.gn -@@ -681,7 +681,7 @@ cc_test_static_library("test_support") { - if (enable_vulkan) { - deps += [ "//gpu/vulkan/init" ] - } -- if (!is_android) { -+ if (!is_android && !is_bsd) { - data_deps = [ "//third_party/mesa_headers" ] - } - if (skia_use_dawn) { -@@ -940,7 +940,6 @@ cc_test("cc_unittests") { - data = [ "//components/test/data/viz/" ] - data_deps = [ - "//testing/buildbot/filters:cc_unittests_filters", -- "//third_party/mesa_headers", - ] - - if (is_android && enable_chrome_android_internal) { diff --git a/www/chromium/files/patch-cc_base_features.cc b/www/chromium/files/patch-cc_base_features.cc index acb4b05a37a8..ff7dff601475 100644 --- a/www/chromium/files/patch-cc_base_features.cc +++ b/www/chromium/files/patch-cc_base_features.cc @@ -1,6 +1,6 @@ ---- cc/base/features.cc.orig 2024-01-30 07:53:34 UTC +--- cc/base/features.cc.orig 2025-05-28 14:55:43 UTC +++ cc/base/features.cc -@@ -88,7 +88,7 @@ BASE_FEATURE(kNormalPriorityImageDecoding, +@@ -52,7 +52,7 @@ const base::FeatureParam<int> kDeferImplInvalidationFr // be using a separate flag to control the launch on GL. BASE_FEATURE(kUseDMSAAForTiles, "UseDMSAAForTiles", diff --git a/www/chromium/files/patch-chrome_app_chrome__command__ids.h b/www/chromium/files/patch-chrome_app_chrome__command__ids.h index a7f93a9ada50..c22a5e46b2d2 100644 --- a/www/chromium/files/patch-chrome_app_chrome__command__ids.h +++ b/www/chromium/files/patch-chrome_app_chrome__command__ids.h @@ -1,6 +1,6 @@ ---- chrome/app/chrome_command_ids.h.orig 2023-09-13 12:11:42 UTC +--- chrome/app/chrome_command_ids.h.orig 2025-03-05 08:14:56 UTC +++ chrome/app/chrome_command_ids.h -@@ -68,12 +68,12 @@ +@@ -72,11 +72,11 @@ #define IDC_TOGGLE_MULTITASK_MENU 34050 #endif @@ -9,9 +9,8 @@ #define IDC_USE_SYSTEM_TITLE_BAR 34051 #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #define IDC_RESTORE_WINDOW 34052 #endif diff --git a/www/chromium/files/patch-chrome_app_chrome__main.cc b/www/chromium/files/patch-chrome_app_chrome__main.cc index cb1edb8de3a8..c778a6f5c376 100644 --- a/www/chromium/files/patch-chrome_app_chrome__main.cc +++ b/www/chromium/files/patch-chrome_app_chrome__main.cc @@ -1,4 +1,4 @@ ---- chrome/app/chrome_main.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/app/chrome_main.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/app/chrome_main.cc @@ -28,11 +28,11 @@ #include "chrome/app/chrome_main_mac.h" @@ -14,7 +14,16 @@ #include "chrome/app/chrome_main_linux.h" #endif -@@ -80,7 +80,7 @@ int ChromeMain(int argc, const char** argv) { +@@ -57,7 +57,7 @@ + // sometime after old headless code is removed from Chrome. + // See https://crbug.com/373672160. + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #define ENABLE_OLD_HEADLESS_INFO + #endif + +@@ -115,7 +115,7 @@ int ChromeMain(int argc, const char** argv) { #error Unknown platform. #endif @@ -23,7 +32,7 @@ PossiblyDetermineFallbackChromeChannel(argv[0]); #endif -@@ -141,7 +141,7 @@ int ChromeMain(int argc, const char** argv) { +@@ -181,7 +181,7 @@ int ChromeMain(int argc, const char** argv) { SetUpBundleOverrides(); #endif @@ -32,12 +41,3 @@ AppendExtraArgumentsToCommandLine(command_line); #endif -@@ -170,7 +170,7 @@ int ChromeMain(int argc, const char** argv) { - headless_mode_handle = headless::InitHeadlessMode(); - } else { - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - if (headless::IsOldHeadlessMode()) { - #if BUILDFLAG(GOOGLE_CHROME_BRANDING) - command_line->AppendSwitch(::headless::switches::kEnableCrashReporter); diff --git a/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc b/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc index 22672e805dd8..39a606b494bb 100644 --- a/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc +++ b/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc @@ -1,7 +1,7 @@ ---- chrome/app/chrome_main_delegate.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/app/chrome_main_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/app/chrome_main_delegate.cc -@@ -146,7 +146,7 @@ - #include "components/about_ui/credit_utils.h" +@@ -147,7 +147,7 @@ + #include "components/webui/about/credit_utils.h" #endif -#if BUILDFLAG(ENABLE_NACL) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) @@ -9,23 +9,19 @@ #include "components/nacl/common/nacl_paths.h" #include "components/nacl/zygote/nacl_fork_delegate_linux.h" #endif -@@ -189,20 +189,20 @@ +@@ -187,17 +187,17 @@ #include "v8/include/v8.h" #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "base/environment.h" #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "base/nix/scoped_xdg_activation_token_injector.h" - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - #include "base/message_loop/message_pump_libevent.h" + #include "ui/linux/display_server_utils.h" #endif #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || \ @@ -34,7 +30,7 @@ #include "chrome/browser/policy/policy_path_parser.h" #include "components/crash/core/app/crashpad.h" #endif -@@ -346,7 +346,7 @@ void AdjustLinuxOOMScore(const std::string& process_ty +@@ -315,7 +315,7 @@ void AdjustLinuxOOMScore(const std::string& process_ty // and resources loaded. bool SubprocessNeedsResourceBundle(const std::string& process_type) { return @@ -43,25 +39,25 @@ // The zygote process opens the resources for the renderers. process_type == switches::kZygoteProcess || #endif -@@ -431,7 +431,7 @@ bool HandleVersionSwitches(const base::CommandLine& co +@@ -398,7 +398,7 @@ bool HandleVersionSwitches(const base::CommandLine& co + return false; + } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Show the man page if --help or -h is on the command line. void HandleHelpSwitches(const base::CommandLine& command_line) { if (command_line.HasSwitch(switches::kHelp) || -@@ -477,7 +477,7 @@ void SetCrashpadUploadConsentPostLogin() { +@@ -410,7 +410,7 @@ void HandleHelpSwitches(const base::CommandLine& comma } - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) + #endif // BUILDFLAG(IS_LINUX) -#if !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_ANDROID) +#if !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_BSD) void SIGTERMProfilingShutdown(int signal) { content::Profiling::Stop(); struct sigaction sigact; -@@ -559,7 +559,7 @@ std::optional<int> AcquireProcessSingleton( +@@ -492,7 +492,7 @@ std::optional<int> AcquireProcessSingleton( // process can be exited. ChromeProcessSingleton::CreateInstance(user_data_dir); @@ -70,7 +66,7 @@ // Read the xdg-activation token and set it in the command line for the // duration of the notification in order to ensure this is propagated to an // already running browser process if it exists. -@@ -643,7 +643,7 @@ void InitializeUserDataDir(base::CommandLine* command_ +@@ -570,7 +570,7 @@ void InitializeUserDataDir(base::CommandLine* command_ std::string process_type = command_line->GetSwitchValueASCII(switches::kProcessType); @@ -79,7 +75,7 @@ // On Linux, Chrome does not support running multiple copies under different // DISPLAYs, so the profile directory can be specified in the environment to // support the virtual desktop use-case. -@@ -770,7 +770,7 @@ void RecordMainStartupMetrics(base::TimeTicks applicat +@@ -668,7 +668,7 @@ void RecordMainStartupMetrics(const StartupTimestamps& #endif #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ @@ -88,8 +84,17 @@ // Record the startup process creation time on supported platforms. On Android // this is recorded in ChromeMainDelegateAndroid. startup_metric_utils::GetCommon().RecordStartupProcessCreationTime( -@@ -1155,7 +1155,7 @@ void ChromeMainDelegate::CommonEarlyInitialization(Inv - chrome::GetChannel() == version_info::Channel::DEV; +@@ -827,7 +827,7 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitia + #if BUILDFLAG(IS_OZONE) + // Initialize Ozone platform and add required feature flags as per platform's + // properties. +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + ui::SetOzonePlatformForLinuxIfNeeded(*base::CommandLine::ForCurrentProcess()); + #endif + ui::OzonePlatform::PreEarlyInitialization(); +@@ -982,7 +982,7 @@ void ChromeMainDelegate::CommonEarlyInitialization() { + const bool is_canary_dev = IsCanaryDev(); const bool emit_crashes = #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ - BUILDFLAG(IS_WIN) @@ -97,26 +102,17 @@ is_canary_dev; #else false; -@@ -1174,7 +1174,7 @@ void ChromeMainDelegate::CommonEarlyInitialization(Inv - // for more context. - base::sequence_manager::internal::ThreadController::InitializeFeatures( - /*record_sample_metadata=*/is_canary_dev); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - base::MessagePumpLibevent::InitializeFeatures(); - #elif BUILDFLAG(IS_MAC) - base::PlatformThread::InitFeaturesPostFieldTrial(); -@@ -1323,7 +1323,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom +@@ -1130,7 +1130,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom + return 0; // Got a --credits switch; exit with a success error code. + } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag - // switch of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // This will directly exit if the user asked for help. HandleHelpSwitches(command_line); #endif -@@ -1353,7 +1353,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom - #if BUILDFLAG(IS_CHROMEOS) +@@ -1155,7 +1155,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom + ash::RegisterPathProvider(); chromeos::dbus_paths::RegisterPathProvider(); #endif -#if BUILDFLAG(ENABLE_NACL) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) @@ -124,21 +120,28 @@ nacl::RegisterPathProvider(); #endif -@@ -1750,7 +1750,7 @@ void ChromeMainDelegate::PreSandboxStartup() { +@@ -1439,7 +1439,7 @@ void ChromeMainDelegate::PreSandboxStartup() { CHECK(!loaded_locale.empty()) << "Locale could not be found for " << locale; } -#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_BSD) // Zygote needs to call InitCrashReporter() in RunZygote(). - if (process_type != switches::kZygoteProcess) { - if (command_line.HasSwitch(switches::kPreCrashpadCrashTest)) { -@@ -1851,7 +1851,7 @@ absl::variant<int, content::MainFunctionParams> Chrome - - // This entry is not needed on Linux, where the NaCl loader - // process is launched via nacl_helper instead. --#if BUILDFLAG(ENABLE_NACL) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(ENABLE_NACL) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) - {switches::kNaClLoaderProcess, NaClMain}, + if (process_type != switches::kZygoteProcess && + !command_line.HasSwitch(switches::kDisableCrashpadForTesting)) { +@@ -1527,13 +1527,13 @@ std::variant<int, content::MainFunctionParams> ChromeM #else - {"<invalid>", nullptr}, // To avoid constant array of size 0 + + #if BUILDFLAG(IS_MAC) || (BUILDFLAG(ENABLE_NACL) && !BUILDFLAG(IS_LINUX) && \ +- !BUILDFLAG(IS_CHROMEOS)) ++ !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD)) + static const MainFunction kMainFunctions[] = { + #if BUILDFLAG(IS_MAC) + {switches::kRelauncherProcess, mac_relauncher::internal::RelauncherMain}, + {switches::kCodeSignCloneCleanupProcess, + code_sign_clone_manager::internal::ChromeCodeSignCloneCleanupMain}, +-#elif BUILDFLAG(ENABLE_NACL) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) ++#elif BUILDFLAG(ENABLE_NACL) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) + // This entry is not needed on Linux, where the NaCl loader + // process is launched via nacl_helper instead. + {switches::kNaClLoaderProcess, NaClMain}, diff --git a/www/chromium/files/patch-chrome_browser_BUILD.gn b/www/chromium/files/patch-chrome_browser_BUILD.gn index 87575ea436c1..a373b591fbb6 100644 --- a/www/chromium/files/patch-chrome_browser_BUILD.gn +++ b/www/chromium/files/patch-chrome_browser_BUILD.gn @@ -1,16 +1,16 @@ ---- chrome/browser/BUILD.gn.orig 2024-04-25 21:17:54 UTC +--- chrome/browser/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/BUILD.gn -@@ -6554,6 +6554,13 @@ static_library("browser") { +@@ -7008,6 +7008,13 @@ static_library("browser") { + [ "//third_party/webrtc/modules/desktop_capture:pipewire_config" ] } - } -+ if (is_bsd) { -+ sources -= [ -+ "metrics/bluetooth_metrics_provider.cc", -+ "metrics/bluetooth_metrics_provider.h", -+ ] -+ } ++ if (is_bsd) { ++ sources -= [ ++ "metrics/bluetooth_metrics_provider.cc", ++ "metrics/bluetooth_metrics_provider.h", ++ ] ++ } + - if (is_linux && use_dbus) { - sources += [ - "dbus_memory_pressure_evaluator_linux.cc", + if (use_dbus) { + sources += [ + "dbus_memory_pressure_evaluator_linux.cc", diff --git a/www/chromium/files/patch-chrome_browser_about__flags.cc b/www/chromium/files/patch-chrome_browser_about__flags.cc index 1933395a868c..fc138c40b813 100644 --- a/www/chromium/files/patch-chrome_browser_about__flags.cc +++ b/www/chromium/files/patch-chrome_browser_about__flags.cc @@ -1,33 +1,51 @@ ---- chrome/browser/about_flags.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/about_flags.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/about_flags.cc -@@ -234,7 +234,7 @@ - #include "ui/ui_features.h" - #include "url/url_features.h" +@@ -263,7 +263,7 @@ + #include "extensions/common/extension_features.h" + #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "base/allocator/buildflags.h" #endif -@@ -322,7 +322,7 @@ - #include "device/vr/public/cpp/features.h" +@@ -353,7 +353,7 @@ + #include "device/vr/public/cpp/switches.h" #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "ui/ozone/public/ozone_switches.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -331,7 +331,7 @@ - #include "chrome/browser/win/titlebar_config.h" +@@ -363,7 +363,7 @@ + #include "chrome/browser/win/mica_titlebar.h" #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/contextual_cueing/contextual_cueing_features.h" // nogncheck #include "chrome/browser/enterprise/profile_management/profile_management_features.h" - #include "components/supervised_user/core/common/features.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -@@ -489,7 +489,7 @@ const FeatureEntry::FeatureVariation kDXGIWaitableSwap + #include "chrome/browser/enterprise/webstore/features.h" +@@ -375,7 +375,7 @@ + #include "components/user_education/common/user_education_features.h" // nogncheck + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/ui_features.h" + #include "ui/base/ui_base_features.h" + #endif +@@ -427,7 +427,7 @@ const FeatureEntry::Choice kPullToRefreshChoices[] = { + #endif // USE_AURA + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + + const FeatureEntry::FeatureParam kLocalNetworkAccessChecksBlock[] = { + {"LocalNetworkAccessChecksWarn", "false"}}; +@@ -543,7 +543,7 @@ const FeatureEntry::FeatureVariation kDXGIWaitableSwap {"Max 3 Frames", &kDXGIWaitableSwapChain3Frames, 1, nullptr}}; #endif @@ -36,124 +54,186 @@ const FeatureEntry::Choice kOzonePlatformHintRuntimeChoices[] = { {flag_descriptions::kOzonePlatformHintChoiceDefault, "", ""}, {flag_descriptions::kOzonePlatformHintChoiceAuto, -@@ -1384,7 +1384,7 @@ const FeatureEntry::FeatureVariation kChromeRefresh202 - nullptr}}; +@@ -900,6 +900,26 @@ const FeatureEntry::FeatureVariation + std::size(kWebIdentityDigitalIdentityCredentialHighRiskDialogParam), + nullptr}}; + ++#if BUILDFLAG(IS_BSD) ++const FeatureEntry::FeatureParam kAudioBackendPulseAudio[] = { ++ { "audio-backend", "pulseaudio" }}; ++const FeatureEntry::FeatureParam kAudioBackendSndio[] = { ++ { "audio-backend", "sndio" }}; ++const FeatureEntry::FeatureParam kAudioBackendAlsa[] = { ++ { "audio-backend", "alsa" }}; ++const FeatureEntry::FeatureVariation ++ kAudioBackendVariations[] = { ++ {"using PulseAudio by default if available", kAudioBackendPulseAudio, ++ std::size(kAudioBackendPulseAudio), ++ nullptr}, ++ {"using sndio by default if available", kAudioBackendSndio, ++ std::size(kAudioBackendSndio), ++ nullptr}, ++ {"using ALSA by default if available", kAudioBackendAlsa, ++ std::size(kAudioBackendAlsa), ++ nullptr}}; ++#endif ++ + const FeatureEntry::FeatureParam kClipboardMaximumAge60Seconds[] = { + {"UIClipboardMaximumAge", "60"}}; + const FeatureEntry::FeatureParam kClipboardMaximumAge90Seconds[] = { +@@ -1292,7 +1312,7 @@ constexpr FeatureEntry::FeatureVariation + #endif // !BUILDFLAG(IS_ANDROID) #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - const FeatureEntry::FeatureParam kShortcutBoostSingleUrl[] = { - {"ShortcutBoostSearchScore", "0"}, - {"ShortcutBoostNonTopHitThreshold", "0"}, -@@ -3704,7 +3704,7 @@ const flags_ui::FeatureEntry::FeatureVariation - std::size(kParcelTrackingTestDataOutForDelivery), nullptr}, +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + const FeatureEntry::FeatureParam kHistoryEmbeddingsAtKeywordAcceleration[]{ + {"AtKeywordAcceleration", "true"}, + }; +@@ -1330,7 +1350,7 @@ const FeatureEntry::FeatureVariation kRemotePageMetada }; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - const flags_ui::FeatureEntry::FeatureParam - kDesktopPWAsLinkCapturingDefaultOn[] = {{"on_by_default", "true"}}; - const flags_ui::FeatureEntry::FeatureParam -@@ -4495,7 +4495,7 @@ const FeatureEntry kFeatureEntries[] = { - }, + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + + // A limited number of combinations of the rich autocompletion params. + const FeatureEntry::FeatureParam kOmniboxRichAutocompletionAggressive1[] = { +@@ -3826,7 +3846,7 @@ const FeatureEntry::FeatureVariation #endif // BUILDFLAG(IS_ANDROID) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + const flags_ui::FeatureEntry::FeatureParam kPwaNavigationCapturingDefaultOn[] = + {{"link_capturing_state", "on_by_default"}}; + const flags_ui::FeatureEntry::FeatureParam kPwaNavigationCapturingDefaultOff[] = +@@ -4261,7 +4281,7 @@ const FeatureEntry::FeatureVariation kSkiaGraphiteVari + std::size(kSkiaGraphite_DebugLabelsEnabled), nullptr}, + }; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const FeatureEntry::FeatureParam kTranslationAPI_SkipLanguagePackLimit[] = { + {"TranslationAPIAcceptLanguagesCheck", "false"}, + {"TranslationAPILimitLanguagePackCount", "false"}}; +@@ -4321,7 +4341,7 @@ const FeatureEntry::FeatureVariation + 1, nullptr}, + }; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const FeatureEntry::FeatureParam kContextualCueingEnabledNoEngagementCap[] = { + {"BackoffTime", "0h"}, + {"BackoffMultiplierBase", "0.0"}, +@@ -5264,7 +5284,7 @@ const FeatureEntry kFeatureEntries[] = { + }, + #endif // BUILDFLAG(IS_WIN) + -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) { "fluent-overlay-scrollbars", flag_descriptions::kFluentOverlayScrollbarsName, -@@ -4936,7 +4936,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(features::kWebAppUniversalInstall)}, - #endif // !BUILDFLAG(IS_ANDROID) - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - {"shortcuts-not-apps", flag_descriptions::kShortcutsNotAppsName, - flag_descriptions::kShortcutsNotAppsDescription, - kOsMac | kOsWin | kOsLinux | kOsFuchsia, -@@ -5061,7 +5061,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(features::kWebShare)}, - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) +@@ -5555,7 +5575,7 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kEnableIsolatedWebAppDevModeName, + flag_descriptions::kEnableIsolatedWebAppDevModeDescription, kOsDesktop, + FEATURE_VALUE_TYPE(features::kIsolatedWebAppDevMode)}, +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"enable-iwa-key-distribution-component", + flag_descriptions::kEnableIwaKeyDistributionComponentName, + flag_descriptions::kEnableIwaKeyDistributionComponentDescription, +@@ -5780,7 +5800,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(media::kUseSCContentSharingPicker)}, + #endif // BUILDFLAG(IS_MAC) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) {"pulseaudio-loopback-for-cast", flag_descriptions::kPulseaudioLoopbackForCastName, flag_descriptions::kPulseaudioLoopbackForCastDescription, kOsLinux, -@@ -5077,7 +5077,7 @@ const FeatureEntry kFeatureEntries[] = { - MULTI_VALUE_TYPE(kOzonePlatformHintRuntimeChoices)}, +@@ -5821,6 +5841,16 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kWaylandSessionManagementName, + flag_descriptions::kWaylandSessionManagementDescription, kOsLinux, + FEATURE_VALUE_TYPE(features::kWaylandSessionManagement)}, ++ ++#if BUILDFLAG(IS_BSD) ++ {"audio-backend", ++ flag_descriptions::kAudioBackendName, ++ flag_descriptions::kAudioBackendDescription, kOsLinux, ++ FEATURE_WITH_PARAMS_VALUE_TYPE( ++ media::kAudioBackend, ++ kAudioBackendVariations, ++ "AudioBackend")}, ++#endif #endif // BUILDFLAG(IS_LINUX) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - {"skip-undecryptable-passwords", - flag_descriptions::kSkipUndecryptablePasswordsName, - flag_descriptions::kSkipUndecryptablePasswordsDescription, -@@ -5981,7 +5981,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(omnibox::kZeroSuggestInMemoryCaching)}, + #if BUILDFLAG(ENABLE_VR) +@@ -6709,7 +6739,7 @@ const FeatureEntry kFeatureEntries[] = { + "MlUrlScoring")}, #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - {"omnibox-domain-suggestions", - flag_descriptions::kOmniboxDomainSuggestionsName, - flag_descriptions::kOmniboxDomainSuggestionsDescription, kOsDesktop, -@@ -6852,7 +6852,7 @@ const FeatureEntry kFeatureEntries[] = { - flag_descriptions::kParallelDownloadingDescription, kOsAll, - FEATURE_VALUE_TYPE(download::features::kParallelDownloading)}, +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + {"contextual-search-box-uses-contextual-search-provider", + flag_descriptions::kContextualSearchBoxUsesContextualSearchProviderName, + flag_descriptions:: +@@ -7061,7 +7091,7 @@ const FeatureEntry kFeatureEntries[] = { + kNumSrpZpsRelatedSearches, + "PowerTools")}, + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + {"history-embeddings", flag_descriptions::kHistoryEmbeddingsName, + flag_descriptions::kHistoryEmbeddingsDescription, kOsDesktop, + FEATURE_WITH_PARAMS_VALUE_TYPE(history_embeddings::kHistoryEmbeddings, +@@ -7560,7 +7590,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(printing::features::kAddPrinterViaPrintscanmgr)}, + #endif // BUILDFLAG(IS_CHROMEOS) --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - {"enable-async-dns", flag_descriptions::kAsyncDnsName, - flag_descriptions::kAsyncDnsDescription, kOsWin | kOsLinux, - FEATURE_VALUE_TYPE(net::features::kAsyncDns)}, -@@ -7857,7 +7857,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(ash::features::kPrivacyIndicators)}, - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + {"cups-ipp-printing-backend", + flag_descriptions::kCupsIppPrintingBackendName, + flag_descriptions::kCupsIppPrintingBackendDescription, kOsDesktop, +@@ -7851,7 +7881,7 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kSupportToolScreenshotDescription, kOsDesktop, + FEATURE_VALUE_TYPE(features::kSupportToolScreenshot)}, + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + {"wasm-tts-component-updater-enabled", + flag_descriptions::kWasmTtsComponentUpdaterEnabledName, + flag_descriptions::kWasmTtsComponentUpdaterEnabledDescription, kOsDesktop, +@@ -8523,7 +8553,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(media::kGlobalMediaControlsUpdatedUI)}, + #endif // !BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) {"enable-network-service-sandbox", flag_descriptions::kEnableNetworkServiceSandboxName, flag_descriptions::kEnableNetworkServiceSandboxDescription, -@@ -7881,7 +7881,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(media::kV4L2FlatStatefulVideoDecoder)}, - #endif - --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - {"enable-family-link-extensions-permissions", - flag_descriptions:: - kEnableExtensionsPermissionsForSupervisedUsersOnDesktopName, -@@ -8733,7 +8733,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(ash::features::kWallpaperPerDesk)}, - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +@@ -9176,7 +9206,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(ash::features::kWallpaperGooglePhotosSharedAlbums)}, + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) {"enable-get-all-screens-media", flag_descriptions::kGetAllScreensMediaName, - flag_descriptions::kGetAllScreensMediaDescription, - kOsCrOS | kOsLacros | kOsLinux, -@@ -8775,7 +8775,7 @@ const FeatureEntry kFeatureEntries[] = { - - #if BUILDFLAG(IS_WIN) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || \ -- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + flag_descriptions::kGetAllScreensMediaDescription, kOsCrOS | kOsLinux, + FEATURE_VALUE_TYPE(blink::features::kGetAllScreensMedia)}, +@@ -9201,7 +9231,7 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kGlobalVaapiLockDescription, kOsCrOS | kOsLinux, + FEATURE_VALUE_TYPE(media::kGlobalVaapiLock)}, + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) { "ui-debug-tools", flag_descriptions::kUIDebugToolsName, -@@ -9044,7 +9044,7 @@ const FeatureEntry kFeatureEntries[] = { - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - {"policy-indication-for-managed-default-search", - flag_descriptions::kPolicyIndicationForManagedDefaultSearchName, - flag_descriptions::kPolicyIndicationForManagedDefaultSearchDescription, -@@ -9340,7 +9340,7 @@ const FeatureEntry kFeatureEntries[] = { +@@ -9668,7 +9698,7 @@ const FeatureEntry kFeatureEntries[] = { #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ @@ -162,7 +242,16 @@ {"media-session-enter-picture-in-picture", flag_descriptions::kMediaSessionEnterPictureInPictureName, flag_descriptions::kMediaSessionEnterPictureInPictureDescription, -@@ -10280,7 +10280,7 @@ const FeatureEntry kFeatureEntries[] = { +@@ -9830,7 +9860,7 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kReduceTransferSizeUpdatedIPCDescription, kOsAll, + FEATURE_VALUE_TYPE(network::features::kReduceTransferSizeUpdatedIPC)}, + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"reduce-user-agent-data-linux-platform-version", + flag_descriptions::kReduceUserAgentDataLinuxPlatformVersionName, + flag_descriptions::kReduceUserAgentDataLinuxPlatformVersionDescription, +@@ -10334,7 +10364,7 @@ const FeatureEntry kFeatureEntries[] = { kOsDesktop | kOsAndroid, FEATURE_VALUE_TYPE(features::kProcessPerSiteUpToMainFrameThreshold)}, @@ -171,17 +260,8 @@ {"camera-mic-effects", flag_descriptions::kCameraMicEffectsName, flag_descriptions::kCameraMicEffectsDescription, static_cast<unsigned short>(kOsMac | kOsWin | kOsLinux), -@@ -10318,7 +10318,7 @@ const FeatureEntry kFeatureEntries[] = { - FEATURE_VALUE_TYPE(features::kSiteInstanceGroupsForDataUrls)}, - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - {"site-search-settings-policy", - flag_descriptions::kSiteSearchSettingsPolicyName, - flag_descriptions::kSiteSearchSettingsPolicyDescription, kOsAll, -@@ -10452,7 +10452,7 @@ const FeatureEntry kFeatureEntries[] = { - password_manager::features::kFillingAcrossAffiliatedWebsitesAndroid)}, +@@ -10458,7 +10488,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(chrome::android::kReadAloudTapToSeek)}, #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) @@ -189,21 +269,138 @@ {"third-party-profile-management", flag_descriptions::kThirdPartyProfileManagementName, flag_descriptions::kThirdPartyProfileManagementDescription, -@@ -10804,7 +10804,7 @@ const FeatureEntry kFeatureEntries[] = { - trusted_vault::kTrustedVaultFrequentDegradedRecoverabilityPolling)}, - #endif +@@ -10487,7 +10517,7 @@ const FeatureEntry kFeatureEntries[] = { + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - {"restart-to-gain-access-to-keychain", - flag_descriptions::kRestartToGainAccessToKeychainName, - flag_descriptions::kRestartToGainAccessToKeychainDescription, -@@ -11078,7 +11078,7 @@ const FeatureEntry kFeatureEntries[] = { - - // Controls the view mode for (history) sync screen. - #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - {"minor-mode-restrictions-for-history-sync-opt-in", - flag_descriptions::kMinorModeRestrictionsForHistorySyncOptInName, - flag_descriptions::kMinorModeRestrictionsForHistorySyncOptInDescription, + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"enable-user-navigation-capturing-pwa", + flag_descriptions::kPwaNavigationCapturingName, + flag_descriptions::kPwaNavigationCapturingDescription, +@@ -11223,7 +11253,7 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kCanvasHibernationDescription, kOsAll, + FEATURE_VALUE_TYPE(blink::features::kCanvas2DHibernation)}, + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"enable-history-sync-optin", + flag_descriptions::kEnableHistorySyncOptinName, + flag_descriptions::kEnableHistorySyncOptinDescription, +@@ -11334,7 +11364,7 @@ const FeatureEntry kFeatureEntries[] = { + "HistoryOptInEducationalTipVariations")}, + #endif // BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + {"supervised-profile-safe-search", + flag_descriptions::kSupervisedProfileSafeSearchName, + flag_descriptions::kSupervisedProfileSafeSearchDescription, +@@ -11586,7 +11616,7 @@ const FeatureEntry kFeatureEntries[] = { + segmentation_platform::features::kSegmentationSurveyPage)}, + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"autofill-enable-buy-now-pay-later", + flag_descriptions::kAutofillEnableBuyNowPayLaterName, + flag_descriptions::kAutofillEnableBuyNowPayLaterDescription, kOsDesktop, +@@ -11687,7 +11717,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE( + autofill::features::kAutofillEnableCardInfoRuntimeRetrieval)}, + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"translation-api", flag_descriptions::kTranslationAPIName, + flag_descriptions::kTranslationAPIDescription, kOsMac | kOsWin | kOsLinux, + FEATURE_WITH_PARAMS_VALUE_TYPE(blink::features::kTranslationAPI, +@@ -11721,7 +11751,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE( + password_manager::features::kPasswordFormClientsideClassifier)}, + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"contextual-cueing", flag_descriptions::kContextualCueingName, + flag_descriptions::kContextualCueingDescription, + kOsLinux | kOsMac | kOsWin, +@@ -12053,7 +12083,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(ui::kUseNewEtc1Encoder)}, + #endif // !BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"automatic-usb-detach", flag_descriptions::kAutomaticUsbDetachName, + flag_descriptions::kAutomaticUsbDetachDescription, kOsAndroid | kOsLinux, + FEATURE_VALUE_TYPE(features::kAutomaticUsbDetach)}, +@@ -12103,7 +12133,7 @@ const FeatureEntry kFeatureEntries[] = { + #endif // !BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"autofill-enable-amount-extraction-desktop", + flag_descriptions::kAutofillEnableAmountExtractionDesktopName, + flag_descriptions::kAutofillEnableAmountExtractionDesktopDescription, +@@ -12123,7 +12153,7 @@ const FeatureEntry kFeatureEntries[] = { + FEATURE_VALUE_TYPE(blink::features::kClipboardContentsId)}, + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"autofill-enable-amount-extraction-allowlist-desktop", + flag_descriptions::kAutofillEnableAmountExtractionAllowlistDesktopName, + flag_descriptions:: +@@ -12241,7 +12271,7 @@ const FeatureEntry kFeatureEntries[] = { + apps::chrome_app_deprecation::kAllowUserInstalledChromeApps)}, + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + {"chrome-web-store-navigation-throttle", + flag_descriptions::kChromeWebStoreNavigationThrottleName, + flag_descriptions::kChromeWebStoreNavigationThrottleDescription, +@@ -12277,7 +12307,7 @@ const FeatureEntry kFeatureEntries[] = { + #endif // BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"autofill-enable-amount-extraction-desktop-logging", + flag_descriptions::kAutofillEnableAmountExtractionDesktopLoggingName, + flag_descriptions:: +@@ -12300,7 +12330,7 @@ const FeatureEntry kFeatureEntries[] = { + flag_descriptions::kEnableWebAppUpdateTokenParsingDescription, kOsAll, + FEATURE_VALUE_TYPE(features::kWebAppEnableUpdateTokenParsing)}, + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + {"root-scrollbar-follows-browser-theme", + flag_descriptions::kRootScrollbarFollowsTheme, + flag_descriptions::kRootScrollbarFollowsThemeDescription, +@@ -12329,7 +12359,7 @@ const FeatureEntry kFeatureEntries[] = { + #endif // BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"local-network-access-check", + flag_descriptions::kLocalNetworkAccessChecksName, + flag_descriptions::kLocalNetworkAccessChecksDescription, kOsDesktop, +@@ -12551,7 +12581,7 @@ const FeatureEntry kFeatureEntries[] = { + #endif // BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"tab-group-home", tabs::flag_descriptions::kTabGroupHomeName, + tabs::flag_descriptions::kTabGroupHomeDescription, kOsDesktop, + FEATURE_VALUE_TYPE(tabs::kTabGroupHome)}, +@@ -12629,7 +12659,7 @@ const FeatureEntry kFeatureEntries[] = { + #endif // BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {"enable-site-search-allow-user-override-policy", + flag_descriptions::kEnableSiteSearchAllowUserOverridePolicyName, + flag_descriptions::kEnableSiteSearchAllowUserOverridePolicyDescription, diff --git a/www/chromium/files/patch-chrome_browser_accessibility_page__colors.cc b/www/chromium/files/patch-chrome_browser_accessibility_page__colors.cc new file mode 100644 index 000000000000..8f5326a830d9 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_accessibility_page__colors.cc @@ -0,0 +1,20 @@ +--- chrome/browser/accessibility/page_colors.cc.orig 2024-08-26 12:06:38 UTC ++++ chrome/browser/accessibility/page_colors.cc +@@ -12,7 +12,7 @@ + #include "components/sync_preferences/pref_service_syncable.h" + #include "ui/native_theme/native_theme.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "ui/linux/linux_ui.h" + #include "ui/linux/linux_ui_factory.h" + #endif // BUILDFLAG(IS_LINUX) +@@ -55,7 +55,7 @@ void PageColors::Init() { + + void PageColors::OnPageColorsChanged() { + auto* native_theme = ui::NativeTheme::GetInstanceForNativeUi(); +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Allow the Linux native theme to update its state for page colors. + if (auto* linux_ui_theme = ui::GetDefaultLinuxUiTheme()) { + if (auto* linux_native_theme = linux_ui_theme->GetNativeTheme()) { diff --git a/www/chromium/files/patch-chrome_browser_accessibility_pdf__ocr__controller.cc b/www/chromium/files/patch-chrome_browser_accessibility_pdf__ocr__controller.cc deleted file mode 100644 index 568fbf176797..000000000000 --- a/www/chromium/files/patch-chrome_browser_accessibility_pdf__ocr__controller.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/accessibility/pdf_ocr_controller.cc.orig 2024-03-22 08:19:40 UTC -+++ chrome/browser/accessibility/pdf_ocr_controller.cc -@@ -111,7 +111,7 @@ void AnnounceToScreenReader(const int message_id) { - // TODO(crbug.com/1442928): Sending announcements results in a failure in - // `AuraLinuxAccessibilityInProcessBrowserTest::IndexInParentWithModal` and - // flaky fail when running Chrome. --#if !BUILDFLAG(IS_LINUX) -+#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) - const Browser* browser = BrowserList::GetInstance()->GetLastActive(); - if (!browser) { - VLOG(2) << "Browser is not ready to announce"; diff --git a/www/chromium/files/patch-chrome_browser_after__startup__task__utils.cc b/www/chromium/files/patch-chrome_browser_after__startup__task__utils.cc index 2c5887ba8034..5e3a866918d1 100644 --- a/www/chromium/files/patch-chrome_browser_after__startup__task__utils.cc +++ b/www/chromium/files/patch-chrome_browser_after__startup__task__utils.cc @@ -1,6 +1,6 @@ ---- chrome/browser/after_startup_task_utils.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/after_startup_task_utils.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/after_startup_task_utils.cc -@@ -115,7 +115,7 @@ void SetBrowserStartupIsComplete() { +@@ -112,7 +112,7 @@ void SetBrowserStartupIsComplete() { TRACE_EVENT_SCOPE_GLOBAL, "BrowserCount", browser_count); GetStartupCompleteFlag().Set(); #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-chrome_browser_apps_platform__apps_platform__app__launch.h b/www/chromium/files/patch-chrome_browser_apps_platform__apps_platform__app__launch.h index 54e492d2ecef..0e6a61cde5b2 100644 --- a/www/chromium/files/patch-chrome_browser_apps_platform__apps_platform__app__launch.h +++ b/www/chromium/files/patch-chrome_browser_apps_platform__apps_platform__app__launch.h @@ -1,11 +1,11 @@ ---- chrome/browser/apps/platform_apps/platform_app_launch.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/apps/platform_apps/platform_app_launch.h.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/apps/platform_apps/platform_app_launch.h -@@ -39,7 +39,7 @@ content::WebContents* OpenExtensionApplicationTab(Prof +@@ -38,7 +38,7 @@ bool OpenExtensionApplicationWindow(Profile* profile, + content::WebContents* OpenExtensionApplicationTab(Profile* profile, const std::string& app_id); - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Opens the deprecated Chrome Apps flow if |app_id| refers to a Chrome App and // Chrome Apps are deprecated on the |profile|. Returns true if that was the // case, or false otherwise. diff --git a/www/chromium/files/patch-chrome_browser_autocomplete_chrome__autocomplete__scheme__classifier.cc b/www/chromium/files/patch-chrome_browser_autocomplete_chrome__autocomplete__scheme__classifier.cc index a35891fc20c5..a710b0db67b5 100644 --- a/www/chromium/files/patch-chrome_browser_autocomplete_chrome__autocomplete__scheme__classifier.cc +++ b/www/chromium/files/patch-chrome_browser_autocomplete_chrome__autocomplete__scheme__classifier.cc @@ -1,6 +1,6 @@ ---- chrome/browser/autocomplete/chrome_autocomplete_scheme_classifier.cc.orig 2023-03-09 06:31:50 UTC +--- chrome/browser/autocomplete/chrome_autocomplete_scheme_classifier.cc.orig 2024-05-21 18:07:39 UTC +++ chrome/browser/autocomplete/chrome_autocomplete_scheme_classifier.cc -@@ -90,7 +90,7 @@ ChromeAutocompleteSchemeClassifier::GetInputTypeForSch +@@ -88,7 +88,7 @@ ChromeAutocompleteSchemeClassifier::GetInputTypeForSch return metrics::OmniboxInputType::QUERY; case ExternalProtocolHandler::UNKNOWN: { diff --git a/www/chromium/files/patch-chrome_browser_background_background__mode__manager.cc b/www/chromium/files/patch-chrome_browser_background_extensions_background__mode__manager.cc index b16930dc8c0c..c34004f0c8b9 100644 --- a/www/chromium/files/patch-chrome_browser_background_background__mode__manager.cc +++ b/www/chromium/files/patch-chrome_browser_background_extensions_background__mode__manager.cc @@ -1,7 +1,7 @@ ---- chrome/browser/background/background_mode_manager.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/background/background_mode_manager.cc -@@ -872,7 +872,7 @@ gfx::ImageSkia GetStatusTrayIcon() { - return gfx::ImageSkia(); +--- chrome/browser/background/extensions/background_mode_manager.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/background/extensions/background_mode_manager.cc +@@ -893,7 +893,7 @@ gfx::ImageSkia GetStatusTrayIcon() { + } return family->CreateExact(size).AsImageSkia(); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-chrome_browser_background_background__mode__optimizer.cc b/www/chromium/files/patch-chrome_browser_background_extensions_background__mode__optimizer.cc index 61cf1ecf80b2..6667da0ac5c1 100644 --- a/www/chromium/files/patch-chrome_browser_background_background__mode__optimizer.cc +++ b/www/chromium/files/patch-chrome_browser_background_extensions_background__mode__optimizer.cc @@ -1,5 +1,5 @@ ---- chrome/browser/background/background_mode_optimizer.cc.orig 2024-03-22 08:19:40 UTC -+++ chrome/browser/background/background_mode_optimizer.cc +--- chrome/browser/background/extensions/background_mode_optimizer.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/background/extensions/background_mode_optimizer.cc @@ -31,7 +31,7 @@ std::unique_ptr<BackgroundModeOptimizer> BackgroundMod return nullptr; } diff --git a/www/chromium/files/patch-chrome_browser_background_glic_glic__status__icon.cc b/www/chromium/files/patch-chrome_browser_background_glic_glic__status__icon.cc new file mode 100644 index 000000000000..e705413c540a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_background_glic_glic__status__icon.cc @@ -0,0 +1,38 @@ +--- chrome/browser/background/glic/glic_status_icon.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/background/glic/glic_status_icon.cc +@@ -86,7 +86,7 @@ GlicStatusIcon::GlicStatusIcon(GlicController* control + if (!status_icon_) { + return; + } +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Set a vector icon for proper themeing on Linux. + status_icon_->SetIcon( + GlicVectorIconManager::GetVectorIcon(IDR_GLIC_BUTTON_VECTOR_ICON)); +@@ -128,7 +128,7 @@ GlicStatusIcon::~GlicStatusIcon() { + + context_menu_ = nullptr; + if (status_icon_) { +-#if !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) + status_icon_->RemoveObserver(this); + #endif + std::unique_ptr<StatusIcon> removed_icon = +@@ -234,7 +234,7 @@ void GlicStatusIcon::UpdateHotkey(const ui::Accelerato + } + + void GlicStatusIcon::UpdateVisibilityOfExitInContextMenu() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (context_menu_) { + const bool is_visible = BrowserList::GetInstance()->empty(); + const std::optional<size_t> index = +@@ -284,7 +284,7 @@ std::unique_ptr<StatusIconMenuModel> GlicStatusIcon::C + menu->AddItem(IDC_GLIC_STATUS_ICON_MENU_SETTINGS, + l10n_util::GetStringUTF16(IDS_GLIC_STATUS_ICON_MENU_SETTINGS)); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + menu->AddSeparator(ui::NORMAL_SEPARATOR); + menu->AddItem(IDC_GLIC_STATUS_ICON_MENU_EXIT, + l10n_util::GetStringUTF16(IDS_GLIC_STATUS_ICON_MENU_EXIT)); diff --git a/www/chromium/files/patch-chrome_browser_browser__features.cc b/www/chromium/files/patch-chrome_browser_browser__features.cc index 763656bbbc11..9789ae5d2925 100644 --- a/www/chromium/files/patch-chrome_browser_browser__features.cc +++ b/www/chromium/files/patch-chrome_browser_browser__features.cc @@ -1,20 +1,29 @@ ---- chrome/browser/browser_features.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/browser_features.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/browser_features.cc -@@ -76,7 +76,7 @@ const base::FeatureParam<bool> kSpareRendererWarmupDel +@@ -75,7 +75,7 @@ BASE_FEATURE(kClearUserDataUponProfileDestruction, + "ClearUserDataUponProfileDestruction", + base::FEATURE_ENABLED_BY_DEFAULT); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Enables usage of os_crypt_async::SecretPortalKeyProvider. Once + // `kSecretPortalKeyProviderUseForEncryption` is enabled, this flag cannot be + // disabled without losing data. +@@ -94,7 +94,7 @@ BASE_FEATURE(kUseFreedesktopSecretKeyProvider, + // the browser exits. BASE_FEATURE(kDestroyProfileOnBrowserClose, "DestroyProfileOnBrowserClose", - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) base::FEATURE_ENABLED_BY_DEFAULT); #else base::FEATURE_DISABLED_BY_DEFAULT); -@@ -337,7 +337,7 @@ BASE_FEATURE(kSandboxExternalProtocolBlockedWarning, - BASE_FEATURE(kSupportSearchSuggestionForPrerender2, - "SupportSearchSuggestionForPrerender2", - #if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_CHROMEOS_LACROS) || \ -- BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +@@ -232,7 +232,7 @@ BASE_FEATURE(kSandboxExternalProtocolBlockedWarning, + "SandboxExternalProtocolBlockedWarning", base::FEATURE_ENABLED_BY_DEFAULT); - #else - base::FEATURE_DISABLED_BY_DEFAULT); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // If true, encrypt new data with the key provided by SecretPortalKeyProvider. + // Otherwise, it will only decrypt existing data. + BASE_FEATURE(kSecretPortalKeyProviderUseForEncryption, diff --git a/www/chromium/files/patch-chrome_browser_browser__features.h b/www/chromium/files/patch-chrome_browser_browser__features.h new file mode 100644 index 000000000000..d65bb867aeb8 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_browser__features.h @@ -0,0 +1,20 @@ +--- chrome/browser/browser_features.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/browser_features.h +@@ -38,7 +38,7 @@ BASE_DECLARE_FEATURE(kCertificateTransparencyAskBefore + BASE_DECLARE_FEATURE(kCertVerificationNetworkTime); + BASE_DECLARE_FEATURE(kClearUserDataUponProfileDestruction); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_DECLARE_FEATURE(kDbusSecretPortal); + BASE_DECLARE_FEATURE(kUseFreedesktopSecretKeyProvider); + #endif +@@ -101,7 +101,7 @@ BASE_DECLARE_FEATURE(kRestartNetworkServiceUnsandboxed + BASE_DECLARE_FEATURE(kSandboxExternalProtocolBlocked); + BASE_DECLARE_FEATURE(kSandboxExternalProtocolBlockedWarning); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_DECLARE_FEATURE(kSecretPortalKeyProviderUseForEncryption); + BASE_DECLARE_FEATURE(kUseFreedesktopSecretKeyProviderForEncryption); + #endif diff --git a/www/chromium/files/patch-chrome_browser_browser__process__impl.cc b/www/chromium/files/patch-chrome_browser_browser__process__impl.cc index bb269b3a46a0..c2a2cf579ab0 100644 --- a/www/chromium/files/patch-chrome_browser_browser__process__impl.cc +++ b/www/chromium/files/patch-chrome_browser_browser__process__impl.cc @@ -1,29 +1,47 @@ ---- chrome/browser/browser_process_impl.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/browser_process_impl.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/browser_process_impl.cc -@@ -220,7 +220,7 @@ - #include "chrome/browser/ui/profiles/profile_picker.h" +@@ -256,7 +256,7 @@ + #include "components/enterprise/browser/controller/chrome_browser_cloud_management_controller.h" #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/error_reporting/chrome_js_error_report_processor.h" // nogncheck +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/browser_features.h" + #include "components/os_crypt/async/browser/fallback_linux_key_provider.h" + #include "components/os_crypt/async/browser/freedesktop_secret_key_provider.h" +@@ -268,7 +268,7 @@ + #include "chrome/browser/safe_browsing/safe_browsing_service.h" #endif -@@ -1253,7 +1253,7 @@ void BrowserProcessImpl::PreMainMessageLoopRun() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // How often to check if the persistent instance of Chrome needs to restart + // to install an update. + static const int kUpdateCheckIntervalHours = 6; +@@ -1168,7 +1168,7 @@ void BrowserProcessImpl::RegisterPrefs(PrefRegistrySim + GoogleUpdateSettings::GetCollectStatsConsent()); + registry->RegisterBooleanPref(prefs::kDevToolsRemoteDebuggingAllowed, true); - ApplyMetricsReportingPolicy(); - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - ChromeJsErrorReportProcessor::Create(); +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + os_crypt_async::SecretPortalKeyProvider::RegisterLocalPrefs(registry); #endif + } +@@ -1436,7 +1436,7 @@ void BrowserProcessImpl::PreMainMessageLoopRun() { + local_state()))); + #endif // BUILDFLAG(IS_WIN) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::CommandLine* cmd_line = base::CommandLine::ForCurrentProcess(); + if (cmd_line->GetSwitchValueASCII(password_manager::kPasswordStore) != + "basic") { +@@ -1720,7 +1720,7 @@ void BrowserProcessImpl::Unpin() { + } -@@ -1533,7 +1533,7 @@ void BrowserProcessImpl::Unpin() { // Mac is currently not supported. - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_WIN) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if BUILDFLAG(IS_WIN) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool BrowserProcessImpl::IsRunningInBackground() const { // Check if browser is in the background. diff --git a/www/chromium/files/patch-chrome_browser_browser__process__impl.h b/www/chromium/files/patch-chrome_browser_browser__process__impl.h index ecc8b68284cb..fc5d863712f9 100644 --- a/www/chromium/files/patch-chrome_browser_browser__process__impl.h +++ b/www/chromium/files/patch-chrome_browser_browser__process__impl.h @@ -1,11 +1,11 @@ ---- chrome/browser/browser_process_impl.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/browser_process_impl.h.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/browser_process_impl.h -@@ -389,7 +389,7 @@ class BrowserProcessImpl : public BrowserProcess, +@@ -416,7 +416,7 @@ class BrowserProcessImpl : public BrowserProcess, - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if BUILDFLAG(IS_WIN) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) + std::unique_ptr<BatteryMetrics> battery_metrics_; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) base::RepeatingTimer autoupdate_timer_; // Gets called by autoupdate timer to see if browser needs restart and can be diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__field__trials.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__field__trials.cc new file mode 100644 index 000000000000..b47c86aa1ff6 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__field__trials.cc @@ -0,0 +1,20 @@ +--- chrome/browser/chrome_browser_field_trials.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/chrome_browser_field_trials.cc +@@ -38,7 +38,7 @@ + #include "chromeos/ash/services/multidevice_setup/public/cpp/first_run_field_trial.h" + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "base/nix/xdg_util.h" + #include "ui/base/ui_base_features.h" + #endif // BUILDFLAG(IS_LINUX) +@@ -118,7 +118,7 @@ void ChromeBrowserFieldTrials::RegisterSyntheticTrials + #endif // BUILDFLAG(IS_ANDROID) + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // On Linux/Desktop platform variants, such as ozone/wayland, some features + // might need to be disabled as per OzonePlatform's runtime properties. + // OzonePlatform selection and initialization, in turn, depend on Chrome flags diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__field__trials.h b/www/chromium/files/patch-chrome_browser_chrome__browser__field__trials.h new file mode 100644 index 000000000000..34f3d97dc933 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__field__trials.h @@ -0,0 +1,11 @@ +--- chrome/browser/chrome_browser_field_trials.h.orig 2024-11-14 07:57:23 UTC ++++ chrome/browser/chrome_browser_field_trials.h +@@ -33,7 +33,7 @@ class ChromeBrowserFieldTrials : public variations::Pl + const variations::EntropyProviders& entropy_providers, + base::FeatureList* feature_list) override; + void RegisterSyntheticTrials() override; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void RegisterFeatureOverrides(base::FeatureList* feature_list) override; + #endif + diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders.cc index 4de90df96d71..d91fb3607a88 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders.cc @@ -1,81 +1,29 @@ ---- chrome/browser/chrome_browser_interface_binders.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/chrome_browser_interface_binders.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/chrome_browser_interface_binders.cc -@@ -129,13 +129,13 @@ - #endif // BUILDFLAG(FULL_SAFE_BROWSING) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/webui/connectors_internals/connectors_internals.mojom.h" - #include "chrome/browser/ui/webui/connectors_internals/connectors_internals_ui.h" - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/webui/app_settings/web_app_settings_ui.h" - #include "ui/webui/resources/cr_components/app_management/app_management.mojom.h" - #endif -@@ -224,7 +224,7 @@ - #endif // BUILDFLAG(IS_ANDROID) +@@ -80,7 +80,7 @@ + #endif // BUILDFLAG(ENABLE_UNHANDLED_TAP) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/companion/visual_query/visual_query_suggestions_service_factory.h" + #include "chrome/browser/screen_ai/screen_ai_service_router.h" + #include "chrome/browser/screen_ai/screen_ai_service_router_factory.h" #include "chrome/browser/ui/web_applications/sub_apps_service_impl.h" - #include "chrome/browser/ui/webui/discards/discards.mojom.h" -@@ -834,7 +834,7 @@ void BindScreen2xMainContentExtractor( - #endif +@@ -363,7 +363,7 @@ void BindMediaFoundationPreferences( + #endif // BUILDFLAG(IS_WIN) #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ - BUILDFLAG(IS_WIN) + BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - void BindVisualSuggestionsModelProvider( + void BindScreenAIAnnotator( content::RenderFrameHost* frame_host, - mojo::PendingReceiver< -@@ -1030,7 +1030,7 @@ void PopulateChromeFrameBinders( + mojo::PendingReceiver<screen_ai::mojom::ScreenAIAnnotator> receiver) { +@@ -522,7 +522,7 @@ void PopulateChromeFrameBinders( #endif // BUILDFLAG(ENABLE_SPEECH_SERVICE) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (!render_frame_host->GetParent()) { - map->Add<chrome::mojom::DraggableRegions>( - base::BindRepeating(&DraggableRegionsHostImpl::CreateIfAllowed)); -@@ -1038,7 +1038,7 @@ void PopulateChromeFrameBinders( - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) if (base::FeatureList::IsEnabled(blink::features::kDesktopPWAsSubApps) && !render_frame_host->GetParentOrOuterDocument()) { // The service binder will reject non-primary main frames, but we still need -@@ -1125,7 +1125,7 @@ void PopulateChromeWebUIFrameBinders( - commerce::CommerceInternalsUI>(map); - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - RegisterWebUIControllerInterfaceBinder< - connectors_internals::mojom::PageHandler, - enterprise_connectors::ConnectorsInternalsUI>(map); -@@ -1137,7 +1137,7 @@ void PopulateChromeWebUIFrameBinders( - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - RegisterWebUIControllerInterfaceBinder< - app_management::mojom::PageHandlerFactory, WebAppSettingsUI>(map); - #endif -@@ -1704,7 +1704,7 @@ void PopulateChromeWebUIFrameBinders( - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - RegisterWebUIControllerInterfaceBinder<discards::mojom::DetailsProvider, - DiscardsUI>(map); - diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders__webui.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders__webui.cc new file mode 100644 index 000000000000..4084d2ee4ef6 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__interface__binders__webui.cc @@ -0,0 +1,70 @@ +--- chrome/browser/chrome_browser_interface_binders_webui.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/chrome_browser_interface_binders_webui.cc +@@ -48,20 +48,20 @@ + #include "content/public/browser/web_ui_controller_interface_binder.h" + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/connectors_internals/connectors_internals.mojom.h" + #include "chrome/browser/ui/webui/connectors_internals/connectors_internals_ui.h" + #include "ui/webui/resources/cr_components/app_management/app_management.mojom.h" + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/discards/discards.mojom.h" + #include "chrome/browser/ui/webui/discards/discards_ui.h" + #include "chrome/browser/ui/webui/discards/site_data.mojom.h" + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/app_settings/web_app_settings_ui.h" + #include "chrome/browser/ui/webui/on_device_translation_internals/on_device_translation_internals_ui.h" + #include "chrome/browser/ui/webui/signin/history_sync_optin/history_sync_optin.mojom.h" +@@ -460,7 +460,7 @@ void PopulateChromeWebUIFrameBinders( + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + RegisterWebUIControllerInterfaceBinder< + connectors_internals::mojom::PageHandler, + enterprise_connectors::ConnectorsInternalsUI>(map); +@@ -471,7 +471,7 @@ void PopulateChromeWebUIFrameBinders( + policy::DlpInternalsUI>(map); + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + RegisterWebUIControllerInterfaceBinder< + app_management::mojom::PageHandlerFactory, WebAppSettingsUI>(map); + +@@ -609,14 +609,14 @@ void PopulateChromeWebUIFrameBinders( + HistoryClustersSidePanelUI, NewTabPageUI, BookmarksSidePanelUI>(map); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + RegisterWebUIControllerInterfaceBinder<whats_new::mojom::PageHandlerFactory, + WhatsNewUI>(map); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + + RegisterWebUIControllerInterfaceBinder< + browser_command::mojom::CommandHandlerFactory, +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + WhatsNewUI, + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + NewTabPageUI>(map); +@@ -1154,7 +1154,7 @@ void PopulateChromeWebUIFrameBinders( + #endif // BUILDFLAG(IS_CHROMEOS) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) || BUILDFLAG(IS_BSD) + RegisterWebUIControllerInterfaceBinder<discards::mojom::DetailsProvider, + DiscardsUI>(map); + diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__main.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__main.cc index d12840851581..103089671434 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__main.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__main.cc @@ -1,59 +1,56 @@ ---- chrome/browser/chrome_browser_main.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/chrome_browser_main.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/chrome_browser_main.cc -@@ -246,15 +246,15 @@ - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/first_run/upgrade_util_linux.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) +@@ -150,7 +150,7 @@ + #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "components/crash/core/app/crashpad.h" + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "sql/database.h" #endif +@@ -176,11 +176,11 @@ + #include "components/enterprise/browser/controller/chrome_browser_cloud_management_controller.h" + #endif // BUILDFLAG(IS_CHROMEOS) + -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "base/nix/xdg_util.h" + #include "chrome/browser/first_run/upgrade_util_linux.h" #endif -@@ -287,14 +287,14 @@ - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/headless/headless_mode_metrics.h" // nogncheck + #include "chrome/browser/headless/headless_mode_util.h" // nogncheck #include "chrome/browser/metrics/desktop_session_duration/desktop_session_duration_tracker.h" - #include "chrome/browser/metrics/desktop_session_duration/touch_mode_stats_tracker.h" - #include "chrome/browser/profiles/profile_activity_metrics_recorder.h" - #include "ui/base/pointer/touch_ui_controller.h" +@@ -191,7 +191,7 @@ + #include "ui/gfx/switches.h" #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - #include "chrome/browser/headless/headless_mode_metrics.h" // nogncheck - #include "chrome/browser/headless/headless_mode_util.h" // nogncheck - #include "components/headless/select_file_dialog/headless_select_file_dialog.h" -@@ -361,14 +361,14 @@ - #endif // BUILDFLAG(IS_WIN) && BUILDFLAG(USE_BROWSER_SPELLCHECKER) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/first_run/upgrade_util.h" + #endif - #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - #include "sql/database.h" - #endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || - // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) +@@ -269,7 +269,7 @@ + #include "chrome/browser/chrome_process_singleton.h" + #include "chrome/browser/ui/startup/startup_browser_creator.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "base/nix/xdg_util.h" + #endif + #endif // BUILDFLAG(ENABLE_PROCESS_SINGLETON) +@@ -292,7 +292,7 @@ namespace { - #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) constexpr base::FilePath::CharType kMediaHistoryDatabaseName[] = FILE_PATH_LITERAL("Media History"); -@@ -523,7 +523,7 @@ void ProcessSingletonNotificationCallbackImpl( +@@ -443,7 +443,7 @@ void ProcessSingletonNotificationCallbackImpl( } #endif @@ -62,57 +59,57 @@ // Set the global activation token sent as a command line switch by another // browser process. This also removes the switch after use to prevent any side // effects of leaving it in the command line after this point. -@@ -1089,7 +1089,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() { +@@ -1006,7 +1006,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() { browser_creator_->AddFirstRunTabs(master_prefs_->new_tabs); } --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) // Create directory for user-level Native Messaging manifest files. This // makes it less likely that the directory will be created by third-party // software with incorrect owner or permission. See crbug.com/725513 . -@@ -1137,7 +1137,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +@@ -1051,7 +1051,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() { + + #endif // BUILDFLAG(IS_MAC) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) metrics::DesktopSessionDurationTracker::Initialize(); ProfileActivityMetricsRecorder::Initialize(); TouchModeStatsTracker::Initialize( -@@ -1328,7 +1328,7 @@ void ChromeBrowserMainParts::PostProfileInit(Profile* +@@ -1247,7 +1247,7 @@ void ChromeBrowserMainParts::PostProfileInit(Profile* #endif // BUILDFLAG(IS_WIN) - #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) // Delete the media history database if it still exists. - // TODO(crbug.com/1198344): Remove this. + // TODO(crbug.com/40177301): Remove this. base::ThreadPool::PostTask( -@@ -1377,7 +1377,7 @@ void ChromeBrowserMainParts::PostProfileInit(Profile* +@@ -1295,7 +1295,7 @@ void ChromeBrowserMainParts::PostProfileInit(Profile* *UrlLanguageHistogramFactory::GetForBrowserContext(profile)); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) + #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) if (headless::IsHeadlessMode()) { headless::ReportHeadlessActionMetrics(); } -@@ -1485,7 +1485,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl( +@@ -1404,7 +1404,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl( // In headless mode provide alternate SelectFileDialog factory overriding // any platform specific SelectFileDialog implementation that may have been // set. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) if (headless::IsHeadlessMode()) { headless::HeadlessSelectFileDialogFactory::SetUp(); } -@@ -2030,7 +2030,7 @@ bool ChromeBrowserMainParts::ProcessSingletonNotificat +@@ -1949,7 +1949,7 @@ bool ChromeBrowserMainParts::ProcessSingletonNotificat // Drop the request if headless mode is in effect or the request is from // a headless Chrome process. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) if (headless::IsHeadlessMode() || command_line.HasSwitch(switches::kHeadless)) { return false; diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__linux.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__linux.cc index e30002b2521b..05371e9791c2 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__linux.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__linux.cc @@ -1,11 +1,11 @@ ---- chrome/browser/chrome_browser_main_extra_parts_linux.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/chrome_browser_main_extra_parts_linux.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/chrome_browser_main_extra_parts_linux.cc -@@ -169,7 +169,7 @@ ChromeBrowserMainExtraPartsLinux::ChromeBrowserMainExt - ChromeBrowserMainExtraPartsLinux::~ChromeBrowserMainExtraPartsLinux() = default; +@@ -60,7 +60,7 @@ void ChromeBrowserMainExtraPartsLinux::PostBrowserStar - void ChromeBrowserMainExtraPartsLinux::PreEarlyInitialization() { + // static + void ChromeBrowserMainExtraPartsLinux::InitOzonePlatformHint() { -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // On the desktop, we fix the platform name if necessary. - // See https://crbug.com/1246928. - auto* const command_line = base::CommandLine::ForCurrentProcess(); + base::CommandLine* const command_line = + base::CommandLine::ForCurrentProcess(); + std::unique_ptr<base::Environment> env = base::Environment::Create(); diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__ozone.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__ozone.cc index d230e1311166..8f2af9288018 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__ozone.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__main__extra__parts__ozone.cc @@ -1,11 +1,11 @@ ---- chrome/browser/chrome_browser_main_extra_parts_ozone.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/chrome_browser_main_extra_parts_ozone.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/chrome_browser_main_extra_parts_ozone.cc -@@ -27,7 +27,7 @@ void ChromeBrowserMainExtraPartsOzone::PostCreateMainM +@@ -28,7 +28,7 @@ void ChromeBrowserMainExtraPartsOzone::PostCreateMainM } void ChromeBrowserMainExtraPartsOzone::PostMainMessageLoopRun() { --#if !BUILDFLAG(IS_CHROMEOS_LACROS) && !BUILDFLAG(IS_LINUX) -+#if !BUILDFLAG(IS_CHROMEOS_LACROS) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) - // Lacros's `PostMainMessageLoopRun` must be called at the very end of - // `PostMainMessageLoopRun` in - // `ChromeBrowserMainPartsLacros::PostMainMessageLoopRun`. +-#if !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) + ui::OzonePlatform::GetInstance()->PostMainMessageLoopRun(); + #endif + } diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.cc index c341ed44a5cd..03bb56d75603 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.cc @@ -1,4 +1,4 @@ ---- chrome/browser/chrome_browser_main_linux.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/chrome_browser_main_linux.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/chrome_browser_main_linux.cc @@ -24,7 +24,7 @@ #include "device/bluetooth/dbus/bluez_dbus_thread_manager.h" @@ -9,7 +9,7 @@ #include "ui/ozone/public/ozone_platform.h" #endif -@@ -71,7 +71,9 @@ void ChromeBrowserMainPartsLinux::PostCreateMainMessag +@@ -65,7 +65,9 @@ void ChromeBrowserMainPartsLinux::PostCreateMainMessag #endif // BUILDFLAG(IS_CHROMEOS) #if !BUILDFLAG(IS_CHROMEOS) @@ -19,7 +19,7 @@ // Set up crypt config. This needs to be done before anything starts the // network service, as the raw encryption key needs to be shared with the -@@ -96,7 +98,7 @@ void ChromeBrowserMainPartsLinux::PostCreateMainMessag +@@ -91,7 +93,7 @@ void ChromeBrowserMainPartsLinux::PostCreateMainMessag ChromeBrowserMainPartsPosix::PostCreateMainMessageLoop(); } @@ -28,8 +28,8 @@ void ChromeBrowserMainPartsLinux::PostMainMessageLoopRun() { ChromeBrowserMainPartsPosix::PostMainMessageLoopRun(); ui::OzonePlatform::GetInstance()->PostMainMessageLoopRun(); -@@ -135,7 +137,7 @@ void ChromeBrowserMainPartsLinux::PostBrowserStart() { - #endif // defined(USE_DBUS) && !BUILDFLAG(IS_CHROMEOS) +@@ -129,7 +131,7 @@ void ChromeBrowserMainPartsLinux::PostBrowserStart() { + #endif // BUILDFLAG(USE_DBUS) && !BUILDFLAG(IS_CHROMEOS) void ChromeBrowserMainPartsLinux::PostDestroyThreads() { -#if BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.h b/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.h index ae75c65d03cb..6ef1f1fc63ae 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.h +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__main__linux.h @@ -1,6 +1,6 @@ ---- chrome/browser/chrome_browser_main_linux.h.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/chrome_browser_main_linux.h.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/chrome_browser_main_linux.h -@@ -30,7 +30,7 @@ class ChromeBrowserMainPartsLinux : public ChromeBrows +@@ -31,7 +31,7 @@ class ChromeBrowserMainPartsLinux : public ChromeBrows // ChromeBrowserMainPartsPosix overrides. void PostCreateMainMessageLoop() override; diff --git a/www/chromium/files/patch-chrome_browser_chrome__browser__main__posix.cc b/www/chromium/files/patch-chrome_browser_chrome__browser__main__posix.cc index 2a8765abda83..0d62e8fa4feb 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__browser__main__posix.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__browser__main__posix.cc @@ -1,11 +1,11 @@ ---- chrome/browser/chrome_browser_main_posix.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/chrome_browser_main_posix.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/chrome_browser_main_posix.cc -@@ -79,7 +79,7 @@ void ExitHandler::ExitWhenPossibleOnUIThread(int signa +@@ -81,7 +81,7 @@ void ExitHandler::ExitWhenPossibleOnUIThread(int signa + // ExitHandler takes care of deleting itself. + new ExitHandler(); } else { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) switch (signal) { case SIGINT: case SIGHUP: diff --git a/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.cc b/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.cc index 7f9cb252ad26..f75ed139169f 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.cc +++ b/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.cc @@ -1,49 +1,34 @@ ---- chrome/browser/chrome_content_browser_client.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/chrome_content_browser_client.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/chrome_content_browser_client.cc -@@ -460,7 +460,7 @@ +@@ -468,7 +468,7 @@ + #include "components/user_manager/user_manager.h" + #include "services/service_manager/public/mojom/interface_provider_spec.mojom.h" #include "storage/browser/file_system/external_mount_points.h" - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "chrome/browser/chrome_browser_main_linux.h" #include "chrome/browser/ui/views/chrome_browser_main_extra_parts_views_linux.h" #elif BUILDFLAG(IS_ANDROID) -@@ -569,12 +569,12 @@ - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) - #include "chrome/browser/browser_switcher/browser_switcher_navigation_throttle.h" - #endif +@@ -563,7 +563,7 @@ + #include "services/network/public/mojom/permissions_policy/permissions_policy_feature.mojom.h" + #endif // !BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "components/crash/core/app/crash_switches.h" #include "components/crash/core/app/crashpad.h" #endif -@@ -585,7 +585,7 @@ - #include "chrome/browser/apps/link_capturing/web_app_link_capturing_delegate.h" +@@ -572,7 +572,7 @@ + #include "components/crash/content/browser/crash_handler_host_linux.h" #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) #include "chrome/browser/enterprise/chrome_browser_main_extra_parts_enterprise.h" - #include "chrome/browser/enterprise/profile_management/oidc_auth_response_capture_navigation_throttle.h" - #include "chrome/browser/enterprise/profile_management/profile_management_navigation_throttle.h" -@@ -593,7 +593,7 @@ #endif - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "chrome/browser/enterprise/connectors/device_trust/navigation_throttle.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || - // BUILDFLAG(IS_CHROMEOS_ASH) -@@ -609,7 +609,7 @@ - #include "components/lens/lens_features.h" +@@ -580,7 +580,7 @@ + #include "chrome/browser/ui/views/chrome_browser_main_extra_parts_views.h" #endif -#if BUILDFLAG(IS_LINUX) @@ -51,35 +36,35 @@ #include "chrome/browser/chrome_browser_main_extra_parts_linux.h" #elif BUILDFLAG(IS_OZONE) #include "chrome/browser/chrome_browser_main_extra_parts_ozone.h" -@@ -1474,7 +1474,7 @@ void ChromeContentBrowserClient::RegisterLocalStatePre - #if BUILDFLAG(IS_CHROMEOS) - registry->RegisterBooleanPref(prefs::kNativeClientForceAllowed, false); +@@ -1398,7 +1398,7 @@ void ChromeContentBrowserClient::RegisterLocalStatePre + registry->RegisterBooleanPref(prefs::kDeviceNativeClientForceAllowedCache, + false); #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) registry->RegisterBooleanPref(prefs::kOutOfProcessSystemDnsResolutionEnabled, true); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_ANDROID) -@@ -1598,7 +1598,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo - #elif BUILDFLAG(IS_CHROMEOS_LACROS) - main_parts = std::make_unique<ChromeBrowserMainPartsLacros>( +@@ -1617,7 +1617,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo + #elif BUILDFLAG(IS_CHROMEOS) + main_parts = std::make_unique<ash::ChromeBrowserMainPartsAsh>( is_integration_test, &startup_data_); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) main_parts = std::make_unique<ChromeBrowserMainPartsLinux>( is_integration_test, &startup_data_); #elif BUILDFLAG(IS_ANDROID) -@@ -1635,7 +1635,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo - std::make_unique<ChromeBrowserMainExtraPartsViewsLacros>()); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +@@ -1648,7 +1648,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo + // Construct additional browser parts. Stages are called in the order in + // which they are added. + #if defined(TOOLKIT_VIEWS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) main_parts->AddParts( std::make_unique<ChromeBrowserMainExtraPartsViewsLinux>()); #else -@@ -1656,7 +1656,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo - main_parts->AddParts(std::make_unique<ChromeBrowserMainExtraPartsLacros>()); +@@ -1665,7 +1665,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo + main_parts->AddParts(std::make_unique<ChromeBrowserMainExtraPartsAsh>()); #endif -#if BUILDFLAG(IS_LINUX) @@ -87,7 +72,7 @@ main_parts->AddParts(std::make_unique<ChromeBrowserMainExtraPartsLinux>()); #elif BUILDFLAG(IS_OZONE) main_parts->AddParts(std::make_unique<ChromeBrowserMainExtraPartsOzone>()); -@@ -1675,7 +1675,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo +@@ -1684,7 +1684,7 @@ ChromeContentBrowserClient::CreateBrowserMainParts(boo chrome::AddMetricsExtraParts(main_parts.get()); @@ -95,8 +80,18 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) main_parts->AddParts( std::make_unique< - chrome::enterprise_util::ChromeBrowserMainExtraPartsEnterprise>()); -@@ -2515,7 +2515,7 @@ void ChromeContentBrowserClient::AppendExtraCommandLin + enterprise_util::ChromeBrowserMainExtraPartsEnterprise>()); +@@ -2628,7 +2628,9 @@ void MaybeAppendBlinkSettingsSwitchForFieldTrial( + void ChromeContentBrowserClient::AppendExtraCommandLineSwitches( + base::CommandLine* command_line, + int child_process_id) { ++#ifdef notyet + crash_keys::AppendStringAnnotationsCommandLineSwitch(command_line); ++#endif + #if BUILDFLAG(IS_MAC) + std::unique_ptr<metrics::ClientInfo> client_info = + GoogleUpdateSettings::LoadMetricsClientInfo(); +@@ -2637,7 +2639,7 @@ void ChromeContentBrowserClient::AppendExtraCommandLin client_info->client_id); } #elif BUILDFLAG(IS_POSIX) @@ -105,16 +100,34 @@ pid_t pid; if (crash_reporter::GetHandlerSocket(nullptr, &pid)) { command_line->AppendSwitchASCII( -@@ -2847,7 +2847,7 @@ void ChromeContentBrowserClient::AppendExtraCommandLin - ThreadProfilerConfiguration::Get()->AppendCommandLineSwitchForChildProcess( - command_line); +@@ -3005,7 +3007,7 @@ void ChromeContentBrowserClient::AppendExtraCommandLin + } + } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && !BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && !BUILDFLAG(IS_BSD) // Opt into a hardened stack canary mitigation if it hasn't already been // force-disabled. if (!browser_command_line.HasSwitch(switches::kChangeStackGuardOnFork)) { -@@ -4551,7 +4551,7 @@ void ChromeContentBrowserClient::GetAdditionalFileSyst +@@ -3994,7 +3996,7 @@ bool UpdatePreferredColorScheme(WebPreferences* web_pr + return old_preferred_color_scheme != web_prefs->preferred_color_scheme; + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // Sets the `root_scrollbar_theme_color` web pref if the user has enabled a + // custom colored frame for the UI. + void UpdateRootScrollbarThemeColor(Profile* profile, +@@ -4631,7 +4633,7 @@ void ChromeContentBrowserClient::OverrideWebPreference + + UpdatePreferredColorScheme(web_prefs, main_frame_site.GetSiteURL(), + web_contents, GetWebTheme()); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + UpdateRootScrollbarThemeColor(profile, web_contents, web_prefs); + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) + +@@ -4956,7 +4958,7 @@ void ChromeContentBrowserClient::GetAdditionalFileSyst } } @@ -123,34 +136,7 @@ void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess( const base::CommandLine& command_line, int child_process_id, -@@ -5109,7 +5109,7 @@ ChromeContentBrowserClient::CreateThrottlesForNavigati - &throttles); - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - MaybeAddThrottle( - WebAppSettingsNavigationThrottle::MaybeCreateThrottleFor(handle), - &throttles); -@@ -5123,7 +5123,7 @@ ChromeContentBrowserClient::CreateThrottlesForNavigati - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) - - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - MaybeAddThrottle(enterprise_connectors::DeviceTrustNavigationThrottle:: - MaybeCreateThrottleFor(handle), - &throttles); -@@ -5162,7 +5162,7 @@ ChromeContentBrowserClient::CreateThrottlesForNavigati - handle)); - } - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - MaybeAddThrottle(browser_switcher::BrowserSwitcherNavigationThrottle:: - MaybeCreateThrottleFor(handle), - &throttles); -@@ -7137,7 +7137,7 @@ bool ChromeContentBrowserClient::ShouldSandboxNetworkS +@@ -7120,7 +7122,7 @@ bool ChromeContentBrowserClient::ShouldSandboxNetworkS bool ChromeContentBrowserClient::ShouldRunOutOfProcessSystemDnsResolution() { // This enterprise policy is supported on Android, but the feature will not be // launched there. diff --git a/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.h b/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.h index 09f934d3be83..f0a2c6fd2ed0 100644 --- a/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.h +++ b/www/chromium/files/patch-chrome_browser_chrome__content__browser__client.h @@ -1,6 +1,6 @@ ---- chrome/browser/chrome_content_browser_client.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/chrome_content_browser_client.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/chrome_content_browser_client.h -@@ -500,7 +500,7 @@ class ChromeContentBrowserClient : public content::Con +@@ -577,7 +577,7 @@ class ChromeContentBrowserClient : public content::Con bool IsPluginAllowedToUseDevChannelAPIs( content::BrowserContext* browser_context, const GURL& url) override; diff --git a/www/chromium/files/patch-chrome_browser_chrome__content__browser__client__navigation__throttles.cc b/www/chromium/files/patch-chrome_browser_chrome__content__browser__client__navigation__throttles.cc new file mode 100644 index 000000000000..0e9b92fa33a5 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_chrome__content__browser__client__navigation__throttles.cc @@ -0,0 +1,38 @@ +--- chrome/browser/chrome_content_browser_client_navigation_throttles.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/chrome_content_browser_client_navigation_throttles.cc +@@ -123,7 +123,7 @@ + #include "chrome/browser/captive_portal/captive_portal_service_factory.h" + #endif // BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/browser_switcher/browser_switcher_navigation_throttle.h" + #include "chrome/browser/enterprise/profile_management/oidc_auth_response_capture_navigation_throttle.h" + #include "chrome/browser/enterprise/profile_management/profile_management_navigation_throttle.h" +@@ -407,7 +407,7 @@ void CreateAndAddChromeThrottlesForNavigation( + TypedNavigationUpgradeThrottle::MaybeCreateAndAdd(registry); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + WebAppSettingsNavigationThrottle::MaybeCreateAndAdd(registry); + profile_management::ProfileManagementNavigationThrottle::MaybeCreateAndAdd( + registry); +@@ -425,7 +425,7 @@ void CreateAndAddChromeThrottlesForNavigation( + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + enterprise_connectors::DeviceTrustNavigationThrottle::MaybeCreateAndAdd( + registry); + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || +@@ -457,7 +457,7 @@ void CreateAndAddChromeThrottlesForNavigation( + } + #endif // BUILDFLAG(SAFE_BROWSING_AVAILABLE) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + browser_switcher::BrowserSwitcherNavigationThrottle::MaybeCreateAndAdd( + registry); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_collaboration_messaging_messaging__backend__service__factory.cc b/www/chromium/files/patch-chrome_browser_collaboration_messaging_messaging__backend__service__factory.cc new file mode 100644 index 000000000000..ccc64fc33650 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_collaboration_messaging_messaging__backend__service__factory.cc @@ -0,0 +1,11 @@ +--- chrome/browser/collaboration/messaging/messaging_backend_service_factory.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/collaboration/messaging/messaging_backend_service_factory.cc +@@ -102,7 +102,7 @@ MessagingBackendServiceFactory::BuildServiceInstanceFo + // This configuration object allows us to control platform specific behavior. + MessagingBackendConfiguration configuration; + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + configuration.clear_chip_on_tab_selection = false; + #endif + diff --git a/www/chromium/files/patch-chrome_browser_component__updater_iwa__key__distribution__component__installer.cc b/www/chromium/files/patch-chrome_browser_component__updater_iwa__key__distribution__component__installer.cc new file mode 100644 index 000000000000..e7f059c0acd7 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_component__updater_iwa__key__distribution__component__installer.cc @@ -0,0 +1,20 @@ +--- chrome/browser/component_updater/iwa_key_distribution_component_installer.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/component_updater/iwa_key_distribution_component_installer.cc +@@ -77,7 +77,7 @@ bool IsOnDemandUpdateSupported() { + + namespace component_updater { + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kIwaKeyDistributionComponent, + "IwaKeyDistributionComponent", + #if BUILDFLAG(IS_CHROMEOS) +@@ -102,7 +102,7 @@ bool IwaKeyDistributionComponentInstallerPolicy::IsSup + // the main IWA feature. + #if BUILDFLAG(IS_WIN) + return base::FeatureList::IsEnabled(features::kIsolatedWebApps); +-#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return base::FeatureList::IsEnabled(kIwaKeyDistributionComponent); + #else + return false; diff --git a/www/chromium/files/patch-chrome_browser_component__updater_iwa__key__distribution__component__installer.h b/www/chromium/files/patch-chrome_browser_component__updater_iwa__key__distribution__component__installer.h new file mode 100644 index 000000000000..2ea48944aab1 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_component__updater_iwa__key__distribution__component__installer.h @@ -0,0 +1,11 @@ +--- chrome/browser/component_updater/iwa_key_distribution_component_installer.h.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/component_updater/iwa_key_distribution_component_installer.h +@@ -27,7 +27,7 @@ class IwaKeyDistributionInfoProvider; + + namespace component_updater { + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_DECLARE_FEATURE(kIwaKeyDistributionComponent); + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-chrome_browser_component__updater_registration.cc b/www/chromium/files/patch-chrome_browser_component__updater_registration.cc new file mode 100644 index 000000000000..c47015903a39 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_component__updater_registration.cc @@ -0,0 +1,35 @@ +--- chrome/browser/component_updater/registration.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/component_updater/registration.cc +@@ -102,7 +102,7 @@ + #endif // BUILDFLAG(ENABLE_WIDEVINE_CDM_COMPONENT) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "components/component_updater/installer_policies/amount_extraction_heuristic_regexes_component_installer.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) +@@ -115,7 +115,7 @@ + #include "chrome/browser/component_updater/lacros_component_remover.h" + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/component_updater/wasm_tts_engine_component_installer.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +@@ -263,12 +263,12 @@ void RegisterComponentsForUpdate() { + RegisterCookieReadinessListComponent(cus); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + RegisterAmountExtractionHeuristicRegexesComponent(cus); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (features::IsWasmTtsComponentUpdaterEnabled()) { + RegisterWasmTtsEngineComponent(cus); + } diff --git a/www/chromium/files/patch-chrome_browser_component__updater_wasm__tts__engine__component__installer.cc b/www/chromium/files/patch-chrome_browser_component__updater_wasm__tts__engine__component__installer.cc new file mode 100644 index 000000000000..7b0728bdadce --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_component__updater_wasm__tts__engine__component__installer.cc @@ -0,0 +1,38 @@ +--- chrome/browser/component_updater/wasm_tts_engine_component_installer.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/component_updater/wasm_tts_engine_component_installer.cc +@@ -9,7 +9,7 @@ + #include "base/logging.h" + #include "content/public/browser/browser_thread.h" + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/accessibility/embedded_a11y_extension_loader.h" + #include "chrome/common/extensions/extension_constants.h" + #include "ui/accessibility/accessibility_features.h" +@@ -41,7 +41,7 @@ constexpr std::array<uint8_t, 32> kWasmTtsEnginePublic + + const char kWasmTtsEngineManifestName[] = "WASM TTS Engine"; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + class WasmTTSEngineDirectory { + public: + static WasmTTSEngineDirectory* Get() { +@@ -111,7 +111,7 @@ void WasmTtsEngineComponentInstallerPolicy::ComponentR + VLOG(1) << "Component ready, version " << version.GetString() << " in " + << install_dir.value(); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (features::IsWasmTtsComponentUpdaterEnabled() && + !features::IsWasmTtsEngineAutoInstallDisabled()) { + // Instead of installing the component extension as soon as it is ready, +@@ -166,7 +166,7 @@ void RegisterWasmTtsEngineComponent(ComponentUpdateSer + + void WasmTtsEngineComponentInstallerPolicy::GetWasmTTSEngineDirectory( + base::OnceCallback<void(const base::FilePath&)> callback) { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + WasmTTSEngineDirectory* wasm_directory = WasmTTSEngineDirectory::Get(); + wasm_directory->Get(std::move(callback)); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_component__updater_widevine__cdm__component__installer.cc b/www/chromium/files/patch-chrome_browser_component__updater_widevine__cdm__component__installer.cc index 3480496cccdd..c3ca1b36768c 100644 --- a/www/chromium/files/patch-chrome_browser_component__updater_widevine__cdm__component__installer.cc +++ b/www/chromium/files/patch-chrome_browser_component__updater_widevine__cdm__component__installer.cc @@ -1,15 +1,15 @@ ---- chrome/browser/component_updater/widevine_cdm_component_installer.cc.orig 2024-03-27 13:31:02 UTC +--- chrome/browser/component_updater/widevine_cdm_component_installer.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/component_updater/widevine_cdm_component_installer.cc -@@ -40,7 +40,7 @@ +@@ -41,7 +41,7 @@ #include "third_party/widevine/cdm/buildflags.h" #include "third_party/widevine/cdm/widevine_cdm_common.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "base/path_service.h" + #include "chrome/common/chrome_paths.h" #include "chrome/common/media/component_widevine_cdm_hint_file_linux.h" - #endif - -@@ -78,7 +78,7 @@ static_assert(std::size(kWidevineSha2Hash) == crypto:: +@@ -73,7 +73,7 @@ static_assert(std::size(kWidevineSha2Hash) == crypto:: const char ImageLoaderComponentName[] = "WidevineCdm"; #endif @@ -18,12 +18,21 @@ // On Linux and ChromeOS the Widevine CDM is loaded at startup before the // zygote is locked down. As a result there is no need to register the CDM // with Chrome as it can't be used until Chrome is restarted. -@@ -364,7 +364,7 @@ void WidevineCdmComponentInstallerPolicy::UpdateCdmPat +@@ -101,7 +101,7 @@ void RegisterWidevineCdmWithChrome(const base::Version + } + #endif // !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // On Linux and ChromeOS the Widevine CDM is loaded at startup before the + // zygote is locked down. To locate the Widevine CDM at startup, a hint file + // is used. Update the hint file with the new Widevine CDM path. +@@ -392,7 +392,7 @@ void WidevineCdmComponentInstallerPolicy::UpdateCdmPat return; } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) VLOG(1) << "Updating hint file with Widevine CDM " << cdm_version; // This is running on a thread that allows IO, so simply update the hint file. diff --git a/www/chromium/files/patch-chrome_browser_defaults.cc b/www/chromium/files/patch-chrome_browser_defaults.cc index 0c5849fe4b5e..327623f2fde4 100644 --- a/www/chromium/files/patch-chrome_browser_defaults.cc +++ b/www/chromium/files/patch-chrome_browser_defaults.cc @@ -1,6 +1,6 @@ ---- chrome/browser/defaults.cc.orig 2023-10-11 18:22:24 UTC +--- chrome/browser/defaults.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/defaults.cc -@@ -44,7 +44,7 @@ const bool kShowHelpMenuItemIcon = true; +@@ -31,7 +31,7 @@ const bool kAlwaysCreateTabbedBrowserOnSessionRestore const bool kShowHelpMenuItemIcon = false; #endif diff --git a/www/chromium/files/patch-chrome_browser_device__identity_device__oauth2__token__service__factory.cc b/www/chromium/files/patch-chrome_browser_device__identity_device__oauth2__token__service__factory.cc index e5e00061d6ab..6430e200c973 100644 --- a/www/chromium/files/patch-chrome_browser_device__identity_device__oauth2__token__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_device__identity_device__oauth2__token__service__factory.cc @@ -1,11 +1,11 @@ ---- chrome/browser/device_identity/device_oauth2_token_service_factory.cc.orig 2022-02-28 16:54:41 UTC +--- chrome/browser/device_identity/device_oauth2_token_service_factory.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/device_identity/device_oauth2_token_service_factory.cc -@@ -28,7 +28,7 @@ std::unique_ptr<DeviceOAuth2TokenStore> CreatePlatform +@@ -26,7 +26,7 @@ std::unique_ptr<DeviceOAuth2TokenStore> CreatePlatform + #if BUILDFLAG(IS_CHROMEOS) return std::make_unique<chromeos::DeviceOAuth2TokenStoreChromeOS>( local_state); - #elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return std::make_unique<DeviceOAuth2TokenStoreDesktop>(local_state); #else NOTREACHED(); diff --git a/www/chromium/files/patch-chrome_browser_devtools_features.cc b/www/chromium/files/patch-chrome_browser_devtools_features.cc new file mode 100644 index 000000000000..f89d9de69779 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_devtools_features.cc @@ -0,0 +1,11 @@ +--- chrome/browser/devtools/features.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/devtools/features.cc +@@ -164,7 +164,7 @@ BASE_FEATURE(kDevToolsNewPermissionDialog, + "DevToolsNewPermissionDialog", + base::FEATURE_ENABLED_BY_DEFAULT); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // If enabled, DevTools does not accept remote debugging connections unless + // using a non-default user data dir via the --user-data-dir switch. + BASE_FEATURE(kDevToolsDebuggingRestrictions, diff --git a/www/chromium/files/patch-chrome_browser_devtools_features.h b/www/chromium/files/patch-chrome_browser_devtools_features.h new file mode 100644 index 000000000000..8496bb3def7f --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_devtools_features.h @@ -0,0 +1,11 @@ +--- chrome/browser/devtools/features.h.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/devtools/features.h +@@ -92,7 +92,7 @@ BASE_DECLARE_FEATURE(kDevToolsAiGeneratedTimelineLabel + + BASE_DECLARE_FEATURE(kDevToolsNewPermissionDialog); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_DECLARE_FEATURE(kDevToolsDebuggingRestrictions); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-chrome_browser_devtools_remote__debugging__server.cc b/www/chromium/files/patch-chrome_browser_devtools_remote__debugging__server.cc new file mode 100644 index 000000000000..703521dd27a1 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_devtools_remote__debugging__server.cc @@ -0,0 +1,11 @@ +--- chrome/browser/devtools/remote_debugging_server.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/devtools/remote_debugging_server.cc +@@ -109,7 +109,7 @@ IsRemoteDebuggingAllowed(const std::optional<bool>& is + RemoteDebuggingServer::NotStartedReason::kDisabledByPolicy); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled(features::kDevToolsDebuggingRestrictions) && + is_default_user_data_dir.value_or(true)) { + return base::unexpected( diff --git a/www/chromium/files/patch-chrome_browser_diagnostics_diagnostics__writer.h b/www/chromium/files/patch-chrome_browser_diagnostics_diagnostics__writer.h index 43c1038a8248..62fe3d689a00 100644 --- a/www/chromium/files/patch-chrome_browser_diagnostics_diagnostics__writer.h +++ b/www/chromium/files/patch-chrome_browser_diagnostics_diagnostics__writer.h @@ -1,6 +1,6 @@ ---- chrome/browser/diagnostics/diagnostics_writer.h.orig 2022-02-07 13:39:41 UTC +--- chrome/browser/diagnostics/diagnostics_writer.h.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/diagnostics/diagnostics_writer.h -@@ -14,6 +14,8 @@ namespace diagnostics { +@@ -16,6 +16,8 @@ namespace diagnostics { // Console base class used internally. class SimpleConsole; diff --git a/www/chromium/files/patch-chrome_browser_download_chrome__download__manager__delegate.cc b/www/chromium/files/patch-chrome_browser_download_chrome__download__manager__delegate.cc index 6f39ad9b49ca..cbfd429fc181 100644 --- a/www/chromium/files/patch-chrome_browser_download_chrome__download__manager__delegate.cc +++ b/www/chromium/files/patch-chrome_browser_download_chrome__download__manager__delegate.cc @@ -1,6 +1,6 @@ ---- chrome/browser/download/chrome_download_manager_delegate.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/download/chrome_download_manager_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/download/chrome_download_manager_delegate.cc -@@ -1700,7 +1700,7 @@ void ChromeDownloadManagerDelegate::OnDownloadTargetDe +@@ -1922,7 +1922,7 @@ void ChromeDownloadManagerDelegate::OnDownloadTargetDe bool ChromeDownloadManagerDelegate::IsOpenInBrowserPreferredForFile( const base::FilePath& path) { #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -9,7 +9,7 @@ if (path.MatchesExtension(FILE_PATH_LITERAL(".pdf"))) { return !download_prefs_->ShouldOpenPdfInSystemReader(); } -@@ -1819,7 +1819,7 @@ void ChromeDownloadManagerDelegate::CheckDownloadAllow +@@ -2058,7 +2058,7 @@ void ChromeDownloadManagerDelegate::CheckDownloadAllow content::CheckDownloadAllowedCallback check_download_allowed_cb) { DCHECK_CURRENTLY_ON(BrowserThread::UI); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -18,12 +18,12 @@ // Don't download pdf if it is a file URL, as that might cause an infinite // download loop if Chrome is not the system pdf viewer. if (url.SchemeIsFile() && download_prefs_->ShouldOpenPdfInSystemReader()) { -@@ -1865,7 +1865,7 @@ void ChromeDownloadManagerDelegate::CheckSavePackageAl +@@ -2140,7 +2140,7 @@ void ChromeDownloadManagerDelegate::CheckSavePackageAl DCHECK(download_item->IsSavePackageDownload()); - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_MAC) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ +- BUILDFLAG(IS_MAC)) && \ ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD)) && \ + BUILDFLAG(SAFE_BROWSING_AVAILABLE) std::optional<enterprise_connectors::AnalysisSettings> settings = - safe_browsing::DeepScanningRequest::ShouldUploadBinary(download_item); - + safe_browsing::ShouldUploadBinaryForDeepScanning(download_item); diff --git a/www/chromium/files/patch-chrome_browser_download_download__commands.cc b/www/chromium/files/patch-chrome_browser_download_download__commands.cc index 2f0723813bcb..945383043a0c 100644 --- a/www/chromium/files/patch-chrome_browser_download_download__commands.cc +++ b/www/chromium/files/patch-chrome_browser_download_download__commands.cc @@ -1,20 +1,20 @@ ---- chrome/browser/download/download_commands.cc.orig 2023-04-05 11:05:06 UTC +--- chrome/browser/download/download_commands.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/download/download_commands.cc -@@ -26,7 +26,7 @@ +@@ -27,7 +27,7 @@ #include "ui/base/clipboard/scoped_clipboard_writer.h" #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) #include "chrome/browser/ui/browser.h" #include "chrome/browser/ui/browser_finder.h" #include "chrome/browser/ui/scoped_tabbed_browser_displayer.h" -@@ -167,7 +167,7 @@ void DownloadCommands::ExecuteCommand(Command command) +@@ -177,7 +177,7 @@ void DownloadCommands::ExecuteCommand(Command command) } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) Browser* DownloadCommands::GetBrowser() const { if (!model_) diff --git a/www/chromium/files/patch-chrome_browser_download_download__commands.h b/www/chromium/files/patch-chrome_browser_download_download__commands.h index edbc1392ce5a..b0cbfb893cc3 100644 --- a/www/chromium/files/patch-chrome_browser_download_download__commands.h +++ b/www/chromium/files/patch-chrome_browser_download_download__commands.h @@ -1,11 +1,11 @@ ---- chrome/browser/download/download_commands.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/download/download_commands.h.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/download/download_commands.h -@@ -63,7 +63,7 @@ class DownloadCommands { +@@ -66,7 +66,7 @@ class DownloadCommands { void ExecuteCommand(Command command); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) bool IsDownloadPdf() const; bool CanOpenPdfInSystemViewer() const; Browser* GetBrowser() const; diff --git a/www/chromium/files/patch-chrome_browser_download_download__file__picker.cc b/www/chromium/files/patch-chrome_browser_download_download__file__picker.cc index 2507aa8f3529..f2bee5115058 100644 --- a/www/chromium/files/patch-chrome_browser_download_download__file__picker.cc +++ b/www/chromium/files/patch-chrome_browser_download_download__file__picker.cc @@ -1,11 +1,11 @@ ---- chrome/browser/download/download_file_picker.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/download/download_file_picker.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/download/download_file_picker.cc @@ -18,7 +18,7 @@ #include "content/public/browser/web_contents.h" #include "ui/shell_dialogs/selected_file_info.h" --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) #include "chrome/browser/ui/browser_list.h" #include "chrome/browser/ui/browser_window.h" #include "ui/aura/window.h" @@ -13,8 +13,8 @@ // dialog in Linux (See SelectFileImpl() in select_file_dialog_linux_gtk.cc). // and windows.Here we make owning_window host to browser current active // window if it is null. https://crbug.com/1301898 --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) if (!owning_window || !owning_window->GetHost()) { owning_window = BrowserList::GetInstance() ->GetLastActive() diff --git a/www/chromium/files/patch-chrome_browser_download_download__item__model.cc b/www/chromium/files/patch-chrome_browser_download_download__item__model.cc index 7797d68c90b6..b36398cd3df6 100644 --- a/www/chromium/files/patch-chrome_browser_download_download__item__model.cc +++ b/www/chromium/files/patch-chrome_browser_download_download__item__model.cc @@ -1,6 +1,6 @@ ---- chrome/browser/download/download_item_model.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/download/download_item_model.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/download/download_item_model.cc -@@ -752,7 +752,7 @@ bool DownloadItemModel::IsCommandChecked( +@@ -772,7 +772,7 @@ bool DownloadItemModel::IsCommandChecked( download_crx_util::IsExtensionDownload(*download_); case DownloadCommands::ALWAYS_OPEN_TYPE: #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -9,7 +9,7 @@ if (download_commands->CanOpenPdfInSystemViewer()) { DownloadPrefs* prefs = DownloadPrefs::FromBrowserContext(profile()); return prefs->ShouldOpenPdfInSystemReader(); -@@ -798,7 +798,7 @@ void DownloadItemModel::ExecuteCommand(DownloadCommand +@@ -820,7 +820,7 @@ void DownloadItemModel::ExecuteCommand(DownloadCommand DownloadCommands::ALWAYS_OPEN_TYPE); DownloadPrefs* prefs = DownloadPrefs::FromBrowserContext(profile()); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -18,7 +18,7 @@ if (download_commands->CanOpenPdfInSystemViewer()) { prefs->SetShouldOpenPdfInSystemReader(!is_checked); SetShouldPreferOpeningInBrowser(is_checked); -@@ -1189,7 +1189,7 @@ void DownloadItemModel::DetermineAndSetShouldPreferOpe +@@ -1210,7 +1210,7 @@ void DownloadItemModel::DetermineAndSetShouldPreferOpe return; } diff --git a/www/chromium/files/patch-chrome_browser_download_download__prefs.cc b/www/chromium/files/patch-chrome_browser_download_download__prefs.cc index e2e9c3914f64..7b23d163ccc3 100644 --- a/www/chromium/files/patch-chrome_browser_download_download__prefs.cc +++ b/www/chromium/files/patch-chrome_browser_download_download__prefs.cc @@ -1,4 +1,4 @@ ---- chrome/browser/download/download_prefs.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/download/download_prefs.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/download/download_prefs.cc @@ -11,6 +11,7 @@ #include <vector> @@ -8,8 +8,8 @@ #include "base/feature_list.h" #include "base/files/file_util.h" #include "base/functional/bind.h" -@@ -64,6 +65,10 @@ - #include "chrome/browser/flags/android/chrome_feature_list.h" +@@ -61,6 +62,10 @@ + #include "components/safe_browsing/content/common/file_type_policies.h" #endif +#if BUILDFLAG(IS_BSD) @@ -29,7 +29,7 @@ if (download_path == home_dir) { return true; @@ -180,7 +185,7 @@ DownloadPrefs::DownloadPrefs(Profile* profile) : profi - #endif // BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_CHROMEOS) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_MAC) @@ -37,7 +37,7 @@ should_open_pdf_in_system_reader_ = prefs->GetBoolean(prefs::kOpenPdfDownloadInSystemReader); #endif -@@ -306,7 +311,7 @@ void DownloadPrefs::RegisterProfilePrefs( +@@ -307,7 +312,7 @@ void DownloadPrefs::RegisterProfilePrefs( registry->RegisterFilePathPref(prefs::kSaveFileDefaultDirectory, default_download_path); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -46,7 +46,7 @@ registry->RegisterBooleanPref(prefs::kOpenPdfDownloadInSystemReader, false); #endif #if BUILDFLAG(IS_ANDROID) -@@ -473,7 +478,7 @@ void DownloadPrefs::DisableAutoOpenByUserBasedOnExtens +@@ -480,7 +485,7 @@ void DownloadPrefs::DisableAutoOpenByUserBasedOnExtens } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -55,7 +55,7 @@ void DownloadPrefs::SetShouldOpenPdfInSystemReader(bool should_open) { if (should_open_pdf_in_system_reader_ == should_open) return; -@@ -505,7 +510,7 @@ bool DownloadPrefs::ShouldOpenPdfInSystemReader() cons +@@ -506,7 +511,7 @@ bool DownloadPrefs::ShouldOpenPdfInSystemReader() cons void DownloadPrefs::ResetAutoOpenByUser() { #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -64,7 +64,7 @@ SetShouldOpenPdfInSystemReader(false); #endif auto_open_by_user_.clear(); -@@ -545,7 +550,7 @@ void DownloadPrefs::SaveAutoOpenState() { +@@ -543,7 +548,7 @@ void DownloadPrefs::SaveAutoOpenState() { bool DownloadPrefs::CanPlatformEnableAutoOpenForPdf() const { #if BUILDFLAG(IS_CHROMEOS) return false; // There is no UI for auto-open on ChromeOS. @@ -73,7 +73,7 @@ return ShouldOpenPdfInSystemReader(); #else return false; -@@ -697,7 +702,14 @@ base::FilePath DownloadPrefs::SanitizeDownloadTargetPa +@@ -625,7 +630,14 @@ base::FilePath DownloadPrefs::SanitizeDownloadTargetPa #else // If the stored download directory is an absolute path, we presume it's // correct; there's not really much more validation we can do here. diff --git a/www/chromium/files/patch-chrome_browser_download_download__prefs.h b/www/chromium/files/patch-chrome_browser_download_download__prefs.h index 2e348b1e453b..a68cb8042f12 100644 --- a/www/chromium/files/patch-chrome_browser_download_download__prefs.h +++ b/www/chromium/files/patch-chrome_browser_download_download__prefs.h @@ -1,6 +1,6 @@ ---- chrome/browser/download/download_prefs.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/download/download_prefs.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/download/download_prefs.h -@@ -115,7 +115,7 @@ class DownloadPrefs { +@@ -107,7 +107,7 @@ class DownloadPrefs { void DisableAutoOpenByUserBasedOnExtension(const base::FilePath& file_name); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -9,7 +9,7 @@ // Store the user preference to disk. If |should_open| is true, also disable // the built-in PDF plugin. If |should_open| is false, enable the PDF plugin. void SetShouldOpenPdfInSystemReader(bool should_open); -@@ -179,7 +179,7 @@ class DownloadPrefs { +@@ -171,7 +171,7 @@ class DownloadPrefs { std::unique_ptr<policy::URLBlocklist> auto_open_allowed_by_urls_; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ diff --git a/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.cc b/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.cc index bef6889d4a8e..e97709652b0b 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.cc @@ -1,29 +1,47 @@ ---- chrome/browser/enterprise/browser_management/browser_management_service.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/enterprise/browser_management/browser_management_service.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/enterprise/browser_management/browser_management_service.cc -@@ -21,7 +21,7 @@ namespace policy { +@@ -50,7 +50,7 @@ GetManagementStatusProviders(Profile* profile) { - namespace { + BrowserManagementService::BrowserManagementService(Profile* profile) + : ManagementService(GetManagementStatusProviders(profile)) { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::SequencedTaskRunner::GetCurrentDefault()->PostTask( + FROM_HERE, + base::BindOnce(&BrowserManagementService::UpdateManagementIconForProfile, +@@ -74,7 +74,7 @@ BrowserManagementService::BrowserManagementService(Pro + } + ui::ImageModel* BrowserManagementService::GetManagementIconForProfile() { -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void UpdateEnterpriseLogo( - Profile* profile, - base::OnceCallback<void(const gfx::Image&, -@@ -98,7 +98,7 @@ GetManagementStatusProviders(Profile* profile) { - } // namespace + return management_icon_for_profile_.IsEmpty() ? nullptr + : &management_icon_for_profile_; + #else +@@ -83,7 +83,7 @@ ui::ImageModel* BrowserManagementService::GetManagemen + } - BrowserManagementMetadata::BrowserManagementMetadata(Profile* profile) { + gfx::Image* BrowserManagementService::GetManagementIconForBrowser() { -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - UpdateManagementLogo(profile); - pref_change_registrar_.Init(profile->GetPrefs()); - pref_change_registrar_.Add( -@@ -114,7 +114,7 @@ const gfx::Image& BrowserManagementMetadata::GetManage - return management_logo_; + return management_icon_for_browser_.IsEmpty() ? nullptr + : &management_icon_for_browser_; + #else +@@ -96,7 +96,7 @@ void BrowserManagementService::TriggerPolicyStatusChan + OnPolicyStatusChanged(); } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void BrowserManagementMetadata::UpdateManagementLogo(Profile* profile) { - UpdateEnterpriseLogo( - profile, base::BindOnce(&BrowserManagementMetadata::SetManagementLogo, + void BrowserManagementService::SetBrowserManagementIconForTesting( + const gfx::Image& management_icon) { + CHECK_IS_TEST(); +@@ -171,7 +171,7 @@ void BrowserManagementService::SetManagementIconForBro + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + + void BrowserManagementService::OnPolicyStatusChanged() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + NotifyEnterpriseLabelUpdated(); + #endif + } diff --git a/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.h b/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.h index 65bb8b408533..d366a7518bbf 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.h +++ b/www/chromium/files/patch-chrome_browser_enterprise_browser__management_browser__management__service.h @@ -1,11 +1,20 @@ ---- chrome/browser/enterprise/browser_management/browser_management_service.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/enterprise/browser_management/browser_management_service.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/enterprise/browser_management/browser_management_service.h -@@ -28,7 +28,7 @@ class BrowserManagementMetadata { +@@ -41,7 +41,7 @@ class BrowserManagementService : public ManagementServ - const gfx::Image& GetManagementLogo() const; + void TriggerPolicyStatusChangedForTesting() override; -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - private: - void UpdateManagementLogo(Profile* profile); - void SetManagementLogo( + void SetBrowserManagementIconForTesting( + const gfx::Image& management_icon) override; + #endif +@@ -50,7 +50,7 @@ class BrowserManagementService : public ManagementServ + // PolicyStatusProvider::Observer: + void OnPolicyStatusChanged() override; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Starts listening to changes to policies that affect the enterprise label + // and pill. + void StartListeningToPrefChanges(Profile* profile); diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_analysis_analysis__service__settings.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_analysis_analysis__service__settings.cc index 9b7bb5a36928..bca66636d073 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_analysis_analysis__service__settings.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_analysis_analysis__service__settings.cc @@ -1,6 +1,6 @@ ---- chrome/browser/enterprise/connectors/analysis/analysis_service_settings.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/enterprise/connectors/analysis/analysis_service_settings.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/enterprise/connectors/analysis/analysis_service_settings.cc -@@ -150,7 +150,7 @@ AnalysisServiceSettings::AnalysisServiceSettings( +@@ -151,7 +151,7 @@ AnalysisServiceSettings::AnalysisServiceSettings( const char* verification_key = kKeyWindowsVerification; #elif BUILDFLAG(IS_MAC) const char* verification_key = kKeyMacVerification; diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_common.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_common.cc new file mode 100644 index 000000000000..1e930d3c73a5 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_common.cc @@ -0,0 +1,20 @@ +--- chrome/browser/enterprise/connectors/common.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/enterprise/connectors/common.cc +@@ -17,7 +17,7 @@ + #include "components/user_manager/user.h" + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/signin/enterprise_signin_prefs.h" + #include "components/prefs/pref_service.h" + #endif +@@ -192,7 +192,7 @@ std::string GetProfileEmail(Profile* profile) { + std::string email = + GetProfileEmail(IdentityManagerFactory::GetForProfile(profile)); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (email.empty()) { + email = profile->GetPrefs()->GetString( + enterprise_signin::prefs::kProfileUserEmail); diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_connectors__service.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_connectors__service.cc index 7d1c563ad09f..d1d2fac11c1f 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_connectors__service.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_connectors__service.cc @@ -1,7 +1,7 @@ ---- chrome/browser/enterprise/connectors/connectors_service.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/enterprise/connectors/connectors_service.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/enterprise/connectors/connectors_service.cc -@@ -564,7 +564,7 @@ bool ConnectorsService::ConnectorsEnabled() const { - +@@ -449,7 +449,7 @@ policy::PolicyScope ConnectorsService::GetPolicyScope( + bool ConnectorsService::ConnectorsEnabled() const { Profile* profile = Profile::FromBrowserContext(context_); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__connector__service__factory.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__connector__service__factory.cc index f0e0ac80b052..150a80908e89 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__connector__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__connector__service__factory.cc @@ -1,4 +1,4 @@ ---- chrome/browser/enterprise/connectors/device_trust/device_trust_connector_service_factory.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/enterprise/connectors/device_trust/device_trust_connector_service_factory.cc.orig 2024-08-26 12:06:38 UTC +++ chrome/browser/enterprise/connectors/device_trust/device_trust_connector_service_factory.cc @@ -10,7 +10,7 @@ #include "chrome/browser/profiles/profile.h" @@ -18,7 +18,7 @@ return true; #else return false; -@@ -79,7 +79,7 @@ DeviceTrustConnectorServiceFactory::BuildServiceInstan +@@ -84,7 +84,7 @@ DeviceTrustConnectorServiceFactory::BuildServiceInstan std::unique_ptr<DeviceTrustConnectorService> service = std::make_unique<DeviceTrustConnectorService>(profile->GetPrefs()); diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__service__factory.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__service__factory.cc index 4eb285d38ba2..eab13c42e7cb 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_device__trust__service__factory.cc @@ -1,6 +1,6 @@ ---- chrome/browser/enterprise/connectors/device_trust/device_trust_service_factory.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/enterprise/connectors/device_trust/device_trust_service_factory.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/enterprise/connectors/device_trust/device_trust_service_factory.cc -@@ -23,7 +23,7 @@ +@@ -22,7 +22,7 @@ #include "components/policy/core/common/management/management_service.h" #include "content/public/browser/browser_context.h" @@ -9,7 +9,7 @@ #include "chrome/browser/browser_process.h" #include "chrome/browser/enterprise/connectors/device_trust/attestation/browser/browser_attestation_service.h" #include "chrome/browser/enterprise/connectors/device_trust/attestation/browser/device_attester.h" -@@ -54,7 +54,7 @@ bool IsProfileManaged(Profile* profile) { +@@ -53,7 +53,7 @@ bool IsProfileManaged(Profile* profile) { return management_service && management_service->IsManaged(); } @@ -17,8 +17,8 @@ +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) policy::CloudPolicyStore* GetUserCloudPolicyStore(Profile* profile) { policy::CloudPolicyManager* user_policy_manager = - profile->GetUserCloudPolicyManager(); -@@ -104,7 +104,7 @@ DeviceTrustServiceFactory::DeviceTrustServiceFactory() + profile->GetCloudPolicyManager(); +@@ -105,7 +105,7 @@ DeviceTrustServiceFactory::DeviceTrustServiceFactory() DependsOn(DeviceTrustConnectorServiceFactory::GetInstance()); DependsOn(policy::ManagementServiceFactory::GetInstance()); diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_browser_commands_key__rotation__command__factory.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_browser_commands_key__rotation__command__factory.cc index 0b19e1ffa74d..341bf2cad072 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_browser_commands_key__rotation__command__factory.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_browser_commands_key__rotation__command__factory.cc @@ -1,6 +1,6 @@ ---- chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands/key_rotation_command_factory.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands/key_rotation_command_factory.cc.orig 2024-10-22 08:31:56 UTC +++ chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands/key_rotation_command_factory.cc -@@ -14,7 +14,7 @@ +@@ -19,7 +19,7 @@ #if BUILDFLAG(IS_WIN) #include "chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands/win_key_rotation_command.h" @@ -9,12 +9,12 @@ #include "chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands/linux_key_rotation_command.h" #elif BUILDFLAG(IS_MAC) #include "chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands/mac_key_rotation_command.h" -@@ -47,7 +47,7 @@ std::unique_ptr<KeyRotationCommand> KeyRotationCommand - scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory) { +@@ -53,7 +53,7 @@ std::unique_ptr<KeyRotationCommand> KeyRotationCommand + policy::DeviceManagementService* device_management_service) { #if BUILDFLAG(IS_WIN) return std::make_unique<WinKeyRotationCommand>(); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return std::make_unique<LinuxKeyRotationCommand>(url_loader_factory); #elif BUILDFLAG(IS_MAC) - return std::make_unique<MacKeyRotationCommand>(url_loader_factory); + if (IsDTCKeyRotationUploadedBySharedAPI()) { diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_core_persistence_key__persistence__delegate__factory.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_core_persistence_key__persistence__delegate__factory.cc index fb6820846a59..e8a0f825946c 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_core_persistence_key__persistence__delegate__factory.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_key__management_core_persistence_key__persistence__delegate__factory.cc @@ -1,4 +1,4 @@ ---- chrome/browser/enterprise/connectors/device_trust/key_management/core/persistence/key_persistence_delegate_factory.cc.orig 2023-08-17 07:33:31 UTC +--- chrome/browser/enterprise/connectors/device_trust/key_management/core/persistence/key_persistence_delegate_factory.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/enterprise/connectors/device_trust/key_management/core/persistence/key_persistence_delegate_factory.cc @@ -13,7 +13,7 @@ #include "chrome/browser/enterprise/connectors/device_trust/key_management/core/persistence/win_key_persistence_delegate.h" diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_signals_signals__service__factory.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_signals_signals__service__factory.cc index 93836ab0884c..748d09c6d1e2 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_signals_signals__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_device__trust_signals_signals__service__factory.cc @@ -1,17 +1,17 @@ ---- chrome/browser/enterprise/connectors/device_trust/signals/signals_service_factory.cc.orig 2023-08-17 07:33:31 UTC +--- chrome/browser/enterprise/connectors/device_trust/signals/signals_service_factory.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/enterprise/connectors/device_trust/signals/signals_service_factory.cc -@@ -21,7 +21,7 @@ - #include "chrome/browser/profiles/profile.h" - #include "components/policy/core/common/management/management_service.h" +@@ -23,7 +23,7 @@ + #include "chrome/browser/enterprise/connectors/connectors_service.h" + #endif // BUILDFLAG(ENTERPRISE_CLOUD_CONTENT_ANALYSIS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) #include "base/check.h" #include "chrome/browser/enterprise/connectors/device_trust/signals/decorators/browser/browser_signals_decorator.h" - #include "chrome/browser/enterprise/connectors/device_trust/signals/dependency_factory.h" -@@ -58,7 +58,7 @@ std::unique_ptr<SignalsService> CreateSignalsService(P - enterprise_signals::ContextInfoFetcher::CreateInstance( + #include "chrome/browser/enterprise/core/dependency_factory_impl.h" +@@ -63,7 +63,7 @@ std::unique_ptr<SignalsService> CreateSignalsService(P profile, ConnectorsServiceFactory::GetForBrowserContext(profile)))); + #endif // BUILDFLAG(ENTERPRISE_CLOUD_CONTENT_ANALYSIS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_browser__crash__event__router.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_browser__crash__event__router.cc index cdc383179c1f..a0dce50c23cf 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_browser__crash__event__router.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_browser__crash__event__router.cc @@ -1,20 +1,20 @@ ---- chrome/browser/enterprise/connectors/reporting/browser_crash_event_router.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/enterprise/connectors/reporting/browser_crash_event_router.cc.orig 2024-08-26 12:06:38 UTC +++ chrome/browser/enterprise/connectors/reporting/browser_crash_event_router.cc -@@ -11,7 +11,7 @@ namespace enterprise_connectors { +@@ -13,7 +13,7 @@ namespace enterprise_connectors { BrowserCrashEventRouter::BrowserCrashEventRouter( content::BrowserContext* context) { --#if !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_CHROMEOS) -+#if !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) +-#if !BUILDFLAG(IS_CHROMEOS) ++#if !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) CrashReportingContext* crash_reporting_context = CrashReportingContext::GetInstance(); Profile* profile = Profile::FromBrowserContext(context); -@@ -21,7 +21,7 @@ BrowserCrashEventRouter::BrowserCrashEventRouter( +@@ -23,7 +23,7 @@ BrowserCrashEventRouter::BrowserCrashEventRouter( } BrowserCrashEventRouter::~BrowserCrashEventRouter() { --#if !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_CHROMEOS) -+#if !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) +-#if !BUILDFLAG(IS_CHROMEOS) ++#if !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) CrashReportingContext* crash_reporting_context = CrashReportingContext::GetInstance(); crash_reporting_context->RemoveProfile(this); diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_crash__reporting__context.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_crash__reporting__context.cc index 89fffff10498..f20b4a68911c 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_crash__reporting__context.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_crash__reporting__context.cc @@ -1,11 +1,11 @@ ---- chrome/browser/enterprise/connectors/reporting/crash_reporting_context.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/enterprise/connectors/reporting/crash_reporting_context.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/enterprise/connectors/reporting/crash_reporting_context.cc -@@ -18,7 +18,7 @@ +@@ -28,7 +28,7 @@ namespace enterprise_connectors { --#if !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_CHROMEOS) -+#if !BUILDFLAG(IS_FUCHSIA) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) +-#if !BUILDFLAG(IS_CHROMEOS) ++#if !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) namespace { diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.cc b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.cc index b274583f3a8f..1382503940d2 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.cc @@ -1,25 +1,16 @@ ---- chrome/browser/enterprise/connectors/reporting/realtime_reporting_client.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/enterprise/connectors/reporting/realtime_reporting_client.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/enterprise/connectors/reporting/realtime_reporting_client.cc -@@ -58,7 +58,7 @@ +@@ -52,7 +52,7 @@ #include "base/strings/utf_string_conversions.h" #endif -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "chrome/browser/enterprise/signals/signals_aggregator_factory.h" + #include "chrome/browser/enterprise/signin/enterprise_signin_prefs.h" #include "components/device_signals/core/browser/signals_aggregator.h" - #include "components/device_signals/core/common/signals_constants.h" -@@ -132,7 +132,7 @@ void UploadSecurityEventReport(base::Value::Dict event - std::move(upload_callback)); - } - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void PopulateSignals(base::Value::Dict event, - policy::CloudPolicyClient* client, - std::string name, -@@ -420,7 +420,7 @@ void RealtimeReportingClient::ReportPastEvent(const st - /*include_profile_user_name=*/false); +@@ -157,7 +157,7 @@ void RealtimeReportingClient::ReportPastEvent(const st + /*include_profile_user_name=*/false); } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) @@ -27,12 +18,21 @@ void AddCrowdstrikeSignalsToEvent( base::Value::Dict& event, -@@ -479,7 +479,7 @@ void RealtimeReportingClient::ReportEventWithTimestamp - if (include_profile_user_name) { - event.Set(kKeyProfileUserName, GetProfileUserName()); - } +@@ -193,7 +193,7 @@ std::string RealtimeReportingClient::GetProfileUserNam + username_ = + identity_manager_ ? GetProfileEmail(identity_manager_) : std::string(); + -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - Profile* profile = Profile::FromBrowserContext(context_); - device_signals::SignalsAggregator* signals_aggregator = - enterprise_signals::SignalsAggregatorFactory::GetForProfile(profile); + if (username_.empty()) { + username_ = Profile::FromBrowserContext(context_)->GetPrefs()->GetString( + enterprise_signin::prefs::kProfileUserEmail); +@@ -245,7 +245,7 @@ std::string RealtimeReportingClient::GetBrowserClientI + return client_id; + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(notyet) + void RealtimeReportingClient::MaybeCollectDeviceSignalsAndReportEvent( + ::chrome::cros::reporting::proto::Event event, + policy::CloudPolicyClient* client, diff --git a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.h b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.h index a8318619cded..f8dbce911536 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.h +++ b/www/chromium/files/patch-chrome_browser_enterprise_connectors_reporting_realtime__reporting__client.h @@ -1,6 +1,6 @@ ---- chrome/browser/enterprise/connectors/reporting/realtime_reporting_client.h.orig 2023-10-11 18:22:24 UTC +--- chrome/browser/enterprise/connectors/reporting/realtime_reporting_client.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/enterprise/connectors/reporting/realtime_reporting_client.h -@@ -16,7 +16,7 @@ +@@ -19,7 +19,7 @@ #include "components/keyed_service/core/keyed_service.h" #include "components/policy/core/common/cloud/cloud_policy_client.h" @@ -9,7 +9,16 @@ #include "components/device_signals/core/browser/signals_types.h" #endif -@@ -184,7 +184,7 @@ class RealtimeReportingClient : public KeyedService, +@@ -116,7 +116,7 @@ class RealtimeReportingClient : public RealtimeReporti + const std::string& dm_token) override; + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(notyet) + // DEPRECATED: Use MaybeCollectDeviceSignalsAndReportEvent(Event, ...). + void MaybeCollectDeviceSignalsAndReportEventDeprecated( + base::Value::Dict event, +@@ -166,7 +166,7 @@ class RealtimeReportingClient : public RealtimeReporti base::WeakPtrFactory<RealtimeReportingClient> weak_ptr_factory_{this}; }; diff --git a/www/chromium/files/patch-chrome_browser_enterprise_identifiers_profile__id__delegate__impl.cc b/www/chromium/files/patch-chrome_browser_enterprise_identifiers_profile__id__delegate__impl.cc deleted file mode 100644 index 52e7d98c7add..000000000000 --- a/www/chromium/files/patch-chrome_browser_enterprise_identifiers_profile__id__delegate__impl.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- chrome/browser/enterprise/identifiers/profile_id_delegate_impl.cc.orig 2023-01-11 09:17:16 UTC -+++ chrome/browser/enterprise/identifiers/profile_id_delegate_impl.cc -@@ -12,7 +12,7 @@ - #include "components/enterprise/browser/identifiers/identifiers_prefs.h" - #include "components/prefs/pref_service.h" - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - #include "components/enterprise/browser/controller/browser_dm_token_storage.h" - #if BUILDFLAG(IS_WIN) - #include "base/strings/utf_string_conversions.h" -@@ -36,7 +36,7 @@ void CreateProfileGUID(PrefService* prefs) { - } - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - // Gets the device ID from the BrowserDMTokenStorage. - std::string GetId() { - std::string device_id = diff --git a/www/chromium/files/patch-chrome_browser_enterprise_profile__management_profile__management__navigation__throttle.cc b/www/chromium/files/patch-chrome_browser_enterprise_profile__management_profile__management__navigation__throttle.cc index 106bd4aaaa5e..ce799e41d54c 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_profile__management_profile__management__navigation__throttle.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_profile__management_profile__management__navigation__throttle.cc @@ -1,7 +1,7 @@ ---- chrome/browser/enterprise/profile_management/profile_management_navigation_throttle.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/enterprise/profile_management/profile_management_navigation_throttle.cc.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/enterprise/profile_management/profile_management_navigation_throttle.cc @@ -67,8 +67,8 @@ base::flat_map<std::string, SAMLProfileAttributes>& Ge - // TODO(crbug.com/1445072): Add actual domains with attribute names. + // TODO(crbug.com/40267996): Add actual domains with attribute names. profile_attributes->insert(std::make_pair( "supported.test", - SAMLProfileAttributes("placeholderName", "placeholderDomain", diff --git a/www/chromium/files/patch-chrome_browser_enterprise_reporting_cloud__profile__reporting__service.cc b/www/chromium/files/patch-chrome_browser_enterprise_reporting_cloud__profile__reporting__service.cc new file mode 100644 index 000000000000..a6a6430f017c --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_reporting_cloud__profile__reporting__service.cc @@ -0,0 +1,20 @@ +--- chrome/browser/enterprise/reporting/cloud_profile_reporting_service.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/enterprise/reporting/cloud_profile_reporting_service.cc +@@ -34,7 +34,7 @@ + #include "extensions/buildflags/buildflags.h" + #include "services/network/public/cpp/shared_url_loader_factory.h" + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/signals/signals_aggregator_factory.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +@@ -113,7 +113,7 @@ void CloudProfileReportingService::CreateReportSchedul + params.profile_request_generator = + std::make_unique<ChromeProfileRequestGenerator>( + profile_->GetPath(), &delegate_factory, +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + enterprise_signals::SignalsAggregatorFactory::GetForProfile( + profile_)); + #else diff --git a/www/chromium/files/patch-chrome_browser_enterprise_reporting_cloud__profile__reporting__service__factory.cc b/www/chromium/files/patch-chrome_browser_enterprise_reporting_cloud__profile__reporting__service__factory.cc new file mode 100644 index 000000000000..7c672ac5f5f6 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_reporting_cloud__profile__reporting__service__factory.cc @@ -0,0 +1,20 @@ +--- chrome/browser/enterprise/reporting/cloud_profile_reporting_service_factory.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/enterprise/reporting/cloud_profile_reporting_service_factory.cc +@@ -10,7 +10,7 @@ + #include "components/enterprise/browser/reporting/report_scheduler.h" + #include "services/network/public/cpp/shared_url_loader_factory.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/signals/signals_aggregator_factory.h" + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) + +@@ -48,7 +48,7 @@ CloudProfileReportingServiceFactory::CloudProfileRepor + ProfileSelections::BuildForRegularProfile()) { + DependsOn(enterprise::ProfileIdServiceFactory::GetInstance()); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Depends on this service because + // `CloudProfileReportingService.profile_request_generator_` has a dependency + // on it. diff --git a/www/chromium/files/patch-chrome_browser_enterprise_signals_context__info__fetcher.cc b/www/chromium/files/patch-chrome_browser_enterprise_signals_context__info__fetcher.cc new file mode 100644 index 000000000000..efc9569428b5 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_signals_context__info__fetcher.cc @@ -0,0 +1,20 @@ +--- chrome/browser/enterprise/signals/context_info_fetcher.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/enterprise/signals/context_info_fetcher.cc +@@ -181,6 +181,8 @@ std::vector<std::string> ContextInfoFetcher::GetOnSecu + SettingValue ContextInfoFetcher::GetOSFirewall() { + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) + return device_signals::GetOSFirewall(); ++#elif BUILDFLAG(IS_OPENBSD) ++ return SettingValue::ENABLED; + #elif BUILDFLAG(IS_CHROMEOS) + return GetChromeosFirewall(); + #else +@@ -200,7 +202,7 @@ ScopedUfwConfigPathForTesting::~ScopedUfwConfigPathFor + #endif // BUILDFLAG(IS_LINUX) + + std::vector<std::string> ContextInfoFetcher::GetDnsServers() { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + return device_signals::GetSystemDnsServers(); + #else + return std::vector<std::string>(); diff --git a/www/chromium/files/patch-chrome_browser_enterprise_signals_device__info__fetcher.cc b/www/chromium/files/patch-chrome_browser_enterprise_signals_device__info__fetcher.cc index eea255884d98..2c9e37aee9f4 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_signals_device__info__fetcher.cc +++ b/www/chromium/files/patch-chrome_browser_enterprise_signals_device__info__fetcher.cc @@ -1,4 +1,4 @@ ---- chrome/browser/enterprise/signals/device_info_fetcher.cc.orig 2023-10-11 18:22:24 UTC +--- chrome/browser/enterprise/signals/device_info_fetcher.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/enterprise/signals/device_info_fetcher.cc @@ -10,7 +10,7 @@ #include "chrome/browser/enterprise/signals/device_info_fetcher_mac.h" @@ -9,7 +9,7 @@ #include "chrome/browser/enterprise/signals/device_info_fetcher_linux.h" #endif -@@ -67,7 +67,7 @@ std::unique_ptr<DeviceInfoFetcher> DeviceInfoFetcher:: +@@ -76,7 +76,7 @@ std::unique_ptr<DeviceInfoFetcher> DeviceInfoFetcher:: return CreateInstanceInternal(); } diff --git a/www/chromium/files/patch-chrome_browser_enterprise_signin_enterprise__signin__service.h b/www/chromium/files/patch-chrome_browser_enterprise_signin_enterprise__signin__service.h new file mode 100644 index 000000000000..3d1947147df1 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_signin_enterprise__signin__service.h @@ -0,0 +1,11 @@ +--- chrome/browser/enterprise/signin/enterprise_signin_service.h.orig 2024-08-26 12:06:38 UTC ++++ chrome/browser/enterprise/signin/enterprise_signin_service.h +@@ -9,7 +9,7 @@ + + #include "build/build_config.h" + +-#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN)) ++#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) + #error EnterpriseSigninService should only be built on desktop platforms. + #endif // !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN)) + diff --git a/www/chromium/files/patch-chrome_browser_enterprise_signin_interstitials_managed__profile__required__page.cc b/www/chromium/files/patch-chrome_browser_enterprise_signin_interstitials_managed__profile__required__page.cc new file mode 100644 index 000000000000..a7d58bbd898d --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_signin_interstitials_managed__profile__required__page.cc @@ -0,0 +1,11 @@ +--- chrome/browser/enterprise/signin/interstitials/managed_profile_required_page.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/enterprise/signin/interstitials/managed_profile_required_page.cc +@@ -94,7 +94,7 @@ void ManagedProfileRequiredPage::CommandReceived(const + + switch (cmd) { + case security_interstitials::CMD_DONT_PROCEED: +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (ManagedProfileRequiredNavigationThrottle::IsBlockingNavigations( + web_contents()->GetBrowserContext())) { + ManagedProfileRequiredNavigationThrottle::ShowBlockedWindow( diff --git a/www/chromium/files/patch-chrome_browser_enterprise_util_managed__browser__utils.cc b/www/chromium/files/patch-chrome_browser_enterprise_util_managed__browser__utils.cc new file mode 100644 index 000000000000..d94a8cc5ff77 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_enterprise_util_managed__browser__utils.cc @@ -0,0 +1,29 @@ +--- chrome/browser/enterprise/util/managed_browser_utils.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/enterprise/util/managed_browser_utils.cc +@@ -213,7 +213,7 @@ void SetUserAcceptedAccountManagement(Profile* profile + // The updated consent screen also ask the user for consent to share device + // signals. + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (accepted && base::FeatureList::IsEnabled( + features::kEnterpriseUpdatedProfileCreationScreen)) { + profile->GetPrefs()->SetBoolean( +@@ -225,7 +225,7 @@ void SetUserAcceptedAccountManagement(Profile* profile + profile_manager->GetProfileAttributesStorage() + .GetProfileAttributesWithPath(profile->GetPath()); + if (entry) { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + SetEnterpriseProfileLabel(profile); + #endif + entry->SetUserAcceptedAccountManagement(accepted); +@@ -344,7 +344,7 @@ bool CanShowEnterpriseProfileUI(Profile* profile) { + } + + bool CanShowEnterpriseBadgingForNTPFooter(Profile* profile) { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + + auto* management_service = + policy::ManagementServiceFactory::GetForProfile(profile); diff --git a/www/chromium/files/patch-chrome_browser_extensions_BUILD.gn b/www/chromium/files/patch-chrome_browser_extensions_BUILD.gn index a79290ef12de..2468ea83d223 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_BUILD.gn +++ b/www/chromium/files/patch-chrome_browser_extensions_BUILD.gn @@ -1,13 +1,13 @@ ---- chrome/browser/extensions/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/extensions/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/extensions/BUILD.gn -@@ -1384,6 +1384,10 @@ static_library("extensions") { - deps += [ "//chrome/services/printing/public/mojom" ] - } +@@ -1479,6 +1479,10 @@ source_set("extensions") { + deps += [ "//chrome/services/printing/public/mojom" ] + } -+ if (is_bsd) { -+ sources -= [ "api/image_writer_private/removable_storage_provider_linux.cc" ] -+ } ++ if (is_bsd) { ++ sources -= [ "api/image_writer_private/removable_storage_provider_linux.cc" ] ++ } + - if (enable_service_discovery) { - sources += [ - "api/mdns/mdns_api.cc", + if (enable_pdf) { + deps += [ + "//chrome/browser/pdf", diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_api__browser__context__keyed__service__factories.cc b/www/chromium/files/patch-chrome_browser_extensions_api_api__browser__context__keyed__service__factories.cc deleted file mode 100644 index ce01047a2f5e..000000000000 --- a/www/chromium/files/patch-chrome_browser_extensions_api_api__browser__context__keyed__service__factories.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- chrome/browser/extensions/api/api_browser_context_keyed_service_factories.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/extensions/api/api_browser_context_keyed_service_factories.cc -@@ -45,7 +45,7 @@ - #include "printing/buildflags/buildflags.h" - #include "services/screen_ai/buildflags/buildflags.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "chrome/browser/extensions/api/system_indicator/system_indicator_manager_factory.h" - #endif - -@@ -128,7 +128,7 @@ void EnsureApiBrowserContextKeyedServiceFactoriesBuilt - extensions::SettingsPrivateEventRouterFactory::GetInstance(); - extensions::SettingsOverridesAPI::GetFactoryInstance(); - extensions::SidePanelService::GetFactoryInstance(); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - extensions::SystemIndicatorManagerFactory::GetInstance(); - #endif - extensions::TabGroupsEventRouterFactory::GetInstance(); diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_chrome__desktop__report__request__helper.cc b/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_chrome__desktop__report__request__helper.cc index 6da3a15e6d7e..9db1d37817f4 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_chrome__desktop__report__request__helper.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_chrome__desktop__report__request__helper.cc @@ -1,4 +1,4 @@ ---- chrome/browser/extensions/api/enterprise_reporting_private/chrome_desktop_report_request_helper.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/extensions/api/enterprise_reporting_private/chrome_desktop_report_request_helper.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/extensions/api/enterprise_reporting_private/chrome_desktop_report_request_helper.cc @@ -24,7 +24,7 @@ #include "base/win/registry.h" @@ -9,7 +9,7 @@ #include "base/environment.h" #include "base/nix/xdg_util.h" #endif -@@ -255,7 +255,7 @@ base::FilePath GetEndpointVerificationDir() { +@@ -264,7 +264,7 @@ base::FilePath GetEndpointVerificationDir() { bool got_path = false; #if BUILDFLAG(IS_WIN) got_path = base::PathService::Get(base::DIR_LOCAL_APP_DATA, &path); @@ -18,7 +18,7 @@ std::unique_ptr<base::Environment> env(base::Environment::Create()); path = base::nix::GetXDGDirectory(env.get(), base::nix::kXdgConfigHomeEnvVar, base::nix::kDotConfigDir); -@@ -266,7 +266,7 @@ base::FilePath GetEndpointVerificationDir() { +@@ -275,7 +275,7 @@ base::FilePath GetEndpointVerificationDir() { if (!got_path) return path; diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_enterprise__reporting__private__api.cc b/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_enterprise__reporting__private__api.cc index cd22ff4c2f1e..c12e349ee015 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_enterprise__reporting__private__api.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_enterprise__reporting__private_enterprise__reporting__private__api.cc @@ -1,6 +1,6 @@ ---- chrome/browser/extensions/api/enterprise_reporting_private/enterprise_reporting_private_api.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/extensions/api/enterprise_reporting_private/enterprise_reporting_private_api.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/extensions/api/enterprise_reporting_private/enterprise_reporting_private_api.cc -@@ -32,7 +32,7 @@ +@@ -40,7 +40,7 @@ #include "components/reporting/util/statusor.h" #endif @@ -9,8 +9,17 @@ #include <optional> #include "base/strings/string_util.h" -@@ -149,7 +149,7 @@ api::enterprise_reporting_private::ContextInfo ToConte - return info; +@@ -156,7 +156,7 @@ api::enterprise_reporting_private::ContextInfo ToConte + } + + bool AllowClientCertificateReportingForUsers() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return base::FeatureList::IsEnabled( + enterprise_signals::features::kAllowClientCertificateReportingForUsers); + #else +@@ -169,7 +169,7 @@ bool IsProfilePrefManaged(Profile* profile, std::strin + return pref && pref->IsManaged(); } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) @@ -18,7 +27,7 @@ device_signals::SignalsAggregationRequest CreateAggregationRequest( device_signals::SignalName signal_name) { -@@ -210,7 +210,7 @@ EnterpriseReportingPrivateGetDeviceIdFunction:: +@@ -231,7 +231,7 @@ EnterpriseReportingPrivateGetDeviceIdFunction:: // getPersistentSecret @@ -27,7 +36,7 @@ EnterpriseReportingPrivateGetPersistentSecretFunction:: EnterpriseReportingPrivateGetPersistentSecretFunction() = default; -@@ -636,7 +636,7 @@ void EnterpriseReportingPrivateEnqueueRecordFunction:: +@@ -671,7 +671,7 @@ void EnterpriseReportingPrivateEnqueueRecordFunction:: } #endif diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_management_chrome__management__api__delegate.cc b/www/chromium/files/patch-chrome_browser_extensions_api_management_chrome__management__api__delegate.cc deleted file mode 100644 index 308f32b4efcd..000000000000 --- a/www/chromium/files/patch-chrome_browser_extensions_api_management_chrome__management__api__delegate.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/extensions/api/management/chrome_management_api_delegate.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/extensions/api/management/chrome_management_api_delegate.cc -@@ -408,7 +408,7 @@ bool ChromeManagementAPIDelegate::LaunchAppFunctionDel - apps::LaunchContainer launch_container = - GetLaunchContainer(extensions::ExtensionPrefs::Get(context), extension); - Profile* profile = Profile::FromBrowserContext(context); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (extensions::IsExtensionUnsupportedDeprecatedApp(profile, - extension->id())) { - return false; diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_messaging_launch__context__posix.cc b/www/chromium/files/patch-chrome_browser_extensions_api_messaging_launch__context__posix.cc new file mode 100644 index 000000000000..c9db7cee9df4 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_extensions_api_messaging_launch__context__posix.cc @@ -0,0 +1,11 @@ +--- chrome/browser/extensions/api/messaging/launch_context_posix.cc.orig 2024-11-14 07:57:23 UTC ++++ chrome/browser/extensions/api/messaging/launch_context_posix.cc +@@ -84,7 +84,7 @@ std::optional<LaunchContext::ProcessState> LaunchConte + + options.current_directory = command_line.GetProgram().DirName(); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Don't use no_new_privs mode, e.g. in case the host needs to use sudo. + options.allow_new_privs = true; + #endif diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_messaging_native__process__launcher__posix.cc b/www/chromium/files/patch-chrome_browser_extensions_api_messaging_native__process__launcher__posix.cc deleted file mode 100644 index 835ab8925c96..000000000000 --- a/www/chromium/files/patch-chrome_browser_extensions_api_messaging_native__process__launcher__posix.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc.orig 2023-12-10 06:10:27 UTC -+++ chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc -@@ -84,7 +84,7 @@ bool NativeProcessLauncher::LaunchNativeProcess( - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - // Don't use no_new_privs mode, e.g. in case the host needs to use sudo. - options.allow_new_privs = true; - #endif diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_passwords__private_passwords__private__delegate__impl.cc b/www/chromium/files/patch-chrome_browser_extensions_api_passwords__private_passwords__private__delegate__impl.cc index 54023892bd1c..94e200529eb7 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_passwords__private_passwords__private__delegate__impl.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_passwords__private_passwords__private__delegate__impl.cc @@ -1,6 +1,6 @@ ---- chrome/browser/extensions/api/passwords_private/passwords_private_delegate_impl.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/extensions/api/passwords_private/passwords_private_delegate_impl.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/extensions/api/passwords_private/passwords_private_delegate_impl.cc -@@ -605,7 +605,7 @@ void PasswordsPrivateDelegateImpl::OnFetchingFamilyMem +@@ -634,7 +634,7 @@ void PasswordsPrivateDelegateImpl::OnFetchingFamilyMem } void PasswordsPrivateDelegateImpl::OsReauthTimeoutCall() { diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_runtime_chrome__runtime__api__delegate.cc b/www/chromium/files/patch-chrome_browser_extensions_api_runtime_chrome__runtime__api__delegate.cc index 24f295a38112..481c02106e4b 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_runtime_chrome__runtime__api__delegate.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_runtime_chrome__runtime__api__delegate.cc @@ -1,6 +1,6 @@ ---- chrome/browser/extensions/api/runtime/chrome_runtime_api_delegate.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/extensions/api/runtime/chrome_runtime_api_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/extensions/api/runtime/chrome_runtime_api_delegate.cc -@@ -284,7 +284,9 @@ bool ChromeRuntimeAPIDelegate::GetPlatformInfo(Platfor +@@ -326,7 +326,9 @@ bool ChromeRuntimeAPIDelegate::GetPlatformInfo(Platfor } else if (strcmp(os, "linux") == 0) { info->os = extensions::api::runtime::PlatformOs::kLinux; } else if (strcmp(os, "openbsd") == 0) { @@ -8,6 +8,6 @@ + info->os = extensions::api::runtime::PlatformOs::kLinux; + } else if (strcmp(os, "freebsd") == 0) { + info->os = extensions::api::runtime::PlatformOs::kLinux; - } else if (strcmp(os, "fuchsia") == 0) { - info->os = extensions::api::runtime::PlatformOs::kFuchsia; + } else if (strcmp(os, "android") == 0) { + info->os = extensions::api::runtime::PlatformOs::kAndroid; } else { diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_settings__private_prefs__util.cc b/www/chromium/files/patch-chrome_browser_extensions_api_settings__private_prefs__util.cc index 069e140c367e..6280f7f7b71f 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_settings__private_prefs__util.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_settings__private_prefs__util.cc @@ -1,7 +1,16 @@ ---- chrome/browser/extensions/api/settings_private/prefs_util.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/extensions/api/settings_private/prefs_util.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/extensions/api/settings_private/prefs_util.cc -@@ -204,7 +204,7 @@ const PrefsUtil::TypedPrefMap& PrefsUtil::GetAllowlist - (*s_allowlist)[::prefs::kSidePanelHorizontalAlignment] = +@@ -196,7 +196,7 @@ const PrefsUtil::TypedPrefMap& PrefsUtil::GetAllowlist + (*s_allowlist)[autofill::prefs::kAutofillPaymentCardBenefits] = + settings_api::PrefType::kBoolean; + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + (*s_allowlist)[autofill::prefs::kAutofillBnplEnabled] = + settings_api::PrefType::kBoolean; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || +@@ -214,7 +214,7 @@ const PrefsUtil::TypedPrefMap& PrefsUtil::GetAllowlist + (*s_allowlist)[tab_groups::prefs::kAutoPinNewTabGroups] = settings_api::PrefType::kBoolean; -#if BUILDFLAG(IS_LINUX) @@ -9,9 +18,9 @@ (*s_allowlist)[::prefs::kUseCustomChromeFrame] = settings_api::PrefType::kBoolean; #endif -@@ -213,7 +213,7 @@ const PrefsUtil::TypedPrefMap& PrefsUtil::GetAllowlist - // Appearance settings. +@@ -228,7 +228,7 @@ const PrefsUtil::TypedPrefMap& PrefsUtil::GetAllowlist (*s_allowlist)[::prefs::kCurrentThemeID] = settings_api::PrefType::kString; + (*s_allowlist)[::prefs::kPinnedActions] = settings_api::PrefType::kList; (*s_allowlist)[::prefs::kPolicyThemeColor] = settings_api::PrefType::kNumber; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_tabs_tabs__api.cc b/www/chromium/files/patch-chrome_browser_extensions_api_tabs_tabs__api.cc index 8458dbdf455c..b4463d62ed95 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_tabs_tabs__api.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_tabs_tabs__api.cc @@ -1,11 +1,11 @@ ---- chrome/browser/extensions/api/tabs/tabs_api.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/extensions/api/tabs/tabs_api.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/extensions/api/tabs/tabs_api.cc -@@ -890,7 +890,7 @@ ExtensionFunction::ResponseAction WindowsCreateFunctio - // minimized. - // TODO(crbug.com/1410400): Remove this workaround when linux is fixed. - // TODO(crbug.com/1410400): Find a fix for wayland as well. +@@ -945,7 +945,7 @@ ExtensionFunction::ResponseAction WindowsCreateFunctio + // created as minimized. + // TODO(crbug.com/40254339): Remove this workaround when linux is fixed. + // TODO(crbug.com/40254339): Find a fix for wayland as well. -#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE_X11) - if (new_window->initial_show_state() == ui::SHOW_STATE_MINIMIZED) { + if (new_window->initial_show_state() == + ui::mojom::WindowShowState::kMinimized) { new_window->window()->Minimize(); - } diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_webrtc__logging__private_webrtc__logging__private__api.cc b/www/chromium/files/patch-chrome_browser_extensions_api_webrtc__logging__private_webrtc__logging__private__api.cc index 56aa4680bb09..9dad62a236f8 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_webrtc__logging__private_webrtc__logging__private__api.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_webrtc__logging__private_webrtc__logging__private__api.cc @@ -1,6 +1,6 @@ ---- chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.cc.orig 2024-11-14 07:57:23 UTC +++ chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.cc -@@ -29,7 +29,7 @@ +@@ -28,7 +28,7 @@ #include "extensions/browser/process_manager.h" #include "extensions/common/error_utils.h" @@ -9,7 +9,7 @@ #include "extensions/common/permissions/permissions_data.h" #endif -@@ -38,7 +38,7 @@ namespace { +@@ -37,7 +37,7 @@ namespace { bool CanEnableAudioDebugRecordingsFromExtension( const extensions::Extension* extension) { bool enabled_by_permissions = false; @@ -18,7 +18,7 @@ if (extension) { enabled_by_permissions = extension->permissions_data()->active_permissions().HasAPIPermission( -@@ -576,7 +576,7 @@ void WebrtcLoggingPrivateStartEventLoggingFunction::Fi +@@ -575,7 +575,7 @@ void WebrtcLoggingPrivateStartEventLoggingFunction::Fi ExtensionFunction::ResponseAction WebrtcLoggingPrivateGetLogsDirectoryFunction::Run() { diff --git a/www/chromium/files/patch-chrome_browser_extensions_api_webstore__private_webstore__private__api.cc b/www/chromium/files/patch-chrome_browser_extensions_api_webstore__private_webstore__private__api.cc index c4cf225a7414..51c91f333671 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_api_webstore__private_webstore__private__api.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_api_webstore__private_webstore__private__api.cc @@ -1,6 +1,6 @@ ---- chrome/browser/extensions/api/webstore_private/webstore_private_api.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/extensions/api/webstore_private/webstore_private_api.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/extensions/api/webstore_private/webstore_private_api.cc -@@ -934,7 +934,7 @@ void WebstorePrivateBeginInstallWithManifest3Function: +@@ -911,7 +911,7 @@ void WebstorePrivateBeginInstallWithManifest3Function: #if BUILDFLAG(IS_CHROMEOS) RequestExtensionApproval(contents); return; diff --git a/www/chromium/files/patch-chrome_browser_extensions_component__extensions__allowlist_allowlist.cc b/www/chromium/files/patch-chrome_browser_extensions_component__extensions__allowlist_allowlist.cc new file mode 100644 index 000000000000..0e29da45b7f2 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_extensions_component__extensions__allowlist_allowlist.cc @@ -0,0 +1,20 @@ +--- chrome/browser/extensions/component_extensions_allowlist/allowlist.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/extensions/component_extensions_allowlist/allowlist.cc +@@ -48,7 +48,7 @@ bool IsComponentExtensionAllowlisted(const std::string + #endif // BUILDFLAG(GOOGLE_CHROME_BRANDING) + #endif // BUILDFLAG(IS_CHROMEOS) + extension_misc::kReadingModeGDocsHelperExtensionId, +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + extension_misc::kTTSEngineExtensionId, + extension_misc::kComponentUpdaterTTSEngineExtensionId, + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +@@ -85,7 +85,7 @@ bool IsComponentExtensionAllowlisted(int manifest_reso + case IDR_NETWORK_SPEECH_SYNTHESIS_MANIFEST: + case IDR_NETWORK_SPEECH_SYNTHESIS_MANIFEST_MV3: + case IDR_READING_MODE_GDOCS_HELPER_MANIFEST: +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + case IDR_TTS_ENGINE_MANIFEST: + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) + case IDR_WEBSTORE_MANIFEST: diff --git a/www/chromium/files/patch-chrome_browser_extensions_external__provider__impl.cc b/www/chromium/files/patch-chrome_browser_extensions_external__provider__impl.cc index a8f648531454..882dfca58565 100644 --- a/www/chromium/files/patch-chrome_browser_extensions_external__provider__impl.cc +++ b/www/chromium/files/patch-chrome_browser_extensions_external__provider__impl.cc @@ -1,15 +1,15 @@ ---- chrome/browser/extensions/external_provider_impl.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/extensions/external_provider_impl.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/extensions/external_provider_impl.cc -@@ -830,7 +830,7 @@ void ExternalProviderImpl::CreateExternalProviders( +@@ -828,7 +828,7 @@ void ExternalProviderImpl::CreateExternalProviders( + + #endif // BUILDFLAG(IS_CHROMEOS) if (!profile->GetPrefs()->GetBoolean(pref_names::kBlockExternalExtensions)) { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) provider_list->push_back(std::make_unique<ExternalProviderImpl>( service, base::MakeRefCounted<ExternalPrefLoader>( -@@ -858,7 +858,7 @@ void ExternalProviderImpl::CreateExternalProviders( +@@ -856,7 +856,7 @@ void ExternalProviderImpl::CreateExternalProviders( bundled_extension_creation_flags)); // Define a per-user source of external extensions. diff --git a/www/chromium/files/patch-chrome_browser_feedback_system__logs_about__system__logs__fetcher.cc b/www/chromium/files/patch-chrome_browser_feedback_system__logs_about__system__logs__fetcher.cc new file mode 100644 index 000000000000..8156dee230e9 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_feedback_system__logs_about__system__logs__fetcher.cc @@ -0,0 +1,20 @@ +--- chrome/browser/feedback/system_logs/about_system_logs_fetcher.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/feedback/system_logs/about_system_logs_fetcher.cc +@@ -38,7 +38,7 @@ + #include "chrome/browser/ash/system_logs/ui_hierarchy_log_source.h" + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/feedback/system_logs/log_sources/ozone_platform_state_dump_source.h" + #endif + +@@ -85,7 +85,7 @@ SystemLogsFetcher* BuildAboutSystemLogsFetcher(content + fetcher->AddSource(std::make_unique<KeyboardInfoLogSource>()); + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + fetcher->AddSource(std::make_unique<OzonePlatformStateDumpSource>()); + #endif // BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-chrome_browser_feedback_system__logs_chrome__system__logs__fetcher.cc b/www/chromium/files/patch-chrome_browser_feedback_system__logs_chrome__system__logs__fetcher.cc new file mode 100644 index 000000000000..a104f24e4610 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_feedback_system__logs_chrome__system__logs__fetcher.cc @@ -0,0 +1,20 @@ +--- chrome/browser/feedback/system_logs/chrome_system_logs_fetcher.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/feedback/system_logs/chrome_system_logs_fetcher.cc +@@ -45,7 +45,7 @@ + #include "services/network/public/cpp/shared_url_loader_factory.h" + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/feedback/system_logs/log_sources/ozone_platform_state_dump_source.h" + #endif + +@@ -102,7 +102,7 @@ SystemLogsFetcher* BuildChromeSystemLogsFetcher(Profil + fetcher->AddSource(std::make_unique<UiHierarchyLogSource>(scrub_data)); + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + fetcher->AddSource(std::make_unique<OzonePlatformStateDumpSource>()); + #endif // BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-chrome_browser_file__system__access_chrome__file__system__access__permission__context.cc b/www/chromium/files/patch-chrome_browser_file__system__access_chrome__file__system__access__permission__context.cc index c81fa23e5192..f46250d3a64d 100644 --- a/www/chromium/files/patch-chrome_browser_file__system__access_chrome__file__system__access__permission__context.cc +++ b/www/chromium/files/patch-chrome_browser_file__system__access_chrome__file__system__access__permission__context.cc @@ -1,11 +1,11 @@ ---- chrome/browser/file_system_access/chrome_file_system_access_permission_context.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/file_system_access/chrome_file_system_access_permission_context.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/file_system_access/chrome_file_system_access_permission_context.cc -@@ -317,7 +317,7 @@ const struct { - FILE_PATH_LITERAL("Library/Mobile Documents/com~apple~CloudDocs"), - kDontBlockChildren}, +@@ -341,7 +341,7 @@ GenerateBlockedPath() { + FILE_PATH_LITERAL("Library/Mobile Documents/com~apple~CloudDocs"), + BlockType::kDontBlockChildren}, #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // On Linux also block access to devices via /dev. - {kNoBasePathKey, FILE_PATH_LITERAL("/dev"), kBlockAllChildren}, - // And security sensitive data in /proc and /sys. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + // On Linux also block access to devices via /dev. + {kNoBasePathKey, FILE_PATH_LITERAL("/dev"), BlockType::kBlockAllChildren}, + // And security sensitive data in /proc and /sys. diff --git a/www/chromium/files/patch-chrome_browser_first__run_first__run__dialog.h b/www/chromium/files/patch-chrome_browser_first__run_first__run__dialog.h index 8f7d4918c91a..ff55075997c3 100644 --- a/www/chromium/files/patch-chrome_browser_first__run_first__run__dialog.h +++ b/www/chromium/files/patch-chrome_browser_first__run_first__run__dialog.h @@ -1,11 +1,11 @@ ---- chrome/browser/first_run/first_run_dialog.h.orig 2022-11-30 08:12:58 UTC +--- chrome/browser/first_run/first_run_dialog.h.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/first_run/first_run_dialog.h -@@ -12,7 +12,7 @@ +@@ -9,7 +9,7 @@ + #include "build/build_config.h" + // Hide this function on platforms where the dialog does not exist. - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_MAC) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if BUILDFLAG(IS_MAC) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) namespace first_run { diff --git a/www/chromium/files/patch-chrome_browser_first__run_first__run__internal.h b/www/chromium/files/patch-chrome_browser_first__run_first__run__internal.h index c20f89819d93..0dd89ae59be7 100644 --- a/www/chromium/files/patch-chrome_browser_first__run_first__run__internal.h +++ b/www/chromium/files/patch-chrome_browser_first__run_first__run__internal.h @@ -1,6 +1,6 @@ ---- chrome/browser/first_run/first_run_internal.h.orig 2022-11-30 08:12:58 UTC +--- chrome/browser/first_run/first_run_internal.h.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/first_run/first_run_internal.h -@@ -54,7 +54,7 @@ FirstRunState DetermineFirstRunState(bool has_sentinel +@@ -53,7 +53,7 @@ FirstRunState DetermineFirstRunState(bool has_sentinel bool force_first_run, bool no_first_run); diff --git a/www/chromium/files/patch-chrome_browser_flag__descriptions.cc b/www/chromium/files/patch-chrome_browser_flag__descriptions.cc index 6b4a13f8a04c..5369ef1ca1b1 100644 --- a/www/chromium/files/patch-chrome_browser_flag__descriptions.cc +++ b/www/chromium/files/patch-chrome_browser_flag__descriptions.cc @@ -1,33 +1,105 @@ ---- chrome/browser/flag_descriptions.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/flag_descriptions.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/flag_descriptions.cc -@@ -2946,7 +2946,7 @@ const char kCbdTimeframeRequiredDescription[] = - "value to the list."; +@@ -659,7 +659,7 @@ const char kAutofillEnableAllowlistForBmoCardCategoryB + "Autofill suggestions on the allowlisted merchant websites."; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - const char kPolicyIndicationForManagedDefaultSearchName[] = - "Enable policy indication for managed Default Search provider"; - const char kPolicyIndicationForManagedDefaultSearchDescription[] = -@@ -3259,7 +3259,7 @@ const char kSiteInstanceGroupsForDataUrlsDescription[] - "but in the same SiteInstanceGroup, and thus the same process."; +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + const char kAutofillEnableAmountExtractionAllowlistDesktopName[] = + "Enable loading and querying the checkout amount extraction allowlist on " + "Chrome Desktop"; +@@ -683,7 +683,7 @@ const char kAutofillEnableAmountExtractionDesktopLoggi + // BUILDFLAG(IS_CHROMEOS) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + const char kAutofillEnableBuyNowPayLaterName[] = + "Enable buy now pay later on Autofill"; + const char kAutofillEnableBuyNowPayLaterDescription[] = +@@ -1116,7 +1116,7 @@ const char kDevicePostureDescription[] = + "Enables Device Posture API (foldable devices)"; + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + const char kDocumentPictureInPictureAnimateResizeName[] = + "Document Picture-in-Picture Animate Resize"; + const char kDocumentPictureInPictureAnimateResizeDescription[] = +@@ -1250,7 +1250,7 @@ const char kContextMenuEmptySpaceDescription[] = + "space, a context menu containing page-related items will be shown."; + #endif // BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + const char kContextualCueingName[] = "Contextual cueing"; + const char kContextualCueingDescription[] = + "Enables the contextual cueing system to support showing actions."; +@@ -1633,7 +1633,7 @@ const char kEnableIsolatedWebAppDevModeName[] = + const char kEnableIsolatedWebAppDevModeDescription[] = + "Enables the installation of unverified Isolated Web Apps"; + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char kEnableIwaKeyDistributionComponentName[] = + "Enable the Iwa Key Distribution component"; + const char kEnableIwaKeyDistributionComponentDescription[] = +@@ -3596,7 +3596,7 @@ const char kReduceTransferSizeUpdatedIPCDescription[] + "When enabled, the network service will send TransferSizeUpdatedIPC IPC " + "only when DevTools is attached or the request is for an ad request."; + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char kReduceUserAgentDataLinuxPlatformVersionName[] = + "Reduce Linux platform version Client Hint"; + const char kReduceUserAgentDataLinuxPlatformVersionDescription[] = +@@ -3628,7 +3628,7 @@ const char kRetainOmniboxOnFocusDescription[] = + "exhibit a change in behavior."; + #endif // BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char kRootScrollbarFollowsTheme[] = "Make scrollbar follow theme"; + const char kRootScrollbarFollowsThemeDescription[] = + "If enabled makes the root scrollbar follow the browser's theme color."; +@@ -3887,7 +3887,7 @@ const char kDefaultSiteInstanceGroupsDescription[] = + "SiteInstance."; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const char kSiteSearchSettingsPolicyName[] = "Enable SiteSearchSettings policy"; - const char kSiteSearchSettingsPolicyDescription[] = - "Allow site search engines to be defined by the SiteSearchSettings policy."; -@@ -7496,7 +7496,7 @@ const char kLacrosMergeIcuDataFileDescription[] = - "Enables sharing common areas of icudtl.dat between Ash and Lacros."; - #endif // #if BUILDFLAG(IS_CHROMEOS_LACROS) + const char kPwaNavigationCapturingName[] = "Desktop PWA Link Capturing"; + const char kPwaNavigationCapturingDescription[] = + "Enables opening links from Chrome in an installed PWA. Currently under " +@@ -4123,7 +4123,7 @@ const char kTranslateForceTriggerOnEnglishDescription[ + "Force the Translate Triggering on English pages experiment to be enabled " + "with the selected language model active."; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char kEnableHistorySyncOptinName[] = "History Sync Opt-in"; + const char kEnableHistorySyncOptinDescription[] = + "Enables the History Sync Opt-in screen on Desktop platforms. The screen " +@@ -5840,7 +5840,7 @@ const char kTranslateOpenSettingsDescription[] = + "Add an option to the translate bubble menu to open language settings."; + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + const char kWasmTtsComponentUpdaterEnabledName[] = + "Enable Wasm TTS Extension Component"; + const char kWasmTtsComponentUpdaterEnabledDescription[] = +@@ -7871,7 +7871,7 @@ const char kTetheringExperimentalFunctionalityDescript + + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) const char kGetAllScreensMediaName[] = "GetAllScreensMedia API"; const char kGetAllScreensMediaDescription[] = "When enabled, the getAllScreensMedia API for capturing multiple screens " -@@ -7756,7 +7756,7 @@ const char kV4L2FlatStatefulVideoDecoderDescription[] +@@ -8100,7 +8100,7 @@ const char kEnableArmHwdrmDescription[] = "Enable HW b // Linux ----------------------------------------------------------------------- @@ -36,53 +108,63 @@ const char kOzonePlatformHintChoiceDefault[] = "Default"; const char kOzonePlatformHintChoiceAuto[] = "Auto"; const char kOzonePlatformHintChoiceX11[] = "X11"; -@@ -7804,7 +7804,7 @@ const char kZeroCopyVideoCaptureDescription[] = - #endif // BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) +@@ -8150,6 +8150,18 @@ const char kWaylandUiScalingDescription[] = + "Enable experimental support for text scaling in the Wayland backend " + "backed by full UI scaling. Requires #wayland-per-window-scaling to be " + "enabled too."; ++ ++#if BUILDFLAG(IS_BSD) ++const char kAudioBackendName[] = ++ "Audio Backend"; ++const char kAudioBackendDescription[] = ++#if BUILDFLAG(IS_OPENBSD) ++ "Select the desired audio backend to use. The default is sndio."; ++#elif BUILDFLAG(IS_FREEBSD) ++ "Select the desired audio backend to use. The default will automatically " ++ "enumerate through the supported backends."; ++#endif ++#endif + #endif // BUILDFLAG(IS_LINUX) + + // Random platform combinations ----------------------------------------------- +@@ -8162,7 +8174,7 @@ const char kZeroCopyVideoCaptureDescription[] = + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) const char kFollowingFeedSidepanelName[] = "Following feed in the sidepanel"; const char kFollowingFeedSidepanelDescription[] = "Enables the following feed in the sidepanel."; -@@ -7819,7 +7819,7 @@ const char kEnableProtoApiForClassifyUrlDescription[] - "instead of JSON."; - #endif +@@ -8205,7 +8217,7 @@ const char kGroupPromoPrototypeName[] = "Group Promo P + const char kGroupPromoPrototypeDescription[] = + "Enables prototype for group promo."; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) const char kEnableNetworkServiceSandboxName[] = "Enable the network service sandbox."; const char kEnableNetworkServiceSandboxDescription[] = -@@ -7851,7 +7851,7 @@ const char kWebBluetoothConfirmPairingSupportDescripti +@@ -8226,7 +8238,7 @@ const char kWebBluetoothConfirmPairingSupportDescripti "Bluetooth"; #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - const char kSkipUndecryptablePasswordsName[] = - "Skip undecryptable passwords to use the available decryptable " - "passwords."; -@@ -7871,7 +7871,7 @@ const char kRestartToGainAccessToKeychainDescription[] - "to restart Chrome to gain access to computer's password manager."; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const char kAsyncDnsName[] = "Async DNS resolver"; - const char kAsyncDnsDescription[] = "Enables the built-in DNS resolver."; - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -@@ -7972,7 +7972,7 @@ const char kElementCaptureDescription[] = + #if BUILDFLAG(ENABLE_PRINTING) + const char kCupsIppPrintingBackendName[] = "CUPS IPP Printing Backend"; + const char kCupsIppPrintingBackendDescription[] = +@@ -8369,7 +8381,7 @@ const char kElementCaptureDescription[] = + "media track into a track capturing just a specific DOM element."; + #endif // !BUILDFLAG(IS_ANDROID) - #if BUILDFLAG(IS_WIN) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || \ -- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) const char kUIDebugToolsName[] = "Debugging tools for UI"; const char kUIDebugToolsDescription[] = "Enables additional keyboard shortcuts to help debugging."; -@@ -8021,7 +8021,7 @@ const char kComposeTextSelectionDescription[] = - "Enables feature for different heuristics for selecting text for Compose"; +@@ -8420,7 +8432,7 @@ const char kComposeUpfrontInputModesDescription[] = + "Enables upfront input modes in the Compose dialog"; #endif // BUILDFLAG(ENABLE_COMPOSE) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) @@ -90,3 +172,12 @@ const char kThirdPartyProfileManagementName[] = "Third party profile management"; const char kThirdPartyProfileManagementDescription[] = +@@ -8538,7 +8550,7 @@ const char kSupervisedUserBlockInterstitialV3Name[] = + const char kSupervisedUserBlockInterstitialV3Description[] = + "Enables URL filter interstitial V3 for Family Link users."; + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + const char kSupervisedProfileHideGuestName[] = "Supervised Profile Hide Guest"; + const char kSupervisedProfileHideGuestDescription[] = + "Hides Guest Profile entry points for supervised users"; diff --git a/www/chromium/files/patch-chrome_browser_flag__descriptions.h b/www/chromium/files/patch-chrome_browser_flag__descriptions.h index 5b361c39b876..7a867c777655 100644 --- a/www/chromium/files/patch-chrome_browser_flag__descriptions.h +++ b/www/chromium/files/patch-chrome_browser_flag__descriptions.h @@ -1,33 +1,105 @@ ---- chrome/browser/flag_descriptions.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/flag_descriptions.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/flag_descriptions.h -@@ -1709,7 +1709,7 @@ extern const char kCbdTimeframeRequiredName[]; - extern const char kCbdTimeframeRequiredDescription[]; +@@ -413,7 +413,7 @@ extern const char + kAutofillEnableAllowlistForBmoCardCategoryBenefitsDescription[]; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - extern const char kPolicyIndicationForManagedDefaultSearchName[]; - extern const char kPolicyIndicationForManagedDefaultSearchDescription[]; - #endif -@@ -1890,7 +1890,7 @@ extern const char kSiteInstanceGroupsForDataUrlsName[] - extern const char kSiteInstanceGroupsForDataUrlsDescription[]; +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + extern const char kAutofillEnableAmountExtractionAllowlistDesktopName[]; + extern const char kAutofillEnableAmountExtractionAllowlistDesktopDescription[]; + extern const char kAutofillEnableAmountExtractionDesktopName[]; +@@ -424,7 +424,7 @@ extern const char kAutofillEnableAmountExtractionDeskt + // BUILDFLAG(IS_CHROMEOS) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + extern const char kAutofillEnableBuyNowPayLaterName[]; + extern const char kAutofillEnableBuyNowPayLaterDescription[]; + +@@ -656,7 +656,7 @@ extern const char kContextMenuEmptySpaceName[]; + extern const char kContextMenuEmptySpaceDescription[]; + #endif // BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + extern const char kContextualCueingName[]; + extern const char kContextualCueingDescription[]; + extern const char kGlicZeroStateSuggestionsName[]; +@@ -847,7 +847,7 @@ extern const char kDevicePostureName[]; + extern const char kDevicePostureDescription[]; + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + extern const char kDocumentPictureInPictureAnimateResizeName[]; + extern const char kDocumentPictureInPictureAnimateResizeDescription[]; + +@@ -1006,7 +1006,7 @@ extern const char kEnableIsolatedWebAppAllowlistDescri + extern const char kEnableIsolatedWebAppDevModeName[]; + extern const char kEnableIsolatedWebAppDevModeDescription[]; + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extern const char kEnableIwaKeyDistributionComponentName[]; + extern const char kEnableIwaKeyDistributionComponentDescription[]; + #endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +@@ -2079,7 +2079,7 @@ extern const char kRetainOmniboxOnFocusName[]; + extern const char kRetainOmniboxOnFocusDescription[]; + #endif // BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extern const char kRootScrollbarFollowsTheme[]; + extern const char kRootScrollbarFollowsThemeDescription[]; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) +@@ -2226,7 +2226,7 @@ extern const char kDefaultSiteInstanceGroupsName[]; + extern const char kDefaultSiteInstanceGroupsDescription[]; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - extern const char kSiteSearchSettingsPolicyName[]; - extern const char kSiteSearchSettingsPolicyDescription[]; + extern const char kPwaNavigationCapturingName[]; + extern const char kPwaNavigationCapturingDescription[]; + #endif +@@ -2386,7 +2386,7 @@ extern const char kTouchTextEditingRedesignDescription + extern const char kTranslateForceTriggerOnEnglishName[]; + extern const char kTranslateForceTriggerOnEnglishDescription[]; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extern const char kEnableHistorySyncOptinName[]; + extern const char kEnableHistorySyncOptinDescription[]; + +@@ -2641,7 +2641,7 @@ extern const char kReduceAcceptLanguageDescription[]; + extern const char kReduceTransferSizeUpdatedIPCName[]; + extern const char kReduceTransferSizeUpdatedIPCDescription[]; + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extern const char kReduceUserAgentDataLinuxPlatformVersionName[]; + extern const char kReduceUserAgentDataLinuxPlatformVersionDescription[]; + #endif // #if BUILDFLAG(IS_LINUX) +@@ -3430,7 +3430,7 @@ extern const char kTranslateOpenSettingsName[]; + extern const char kTranslateOpenSettingsDescription[]; #endif -@@ -4323,7 +4323,7 @@ extern const char kLacrosMergeIcuDataFileName[]; - extern const char kLacrosMergeIcuDataFileDescription[]; - #endif // #if BUILDFLAG(IS_CHROMEOS_LACROS) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + extern const char kWasmTtsComponentUpdaterEnabledName[]; + extern const char kWasmTtsComponentUpdaterEnabledDescription[]; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +@@ -4630,7 +4630,7 @@ extern const char kTetheringExperimentalFunctionalityD + + #endif // #if BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) extern const char kGetAllScreensMediaName[]; extern const char kGetAllScreensMediaDescription[]; #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -@@ -4471,7 +4471,7 @@ extern const char kV4L2FlatStatefulVideoDecoderDescrip +@@ -4765,7 +4765,7 @@ extern const char kEnableArmHwdrmDescription[]; // Linux --------------------------------------------------------------------- @@ -36,51 +108,54 @@ extern const char kOzonePlatformHintChoiceDefault[]; extern const char kOzonePlatformHintChoiceAuto[]; extern const char kOzonePlatformHintChoiceX11[]; -@@ -4513,7 +4513,7 @@ extern const char kWebBluetoothConfirmPairingSupportNa +@@ -4796,6 +4796,9 @@ extern const char kWaylandTextInputV3Description[]; + + extern const char kWaylandUiScalingName[]; + extern const char kWaylandUiScalingDescription[]; ++ ++extern const char kAudioBackendName[]; ++extern const char kAudioBackendDescription[]; + #endif // BUILDFLAG(IS_LINUX) + + // Random platform combinations ----------------------------------------------- +@@ -4810,7 +4813,7 @@ extern const char kWebBluetoothConfirmPairingSupportNa extern const char kWebBluetoothConfirmPairingSupportDescription[]; #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - extern const char kSkipUndecryptablePasswordsName[]; - extern const char kSkipUndecryptablePasswordsDescription[]; - -@@ -4524,13 +4524,13 @@ extern const char kRestartToGainAccessToKeychainName[] - extern const char kRestartToGainAccessToKeychainDescription[]; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - extern const char kAsyncDnsName[]; - extern const char kAsyncDnsDescription[]; - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) + #if BUILDFLAG(ENABLE_PRINTING) + extern const char kCupsIppPrintingBackendName[]; + extern const char kCupsIppPrintingBackendDescription[]; +@@ -4823,7 +4826,7 @@ extern const char kScreenlockReauthCardDescription[]; + #endif // BUILDFLAG(IS_CHROMEOS) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) extern const char kFollowingFeedSidepanelName[]; extern const char kFollowingFeedSidepanelDescription[]; - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || -@@ -4541,7 +4541,7 @@ extern const char kEnableProtoApiForClassifyUrlName[]; - extern const char kEnableProtoApiForClassifyUrlDescription[]; - #endif // BUILDFLAG(ENABLE_SUPERVISED_USERS) + +@@ -4840,7 +4843,7 @@ extern const char kTaskManagerDesktopRefreshName[]; + extern const char kTaskManagerDesktopRefreshDescription[]; + #endif // BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) extern const char kEnableNetworkServiceSandboxName[]; extern const char kEnableNetworkServiceSandboxDescription[]; -@@ -4618,7 +4618,7 @@ extern const char kElementCaptureDescription[]; +@@ -4932,7 +4935,7 @@ extern const char kElementCaptureName[]; + extern const char kElementCaptureDescription[]; + #endif // !BUILDFLAG(IS_ANDROID) - #if BUILDFLAG(IS_WIN) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || \ -- BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) extern const char kUIDebugToolsName[]; extern const char kUIDebugToolsDescription[]; - -@@ -4652,7 +4652,7 @@ extern const char kComposeTextSelectionName[]; - extern const char kComposeTextSelectionDescription[]; + #endif +@@ -4971,7 +4974,7 @@ extern const char kComposeUpfrontInputModesName[]; + extern const char kComposeUpfrontInputModesDescription[]; #endif // BUILDFLAG(ENABLE_COMPOSE) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) @@ -88,3 +163,12 @@ extern const char kThirdPartyProfileManagementName[]; extern const char kThirdPartyProfileManagementDescription[]; +@@ -5045,7 +5048,7 @@ extern const char kEnablePolicyPromotionBannerDescript + extern const char kSupervisedUserBlockInterstitialV3Name[]; + extern const char kSupervisedUserBlockInterstitialV3Description[]; + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + extern const char kSupervisedProfileHideGuestName[]; + extern const char kSupervisedProfileHideGuestDescription[]; + diff --git a/www/chromium/files/patch-chrome_browser_gcm_gcm__profile__service__factory.cc b/www/chromium/files/patch-chrome_browser_gcm_gcm__profile__service__factory.cc index 228a5851eb04..7d62c4ed8008 100644 --- a/www/chromium/files/patch-chrome_browser_gcm_gcm__profile__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_gcm_gcm__profile__service__factory.cc @@ -1,6 +1,6 @@ ---- chrome/browser/gcm/gcm_profile_service_factory.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/gcm/gcm_profile_service_factory.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/gcm/gcm_profile_service_factory.cc -@@ -89,7 +89,7 @@ GCMProfileServiceFactory::ScopedTestingFactoryInstalle +@@ -110,7 +110,7 @@ GCMProfileServiceFactory::ScopedTestingFactoryInstalle // static GCMProfileService* GCMProfileServiceFactory::GetForProfile( content::BrowserContext* profile) { @@ -9,8 +9,8 @@ // On desktop, incognito profiles are checked with IsIncognitoProfile(). // It's possible for non-incognito profiles to also be off-the-record. bool is_profile_supported = -@@ -129,7 +129,7 @@ GCMProfileServiceFactory::~GCMProfileServiceFactory() - KeyedService* GCMProfileServiceFactory::BuildServiceInstanceFor( +@@ -153,7 +153,7 @@ std::unique_ptr<KeyedService> + GCMProfileServiceFactory::BuildServiceInstanceForBrowserContext( content::BrowserContext* context) const { Profile* profile = Profile::FromBrowserContext(context); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_gcm_instance__id_instance__id__profile__service__factory.cc b/www/chromium/files/patch-chrome_browser_gcm_instance__id_instance__id__profile__service__factory.cc index 4bdb479740ba..9e7b4dafc9e0 100644 --- a/www/chromium/files/patch-chrome_browser_gcm_instance__id_instance__id__profile__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_gcm_instance__id_instance__id__profile__service__factory.cc @@ -1,4 +1,4 @@ ---- chrome/browser/gcm/instance_id/instance_id_profile_service_factory.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/gcm/instance_id/instance_id_profile_service_factory.cc.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/gcm/instance_id/instance_id_profile_service_factory.cc @@ -16,7 +16,7 @@ namespace instance_id { // static @@ -9,8 +9,8 @@ // On desktop, the guest profile is actually the primary OTR profile of // the "regular" guest profile. The regular guest profile is never used // directly by users. Also, user are not able to create child OTR profiles -@@ -61,7 +61,7 @@ InstanceIDProfileServiceFactory::~InstanceIDProfileSer - KeyedService* InstanceIDProfileServiceFactory::BuildServiceInstanceFor( +@@ -65,7 +65,7 @@ std::unique_ptr<KeyedService> + InstanceIDProfileServiceFactory::BuildServiceInstanceForBrowserContext( content::BrowserContext* context) const { Profile* profile = Profile::FromBrowserContext(context); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_global__features.cc b/www/chromium/files/patch-chrome_browser_global__features.cc new file mode 100644 index 000000000000..0fb41d80914c --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_global__features.cc @@ -0,0 +1,29 @@ +--- chrome/browser/global_features.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/global_features.cc +@@ -24,7 +24,7 @@ + #include "chrome/browser/glic/host/glic_synthetic_trial_manager.h" // nogncheck + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // This causes a gn error on Android builds, because gn does not understand + // buildflags, so we include it only on platforms where it is used. + #include "chrome/browser/ui/webui/whats_new/whats_new_registrar.h" +@@ -70,7 +70,7 @@ void GlobalFeatures::ReplaceGlobalFeaturesForTesting( + + void GlobalFeatures::Init() { + system_permissions_platform_handle_ = CreateSystemPermissionsPlatformHandle(); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + whats_new_registry_ = CreateWhatsNewRegistry(); + #endif + +@@ -120,7 +120,7 @@ GlobalFeatures::CreateSystemPermissionsPlatformHandle( + return system_permission_settings::PlatformHandle::Create(); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<whats_new::WhatsNewRegistry> + GlobalFeatures::CreateWhatsNewRegistry() { + return whats_new::CreateWhatsNewRegistry(); diff --git a/www/chromium/files/patch-chrome_browser_global__features.h b/www/chromium/files/patch-chrome_browser_global__features.h new file mode 100644 index 000000000000..de0fbe47272a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_global__features.h @@ -0,0 +1,38 @@ +--- chrome/browser/global_features.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/global_features.h +@@ -15,7 +15,7 @@ + namespace system_permission_settings { + class PlatformHandle; + } // namespace system_permission_settings +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + namespace whats_new { + class WhatsNewRegistry; + } // namespace whats_new +@@ -63,7 +63,7 @@ class GlobalFeatures { + system_permissions_platform_handle() { + return system_permissions_platform_handle_.get(); + } +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + whats_new::WhatsNewRegistry* whats_new_registry() { + return whats_new_registry_.get(); + } +@@ -103,7 +103,7 @@ class GlobalFeatures { + + virtual std::unique_ptr<system_permission_settings::PlatformHandle> + CreateSystemPermissionsPlatformHandle(); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + virtual std::unique_ptr<whats_new::WhatsNewRegistry> CreateWhatsNewRegistry(); + #endif + +@@ -113,7 +113,7 @@ class GlobalFeatures { + + std::unique_ptr<system_permission_settings::PlatformHandle> + system_permissions_platform_handle_; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<whats_new::WhatsNewRegistry> whats_new_registry_; + #endif + diff --git a/www/chromium/files/patch-chrome_browser_headless_headless__mode__util.cc b/www/chromium/files/patch-chrome_browser_headless_headless__mode__util.cc index 428d84fa1c0e..2d5a2a7c4f0b 100644 --- a/www/chromium/files/patch-chrome_browser_headless_headless__mode__util.cc +++ b/www/chromium/files/patch-chrome_browser_headless_headless__mode__util.cc @@ -1,5 +1,14 @@ ---- chrome/browser/headless/headless_mode_util.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/headless/headless_mode_util.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/headless/headless_mode_util.cc +@@ -10,7 +10,7 @@ + // New headless mode is available on Linux, Windows and Mac platforms. + // More platforms will be added later, so avoid function level clutter + // by providing stub implementations at the end of the file. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + + #include "base/base_switches.h" + #include "base/files/file_path.h" @@ -19,7 +19,7 @@ #include "chrome/common/chrome_switches.h" #include "content/public/common/content_switches.h" @@ -9,8 +18,8 @@ #include "ui/gl/gl_switches.h" // nogncheck #include "ui/ozone/public/ozone_switches.h" // nogncheck #endif // BUILDFLAG(IS_LINUX) -@@ -87,7 +87,7 @@ class HeadlessModeHandleImpl : public HeadlessModeHand - command_line->AppendSwitchPath(switches::kUserDataDir, GetUserDataDir()); +@@ -94,7 +94,7 @@ class HeadlessModeHandleImpl : public HeadlessModeHand + } } -#if BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_intranet__redirect__detector.h b/www/chromium/files/patch-chrome_browser_intranet__redirect__detector.h index 1a16f17b16d4..eb9d2e65790b 100644 --- a/www/chromium/files/patch-chrome_browser_intranet__redirect__detector.h +++ b/www/chromium/files/patch-chrome_browser_intranet__redirect__detector.h @@ -1,11 +1,11 @@ ---- chrome/browser/intranet_redirect_detector.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/intranet_redirect_detector.h.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/intranet_redirect_detector.h @@ -25,7 +25,7 @@ class SimpleURLLoader; class PrefRegistrySimple; #if !(BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA)) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD)) +- BUILDFLAG(IS_CHROMEOS)) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) #error "IntranetRedirectDetector should only be built on Desktop platforms." #endif diff --git a/www/chromium/files/patch-chrome_browser_media__galleries_fileapi_mtp__device__map__service.cc b/www/chromium/files/patch-chrome_browser_media__galleries_fileapi_mtp__device__map__service.cc index 2e6370bf650b..c1339afa9c32 100644 --- a/www/chromium/files/patch-chrome_browser_media__galleries_fileapi_mtp__device__map__service.cc +++ b/www/chromium/files/patch-chrome_browser_media__galleries_fileapi_mtp__device__map__service.cc @@ -1,4 +1,4 @@ ---- chrome/browser/media_galleries/fileapi/mtp_device_map_service.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/media_galleries/fileapi/mtp_device_map_service.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/media_galleries/fileapi/mtp_device_map_service.cc @@ -39,10 +39,12 @@ void MTPDeviceMapService::RegisterMTPFileSystem( // Note that this initializes the delegate asynchronously, but since diff --git a/www/chromium/files/patch-chrome_browser_media__galleries_media__file__system__registry.cc b/www/chromium/files/patch-chrome_browser_media__galleries_media__file__system__registry.cc index 232045b7369f..7faca10b2e88 100644 --- a/www/chromium/files/patch-chrome_browser_media__galleries_media__file__system__registry.cc +++ b/www/chromium/files/patch-chrome_browser_media__galleries_media__file__system__registry.cc @@ -1,6 +1,6 @@ ---- chrome/browser/media_galleries/media_file_system_registry.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/media_galleries/media_file_system_registry.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/media_galleries/media_file_system_registry.cc -@@ -584,7 +584,12 @@ class MediaFileSystemRegistry::MediaFileSystemContextI +@@ -582,7 +582,12 @@ class MediaFileSystemRegistry::MediaFileSystemContextI // Constructor in 'private' section because depends on private class definition. MediaFileSystemRegistry::MediaFileSystemRegistry() : file_system_context_(new MediaFileSystemContextImpl) { diff --git a/www/chromium/files/patch-chrome_browser_media_audio__service__util.cc b/www/chromium/files/patch-chrome_browser_media_audio__service__util.cc index 8a5730d4b31a..5faa9431869e 100644 --- a/www/chromium/files/patch-chrome_browser_media_audio__service__util.cc +++ b/www/chromium/files/patch-chrome_browser_media_audio__service__util.cc @@ -1,20 +1,20 @@ ---- chrome/browser/media/audio_service_util.cc.orig 2023-01-11 09:17:16 UTC +--- chrome/browser/media/audio_service_util.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/media/audio_service_util.cc -@@ -21,7 +21,7 @@ +@@ -20,7 +20,7 @@ namespace { --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS)) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) const base::Value* GetPolicy(const char* policy_name) { const policy::PolicyMap& policies = -@@ -43,7 +43,7 @@ bool GetPolicyOrFeature(const char* policy_name, const + g_browser_process->browser_policy_connector() +@@ -39,7 +39,7 @@ bool GetPolicyOrFeature(const char* policy_name, const + } // namespace + bool IsAudioServiceSandboxEnabled() { - // TODO(crbug.com/1052397): Remove !IS_CHROMEOS_LACROS once lacros starts being - // built with OS_CHROMEOS instead of OS_LINUX. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS)) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return GetPolicyOrFeature(policy::key::kAudioSandboxEnabled, features::kAudioServiceSandbox); + #else diff --git a/www/chromium/files/patch-chrome_browser_media_router_discovery_BUILD.gn b/www/chromium/files/patch-chrome_browser_media_router_discovery_BUILD.gn index d6993459de66..48e101dedec0 100644 --- a/www/chromium/files/patch-chrome_browser_media_router_discovery_BUILD.gn +++ b/www/chromium/files/patch-chrome_browser_media_router_discovery_BUILD.gn @@ -1,6 +1,6 @@ ---- chrome/browser/media/router/discovery/BUILD.gn.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/media/router/discovery/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/media/router/discovery/BUILD.gn -@@ -81,7 +81,7 @@ static_library("discovery") { +@@ -79,7 +79,7 @@ static_library("discovery") { ] configs += [ "//build/config/compiler:wexit_time_destructors" ] diff --git a/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__posix.cc b/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__posix.cc index 71650219d44a..8c6e97963ecb 100644 --- a/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__posix.cc +++ b/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__posix.cc @@ -1,6 +1,6 @@ ---- chrome/browser/media/router/discovery/discovery_network_list_posix.cc.orig 2022-02-28 16:54:41 UTC +--- chrome/browser/media/router/discovery/discovery_network_list_posix.cc.orig 2024-09-30 07:45:04 UTC +++ chrome/browser/media/router/discovery/discovery_network_list_posix.cc -@@ -5,11 +5,12 @@ +@@ -10,11 +10,12 @@ #include "chrome/browser/media/router/discovery/discovery_network_list.h" #include <ifaddrs.h> @@ -15,7 +15,7 @@ #include <algorithm> -@@ -18,7 +19,7 @@ +@@ -23,7 +24,7 @@ #include "chrome/browser/media/router/discovery/discovery_network_list_wifi.h" #include "net/base/net_errors.h" @@ -24,7 +24,7 @@ #include <netpacket/packet.h> #else #include <net/if_dl.h> -@@ -27,7 +28,7 @@ +@@ -32,7 +33,7 @@ namespace media_router { namespace { @@ -33,7 +33,7 @@ using sll = struct sockaddr_ll; #define SOCKET_ARP_TYPE(s) ((s)->sll_hatype) #define SOCKET_ADDRESS_LEN(s) ((s)->sll_halen) -@@ -38,6 +39,12 @@ using sll = struct sockaddr_dl; +@@ -43,6 +44,12 @@ using sll = struct sockaddr_dl; #define SOCKET_ARP_TYPE(s) ((s)->sdl_type) #define SOCKET_ADDRESS_LEN(s) ((s)->sdl_alen) #define SOCKET_ADDRESS(s) (LLADDR(s)) diff --git a/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__wifi__linux.cc b/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__wifi__linux.cc index 8fa374f692ce..639f940efa96 100644 --- a/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__wifi__linux.cc +++ b/www/chromium/files/patch-chrome_browser_media_router_discovery_discovery__network__list__wifi__linux.cc @@ -1,18 +1,18 @@ ---- chrome/browser/media/router/discovery/discovery_network_list_wifi_linux.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/media/router/discovery/discovery_network_list_wifi_linux.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/media/router/discovery/discovery_network_list_wifi_linux.cc @@ -9,7 +9,11 @@ - #include <sys/socket.h> - #include <sys/types.h> + + #include "chrome/browser/media/router/discovery/discovery_network_list_wifi.h" +#include "build/build_config.h" + +#if !BUILDFLAG(IS_BSD) #include <linux/wireless.h> +#endif - - #include "base/check.h" - #include "base/files/scoped_file.h" -@@ -20,6 +24,7 @@ namespace media_router { + #include <string.h> + #include <sys/ioctl.h> + #include <sys/socket.h> +@@ -24,6 +28,7 @@ namespace media_router { bool MaybeGetWifiSSID(const std::string& if_name, std::string* ssid_out) { DCHECK(ssid_out); @@ -20,7 +20,7 @@ base::ScopedFD ioctl_socket(socket(AF_INET, SOCK_DGRAM, 0)); if (!ioctl_socket.is_valid()) { // AF_INET is for IPv4, so it may fail for IPv6-only hosts even when there -@@ -41,6 +46,7 @@ bool MaybeGetWifiSSID(const std::string& if_name, std: +@@ -46,6 +51,7 @@ bool MaybeGetWifiSSID(const std::string& if_name, std: ssid_out->assign(ssid); return true; } diff --git a/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.cc b/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.cc index d2e7bfafba61..19bc22f3eeff 100644 --- a/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.cc +++ b/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.cc @@ -1,11 +1,11 @@ ---- chrome/browser/media/webrtc/chrome_screen_enumerator.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/media/webrtc/chrome_screen_enumerator.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/media/webrtc/chrome_screen_enumerator.cc @@ -21,7 +21,7 @@ - #if BUILDFLAG(IS_CHROMEOS_ASH) + #if BUILDFLAG(IS_CHROMEOS) #include "ash/shell.h" #include "ui/aura/window.h" --#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "base/functional/callback.h" #include "content/public/browser/desktop_capture.h" #endif @@ -13,8 +13,8 @@ DestructorAtExit root_windows_for_testing_ = LAZY_INSTANCE_INITIALIZER; } // namespace --#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) namespace { base::LazyInstance<std::unique_ptr<webrtc::DesktopCapturer>>::DestructorAtExit g_desktop_capturer_for_testing = LAZY_INSTANCE_INITIALIZER; @@ -22,8 +22,8 @@ return stream_devices_set; } --#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) blink::mojom::StreamDevicesSetPtr EnumerateScreens( blink::mojom::MediaStreamType stream_type) { DCHECK_CURRENTLY_ON(content::BrowserThread::UI); @@ -31,8 +31,8 @@ root_windows_for_testing_.Get() = std::move(root_windows); } --#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void ChromeScreenEnumerator::SetDesktopCapturerForTesting( std::unique_ptr<webrtc::DesktopCapturer> capturer) { g_desktop_capturer_for_testing.Get() = std::move(capturer); diff --git a/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.h b/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.h index c9c749f5e897..e40e9e9fa28c 100644 --- a/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.h +++ b/www/chromium/files/patch-chrome_browser_media_webrtc_chrome__screen__enumerator.h @@ -1,20 +1,20 @@ ---- chrome/browser/media/webrtc/chrome_screen_enumerator.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/media/webrtc/chrome_screen_enumerator.h.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/media/webrtc/chrome_screen_enumerator.h -@@ -20,7 +20,7 @@ namespace aura { +@@ -18,7 +18,7 @@ + namespace aura { class Window; } - --#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) namespace webrtc { class DesktopCapturer; } -@@ -42,7 +42,7 @@ class ChromeScreenEnumerator : public media::ScreenEnu - #if BUILDFLAG(IS_CHROMEOS_ASH) +@@ -39,7 +39,7 @@ class ChromeScreenEnumerator : public media::ScreenEnu + #if BUILDFLAG(IS_CHROMEOS) static void SetRootWindowsForTesting( std::vector<raw_ptr<aura::Window, VectorExperimental>> root_windows); --#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) static void SetDesktopCapturerForTesting( std::unique_ptr<webrtc::DesktopCapturer> capturer); #endif diff --git a/www/chromium/files/patch-chrome_browser_media_webrtc_desktop__media__picker__controller.cc b/www/chromium/files/patch-chrome_browser_media_webrtc_desktop__media__picker__controller.cc index 7c249c855c29..3452d716158d 100644 --- a/www/chromium/files/patch-chrome_browser_media_webrtc_desktop__media__picker__controller.cc +++ b/www/chromium/files/patch-chrome_browser_media_webrtc_desktop__media__picker__controller.cc @@ -1,9 +1,9 @@ ---- chrome/browser/media/webrtc/desktop_media_picker_controller.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/media/webrtc/desktop_media_picker_controller.cc.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/media/webrtc/desktop_media_picker_controller.cc -@@ -92,7 +92,7 @@ bool DesktopMediaPickerController::IsSystemAudioCaptur - } else { - return base::FeatureList::IsEnabled(media::kMacLoopbackAudioForScreenShare); - } +@@ -89,7 +89,7 @@ bool DesktopMediaPickerController::IsSystemAudioCaptur + #if BUILDFLAG(IS_MAC) + return request_source == Params::RequestSource::kCast || + base::FeatureList::IsEnabled(media::kMacLoopbackAudioForScreenShare); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) if (request_source == Params::RequestSource::kCast) { diff --git a/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__log__uploader.cc b/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__log__uploader.cc index d6e5ac50ed26..eda0ae407386 100644 --- a/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__log__uploader.cc +++ b/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__log__uploader.cc @@ -1,11 +1,11 @@ ---- chrome/browser/media/webrtc/webrtc_log_uploader.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/media/webrtc/webrtc_log_uploader.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/media/webrtc/webrtc_log_uploader.cc -@@ -100,7 +100,7 @@ std::string GetLogUploadProduct() { +@@ -101,7 +101,7 @@ std::string GetLogUploadProduct() { + const char product[] = "Chrome"; + #elif BUILDFLAG(IS_MAC) const char product[] = "Chrome_Mac"; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #if !defined(ADDRESS_SANITIZER) const char product[] = "Chrome_Linux"; #else diff --git a/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__logging__controller.cc b/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__logging__controller.cc index c1c011309544..55b664967dee 100644 --- a/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__logging__controller.cc +++ b/www/chromium/files/patch-chrome_browser_media_webrtc_webrtc__logging__controller.cc @@ -1,4 +1,4 @@ ---- chrome/browser/media/webrtc/webrtc_logging_controller.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/media/webrtc/webrtc_logging_controller.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/media/webrtc/webrtc_logging_controller.cc @@ -25,10 +25,10 @@ #include "components/webrtc_logging/browser/text_log_list.h" @@ -13,7 +13,7 @@ using webrtc_event_logging::WebRtcEventLogManager; -@@ -288,7 +288,7 @@ void WebRtcLoggingController::StartEventLogging( +@@ -304,7 +304,7 @@ void WebRtcLoggingController::StartEventLogging( web_app_id, callback); } @@ -22,7 +22,7 @@ void WebRtcLoggingController::GetLogsDirectory( LogsDirectoryCallback callback, LogsDirectoryErrorCallback error_callback) { -@@ -334,7 +334,7 @@ void WebRtcLoggingController::GrantLogsDirectoryAccess +@@ -350,7 +350,7 @@ void WebRtcLoggingController::GrantLogsDirectoryAccess FROM_HERE, base::BindOnce(std::move(callback), file_system.id(), registered_name)); } @@ -30,4 +30,4 @@ +#endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) void WebRtcLoggingController::OnRtpPacket( - std::unique_ptr<uint8_t[]> packet_header, + base::HeapArray<uint8_t> packet_header, diff --git a/www/chromium/files/patch-chrome_browser_memory__details.cc b/www/chromium/files/patch-chrome_browser_memory__details.cc index bc2d99a75472..63cffb111fbc 100644 --- a/www/chromium/files/patch-chrome_browser_memory__details.cc +++ b/www/chromium/files/patch-chrome_browser_memory__details.cc @@ -1,14 +1,5 @@ ---- chrome/browser/memory_details.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/memory_details.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/memory_details.cc -@@ -38,7 +38,7 @@ - #include "services/resource_coordinator/public/cpp/memory_instrumentation/memory_instrumentation.h" - #include "ui/base/l10n/l10n_util.h" - --#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_ANDROID) -+#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_BSD) - #include "content/public/browser/zygote_host/zygote_host_linux.h" - #endif - @@ -335,7 +335,7 @@ void MemoryDetails::CollectChildInfoOnUIThread() { }); } diff --git a/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.cc b/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.cc index 7a10eb391d30..61509ed380e1 100644 --- a/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.cc +++ b/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.cc @@ -1,36 +1,33 @@ ---- chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc -@@ -80,8 +80,10 @@ +@@ -85,7 +85,7 @@ + #include "chrome/browser/flags/android/chrome_session_state.h" + #endif // BUILDFLAG(IS_ANDROID) - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if defined(__GLIBC__) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if defined(__GLIBC__) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) -+#if !BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #if defined(__GLIBC__) #include <gnu/libc-version.h> -+#endif - - #include "base/linux_util.h" - #include "base/strings/string_split.h" -@@ -106,7 +108,7 @@ - #include "chromeos/crosapi/cpp/crosapi_constants.h" - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) + #endif // defined(__GLIBC__) +@@ -110,7 +110,7 @@ + #include "chrome/installer/util/taskbar_util.h" + #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "chrome/browser/metrics/pressure/pressure_metrics_reporter.h" #endif // BUILDFLAG(IS_LINUX) -@@ -115,7 +117,7 @@ +@@ -119,7 +119,7 @@ #include "components/user_manager/user_manager.h" - #endif // BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "components/power_metrics/system_power_monitor.h" #endif -@@ -858,7 +860,7 @@ void RecordStartupMetrics() { +@@ -899,7 +899,7 @@ void RecordStartupMetrics() { // Record whether Chrome is the default browser or not. // Disabled on Linux due to hanging browser tests, see crbug.com/1216328. @@ -39,8 +36,8 @@ shell_integration::DefaultWebClientState default_state = shell_integration::GetDefaultBrowser(); base::UmaHistogramEnumeration("DefaultBrowser.State", default_state, -@@ -1162,11 +1164,11 @@ void ChromeBrowserMainExtraPartsMetrics::PostBrowserSt - } +@@ -1210,11 +1210,11 @@ void ChromeBrowserMainExtraPartsMetrics::PostBrowserSt + std::make_unique<web_app::SamplingMetricsProvider>(); #endif // !BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.h b/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.h index 193b5133c7b2..ac4d0bbfcdca 100644 --- a/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.h +++ b/www/chromium/files/patch-chrome_browser_metrics_chrome__browser__main__extra__parts__metrics.h @@ -1,6 +1,6 @@ ---- chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h -@@ -28,7 +28,7 @@ class PowerMetricsReporter; +@@ -29,7 +29,7 @@ class PowerMetricsReporter; class ProcessMonitor; #endif @@ -9,8 +9,8 @@ class PressureMetricsReporter; #endif // BUILDFLAG(IS_LINUX) -@@ -115,7 +115,7 @@ class ChromeBrowserMainExtraPartsMetrics : public Chro - std::unique_ptr<BatteryDischargeReporter> battery_discharge_reporter_; +@@ -126,7 +126,7 @@ class ChromeBrowserMainExtraPartsMetrics : public Chro + std::unique_ptr<web_app::SamplingMetricsProvider> web_app_metrics_provider_; #endif // !BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_metrics_chrome__metrics__service__client.cc b/www/chromium/files/patch-chrome_browser_metrics_chrome__metrics__service__client.cc index 58076d199092..c024d5dac097 100644 --- a/www/chromium/files/patch-chrome_browser_metrics_chrome__metrics__service__client.cc +++ b/www/chromium/files/patch-chrome_browser_metrics_chrome__metrics__service__client.cc @@ -1,7 +1,7 @@ ---- chrome/browser/metrics/chrome_metrics_service_client.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/metrics/chrome_metrics_service_client.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/metrics/chrome_metrics_service_client.cc -@@ -194,7 +194,7 @@ - #include "chrome/notification_helper/notification_helper_constants.h" +@@ -202,11 +202,11 @@ + #include "chrome/browser/metrics/google_update_metrics_provider_mac.h" #endif -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) @@ -9,34 +9,48 @@ #include "components/metrics/motherboard_metrics_provider.h" #endif -@@ -211,7 +211,7 @@ - #include "chrome/browser/metrics/power/power_metrics_provider_mac.h" +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/metrics/chrome_metrics_service_crash_reporter.h" #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/metrics/bluetooth_metrics_provider.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - -@@ -577,7 +577,7 @@ void ChromeMetricsServiceClient::RegisterPrefs(PrefReg - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +@@ -238,7 +238,7 @@ const int kMaxHistogramGatheringWaitDuration = 60000; + // Needs to be kept in sync with the writer in + // third_party/crashpad/crashpad/handler/handler_main.cc. + const char kCrashpadHistogramAllocatorName[] = "CrashpadMetrics"; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::LazyInstance<ChromeMetricsServiceCrashReporter>::Leaky g_crash_reporter = + LAZY_INSTANCE_INITIALIZER; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) +@@ -542,7 +542,7 @@ void ChromeMetricsServiceClient::RegisterPrefs(PrefReg + #endif // BUILDFLAG(IS_CHROMEOS) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_MAC) + BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) metrics::structured::StructuredMetricsService::RegisterPrefs(registry); - #if !BUILDFLAG(IS_CHROMEOS_ASH) -@@ -749,7 +749,7 @@ void ChromeMetricsServiceClient::Initialize() { - RegisterUKMProviders(); + #if !BUILDFLAG(IS_CHROMEOS) +@@ -624,7 +624,7 @@ std::string ChromeMetricsServiceClient::GetVersionStri + void ChromeMetricsServiceClient::OnEnvironmentUpdate(std::string* environment) { + // TODO(https://bugs.chromium.org/p/crashpad/issues/detail?id=135): call this + // on Mac when the Crashpad API supports it. +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Register the environment with the crash reporter. Note that there is a + // window from startup to this point during which crash reports will not have + // an environment set. +@@ -726,7 +726,7 @@ void ChromeMetricsServiceClient::Initialize() { + std::make_unique<metrics::dwa::DwaService>(this, local_state); } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) metrics::structured::Recorder::GetInstance()->SetUiTaskRunner( base::SequencedTaskRunner::GetCurrentDefault()); #endif -@@ -796,7 +796,7 @@ void ChromeMetricsServiceClient::RegisterMetricsServic +@@ -786,7 +786,7 @@ void ChromeMetricsServiceClient::RegisterMetricsServic metrics_service_->RegisterMetricsProvider( std::make_unique<metrics::CPUMetricsProvider>()); @@ -45,16 +59,16 @@ metrics_service_->RegisterMetricsProvider( std::make_unique<metrics::MotherboardMetricsProvider>()); #endif -@@ -881,7 +881,7 @@ void ChromeMetricsServiceClient::RegisterMetricsServic - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) +@@ -875,7 +875,7 @@ void ChromeMetricsServiceClient::RegisterMetricsServic + std::make_unique<GoogleUpdateMetricsProviderMac>()); + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) metrics_service_->RegisterMetricsProvider( std::make_unique<DesktopPlatformFeaturesMetricsProvider>()); - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || (BUILDFLAG(IS_LINUX) || -@@ -991,7 +991,7 @@ void ChromeMetricsServiceClient::RegisterMetricsServic + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +@@ -984,7 +984,7 @@ void ChromeMetricsServiceClient::RegisterMetricsServic std::make_unique<PowerMetricsProvider>()); #endif @@ -63,18 +77,18 @@ metrics_service_->RegisterMetricsProvider( metrics::CreateDesktopSessionMetricsProvider()); #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || (BUILDFLAG(IS_LINUX) -@@ -1170,7 +1170,7 @@ bool ChromeMetricsServiceClient::RegisterForProfileEve - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) +@@ -1175,7 +1175,7 @@ bool ChromeMetricsServiceClient::RegisterForProfileEve + } + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // This creates the DesktopProfileSessionDurationsServices if it didn't exist // already. metrics::DesktopProfileSessionDurationsServiceFactory::GetForBrowserContext( -@@ -1513,7 +1513,7 @@ void ChromeMetricsServiceClient::CreateStructuredMetri +@@ -1524,7 +1524,7 @@ void ChromeMetricsServiceClient::CreateStructuredMetri recorder = - std::make_unique<metrics::structured::AshStructuredMetricsRecorder>( + base::MakeRefCounted<metrics::structured::AshStructuredMetricsRecorder>( cros_system_profile_provider_.get()); -#elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +#elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_metrics_perf_cpu__identity.cc b/www/chromium/files/patch-chrome_browser_metrics_perf_cpu__identity.cc index 6b9920395e34..4cac38be1df0 100644 --- a/www/chromium/files/patch-chrome_browser_metrics_perf_cpu__identity.cc +++ b/www/chromium/files/patch-chrome_browser_metrics_perf_cpu__identity.cc @@ -1,11 +1,11 @@ ---- chrome/browser/metrics/perf/cpu_identity.cc.orig 2023-02-08 09:03:45 UTC +--- chrome/browser/metrics/perf/cpu_identity.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/metrics/perf/cpu_identity.cc -@@ -141,7 +141,7 @@ CPUIdentity GetCPUIdentity() { +@@ -146,7 +146,7 @@ CPUIdentity GetCPUIdentity() { result.release = - #if BUILDFLAG(IS_CHROMEOS_ASH) + #if BUILDFLAG(IS_CHROMEOS) base::SysInfo::KernelVersion(); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) base::SysInfo::OperatingSystemVersion(); #else #error "Unsupported configuration" diff --git a/www/chromium/files/patch-chrome_browser_metrics_power_process__monitor.cc b/www/chromium/files/patch-chrome_browser_metrics_power_process__monitor.cc index c5e5d9ac4baa..208fbcd73480 100644 --- a/www/chromium/files/patch-chrome_browser_metrics_power_process__monitor.cc +++ b/www/chromium/files/patch-chrome_browser_metrics_power_process__monitor.cc @@ -1,7 +1,7 @@ ---- chrome/browser/metrics/power/process_monitor.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/metrics/power/process_monitor.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/metrics/power/process_monitor.cc -@@ -61,7 +61,7 @@ ProcessMonitor::Metrics SampleMetrics(base::ProcessMet - metrics.cpu_usage = process_metrics.GetPlatformIndependentCPUUsage(); +@@ -64,7 +64,7 @@ ProcessMonitor::Metrics SampleMetrics(base::ProcessMet + process_metrics.GetPlatformIndependentCPUUsage()); #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_AIX) @@ -9,7 +9,7 @@ metrics.idle_wakeups = process_metrics.GetIdleWakeupsPerSecond(); #endif #if BUILDFLAG(IS_MAC) -@@ -79,7 +79,7 @@ void ScaleMetrics(ProcessMonitor::Metrics* metrics, do +@@ -82,7 +82,7 @@ void ScaleMetrics(ProcessMonitor::Metrics* metrics, do } #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -18,7 +18,7 @@ metrics->idle_wakeups *= factor; #endif -@@ -167,7 +167,7 @@ ProcessMonitor::Metrics& operator+=(ProcessMonitor::Me +@@ -156,7 +156,7 @@ ProcessMonitor::Metrics& operator+=(ProcessMonitor::Me } #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ diff --git a/www/chromium/files/patch-chrome_browser_net_profile__network__context__service.cc b/www/chromium/files/patch-chrome_browser_net_profile__network__context__service.cc new file mode 100644 index 000000000000..dea31282ac27 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_net_profile__network__context__service.cc @@ -0,0 +1,29 @@ +--- chrome/browser/net/profile_network_context_service.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/net/profile_network_context_service.cc +@@ -135,7 +135,7 @@ + #include "extensions/common/constants.h" + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/client_certificates/certificate_provisioning_service_factory.h" + #include "chrome/browser/policy/chrome_browser_policy_connector.h" + #include "components/enterprise/browser/controller/chrome_browser_cloud_management_controller.h" +@@ -276,7 +276,7 @@ void UpdateCookieSettings(Profile* profile, ContentSet + }); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<net::ClientCertStore> GetWrappedCertStore( + Profile* profile, + std::unique_ptr<net::ClientCertStore> platform_store) { +@@ -1224,7 +1224,7 @@ ProfileNetworkContextService::CreateClientCertStore() + std::make_unique<net::ClientCertStoreNSS>( + base::BindRepeating(&CreateCryptoModuleBlockingPasswordDelegate, + kCryptoModulePasswordClientAuth)); +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return GetWrappedCertStore(profile_, std::move(store)); + #else + return store; diff --git a/www/chromium/files/patch-chrome_browser_net_profile__network__context__service__factory.cc b/www/chromium/files/patch-chrome_browser_net_profile__network__context__service__factory.cc new file mode 100644 index 000000000000..fdc23610089e --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_net_profile__network__context__service__factory.cc @@ -0,0 +1,20 @@ +--- chrome/browser/net/profile_network_context_service_factory.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/net/profile_network_context_service_factory.cc +@@ -24,7 +24,7 @@ + #include "chrome/browser/net/server_certificate_database_service_factory.h" // nogncheck + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/client_certificates/certificate_provisioning_service_factory.h" + #endif + +@@ -68,7 +68,7 @@ ProfileNetworkContextServiceFactory::ProfileNetworkCon + #if BUILDFLAG(CHROME_ROOT_STORE_CERT_MANAGEMENT_UI) + DependsOn(net::ServerCertificateDatabaseServiceFactory::GetInstance()); + #endif +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + DependsOn(client_certificates::CertificateProvisioningServiceFactory:: + GetInstance()); + #endif diff --git a/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.cc b/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.cc index 411f8eb4831d..a2d97eee0cab 100644 --- a/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.cc +++ b/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.cc @@ -1,15 +1,6 @@ ---- chrome/browser/net/system_network_context_manager.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/net/system_network_context_manager.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/net/system_network_context_manager.cc -@@ -94,7 +94,7 @@ - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - #include "chrome/common/chrome_paths_internal.h" - #include "chrome/grit/branded_strings.h" - #include "ui/base/l10n/l10n_util.h" -@@ -139,7 +139,7 @@ SystemNetworkContextManager* g_system_network_context_ +@@ -140,7 +140,7 @@ SystemNetworkContextManager* g_system_network_context_ // received a failed launch for a sandboxed network service. bool g_previously_failed_to_launch_sandboxed_service = false; @@ -18,7 +9,7 @@ // Whether kerberos library loading will work in the network service due to the // sandbox. bool g_network_service_will_allow_gssapi_library_load = false; -@@ -147,7 +147,7 @@ bool g_network_service_will_allow_gssapi_library_load +@@ -148,7 +148,7 @@ bool g_network_service_will_allow_gssapi_library_load const char* kGssapiDesiredPref = #if BUILDFLAG(IS_CHROMEOS) prefs::kKerberosEnabled; @@ -27,7 +18,7 @@ prefs::kReceivedHttpAuthNegotiateHeader; #endif #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -@@ -193,7 +193,7 @@ network::mojom::HttpAuthDynamicParamsPtr CreateHttpAut +@@ -194,7 +194,7 @@ network::mojom::HttpAuthDynamicParamsPtr CreateHttpAut auth_dynamic_params->basic_over_http_enabled = local_state->GetBoolean(prefs::kBasicAuthOverHttpEnabled); @@ -36,7 +27,7 @@ auth_dynamic_params->delegate_by_kdc_policy = local_state->GetBoolean(prefs::kAuthNegotiateDelegateByKdcPolicy); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) -@@ -208,7 +208,7 @@ network::mojom::HttpAuthDynamicParamsPtr CreateHttpAut +@@ -209,7 +209,7 @@ network::mojom::HttpAuthDynamicParamsPtr CreateHttpAut local_state->GetString(prefs::kAuthAndroidNegotiateAccountType); #endif // BUILDFLAG(IS_ANDROID) @@ -45,7 +36,7 @@ auth_dynamic_params->allow_gssapi_library_load = local_state->GetBoolean(kGssapiDesiredPref); #endif // BUILDFLAG(IS_CHROMEOS) -@@ -218,7 +218,7 @@ network::mojom::HttpAuthDynamicParamsPtr CreateHttpAut +@@ -219,7 +219,7 @@ network::mojom::HttpAuthDynamicParamsPtr CreateHttpAut void OnNewHttpAuthDynamicParams( network::mojom::HttpAuthDynamicParamsPtr& params) { @@ -54,7 +45,7 @@ // The kerberos library is incompatible with the network service sandbox, so // if library loading is now enabled, the network service needs to be // restarted. It will be restarted unsandboxed because is -@@ -260,11 +260,11 @@ NetworkSandboxState IsNetworkSandboxEnabledInternal() +@@ -261,11 +261,11 @@ NetworkSandboxState IsNetworkSandboxEnabledInternal() if (g_previously_failed_to_launch_sandboxed_service) { return NetworkSandboxState::kDisabledBecauseOfFailedLaunch; } @@ -68,7 +59,7 @@ // The network service sandbox and the kerberos library are incompatible. // If kerberos is enabled by policy, disable the network service sandbox. if (g_network_service_will_allow_gssapi_library_load || -@@ -280,7 +280,7 @@ NetworkSandboxState IsNetworkSandboxEnabledInternal() +@@ -281,7 +281,7 @@ NetworkSandboxState IsNetworkSandboxEnabledInternal() } #endif // BUILDFLAG(IS_WIN) @@ -77,7 +68,7 @@ if (local_state && local_state->HasPrefPath(prefs::kNetworkServiceSandboxEnabled)) { return local_state->GetBoolean(prefs::kNetworkServiceSandboxEnabled) -@@ -510,7 +510,7 @@ void SystemNetworkContextManager::DeleteInstance() { +@@ -527,7 +527,7 @@ void SystemNetworkContextManager::DeleteInstance() { g_system_network_context_manager = nullptr; } @@ -86,7 +77,7 @@ SystemNetworkContextManager::GssapiLibraryLoadObserver:: GssapiLibraryLoadObserver(SystemNetworkContextManager* owner) : owner_(owner) {} -@@ -568,7 +568,7 @@ SystemNetworkContextManager::SystemNetworkContextManag +@@ -585,7 +585,7 @@ SystemNetworkContextManager::SystemNetworkContextManag pref_change_registrar_.Add(prefs::kAllHttpAuthSchemesAllowedForOrigins, auth_pref_callback); @@ -95,7 +86,7 @@ pref_change_registrar_.Add(prefs::kAuthNegotiateDelegateByKdcPolicy, auth_pref_callback); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) -@@ -582,7 +582,7 @@ SystemNetworkContextManager::SystemNetworkContextManag +@@ -599,7 +599,7 @@ SystemNetworkContextManager::SystemNetworkContextManag auth_pref_callback); #endif // BUILDFLAG(IS_ANDROID) @@ -104,34 +95,16 @@ pref_change_registrar_.Add(kGssapiDesiredPref, auth_pref_callback); #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -@@ -608,7 +608,7 @@ SystemNetworkContextManager::SystemNetworkContextManag - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - pref_change_registrar_.Add( - prefs::kEnforceLocalAnchorConstraintsEnabled, - base::BindRepeating(&SystemNetworkContextManager:: -@@ -663,7 +663,7 @@ void SystemNetworkContextManager::RegisterPrefs(PrefRe - registry->RegisterBooleanPref(prefs::kKerberosEnabled, false); - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) +@@ -670,7 +670,7 @@ void SystemNetworkContextManager::RegisterPrefs(PrefRe + registry->RegisterStringPref(prefs::kAuthNegotiateDelegateAllowlist, + std::string()); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) registry->RegisterBooleanPref(prefs::kAuthNegotiateDelegateByKdcPolicy, false); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) -@@ -687,7 +687,7 @@ void SystemNetworkContextManager::RegisterPrefs(PrefRe - registry->RegisterIntegerPref(prefs::kMaxConnectionsPerProxy, -1); - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - // Note that the default value is not relevant because the pref is only - // evaluated when it is managed. - registry->RegisterBooleanPref(prefs::kEnforceLocalAnchorConstraintsEnabled, -@@ -696,11 +696,11 @@ void SystemNetworkContextManager::RegisterPrefs(PrefRe +@@ -695,11 +695,11 @@ void SystemNetworkContextManager::RegisterPrefs(PrefRe registry->RegisterListPref(prefs::kExplicitlyAllowedNetworkPorts); @@ -154,7 +127,7 @@ gssapi_library_loader_observer_.Install(network_service); #endif // BUILDFLAG(IS_LINUX) -@@ -970,7 +970,7 @@ bool SystemNetworkContextManager::IsNetworkSandboxEnab +@@ -975,7 +975,7 @@ bool SystemNetworkContextManager::IsNetworkSandboxEnab break; } @@ -163,12 +136,3 @@ if (!enabled) { g_network_service_will_allow_gssapi_library_load = true; } -@@ -1055,7 +1055,7 @@ void SystemNetworkContextManager::UpdateExplicitlyAllo - } - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - void SystemNetworkContextManager::UpdateEnforceLocalAnchorConstraintsEnabled() { - const PrefService::Preference* enforce_local_anchor_constraints_enabled_pref = - local_state_->FindPreference( diff --git a/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.h b/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.h index 07f2ef79f77a..a7bca37bc021 100644 --- a/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.h +++ b/www/chromium/files/patch-chrome_browser_net_system__network__context__manager.h @@ -1,6 +1,6 @@ ---- chrome/browser/net/system_network_context_manager.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/net/system_network_context_manager.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/net/system_network_context_manager.h -@@ -200,7 +200,7 @@ class SystemNetworkContextManager { +@@ -198,7 +198,7 @@ class SystemNetworkContextManager { class URLLoaderFactoryForSystem; class NetworkProcessLaunchWatcher; @@ -9,18 +9,9 @@ class GssapiLibraryLoadObserver : public network::mojom::GssapiLibraryLoadObserver { public: -@@ -236,7 +236,7 @@ class SystemNetworkContextManager { - void UpdateExplicitlyAllowedNetworkPorts(); - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - // Applies the current value of the kEnforceLocalAnchorConstraintsEnabled - // pref to the enforcement state. - void UpdateEnforceLocalAnchorConstraintsEnabled(); -@@ -286,7 +286,7 @@ class SystemNetworkContextManager { - +@@ -281,7 +281,7 @@ class SystemNetworkContextManager { std::unique_ptr<NetworkAnnotationMonitor> network_annotation_monitor_; + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_new__tab__page_modules_drive_drive__service.cc b/www/chromium/files/patch-chrome_browser_new__tab__page_modules_file__suggestion_drive__service.cc index 98758a0def30..9c0aa3afd6c5 100644 --- a/www/chromium/files/patch-chrome_browser_new__tab__page_modules_drive_drive__service.cc +++ b/www/chromium/files/patch-chrome_browser_new__tab__page_modules_file__suggestion_drive__service.cc @@ -1,6 +1,6 @@ ---- chrome/browser/new_tab_page/modules/drive/drive_service.cc.orig 2023-09-13 12:11:42 UTC -+++ chrome/browser/new_tab_page/modules/drive/drive_service.cc -@@ -32,7 +32,7 @@ +--- chrome/browser/new_tab_page/modules/file_suggestion/drive_service.cc.orig 2025-02-19 07:43:18 UTC ++++ chrome/browser/new_tab_page/modules/file_suggestion/drive_service.cc +@@ -35,7 +35,7 @@ #include "services/network/public/cpp/resource_request.h" namespace { diff --git a/www/chromium/files/patch-chrome_browser_new__tab__page_new__tab__page__util.cc b/www/chromium/files/patch-chrome_browser_new__tab__page_new__tab__page__util.cc index 47d709028e69..31152f4d2ecd 100644 --- a/www/chromium/files/patch-chrome_browser_new__tab__page_new__tab__page__util.cc +++ b/www/chromium/files/patch-chrome_browser_new__tab__page_new__tab__page__util.cc @@ -1,6 +1,6 @@ ---- chrome/browser/new_tab_page/new_tab_page_util.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/new_tab_page/new_tab_page_util.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/new_tab_page/new_tab_page_util.cc -@@ -20,7 +20,7 @@ bool IsOsSupportedForCart() { +@@ -29,7 +29,7 @@ bool IsOsSupportedForCart() { } bool IsOsSupportedForDrive() { diff --git a/www/chromium/files/patch-chrome_browser_notifications_notification__display__service__impl.cc b/www/chromium/files/patch-chrome_browser_notifications_notification__display__service__impl.cc index cf7943370f20..4028e7e8279b 100644 --- a/www/chromium/files/patch-chrome_browser_notifications_notification__display__service__impl.cc +++ b/www/chromium/files/patch-chrome_browser_notifications_notification__display__service__impl.cc @@ -1,15 +1,15 @@ ---- chrome/browser/notifications/notification_display_service_impl.cc.orig 2022-05-19 14:06:27 UTC +--- chrome/browser/notifications/notification_display_service_impl.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/notifications/notification_display_service_impl.cc -@@ -32,7 +32,7 @@ +@@ -31,7 +31,7 @@ #endif #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) #include "chrome/browser/send_tab_to_self/desktop_notification_handler.h" #include "chrome/browser/sharing/sharing_notification_handler.h" #endif -@@ -65,7 +65,7 @@ NotificationDisplayServiceImpl* NotificationDisplaySer +@@ -60,7 +60,7 @@ NotificationDisplayServiceImpl* NotificationDisplaySer // static void NotificationDisplayServiceImpl::RegisterProfilePrefs( user_prefs::PrefRegistrySyncable* registry) { @@ -18,7 +18,7 @@ registry->RegisterBooleanPref(prefs::kAllowSystemNotifications, true); #endif } -@@ -81,7 +81,7 @@ NotificationDisplayServiceImpl::NotificationDisplaySer +@@ -76,7 +76,7 @@ NotificationDisplayServiceImpl::NotificationDisplaySer std::make_unique<PersistentNotificationHandler>()); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ @@ -27,12 +27,12 @@ AddNotificationHandler( NotificationHandler::Type::SEND_TAB_TO_SELF, std::make_unique<send_tab_to_self::DesktopNotificationHandler>( -@@ -89,7 +89,7 @@ NotificationDisplayServiceImpl::NotificationDisplaySer +@@ -84,7 +84,7 @@ NotificationDisplayServiceImpl::NotificationDisplaySer #endif - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN)) && \ ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) && \ + BUILDFLAG(SAFE_BROWSING_AVAILABLE) AddNotificationHandler( NotificationHandler::Type::TAILORED_SECURITY, - std::make_unique<safe_browsing::TailoredSecurityNotificationHandler>()); diff --git a/www/chromium/files/patch-chrome_browser_notifications_notification__platform__bridge__delegator.cc b/www/chromium/files/patch-chrome_browser_notifications_notification__platform__bridge__delegator.cc index 1d138c9c3cb0..d6a83db3a03e 100644 --- a/www/chromium/files/patch-chrome_browser_notifications_notification__platform__bridge__delegator.cc +++ b/www/chromium/files/patch-chrome_browser_notifications_notification__platform__bridge__delegator.cc @@ -1,6 +1,6 @@ ---- chrome/browser/notifications/notification_platform_bridge_delegator.cc.orig 2022-02-28 16:54:41 UTC +--- chrome/browser/notifications/notification_platform_bridge_delegator.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/notifications/notification_platform_bridge_delegator.cc -@@ -57,7 +57,7 @@ bool SystemNotificationsEnabled(Profile* profile) { +@@ -55,7 +55,7 @@ bool SystemNotificationsEnabled(Profile* profile) { #elif BUILDFLAG(IS_WIN) return NotificationPlatformBridgeWin::SystemNotificationEnabled(); #else diff --git a/www/chromium/files/patch-chrome_browser_password__manager_chrome__password__manager__client.cc b/www/chromium/files/patch-chrome_browser_password__manager_chrome__password__manager__client.cc index 62e505acb141..23ea9455b4fe 100644 --- a/www/chromium/files/patch-chrome_browser_password__manager_chrome__password__manager__client.cc +++ b/www/chromium/files/patch-chrome_browser_password__manager_chrome__password__manager__client.cc @@ -1,15 +1,15 @@ ---- chrome/browser/password_manager/chrome_password_manager_client.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/password_manager/chrome_password_manager_client.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/password_manager/chrome_password_manager_client.cc -@@ -468,7 +468,7 @@ bool ChromePasswordManagerClient::ShowKeyboardReplacin - - bool ChromePasswordManagerClient::CanUseBiometricAuthForFilling( +@@ -658,7 +658,7 @@ void ChromePasswordManagerClient:: + bool ChromePasswordManagerClient::IsReauthBeforeFillingRequired( device_reauth::DeviceAuthenticator* authenticator) { --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) if (!GetLocalStatePrefs() || !GetPrefs() || !authenticator) { return false; } -@@ -691,7 +691,7 @@ void ChromePasswordManagerClient::NotifyUserCredential +@@ -936,7 +936,7 @@ void ChromePasswordManagerClient::NotifyUserCredential } void ChromePasswordManagerClient::NotifyKeychainError() { @@ -17,4 +17,22 @@ +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) PasswordsClientUIDelegate* manage_passwords_ui_controller = PasswordsClientUIDelegateFromWebContents(web_contents()); - manage_passwords_ui_controller->OnKeychainError(); + if (manage_passwords_ui_controller) { +@@ -2043,7 +2043,7 @@ void ChromePasswordManagerClient::HideFillingUI() { + bool ChromePasswordManagerClient::IsPasswordManagementEnabledForCurrentPage( + const GURL& url) const { + #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (IsPasswordManagerForUrlDisallowedByPolicy(url)) { + return false; + } +@@ -2082,7 +2082,7 @@ bool ChromePasswordManagerClient::IsPasswordManagement + } + + #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + bool ChromePasswordManagerClient::IsPasswordManagerForUrlDisallowedByPolicy( + const GURL& url) const { + if (!GetPrefs() || !GetPrefs()->HasPrefPath( diff --git a/www/chromium/files/patch-chrome_browser_password__manager_password__reuse__manager__factory.cc b/www/chromium/files/patch-chrome_browser_password__manager_password__reuse__manager__factory.cc index 9d3219e5320b..df2cdbc5a597 100644 --- a/www/chromium/files/patch-chrome_browser_password__manager_password__reuse__manager__factory.cc +++ b/www/chromium/files/patch-chrome_browser_password__manager_password__reuse__manager__factory.cc @@ -1,11 +1,11 @@ ---- chrome/browser/password_manager/password_reuse_manager_factory.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/password_manager/password_reuse_manager_factory.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/password_manager/password_reuse_manager_factory.cc -@@ -137,7 +137,7 @@ PasswordReuseManagerFactory::BuildServiceInstanceForBr - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - std::unique_ptr<password_manager::PasswordStoreSigninNotifier> notifier = - std::make_unique<password_manager::PasswordStoreSigninNotifierImpl>( - IdentityManagerFactory::GetForProfile(profile)); +@@ -128,7 +128,7 @@ PasswordReuseManagerFactory::BuildServiceInstanceForBr + // Prepare password hash data for reuse detection. + reuse_manager->PreparePasswordHashData(GetSignInStateForMetrics(profile)); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<password_manager::PasswordReuseManagerSigninNotifier> + notifier = std::make_unique< + password_manager::PasswordReuseManagerSigninNotifierImpl>( diff --git a/www/chromium/files/patch-chrome_browser_platform__util__linux.cc b/www/chromium/files/patch-chrome_browser_platform__util__linux.cc index cd478994c7af..cedc29de275d 100644 --- a/www/chromium/files/patch-chrome_browser_platform__util__linux.cc +++ b/www/chromium/files/patch-chrome_browser_platform__util__linux.cc @@ -1,6 +1,6 @@ ---- chrome/browser/platform_util_linux.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/platform_util_linux.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/platform_util_linux.cc -@@ -300,7 +300,9 @@ void OnLaunchOptionsCreated(const std::string& command +@@ -302,7 +302,9 @@ void OnLaunchOptionsCreated(const std::string& command argv.push_back(command); argv.push_back(arg); options.current_directory = working_directory; diff --git a/www/chromium/files/patch-chrome_browser_policy_chrome__browser__cloud__management__controller__desktop.cc b/www/chromium/files/patch-chrome_browser_policy_chrome__browser__cloud__management__controller__desktop.cc index a6bc96224851..6b8c8c1dc680 100644 --- a/www/chromium/files/patch-chrome_browser_policy_chrome__browser__cloud__management__controller__desktop.cc +++ b/www/chromium/files/patch-chrome_browser_policy_chrome__browser__cloud__management__controller__desktop.cc @@ -1,6 +1,6 @@ ---- chrome/browser/policy/chrome_browser_cloud_management_controller_desktop.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/policy/chrome_browser_cloud_management_controller_desktop.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/policy/chrome_browser_cloud_management_controller_desktop.cc -@@ -50,7 +50,7 @@ +@@ -60,7 +60,7 @@ #include "chrome/browser/policy/browser_dm_token_storage_mac.h" #endif // BUILDFLAG(IS_MAC) @@ -9,16 +9,16 @@ #include "chrome/browser/policy/browser_dm_token_storage_linux.h" #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -59,7 +59,7 @@ +@@ -69,7 +69,7 @@ #include "chrome/install_static/install_util.h" #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/client_certificates/browser_context_delegate.h" + #include "chrome/browser/enterprise/client_certificates/cert_utils.h" #include "chrome/browser/enterprise/connectors/device_trust/key_management/browser/device_trust_key_manager_impl.h" - #include "chrome/browser/enterprise/connectors/device_trust/key_management/browser/key_rotation_launcher.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -@@ -91,7 +91,7 @@ void ChromeBrowserCloudManagementControllerDesktop:: +@@ -115,7 +115,7 @@ void ChromeBrowserCloudManagementControllerDesktop:: #if BUILDFLAG(IS_MAC) storage_delegate = std::make_unique<BrowserDMTokenStorageMac>(); @@ -27,7 +27,7 @@ storage_delegate = std::make_unique<BrowserDMTokenStorageLinux>(); #elif BUILDFLAG(IS_WIN) storage_delegate = std::make_unique<BrowserDMTokenStorageWin>(); -@@ -261,7 +261,7 @@ ChromeBrowserCloudManagementControllerDesktop::CreateC +@@ -286,7 +286,7 @@ ChromeBrowserCloudManagementControllerDesktop::CreateC std::unique_ptr<enterprise_connectors::DeviceTrustKeyManager> ChromeBrowserCloudManagementControllerDesktop::CreateDeviceTrustKeyManager() { @@ -36,3 +36,12 @@ auto* browser_dm_token_storage = BrowserDMTokenStorage::Get(); auto* device_management_service = GetDeviceManagementService(); auto shared_url_loader_factory = GetSharedURLLoaderFactory(); +@@ -308,7 +308,7 @@ ChromeBrowserCloudManagementControllerDesktop::CreateD + std::unique_ptr<client_certificates::CertificateProvisioningService> + ChromeBrowserCloudManagementControllerDesktop:: + CreateCertificateProvisioningService() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + if (!certificate_store_) { + certificate_store_ = + std::make_unique<client_certificates::PrefsCertificateStore>( diff --git a/www/chromium/files/patch-chrome_browser_policy_configuration__policy__handler__list__factory.cc b/www/chromium/files/patch-chrome_browser_policy_configuration__policy__handler__list__factory.cc index 399f0811eb39..0809f9f0139a 100644 --- a/www/chromium/files/patch-chrome_browser_policy_configuration__policy__handler__list__factory.cc +++ b/www/chromium/files/patch-chrome_browser_policy_configuration__policy__handler__list__factory.cc @@ -1,73 +1,51 @@ ---- chrome/browser/policy/configuration_policy_handler_list_factory.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/policy/configuration_policy_handler_list_factory.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/policy/configuration_policy_handler_list_factory.cc -@@ -233,19 +233,20 @@ +@@ -249,7 +249,7 @@ #include "components/spellcheck/browser/pref_names.h" #endif // BUILDFLAG(ENABLE_SPELLCHECK) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/browser_switcher/browser_switcher_prefs.h" #include "chrome/browser/enterprise/idle/action.h" #include "chrome/browser/enterprise/signin/enterprise_signin_prefs.h" - #include "components/device_signals/core/browser/pref_names.h" // nogncheck due to crbug.com/1125897 - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - #include "components/enterprise/idle/idle_timeout_policy_handler.h" - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_ANDROID) || \ -+ BUILDFLAG(IS_BSD) - #include "chrome/browser/privacy_sandbox/privacy_sandbox_policy_handler.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || - // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || -@@ -260,13 +261,13 @@ - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "chrome/browser/policy/battery_saver_policy_handler.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || - // BUILDFLAG(IS_CHROMEOS_ASH) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "components/search_engines/site_search_policy_handler.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || - // BUILDFLAG(IS_CHROMEOS) -@@ -868,7 +869,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - prefs::kManagedDefaultGeolocationSetting, +@@ -570,7 +570,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + prefs::kManagedDefaultSmartCardConnectSetting, base::Value::Type::INTEGER }, + #endif +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + { key::kDeletingUndecryptablePasswordsEnabled, + password_manager::prefs::kDeletingUndecryptablePasswordsEnabled, + base::Value::Type::BOOLEAN }, +@@ -939,7 +939,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + base::Value::Type::LIST }, + #endif // BUILDFLAG(ENABLE_EXTENSIONS_CORE) #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) \ -- || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_MAC) -+ || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) +- || BUILDFLAG(IS_MAC) ++ || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) { key::kRequireOnlineRevocationChecksForLocalAnchors, prefs::kCertRevocationCheckingRequiredLocalAnchors, base::Value::Type::BOOLEAN }, -@@ -878,7 +879,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = +@@ -951,7 +951,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + base::Value::Type::LIST }, #endif // #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) - // || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_MAC) - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) \ -- || BUILDFLAG(IS_FUCHSIA) -+ || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + // || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) { key::kFullscreenAllowed, prefs::kFullscreenAllowed, base::Value::Type::BOOLEAN }, -@@ -1657,7 +1658,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - }, - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +@@ -1830,7 +1830,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + base::Value::Type::INTEGER}, + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) { key::kGSSAPILibraryName, prefs::kGSSAPILibraryName, base::Value::Type::STRING }, -@@ -1705,7 +1706,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = +@@ -1889,7 +1889,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = base::Value::Type::BOOLEAN }, #endif // BUILDFLAG(IS_WIN) @@ -76,7 +54,7 @@ { key::kNetworkServiceSandboxEnabled, prefs::kNetworkServiceSandboxEnabled, base::Value::Type::BOOLEAN }, -@@ -1731,12 +1732,12 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = +@@ -1909,12 +1909,12 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = prefs::kTotalMemoryLimitMb, base::Value::Type::INTEGER }, #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) @@ -91,25 +69,25 @@ { key::kUnmanagedDeviceSignalsConsentFlowEnabled, device_signals::prefs::kUnmanagedDeviceSignalsConsentFlowEnabled, base::Value::Type::BOOLEAN }, -@@ -1748,7 +1749,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - base::Value::Type::STRING }, +@@ -1928,7 +1928,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + prefs::kLiveTranslateEnabled, + base::Value::Type::BOOLEAN }, #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) \ -- || BUILDFLAG(IS_FUCHSIA) -+ || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) { key::kDefaultBrowserSettingEnabled, prefs::kDefaultBrowserSettingEnabled, base::Value::Type::BOOLEAN }, -@@ -1761,7 +1762,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = +@@ -1940,7 +1940,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + base::Value::Type::BOOLEAN }, #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - // || BUILDFLAG(IS_FUCHSIA) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) \ -- || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- || BUILDFLAG(IS_CHROMEOS) ++ || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) { key::kAutoplayAllowed, prefs::kAutoplayAllowed, base::Value::Type::BOOLEAN }, -@@ -1862,7 +1863,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = +@@ -2041,7 +2041,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = base::Value::Type::BOOLEAN }, #endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS) @@ -118,8 +96,8 @@ { key::kAlternativeBrowserPath, browser_switcher::prefs::kAlternativeBrowserPath, base::Value::Type::STRING }, -@@ -1969,7 +1970,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - base::Value::Type::LIST }, +@@ -2142,7 +2142,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + base::Value::Type::BOOLEAN }, #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) @@ -127,97 +105,70 @@ { key::kAuthNegotiateDelegateByKdcPolicy, prefs::kAuthNegotiateDelegateByKdcPolicy, base::Value::Type::BOOLEAN }, -@@ -1994,7 +1995,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - #endif // BUILDFLAG(ENABLE_EXTENSIONS) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - { key::kEnforceLocalAnchorConstraintsEnabled, - prefs::kEnforceLocalAnchorConstraintsEnabled, - base::Value::Type::BOOLEAN }, -@@ -2052,7 +2053,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = +@@ -2216,7 +2216,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = ash::prefs::kUrlParameterToAutofillSAMLUsername, base::Value::Type::STRING }, - #endif // BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - { key::kTabDiscardingExceptions, - performance_manager::user_tuning::prefs::kManagedTabDiscardingExceptions, - base::Value::Type::LIST }, -@@ -2080,7 +2081,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - prefs::kCloudApAuthEnabled, - base::Value::Type::INTEGER }, + #endif // BUILDFLAG(IS_CHROMEOS) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + { key::kNTPFooterExtensionAttributionEnabled, + prefs::kNTPFooterExtensionAttributionEnabled, + base::Value::Type::BOOLEAN }, +@@ -2248,7 +2248,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + prefs::kUiAutomationProviderEnabled, + base::Value::Type::BOOLEAN }, #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) { key::kOutOfProcessSystemDnsResolutionEnabled, prefs::kOutOfProcessSystemDnsResolutionEnabled, base::Value::Type::BOOLEAN }, -@@ -2109,7 +2110,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - prefs::kManagedPrivateNetworkAccessRestrictionsEnabled, - base::Value::Type::BOOLEAN }, +@@ -2285,7 +2285,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + base::Value::Type::INTEGER }, + #endif #if BUILDFLAG(ENABLE_EXTENSIONS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) { key::kExtensionInstallTypeBlocklist, extensions::pref_names::kExtensionInstallTypeBlocklist, base::Value::Type::LIST}, -@@ -2130,7 +2131,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = - optimization_guide::model_execution::prefs::kWallpaperSearchEnterprisePolicyAllowed, +@@ -2308,7 +2308,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + { key::kTabCompareSettings, + optimization_guide::prefs::kProductSpecificationsEnterprisePolicyAllowed, base::Value::Type::INTEGER}, - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) { key::kChromeForTestingAllowed, prefs::kChromeForTestingAllowed, base::Value::Type::BOOLEAN }, -@@ -2251,7 +2252,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH +@@ -2382,7 +2382,7 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = + policy_prefs::kBuiltInAIAPIsEnabled, + base::Value::Type::BOOLEAN }, + #endif // BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_FUCHSIA) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + { key::kNTPFooterManagementNoticeEnabled, + prefs::kNTPFooterManagementNoticeEnabled, + base::Value::Type::BOOLEAN }, +@@ -2520,7 +2520,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH // Policies for all platforms - End #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - handlers->AddHandler( - std::make_unique<performance_manager::MemorySaverPolicyHandler>()); - // Note: This needs to be created after `DefaultSearchPolicyHandler`. -@@ -2259,7 +2260,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH - // BUILDFLAG(IS_CHROMEOS_ASH) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - handlers->AddHandler( - std::make_unique<SiteSearchPolicyHandler>(chrome_schema)); - -@@ -2468,7 +2469,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH - #endif // BUILDFLAG(IS_ANDROID) - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - handlers->AddHandler( - std::make_unique<enterprise_idle::IdleTimeoutPolicyHandler>()); - handlers->AddHandler( -@@ -2526,7 +2527,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH + handlers->AddHandler(std::make_unique<IntRangePolicyHandler>( + key::kMemorySaverModeSavings, + performance_manager::user_tuning::prefs::kMemorySaverModeAggressiveness, +@@ -2794,7 +2794,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH key::kBrowsingDataLifetime, browsing_data::prefs::kBrowsingDataLifetime, chrome_schema)); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + handlers->AddHandler(std::make_unique<GuestModePolicyHandler>()); handlers->AddHandler(std::make_unique<LocalSyncPolicyHandler>()); handlers->AddHandler(std::make_unique<ThemeColorPolicyHandler>()); - handlers->AddHandler( -@@ -2575,7 +2576,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH - SimpleSchemaValidatingPolicyHandler::RECOMMENDED_PROHIBITED, - SimpleSchemaValidatingPolicyHandler::MANDATORY_ALLOWED))); - --#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - handlers->AddHandler( - std::make_unique<ManagedAccountRestrictionsPolicyHandler>(chrome_schema)); - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -@@ -2613,7 +2614,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH +@@ -2894,7 +2894,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH std::vector<std::unique_ptr<ConfigurationPolicyHandler>> signin_legacy_policies; #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ @@ -226,7 +177,7 @@ signin_legacy_policies.push_back(std::make_unique<SimplePolicyHandler>( key::kForceBrowserSignin, prefs::kForceBrowserSignin, base::Value::Type::BOOLEAN)); -@@ -2970,7 +2971,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH +@@ -3264,7 +3264,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH #endif #if BUILDFLAG(ENABLE_SPELLCHECK) @@ -235,7 +186,7 @@ handlers->AddHandler(std::make_unique<SpellcheckLanguagePolicyHandler>()); handlers->AddHandler( std::make_unique<SpellcheckLanguageBlocklistPolicyHandler>( -@@ -2978,7 +2979,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH +@@ -3272,7 +3272,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) #endif // BUILDFLAG(ENABLE_SPELLCHECK) @@ -244,21 +195,12 @@ handlers->AddHandler(std::make_unique<SimplePolicyHandler>( key::kAllowSystemNotifications, prefs::kAllowSystemNotifications, base::Value::Type::BOOLEAN)); -@@ -2995,7 +2996,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH - /*new_policy_handler=*/std::make_unique< - first_party_sets::FirstPartySetsOverridesPolicyHandler>( - key::kRelatedWebsiteSetsOverrides, chrome_schema))); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_ANDROID) - handlers->AddHandler(std::make_unique<PrivacySandboxPolicyHandler>()); - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || -@@ -3022,7 +3023,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH - base::Value::Type::BOOLEAN))); - +@@ -3325,7 +3325,7 @@ std::unique_ptr<ConfigurationPolicyHandlerList> BuildH + std::vector<GenAiDefaultSettingsPolicyHandler::GenAiPolicyDetails> + gen_ai_default_policies; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - handlers->AddHandler(std::make_unique<BatterySaverPolicyHandler>()); - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || - // BUILDFLAG(IS_CHROMEOS_ASH) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + gen_ai_default_policies.emplace_back( + key::kAutofillPredictionSettings, + optimization_guide::prefs:: diff --git a/www/chromium/files/patch-chrome_browser_policy_device__management__service__configuration.cc b/www/chromium/files/patch-chrome_browser_policy_device__management__service__configuration.cc index 3ae32d3c0cc6..ca99ea425a85 100644 --- a/www/chromium/files/patch-chrome_browser_policy_device__management__service__configuration.cc +++ b/www/chromium/files/patch-chrome_browser_policy_device__management__service__configuration.cc @@ -1,6 +1,6 @@ ---- chrome/browser/policy/device_management_service_configuration.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/policy/device_management_service_configuration.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/policy/device_management_service_configuration.cc -@@ -24,7 +24,7 @@ +@@ -22,7 +22,7 @@ #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ @@ -9,12 +9,3 @@ #include "chrome/browser/enterprise/connectors/common.h" #include "chrome/browser/enterprise/connectors/connectors_service.h" #endif -@@ -102,7 +102,7 @@ DeviceManagementServiceConfiguration::GetReportingConn - content::BrowserContext* context) const { - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ - ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ -- !BUILDFLAG(IS_ANDROID)) -+ !BUILDFLAG(IS_ANDROID)) || BUILDFLAG(IS_BSD) - auto* service = - enterprise_connectors::ConnectorsServiceFactory::GetForBrowserContext( - context); diff --git a/www/chromium/files/patch-chrome_browser_policy_policy__value__and__status__aggregator.cc b/www/chromium/files/patch-chrome_browser_policy_policy__value__and__status__aggregator.cc index 90e7b8d7afcc..3bc5373b56f5 100644 --- a/www/chromium/files/patch-chrome_browser_policy_policy__value__and__status__aggregator.cc +++ b/www/chromium/files/patch-chrome_browser_policy_policy__value__and__status__aggregator.cc @@ -1,6 +1,6 @@ ---- chrome/browser/policy/policy_value_and_status_aggregator.cc.orig 2023-10-11 18:22:24 UTC +--- chrome/browser/policy/policy_value_and_status_aggregator.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/policy/policy_value_and_status_aggregator.cc -@@ -53,7 +53,7 @@ +@@ -49,7 +49,7 @@ #include "chrome/browser/policy/value_provider/extension_policies_value_provider.h" #endif // BUILDFLAG(ENABLE_EXTENSIONS) @@ -9,12 +9,3 @@ #include "components/policy/core/common/cloud/profile_cloud_policy_manager.h" #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -@@ -99,7 +99,7 @@ std::unique_ptr<policy::PolicyStatusProvider> GetUserP - #else // BUILDFLAG(IS_CHROMEOS_ASH) - policy::CloudPolicyManager* cloud_policy_manager = - profile->GetUserCloudPolicyManager(); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (!cloud_policy_manager) { - cloud_policy_manager = profile->GetProfileCloudPolicyManager(); - } diff --git a/www/chromium/files/patch-chrome_browser_prefs_browser__prefs.cc b/www/chromium/files/patch-chrome_browser_prefs_browser__prefs.cc index 5631409a268a..fbbf0601ee56 100644 --- a/www/chromium/files/patch-chrome_browser_prefs_browser__prefs.cc +++ b/www/chromium/files/patch-chrome_browser_prefs_browser__prefs.cc @@ -1,28 +1,29 @@ ---- chrome/browser/prefs/browser_prefs.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/prefs/browser_prefs.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/prefs/browser_prefs.cc -@@ -488,18 +488,18 @@ +@@ -324,7 +324,7 @@ + #include "chrome/browser/devtools/devtools_window.h" + #endif // BUILDFLAG(ENABLE_DEVTOOLS_FRONTEND) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/whats_new/whats_new_ui.h" #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "components/device_signals/core/browser/pref_names.h" // nogncheck due to crbug.com/1125897 +@@ -495,11 +495,11 @@ #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) - #include "chrome/browser/browser_switcher/browser_switcher_prefs.h" + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "components/device_signals/core/browser/pref_names.h" // nogncheck due to crbug.com/1125897 #endif -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/browser_switcher/browser_switcher_prefs.h" #include "chrome/browser/enterprise/signin/enterprise_signin_prefs.h" #endif - -@@ -534,7 +534,7 @@ +@@ -527,7 +527,7 @@ #include "chrome/browser/sessions/session_service_log.h" #endif @@ -31,24 +32,33 @@ #include "ui/color/system_theme.h" #endif -@@ -1715,7 +1715,7 @@ void RegisterLocalState(PrefRegistrySimple* registry) - registry->RegisterBooleanPref(prefs::kOopPrintDriversAllowedByPolicy, true); +@@ -1714,7 +1714,7 @@ void RegisterLocalState(PrefRegistrySimple* registry) + on_device_translation::RegisterLocalStatePrefs(registry); + #endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + WhatsNewUI::RegisterLocalStatePrefs(registry); #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +@@ -1871,7 +1871,7 @@ void RegisterLocalState(PrefRegistrySimple* registry) + #endif // BUILDFLAG(ENABLE_PDF) + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) registry->RegisterBooleanPref(prefs::kChromeForTestingAllowed, true); #endif -@@ -2060,12 +2060,12 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySync +@@ -2235,12 +2235,12 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySync #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) device_signals::RegisterProfilePrefs(registry); #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || - // BUILDFLAG(IS_CHROMEOS_ASH) + // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_prefs_pref__service__incognito__allowlist.cc b/www/chromium/files/patch-chrome_browser_prefs_pref__service__incognito__allowlist.cc index 2d0b781e49c8..c79423bcf551 100644 --- a/www/chromium/files/patch-chrome_browser_prefs_pref__service__incognito__allowlist.cc +++ b/www/chromium/files/patch-chrome_browser_prefs_pref__service__incognito__allowlist.cc @@ -1,6 +1,6 @@ ---- chrome/browser/prefs/pref_service_incognito_allowlist.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/prefs/pref_service_incognito_allowlist.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/prefs/pref_service_incognito_allowlist.cc -@@ -184,7 +184,7 @@ const char* const kPersistentPrefNames[] = { +@@ -203,7 +203,7 @@ const char* const kPersistentPrefNames[] = { prefs::kShowFullscreenToolbar, #endif diff --git a/www/chromium/files/patch-chrome_browser_printing_print__backend__service__manager.cc b/www/chromium/files/patch-chrome_browser_printing_print__backend__service__manager.cc index 5f8466eaf8aa..981de7b44b68 100644 --- a/www/chromium/files/patch-chrome_browser_printing_print__backend__service__manager.cc +++ b/www/chromium/files/patch-chrome_browser_printing_print__backend__service__manager.cc @@ -1,24 +1,24 @@ ---- chrome/browser/printing/print_backend_service_manager.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/printing/print_backend_service_manager.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/printing/print_backend_service_manager.cc -@@ -34,7 +34,7 @@ +@@ -35,7 +35,7 @@ #include "printing/printing_context.h" #include "printing/printing_features.h" -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "content/public/common/content_switches.h" + #include "ui/linux/linux_ui.h" #endif +@@ -879,7 +879,7 @@ PrintBackendServiceManager::GetServiceFromBundle( + << remote_id << "`"; -@@ -861,7 +861,7 @@ PrintBackendServiceManager::GetServiceFromBundle( - host.BindNewPipeAndPassReceiver(), - content::ServiceProcessHost::Options() - .WithDisplayName(IDS_UTILITY_PROCESS_PRINT_BACKEND_SERVICE_NAME) + std::vector<std::string> extra_switches; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - .WithExtraCommandLineSwitches({switches::kMessageLoopTypeUi}) - #endif - .Pass()); -@@ -1038,7 +1038,7 @@ PrintBackendServiceManager::DetermineIdleTimeoutUpdate + if (auto* linux_ui = ui::LinuxUi::instance()) { + extra_switches = linux_ui->GetCmdLineFlagsForCopy(); + } +@@ -1065,7 +1065,7 @@ PrintBackendServiceManager::DetermineIdleTimeoutUpdate return kNoClientsRegisteredResetOnIdleTimeout; case ClientType::kQueryWithUi: diff --git a/www/chromium/files/patch-chrome_browser_printing_printer__query.cc b/www/chromium/files/patch-chrome_browser_printing_printer__query.cc index c59a3ef146e0..0ff8137c63c5 100644 --- a/www/chromium/files/patch-chrome_browser_printing_printer__query.cc +++ b/www/chromium/files/patch-chrome_browser_printing_printer__query.cc @@ -1,6 +1,6 @@ ---- chrome/browser/printing/printer_query.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/printing/printer_query.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/printing/printer_query.cc -@@ -341,7 +341,7 @@ void PrinterQuery::UpdatePrintSettings(base::Value::Di +@@ -342,7 +342,7 @@ void PrinterQuery::UpdatePrintSettings(base::Value::Di crash_key = std::make_unique<crash_keys::ScopedPrinterInfo>( printer_name, print_backend->GetPrinterDriverInfo(printer_name)); diff --git a/www/chromium/files/patch-chrome_browser_process__singleton__posix.cc b/www/chromium/files/patch-chrome_browser_process__singleton__posix.cc index f3cc0f283d98..fc559d0aeaaa 100644 --- a/www/chromium/files/patch-chrome_browser_process__singleton__posix.cc +++ b/www/chromium/files/patch-chrome_browser_process__singleton__posix.cc @@ -1,6 +1,6 @@ ---- chrome/browser/process_singleton_posix.cc.orig 2023-08-17 07:33:31 UTC +--- chrome/browser/process_singleton_posix.cc.orig 2024-09-30 07:45:04 UTC +++ chrome/browser/process_singleton_posix.cc -@@ -97,7 +97,7 @@ +@@ -102,7 +102,7 @@ #include "ui/base/l10n/l10n_util.h" #include "ui/base/resource/scoped_startup_resource_bundle.h" @@ -9,7 +9,7 @@ #include "chrome/browser/ui/process_singleton_dialog_linux.h" #endif -@@ -355,7 +355,7 @@ bool DisplayProfileInUseError(const base::FilePath& lo +@@ -360,7 +360,7 @@ bool DisplayProfileInUseError(const base::FilePath& lo if (g_disable_prompt) return g_user_opted_unlock_in_use_profile; diff --git a/www/chromium/files/patch-chrome_browser_profiles_chrome__browser__main__extra__parts__profiles.cc b/www/chromium/files/patch-chrome_browser_profiles_chrome__browser__main__extra__parts__profiles.cc index 3a73d18b0cbf..f86f86bfe42e 100644 --- a/www/chromium/files/patch-chrome_browser_profiles_chrome__browser__main__extra__parts__profiles.cc +++ b/www/chromium/files/patch-chrome_browser_profiles_chrome__browser__main__extra__parts__profiles.cc @@ -1,114 +1,137 @@ ---- chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.cc -@@ -321,7 +321,7 @@ - #include "chromeos/constants/chromeos_features.h" +@@ -368,7 +368,7 @@ #endif --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "chrome/browser/policy/messaging_layer/util/manual_test_heartbeat_event_factory.h" + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/idle/idle_service_factory.h" #endif -@@ -412,18 +412,18 @@ - +@@ -410,7 +410,7 @@ + #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) #include "chrome/browser/enterprise/connectors/device_trust/device_trust_connector_service_factory.h" #include "chrome/browser/enterprise/connectors/device_trust/device_trust_service_factory.h" #include "chrome/browser/enterprise/signals/user_permission_service_factory.h" +@@ -418,7 +418,7 @@ + #include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_utils.h" #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - #include "chrome/browser/enterprise/idle/idle_service_factory.h" +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/policy/messaging_layer/util/manual_test_heartbeat_event_factory.h" + #endif + +@@ -426,7 +426,7 @@ + #include "chrome/browser/history_embeddings/history_embeddings_service_factory.h" #endif --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) #include "chrome/browser/browser_switcher/browser_switcher_service_factory.h" #include "chrome/browser/enterprise/client_certificates/certificate_provisioning_service_factory.h" #include "chrome/browser/enterprise/client_certificates/certificate_store_factory.h" -@@ -658,7 +658,7 @@ void ChromeBrowserMainExtraPartsProfiles:: +@@ -750,7 +750,7 @@ void ChromeBrowserMainExtraPartsProfiles:: DiceBoundSessionCookieServiceFactory::GetInstance(); - #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) - #endif // BUILDFLAG(ENABLE_BOUND_SESSION_CREDENTIALS) --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #endif + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) browser_switcher::BrowserSwitcherServiceFactory::GetInstance(); #endif browser_sync::UserEventServiceFactory::GetInstance(); -@@ -781,29 +781,29 @@ void ChromeBrowserMainExtraPartsProfiles:: - enterprise_commands::UserRemoteCommandsServiceFactory::GetInstance(); - #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +@@ -805,13 +805,13 @@ void ChromeBrowserMainExtraPartsProfiles:: + collaboration::CollaborationServiceFactory::GetInstance(); + collaboration::messaging::MessagingBackendServiceFactory::GetInstance(); + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + tab_groups::CollaborationMessagingObserverFactory::GetInstance(); + #endif + commerce::ShoppingServiceFactory::GetInstance(); + ConsentAuditorFactory::GetInstance(); + ContentIndexProviderFactory::GetInstance(); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + contextual_cueing::ContextualCueingServiceFactory::GetInstance(); + #endif + CookieControlsServiceFactory::GetInstance(); +@@ -873,31 +873,31 @@ void ChromeBrowserMainExtraPartsProfiles:: + enterprise_connectors::ConnectorsServiceFactory::GetInstance(); + enterprise_connectors::ReportingEventRouterFactory::GetInstance(); + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) enterprise_connectors::DeviceTrustConnectorServiceFactory::GetInstance(); enterprise_connectors::DeviceTrustServiceFactory::GetInstance(); #endif --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN)) && \ ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) && \ + BUILDFLAG(ENTERPRISE_LOCAL_CONTENT_ANALYSIS) && \ + BUILDFLAG(SAFE_BROWSING_AVAILABLE) enterprise_connectors::LocalBinaryUploadServiceFactory::GetInstance(); #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) enterprise_idle::IdleServiceFactory::GetInstance(); #endif - #if !BUILDFLAG(IS_CHROMEOS_ASH) + #if !BUILDFLAG(IS_CHROMEOS) enterprise_reporting::CloudProfileReportingServiceFactory::GetInstance(); #endif enterprise_reporting::LegacyTechServiceFactory::GetInstance(); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) enterprise_signals::SignalsAggregatorFactory::GetInstance(); #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) enterprise_signals::UserPermissionServiceFactory::GetInstance(); #endif --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) enterprise_signin::EnterpriseSigninServiceFactory::GetInstance(); #endif #if BUILDFLAG(ENABLE_SESSION_SERVICE) -@@ -927,7 +927,7 @@ void ChromeBrowserMainExtraPartsProfiles:: +@@ -1029,7 +1029,7 @@ void ChromeBrowserMainExtraPartsProfiles:: + #if BUILDFLAG(IS_ANDROID) + MerchantViewerDataManagerFactory::GetInstance(); #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) metrics::DesktopProfileSessionDurationsServiceFactory::GetInstance(); #endif -@@ -1034,7 +1034,7 @@ void ChromeBrowserMainExtraPartsProfiles:: + #if !BUILDFLAG(IS_ANDROID) +@@ -1156,7 +1156,7 @@ void ChromeBrowserMainExtraPartsProfiles:: #if BUILDFLAG(IS_CHROMEOS) policy::PolicyCertServiceFactory::GetInstance(); #endif --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) policy::ProfileTokenPolicyWebSigninServiceFactory::GetInstance(); policy::UserPolicyOidcSigninServiceFactory::GetInstance(); #endif -@@ -1076,7 +1076,7 @@ void ChromeBrowserMainExtraPartsProfiles:: - #if !BUILDFLAG(IS_CHROMEOS_ASH) && !BUILDFLAG(IS_ANDROID) +@@ -1202,7 +1202,7 @@ void ChromeBrowserMainExtraPartsProfiles:: + #if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS) ProfileStatisticsFactory::GetInstance(); #endif --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) ProfileTokenWebSigninInterceptorFactory::GetInstance(); OidcAuthenticationSigninInterceptorFactory::GetInstance(); #endif -@@ -1095,7 +1095,7 @@ void ChromeBrowserMainExtraPartsProfiles:: - #endif +@@ -1222,7 +1222,7 @@ void ChromeBrowserMainExtraPartsProfiles:: ReduceAcceptLanguageFactory::GetInstance(); RendererUpdaterFactory::GetInstance(); + regional_capabilities::RegionalCapabilitiesServiceFactory::GetInstance(); -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) reporting::ManualTestHeartbeatEventFactory::GetInstance(); #endif - #if BUILDFLAG(IS_CHROMEOS_LACROS) + #if !BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-chrome_browser_profiles_profile__impl.cc b/www/chromium/files/patch-chrome_browser_profiles_profile__impl.cc index 3ab54b78c268..dad6497ea5fa 100644 --- a/www/chromium/files/patch-chrome_browser_profiles_profile__impl.cc +++ b/www/chromium/files/patch-chrome_browser_profiles_profile__impl.cc @@ -1,7 +1,7 @@ ---- chrome/browser/profiles/profile_impl.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/profiles/profile_impl.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/profiles/profile_impl.cc -@@ -267,6 +267,10 @@ - #include "chrome/browser/spellchecker/spellcheck_service.h" +@@ -269,6 +269,10 @@ + #include "chrome/browser/safe_browsing/safe_browsing_service.h" #endif +#if BUILDFLAG(IS_BSD) @@ -11,16 +11,16 @@ using bookmarks::BookmarkModel; using content::BrowserThread; using content::DownloadManagerDelegate; -@@ -600,7 +604,7 @@ void ProfileImpl::LoadPrefsForNormalStartup(bool async - #else +@@ -593,7 +597,7 @@ void ProfileImpl::LoadPrefsForNormalStartup(bool async + policy_provider = GetUserCloudPolicyManagerAsh(); + #else // !BUILDFLAG(IS_CHROMEOS) { - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ProfileManager* profile_manager = g_browser_process->profile_manager(); ProfileAttributesEntry* entry = profile_manager->GetProfileAttributesStorage() -@@ -893,7 +897,17 @@ void ProfileImpl::DoFinalInit(CreateMode create_mode) +@@ -889,7 +893,17 @@ void ProfileImpl::DoFinalInit(CreateMode create_mode) } base::FilePath ProfileImpl::last_selected_directory() { diff --git a/www/chromium/files/patch-chrome_browser_profiles_profiles__state.cc b/www/chromium/files/patch-chrome_browser_profiles_profiles__state.cc index a57a58b41513..3a29a1dca29f 100644 --- a/www/chromium/files/patch-chrome_browser_profiles_profiles__state.cc +++ b/www/chromium/files/patch-chrome_browser_profiles_profiles__state.cc @@ -1,6 +1,6 @@ ---- chrome/browser/profiles/profiles_state.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/profiles/profiles_state.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/profiles/profiles_state.cc -@@ -195,7 +195,7 @@ bool IsGuestModeRequested(const base::CommandLine& com +@@ -188,7 +188,7 @@ bool IsGuestModeRequested(const base::CommandLine& com PrefService* local_state, bool show_warning) { #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ @@ -9,3 +9,21 @@ DCHECK(local_state); // Check if guest mode enforcement commandline switch or policy are provided. +@@ -224,7 +224,7 @@ bool IsGuestModeEnabled() { + return false; + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // If there are any supervised profiles, disable guest mode. + if (std::ranges::any_of(g_browser_process->profile_manager() + ->GetProfileAttributesStorage() +@@ -240,7 +240,7 @@ bool IsGuestModeEnabled() { + } + + bool IsGuestModeEnabled(const Profile& profile) { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + ProfileAttributesEntry* profile_attributes = + g_browser_process->profile_manager() + ->GetProfileAttributesStorage() diff --git a/www/chromium/files/patch-chrome_browser_regional__capabilities_regional__capabilities__service__client.cc b/www/chromium/files/patch-chrome_browser_regional__capabilities_regional__capabilities__service__client.cc new file mode 100644 index 000000000000..aff313dad577 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_regional__capabilities_regional__capabilities__service__client.cc @@ -0,0 +1,11 @@ +--- chrome/browser/regional_capabilities/regional_capabilities_service_client.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/regional_capabilities/regional_capabilities_service_client.cc +@@ -133,7 +133,7 @@ void RegionalCapabilitiesServiceClient::FetchCountryId + base::android::AttachCurrentThread(), + reinterpret_cast<intptr_t>(heap_callback.release())); + } +-#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void RegionalCapabilitiesServiceClient::FetchCountryId( + CountryIdCallback on_country_id_fetched) { + std::move(on_country_id_fetched).Run(variations_latest_country_id_); diff --git a/www/chromium/files/patch-chrome_browser_renderer__preferences__util.cc b/www/chromium/files/patch-chrome_browser_renderer__preferences__util.cc index b16c241f4844..b42bc309272f 100644 --- a/www/chromium/files/patch-chrome_browser_renderer__preferences__util.cc +++ b/www/chromium/files/patch-chrome_browser_renderer__preferences__util.cc @@ -1,6 +1,6 @@ ---- chrome/browser/renderer_preferences_util.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/renderer_preferences_util.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/renderer_preferences_util.cc -@@ -39,7 +39,7 @@ +@@ -40,7 +40,7 @@ #include "ui/views/controls/textfield/textfield.h" #endif @@ -9,7 +9,7 @@ #include "chrome/browser/themes/theme_service.h" #include "chrome/browser/themes/theme_service_factory.h" #include "ui/linux/linux_ui.h" -@@ -154,7 +154,7 @@ void UpdateFromSystemSettings(blink::RendererPreferenc +@@ -180,7 +180,7 @@ void UpdateFromSystemSettings(blink::RendererPreferenc prefs->caret_blink_interval = views::Textfield::GetCaretBlinkInterval(); #endif @@ -18,7 +18,7 @@ auto* linux_ui_theme = ui::LinuxUiTheme::GetForProfile(profile); if (linux_ui_theme) { if (ThemeServiceFactory::GetForProfile(profile)->UsingSystemTheme()) { -@@ -177,7 +177,7 @@ void UpdateFromSystemSettings(blink::RendererPreferenc +@@ -203,7 +203,7 @@ void UpdateFromSystemSettings(blink::RendererPreferenc #endif #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ diff --git a/www/chromium/files/patch-chrome_browser_safe__browsing_chrome__password__protection__service.cc b/www/chromium/files/patch-chrome_browser_safe__browsing_chrome__password__protection__service.cc new file mode 100644 index 000000000000..8c222775573e --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_safe__browsing_chrome__password__protection__service.cc @@ -0,0 +1,11 @@ +--- chrome/browser/safe_browsing/chrome_password_protection_service.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/safe_browsing/chrome_password_protection_service.cc +@@ -1269,7 +1269,7 @@ std::string ChromePasswordProtectionService::GetOrgani + ReusedPasswordAccountType password_type) const { + if (base::FeatureList::IsEnabled( + safe_browsing::kEnterprisePasswordReuseUiRefresh)) { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return GetPrefs()->GetString(prefs::kEnterpriseCustomLabelForProfile); + #else + return std::string(); diff --git a/www/chromium/files/patch-chrome_browser_safe__browsing_cloud__content__scanning_binary__upload__service.cc b/www/chromium/files/patch-chrome_browser_safe__browsing_cloud__content__scanning_binary__upload__service.cc index a8a348758282..192f8b507a6a 100644 --- a/www/chromium/files/patch-chrome_browser_safe__browsing_cloud__content__scanning_binary__upload__service.cc +++ b/www/chromium/files/patch-chrome_browser_safe__browsing_cloud__content__scanning_binary__upload__service.cc @@ -1,20 +1,11 @@ ---- chrome/browser/safe_browsing/cloud_content_scanning/binary_upload_service.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/safe_browsing/cloud_content_scanning/binary_upload_service.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/safe_browsing/cloud_content_scanning/binary_upload_service.cc -@@ -18,7 +18,7 @@ +@@ -20,7 +20,7 @@ + #include "components/safe_browsing/core/common/safebrowsing_switches.h" #include "net/base/url_util.h" - #include "third_party/abseil-cpp/absl/types/variant.h" -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "chrome/browser/enterprise/connectors/analysis/local_binary_upload_service_factory.h" #endif -@@ -417,7 +417,7 @@ BinaryUploadService* BinaryUploadService::GetForProfil - Profile* profile, - const enterprise_connectors::AnalysisSettings& settings) { - // Local content analysis is supported only on desktop platforms. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (settings.cloud_or_local_settings.is_cloud_analysis()) { - return CloudBinaryUploadServiceFactory::GetForProfile(profile); - } else { diff --git a/www/chromium/files/patch-chrome_browser_safe__browsing_download__protection_file__analyzer.cc b/www/chromium/files/patch-chrome_browser_safe__browsing_download__protection_file__analyzer.cc deleted file mode 100644 index 4ea5ef08be3d..000000000000 --- a/www/chromium/files/patch-chrome_browser_safe__browsing_download__protection_file__analyzer.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- chrome/browser/safe_browsing/download_protection/file_analyzer.cc.orig 2024-03-22 08:19:40 UTC -+++ chrome/browser/safe_browsing/download_protection/file_analyzer.cc -@@ -21,7 +21,7 @@ - #include "content/public/browser/browser_thread.h" - #include "url/gurl.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "chrome/browser/safe_browsing/download_protection/document_analysis_service.h" - #endif - -@@ -85,7 +85,7 @@ void FileAnalyzer::Start(const base::FilePath& target_ - } else if (inspection_type == DownloadFileType::DMG) { - StartExtractDmgFeatures(); - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - } else if (inspection_type == DownloadFileType::OFFICE_DOCUMENT && - !base::FeatureList::IsEnabled(kMaldocaSkipCheck)) { - StartExtractDocumentFeatures(); -@@ -326,7 +326,7 @@ void FileAnalyzer::OnDmgAnalysisFinished( - } - #endif // BUILDFLAG(IS_MAC) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - void FileAnalyzer::StartExtractDocumentFeatures() { - DCHECK_CURRENTLY_ON(BrowserThread::UI); - diff --git a/www/chromium/files/patch-chrome_browser_safe__browsing_download__protection_file__analyzer.h b/www/chromium/files/patch-chrome_browser_safe__browsing_download__protection_file__analyzer.h deleted file mode 100644 index 3469ee44763d..000000000000 --- a/www/chromium/files/patch-chrome_browser_safe__browsing_download__protection_file__analyzer.h +++ /dev/null @@ -1,29 +0,0 @@ ---- chrome/browser/safe_browsing/download_protection/file_analyzer.h.orig 2023-12-10 06:10:27 UTC -+++ chrome/browser/safe_browsing/download_protection/file_analyzer.h -@@ -18,7 +18,7 @@ - #include "components/safe_browsing/core/common/proto/csd.pb.h" - #include "third_party/protobuf/src/google/protobuf/repeated_field.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "chrome/services/file_util/public/cpp/sandboxed_document_analyzer.h" - #endif - -@@ -110,7 +110,7 @@ class FileAnalyzer { - const safe_browsing::ArchiveAnalyzerResults& archive_results); - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - void StartExtractDocumentFeatures(); - void OnDocumentAnalysisFinished( - const DocumentAnalyzerResults& document_results); -@@ -141,7 +141,7 @@ class FileAnalyzer { - dmg_analyzer_{nullptr, base::OnTaskRunnerDeleter(nullptr)}; - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - std::unique_ptr<SandboxedDocumentAnalyzer, base::OnTaskRunnerDeleter> - document_analyzer_{nullptr, base::OnTaskRunnerDeleter(nullptr)}; - base::TimeTicks document_analysis_start_time_; diff --git a/www/chromium/files/patch-chrome_browser_safe__browsing_incident__reporting_incident__reporting__service.cc b/www/chromium/files/patch-chrome_browser_safe__browsing_incident__reporting_incident__reporting__service.cc index 0d4abf133c4f..d0a42d73e87d 100644 --- a/www/chromium/files/patch-chrome_browser_safe__browsing_incident__reporting_incident__reporting__service.cc +++ b/www/chromium/files/patch-chrome_browser_safe__browsing_incident__reporting_incident__reporting__service.cc @@ -1,6 +1,6 @@ ---- chrome/browser/safe_browsing/incident_reporting/incident_reporting_service.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/safe_browsing/incident_reporting/incident_reporting_service.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/safe_browsing/incident_reporting/incident_reporting_service.cc -@@ -694,7 +694,7 @@ void IncidentReportingService::OnEnvironmentDataCollec +@@ -693,7 +693,7 @@ void IncidentReportingService::OnEnvironmentDataCollec // Process::Current().CreationTime() is missing on some platforms. #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-chrome_browser_safe__browsing_safe__browsing__pref__change__handler.cc b/www/chromium/files/patch-chrome_browser_safe__browsing_safe__browsing__pref__change__handler.cc new file mode 100644 index 000000000000..8d14509fa596 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_safe__browsing_safe__browsing__pref__change__handler.cc @@ -0,0 +1,20 @@ +--- chrome/browser/safe_browsing/safe_browsing_pref_change_handler.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/safe_browsing/safe_browsing_pref_change_handler.cc +@@ -12,7 +12,7 @@ + #include "content/public/browser/web_contents.h" + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/browser_finder.h" + #include "chrome/browser/ui/browser_window/public/browser_window_features.h" + #include "chrome/browser/ui/toasts/api/toast_id.h" +@@ -59,7 +59,7 @@ SafeBrowsingPrefChangeHandler::~SafeBrowsingPrefChange + void SafeBrowsingPrefChangeHandler:: + MaybeShowEnhancedProtectionSettingChangeNotification() { + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + if (!profile_ || + !base::FeatureList::IsEnabled(safe_browsing::kEsbAsASyncedSetting)) { + return; diff --git a/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__install__state.cc b/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__install__state.cc index 2d0449a4bade..ac589c8f5382 100644 --- a/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__install__state.cc +++ b/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__install__state.cc @@ -1,20 +1,11 @@ ---- chrome/browser/screen_ai/screen_ai_install_state.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/screen_ai/screen_ai_install_state.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/screen_ai/screen_ai_install_state.cc -@@ -23,7 +23,7 @@ - #include "services/screen_ai/public/cpp/utilities.h" - #include "ui/accessibility/accessibility_features.h" - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "base/cpu.h" - #include "base/files/file_util.h" - #endif -@@ -35,7 +35,7 @@ const char kMinExpectedVersion[] = "123.1"; - bool IsDeviceCompatible() { - // Check if the CPU has the required instruction set to run the Screen AI - // library. --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (!base::CPU().has_sse41()) { - return false; - } +@@ -30,7 +30,7 @@ bool IsDeviceCompatible() { + // TODO(crbug.com/381256355): Update when ScreenAI library is compatible with + // older CPUs. + static const bool device_compatible = base::CPU().has_sse42(); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // On Linux, the library is only built for X86 CPUs. + static constexpr bool device_compatible = false; + #else diff --git a/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__service__router.cc b/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__service__handler__base.cc index e9a16d721dbc..5fd16bb70ed1 100644 --- a/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__service__router.cc +++ b/www/chromium/files/patch-chrome_browser_screen__ai_screen__ai__service__handler__base.cc @@ -1,6 +1,6 @@ ---- chrome/browser/screen_ai/screen_ai_service_router.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/screen_ai/screen_ai_service_router.cc -@@ -281,7 +281,7 @@ void ScreenAIServiceRouter::LaunchIfNotRunning() { +--- chrome/browser/screen_ai/screen_ai_service_handler_base.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/screen_ai/screen_ai_service_handler_base.cc +@@ -253,7 +253,7 @@ void ScreenAIServiceHandlerBase::LaunchIfNotRunning() base::FilePath binary_path = state_instance->get_component_binary_path(); #if BUILDFLAG(IS_WIN) std::vector<base::FilePath> preload_libraries = {binary_path}; @@ -9,7 +9,7 @@ std::vector<std::string> extra_switches = { base::StringPrintf("--%s=%s", screen_ai::GetBinaryPathSwitch(), binary_path.MaybeAsASCII().c_str())}; -@@ -295,7 +295,7 @@ void ScreenAIServiceRouter::LaunchIfNotRunning() { +@@ -268,7 +268,7 @@ void ScreenAIServiceHandlerBase::LaunchIfNotRunning() .WithPreloadedLibraries( preload_libraries, content::ServiceProcessHostPreloadLibraries::GetPassKey()) @@ -17,4 +17,4 @@ +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) .WithExtraCommandLineSwitches(extra_switches) #endif // BUILDFLAG(IS_WIN) - .Pass()); + .WithProcessCallback( diff --git a/www/chromium/files/patch-chrome_browser_search__engine__choice_search__engine__choice__client__side__trial.cc b/www/chromium/files/patch-chrome_browser_search__engine__choice_search__engine__choice__client__side__trial.cc deleted file mode 100644 index 134908a9fb0b..000000000000 --- a/www/chromium/files/patch-chrome_browser_search__engine__choice_search__engine__choice__client__side__trial.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/search_engine_choice/search_engine_choice_client_side_trial.cc.orig 2024-02-23 21:04:38 UTC -+++ chrome/browser/search_engine_choice/search_engine_choice_client_side_trial.cc -@@ -132,7 +132,7 @@ void RegisterLocalStatePrefs(PrefRegistrySimple* regis - void SetUpIfNeeded(const base::FieldTrial::EntropyProvider& entropy_provider, - base::FeatureList* feature_list, - PrefService* local_state) { --#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_MAC) -+#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_BSD) - // Platform not in scope for this client-side trial. - return; - #else diff --git a/www/chromium/files/patch-chrome_browser_search__engine__choice_search__engine__choice__service__factory.cc b/www/chromium/files/patch-chrome_browser_search__engine__choice_search__engine__choice__service__factory.cc deleted file mode 100644 index 6772968fcc25..000000000000 --- a/www/chromium/files/patch-chrome_browser_search__engine__choice_search__engine__choice__service__factory.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- chrome/browser/search_engine_choice/search_engine_choice_service_factory.cc.orig 2024-02-23 21:04:38 UTC -+++ chrome/browser/search_engine_choice/search_engine_choice_service_factory.cc -@@ -11,7 +11,7 @@ - #include "components/country_codes/country_codes.h" - #include "components/search_engines/search_engine_choice/search_engine_choice_service.h" - --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "chrome/browser/browser_process.h" - #include "components/variations/service/variations_service.h" - #endif -@@ -21,7 +21,7 @@ namespace { - std::unique_ptr<KeyedService> BuildSearchEngineChoiceService( - content::BrowserContext* context) { - int variations_country_id = country_codes::kCountryIDUnknown; --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (g_browser_process->variations_service()) { - variations_country_id = - country_codes::CountryStringToCountryID(base::ToUpperASCII( diff --git a/www/chromium/files/patch-chrome_browser_send__tab__to__self_receiving__ui__handler__registry.cc b/www/chromium/files/patch-chrome_browser_send__tab__to__self_receiving__ui__handler__registry.cc deleted file mode 100644 index 943f7cc57732..000000000000 --- a/www/chromium/files/patch-chrome_browser_send__tab__to__self_receiving__ui__handler__registry.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- chrome/browser/send_tab_to_self/receiving_ui_handler_registry.cc.orig 2024-03-22 08:19:40 UTC -+++ chrome/browser/send_tab_to_self/receiving_ui_handler_registry.cc -@@ -15,7 +15,7 @@ - #include "components/send_tab_to_self/features.h" - - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - #include "chrome/browser/send_tab_to_self/desktop_notification_handler.h" - #include "chrome/browser/ui/send_tab_to_self/send_tab_to_self_toolbar_icon_controller.h" - #endif -@@ -47,7 +47,7 @@ SendTabToSelfToolbarIconController* - ReceivingUiHandlerRegistry::GetToolbarButtonControllerForProfile( - Profile* profile) { - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - for (const std::unique_ptr<ReceivingUiHandler>& handler : - applicable_handlers_) { - auto* button_controller = diff --git a/www/chromium/files/patch-chrome_browser_send__tab__to__self_send__tab__to__self__client__service.cc b/www/chromium/files/patch-chrome_browser_send__tab__to__self_send__tab__to__self__client__service.cc deleted file mode 100644 index 2e99aa0f1f64..000000000000 --- a/www/chromium/files/patch-chrome_browser_send__tab__to__self_send__tab__to__self__client__service.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- chrome/browser/send_tab_to_self/send_tab_to_self_client_service.cc.orig 2024-03-22 08:19:40 UTC -+++ chrome/browser/send_tab_to_self/send_tab_to_self_client_service.cc -@@ -16,7 +16,7 @@ - #include "components/send_tab_to_self/send_tab_to_self_model.h" - - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/send_tab_to_self/send_tab_to_self_toolbar_icon_controller.h" - #endif - -@@ -50,7 +50,7 @@ void SendTabToSelfClientService::EntriesAddedRemotely( - const std::vector<const SendTabToSelfEntry*>& new_entries) { - for (const std::unique_ptr<ReceivingUiHandler>& handler : GetHandlers()) { - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - // Only respond to notifications corresponding to this service's profile - // for these OSes; mobile does not have a Profile. - // Cast note: on desktop, handlers are guaranteed to be the derived class diff --git a/www/chromium/files/patch-chrome_browser_sessions_session__restore.cc b/www/chromium/files/patch-chrome_browser_sessions_session__restore.cc new file mode 100644 index 000000000000..591d50a7b636 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_sessions_session__restore.cc @@ -0,0 +1,20 @@ +--- chrome/browser/sessions/session_restore.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/sessions/session_restore.cc +@@ -108,7 +108,7 @@ + #include "ui/wm/core/scoped_animation_disabler.h" + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/whats_new/whats_new_fetcher.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +@@ -1118,7 +1118,7 @@ class SessionRestoreImpl : public BrowserListObserver + bool is_first_tab = true; + for (const auto& startup_tab : startup_tabs) { + const GURL& url = startup_tab.url; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (url == whats_new::GetWebUIStartupURL()) { + whats_new::StartWhatsNewFetch(browser); + continue; diff --git a/www/chromium/files/patch-chrome_browser_sharing_sharing__device__registration.cc b/www/chromium/files/patch-chrome_browser_sharing_sharing__device__registration.cc deleted file mode 100644 index 095ab6780e60..000000000000 --- a/www/chromium/files/patch-chrome_browser_sharing_sharing__device__registration.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/sharing/sharing_device_registration.cc.orig 2024-02-23 21:04:38 UTC -+++ chrome/browser/sharing/sharing_device_registration.cc -@@ -328,7 +328,7 @@ bool SharingDeviceRegistration::IsSmsFetcherSupported( - - bool SharingDeviceRegistration::IsRemoteCopySupported() const { - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - return true; - #else - return false; diff --git a/www/chromium/files/patch-chrome_browser_sharing_sharing__handler__registry__impl.cc b/www/chromium/files/patch-chrome_browser_sharing_sharing__handler__registry__impl.cc index d3f31c85c9ce..07f0703aef08 100644 --- a/www/chromium/files/patch-chrome_browser_sharing_sharing__handler__registry__impl.cc +++ b/www/chromium/files/patch-chrome_browser_sharing_sharing__handler__registry__impl.cc @@ -1,16 +1,16 @@ ---- chrome/browser/sharing/sharing_handler_registry_impl.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/sharing/sharing_handler_registry_impl.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/sharing/sharing_handler_registry_impl.cc -@@ -23,7 +23,7 @@ +@@ -21,7 +21,7 @@ #endif // BUILDFLAG(IS_ANDROID) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "chrome/browser/sharing/shared_clipboard/remote_copy_message_handler.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || (BUILDFLAG(IS_LINUX) || - // BUILDFLAG(IS_CHROMEOS_LACROS)) BUILDFLAG(IS_CHROMEOS) -@@ -78,7 +78,7 @@ SharingHandlerRegistryImpl::SharingHandlerRegistryImpl - } + #endif + +@@ -72,7 +72,7 @@ SharingHandlerRegistryImpl::SharingHandlerRegistryImpl + #endif // !BUILDFLAG(IS_ANDROID) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-chrome_browser_shortcuts_icon__badging.cc b/www/chromium/files/patch-chrome_browser_shortcuts_icon__badging.cc new file mode 100644 index 000000000000..0d25cdec5842 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_shortcuts_icon__badging.cc @@ -0,0 +1,11 @@ +--- chrome/browser/shortcuts/icon_badging.cc.orig 2024-06-17 12:56:06 UTC ++++ chrome/browser/shortcuts/icon_badging.cc +@@ -59,7 +59,7 @@ enum class BadgeSize { + constexpr ShortcutSize kSizesNeededForShortcutCreation[] = { + ShortcutSize::k16, ShortcutSize::k32, ShortcutSize::k128, + ShortcutSize::k256, ShortcutSize::k512}; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr ShortcutSize kSizesNeededForShortcutCreation[] = {ShortcutSize::k32, + ShortcutSize::k128}; + #elif BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-chrome_browser_signin_accounts__policy__manager.cc b/www/chromium/files/patch-chrome_browser_signin_accounts__policy__manager.cc new file mode 100644 index 000000000000..5ac82fcc81df --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_signin_accounts__policy__manager.cc @@ -0,0 +1,38 @@ +--- chrome/browser/signin/accounts_policy_manager.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/signin/accounts_policy_manager.cc +@@ -41,7 +41,7 @@ + #include "chrome/browser/ui/webui/profile_helper.h" + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "components/policy/core/common/features.h" + #include "components/signin/public/identity_manager/accounts_mutator.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +@@ -209,7 +209,7 @@ void AccountsPolicyManager::Initialize() { + &AccountsPolicyManager::OnGoogleServicesUsernamePatternChanged, + weak_pointer_factory_.GetWeakPtr())); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + auto* identity_manager = IdentityManagerFactory::GetForProfile(profile_); + identity_manager_observation_.Observe(identity_manager); + profile_pref_change_registrar_.Init(profile_->GetPrefs()); +@@ -224,7 +224,7 @@ void AccountsPolicyManager::Initialize() { + } + + void AccountsPolicyManager::Shutdown() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + profile_pref_change_registrar_.RemoveAll(); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + local_state_pref_registrar_.RemoveAll(); +@@ -332,7 +332,7 @@ void AccountsPolicyManager::OnUserConfirmedProfileDele + } + #endif // defined(TOOLKIT_VIEWS) && !BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void AccountsPolicyManager::OnRefreshTokensLoaded() { + RemoveUnallowedAccounts(); + identity_manager_observation_.Reset(); diff --git a/www/chromium/files/patch-chrome_browser_signin_accounts__policy__manager.h b/www/chromium/files/patch-chrome_browser_signin_accounts__policy__manager.h new file mode 100644 index 000000000000..1a21e6121435 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_signin_accounts__policy__manager.h @@ -0,0 +1,29 @@ +--- chrome/browser/signin/accounts_policy_manager.h.orig 2025-01-15 09:18:26 UTC ++++ chrome/browser/signin/accounts_policy_manager.h +@@ -13,7 +13,7 @@ + #include "components/signin/public/base/signin_metrics.h" + #include "components/signin/public/identity_manager/identity_manager.h" + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "base/scoped_observation.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +@@ -64,7 +64,7 @@ class AccountsPolicyManager : public KeyedService, + } + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void RemoveUnallowedAccounts(); + + // IdentityManager::Observer implementation. +@@ -85,7 +85,7 @@ class AccountsPolicyManager : public KeyedService, + bool hide_ui_for_testing_ = false; + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::ScopedObservation<signin::IdentityManager, + signin::IdentityManager::Observer> + identity_manager_observation_{this}; diff --git a/www/chromium/files/patch-chrome_browser_signin_signin__util.cc b/www/chromium/files/patch-chrome_browser_signin_signin__util.cc index dad1c4fc114b..6283e56cc7dd 100644 --- a/www/chromium/files/patch-chrome_browser_signin_signin__util.cc +++ b/www/chromium/files/patch-chrome_browser_signin_signin__util.cc @@ -1,6 +1,6 @@ ---- chrome/browser/signin/signin_util.cc.orig 2023-11-03 10:09:45 UTC +--- chrome/browser/signin/signin_util.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/signin/signin_util.cc -@@ -75,7 +75,7 @@ CookiesMover::CookiesMover(base::WeakPtr<Profile> sour +@@ -80,7 +80,7 @@ CookiesMover::CookiesMover(base::WeakPtr<Profile> sour CookiesMover::~CookiesMover() = default; void CookiesMover::StartMovingCookies() { diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_classify__url__navigation__throttle.cc b/www/chromium/files/patch-chrome_browser_supervised__user_classify__url__navigation__throttle.cc new file mode 100644 index 000000000000..4a086d497e79 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_supervised__user_classify__url__navigation__throttle.cc @@ -0,0 +1,20 @@ +--- chrome/browser/supervised_user/classify_url_navigation_throttle.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/supervised_user/classify_url_navigation_throttle.cc +@@ -68,7 +68,7 @@ std::ostream& operator<<(std::ostream& stream, + } + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + bool ShouldShowReAuthInterstitial( + content::NavigationHandle& navigation_handle) { + Profile* profile = Profile::FromBrowserContext( +@@ -229,7 +229,7 @@ void ClassifyUrlNavigationThrottle::OnInterstitialResu + } + case InterstitialResultCallbackActions::kCancelWithInterstitial: { + CHECK(navigation_handle()); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + if (ShouldShowReAuthInterstitial(*navigation_handle())) { + // Show the re-authentication interstitial if the user signed out of + // the content area, as parent's approval requires authentication. diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__browser__utils.cc b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__browser__utils.cc new file mode 100644 index 000000000000..b9b4a5af9db1 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__browser__utils.cc @@ -0,0 +1,20 @@ +--- chrome/browser/supervised_user/supervised_user_browser_utils.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/supervised_user/supervised_user_browser_utils.cc +@@ -40,7 +40,7 @@ + #include "chrome/browser/ash/profiles/profile_helper.h" + #include "components/user_manager/user.h" + #include "components/user_manager/user_type.h" +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/supervised_user/supervised_user_verification_controller_client.h" + #include "chrome/browser/supervised_user/supervised_user_verification_page_blocked_sites.h" + #include "chrome/browser/supervised_user/supervised_user_verification_page_youtube.h" +@@ -158,7 +158,7 @@ void AssertChildStatusOfTheUser(Profile* profile, bool + #endif + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + std::string CreateReauthenticationInterstitialForYouTube( + content::NavigationHandle& navigation_handle) { + content::WebContents* web_contents = navigation_handle.GetWebContents(); diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__browser__utils.h b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__browser__utils.h new file mode 100644 index 000000000000..25dc67f21f8b --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__browser__utils.h @@ -0,0 +1,11 @@ +--- chrome/browser/supervised_user/supervised_user_browser_utils.h.orig 2024-11-14 07:57:23 UTC ++++ chrome/browser/supervised_user/supervised_user_browser_utils.h +@@ -52,7 +52,7 @@ std::string GetAccountGivenName(Profile& profile); + // of the user. + void AssertChildStatusOfTheUser(Profile* profile, bool is_child); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // Returns the html content of the reauthentication interstitial for blocked + // sites. This interstitial is associated with the given NavigationHandle. + std::string CreateReauthenticationInterstitialForBlockedSites( diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__delegate__impl.cc b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__delegate__impl.cc index 54cd329bac0b..b2659af38afa 100644 --- a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__delegate__impl.cc +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__delegate__impl.cc @@ -1,6 +1,6 @@ ---- chrome/browser/supervised_user/supervised_user_extensions_delegate_impl.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/supervised_user/supervised_user_extensions_delegate_impl.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/supervised_user/supervised_user_extensions_delegate_impl.cc -@@ -180,7 +180,7 @@ void SupervisedUserExtensionsDelegateImpl::RequestExte +@@ -197,7 +197,7 @@ void SupervisedUserExtensionsDelegateImpl::RequestExte return; } } @@ -8,4 +8,4 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) CHECK(contents.value()); content::WebContents* web_contents = contents.value().get(); - if (CanInstallExtensions()) { + // Always invoke the parent permission dialog. diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.cc b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.cc index 8a53ba975513..60a562b6e09d 100644 --- a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.cc +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.cc @@ -1,6 +1,6 @@ ---- chrome/browser/supervised_user/supervised_user_extensions_manager.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/supervised_user/supervised_user_extensions_manager.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/supervised_user/supervised_user_extensions_manager.cc -@@ -305,7 +305,7 @@ void SupervisedUserExtensionsManager:: +@@ -350,7 +350,7 @@ void SupervisedUserExtensionsManager:: ActivateManagementPolicyAndUpdateRegistration() { SetActiveForSupervisedUsers(); UpdateManagementPolicyRegistration(); @@ -9,7 +9,7 @@ MaybeMarkExtensionsLocallyParentApproved(); #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) } -@@ -417,7 +417,7 @@ bool SupervisedUserExtensionsManager::ShouldBlockExten +@@ -449,7 +449,7 @@ bool SupervisedUserExtensionsManager::ShouldBlockExten return false; } @@ -17,4 +17,4 @@ +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void SupervisedUserExtensionsManager:: MaybeMarkExtensionsLocallyParentApproved() { - if (!is_active_policy_for_supervised_users_) { + supervised_user::LocallyParentApprovedExtensionsMigrationState diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.h b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.h index cdc61fa4d409..10d107927fda 100644 --- a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.h +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__extensions__manager.h @@ -1,6 +1,6 @@ ---- chrome/browser/supervised_user/supervised_user_extensions_manager.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/supervised_user/supervised_user_extensions_manager.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/supervised_user/supervised_user_extensions_manager.h -@@ -143,7 +143,7 @@ class SupervisedUserExtensionsManager : public Extensi +@@ -154,7 +154,7 @@ class SupervisedUserExtensionsManager : public Extensi // launched. bool ShouldBlockExtension(const std::string& extension_id) const; diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__google__auth__navigation__throttle.cc b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__google__auth__navigation__throttle.cc new file mode 100644 index 000000000000..e2e36bef40ea --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__google__auth__navigation__throttle.cc @@ -0,0 +1,26 @@ +--- chrome/browser/supervised_user/supervised_user_google_auth_navigation_throttle.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/supervised_user/supervised_user_google_auth_navigation_throttle.cc +@@ -33,12 +33,12 @@ + #include "chrome/browser/supervised_user/child_accounts/child_account_service_android.h" + #include "components/signin/public/identity_manager/identity_manager.h" + #include "ui/android/view_android.h" +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/supervised_user/supervised_user_verification_controller_client.h" + #include "chrome/browser/supervised_user/supervised_user_verification_page.h" + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + namespace { + bool IsYouTubeInfrastructureSubframe(content::NavigationHandle* handle) { + if (handle->GetNavigatingFrameType() != content::FrameType::kSubframe) { +@@ -160,7 +160,7 @@ SupervisedUserGoogleAuthNavigationThrottle::ShouldProc + return content::NavigationThrottle::DEFER; + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // When an unauthenticated supervised user tries to access YouTube, we force + // re-authentication with an interstitial so that YouTube can be subject to + // content restrictions. This interstitial is only available on Desktop diff --git a/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__metrics__service__factory.cc b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__metrics__service__factory.cc new file mode 100644 index 000000000000..11fb99e085af --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_supervised__user_supervised__user__metrics__service__factory.cc @@ -0,0 +1,20 @@ +--- chrome/browser/supervised_user/supervised_user_metrics_service_factory.cc.orig 2025-01-15 09:18:26 UTC ++++ chrome/browser/supervised_user/supervised_user_metrics_service_factory.cc +@@ -14,7 +14,7 @@ + #include "components/supervised_user/core/browser/supervised_user_service.h" + #include "content/public/browser/browser_context.h" + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/supervised_user/linux_mac_windows/supervised_user_extensions_metrics_delegate_impl.h" + #endif + +@@ -62,7 +62,7 @@ SupervisedUserMetricsServiceFactory::BuildServiceInsta + std::unique_ptr<supervised_user::SupervisedUserMetricsService :: + SupervisedUserMetricsServiceExtensionDelegate> + extensions_metrics_delegate = nullptr; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extensions_metrics_delegate = + std::make_unique<SupervisedUserExtensionsMetricsDelegateImpl>( + extensions::ExtensionRegistry::Get(profile), profile); diff --git a/www/chromium/files/patch-chrome_browser_sync_chrome__sync__client.cc b/www/chromium/files/patch-chrome_browser_sync_chrome__sync__client.cc deleted file mode 100644 index 38cdbf57b259..000000000000 --- a/www/chromium/files/patch-chrome_browser_sync_chrome__sync__client.cc +++ /dev/null @@ -1,38 +0,0 @@ ---- chrome/browser/sync/chrome_sync_client.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/sync/chrome_sync_client.cc -@@ -112,7 +112,7 @@ - #endif // BUILDFLAG(ENABLE_SPELLCHECK) - - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_keyed_service.h" - #include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_service_factory.h" - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || -@@ -460,7 +460,7 @@ ChromeSyncClient::CreateDataTypeControllers(syncer::Sy - #endif // !BUILDFLAG(IS_ANDROID) - - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - if (base::FeatureList::IsEnabled(features::kTabGroupsSave)) { - controllers.push_back(std::make_unique<syncer::ModelTypeController>( - syncer::SAVED_TAB_GROUP, -@@ -473,7 +473,7 @@ ChromeSyncClient::CreateDataTypeControllers(syncer::Sy - - // Chrome prefers OS provided spell checkers where they exist. So only sync the - // custom dictionary on platforms that typically don't provide one. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - // Dictionary sync is enabled by default. - if (GetPrefService()->GetBoolean(spellcheck::prefs::kSpellCheckEnable)) { - controllers.push_back( -@@ -629,7 +629,7 @@ base::WeakPtr<syncer::ModelTypeControllerDelegate> - ChromeSyncClient::GetControllerDelegateForModelType(syncer::ModelType type) { - switch (type) { - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - case syncer::SAVED_TAB_GROUP: { - DCHECK(base::FeatureList::IsEnabled(features::kTabGroupsSave)); - return tab_groups::SavedTabGroupServiceFactory::GetForProfile(profile_) diff --git a/www/chromium/files/patch-chrome_browser_sync_chrome__sync__controller__builder.cc b/www/chromium/files/patch-chrome_browser_sync_chrome__sync__controller__builder.cc new file mode 100644 index 000000000000..e96d944f1a86 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_sync_chrome__sync__controller__builder.cc @@ -0,0 +1,11 @@ +--- chrome/browser/sync/chrome_sync_controller_builder.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/sync/chrome_sync_controller_builder.cc +@@ -280,7 +280,7 @@ ChromeSyncControllerBuilder::Build(syncer::SyncService + #if BUILDFLAG(ENABLE_SPELLCHECK) + // Chrome prefers OS provided spell checkers where they exist. So only sync + // the custom dictionary on platforms that typically don't provide one. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // Dictionary sync is enabled by default. + if (spellcheck_service_.value()) { + controllers.push_back( diff --git a/www/chromium/files/patch-chrome_browser_sync_device__info__sync__client__impl.cc b/www/chromium/files/patch-chrome_browser_sync_device__info__sync__client__impl.cc index 39332951f80b..fa8e7788e185 100644 --- a/www/chromium/files/patch-chrome_browser_sync_device__info__sync__client__impl.cc +++ b/www/chromium/files/patch-chrome_browser_sync_device__info__sync__client__impl.cc @@ -1,11 +1,11 @@ ---- chrome/browser/sync/device_info_sync_client_impl.cc.orig 2023-03-09 06:31:50 UTC +--- chrome/browser/sync/device_info_sync_client_impl.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/sync/device_info_sync_client_impl.cc -@@ -41,7 +41,7 @@ std::string DeviceInfoSyncClientImpl::GetSigninScopedD - // in lacros-chrome once build flag switch of lacros-chrome is - // complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +@@ -34,7 +34,7 @@ DeviceInfoSyncClientImpl::~DeviceInfoSyncClientImpl() + std::string DeviceInfoSyncClientImpl::GetSigninScopedDeviceId() const { + // Since the local sync backend is currently only supported on Windows, Mac and + // Linux don't even check the pref on other os-es. +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) syncer::SyncPrefs prefs(profile_->GetPrefs()); if (prefs.IsLocalSyncEnabled()) { return "local_device"; diff --git a/www/chromium/files/patch-chrome_browser_sync_sync__service__factory.cc b/www/chromium/files/patch-chrome_browser_sync_sync__service__factory.cc index 78a5549e0814..23ddb5a14286 100644 --- a/www/chromium/files/patch-chrome_browser_sync_sync__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_sync_sync__service__factory.cc @@ -1,29 +1,38 @@ ---- chrome/browser/sync/sync_service_factory.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/sync/sync_service_factory.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/sync/sync_service_factory.cc -@@ -84,7 +84,7 @@ - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +@@ -110,7 +110,7 @@ + #endif // BUILDFLAG(IS_CHROMEOS) #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ - BUILDFLAG(IS_WIN) + BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_keyed_service.h" #include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_service_factory.h" - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || - // BUILDFLAG(IS_WIN) -@@ -130,7 +130,7 @@ std::unique_ptr<KeyedService> BuildSyncService( - // TODO(crbug.com/1052397): Reassess whether the following block needs to be - // included in lacros-chrome once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) + #include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_utils.h" +@@ -137,7 +137,7 @@ namespace { + tab_groups::TabGroupSyncService* GetTabGroupSyncService(Profile* profile) { + CHECK(profile); + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + tab_groups::TabGroupSyncService* service = + tab_groups::SavedTabGroupUtils::GetServiceForProfile(profile); + CHECK(service); +@@ -381,7 +381,7 @@ std::unique_ptr<KeyedService> BuildSyncService( + bool local_sync_backend_enabled = false; + // Only check the local sync backend pref on the supported platforms of + // Windows, Mac and Linux. +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) syncer::SyncPrefs prefs(profile->GetPrefs()); local_sync_backend_enabled = prefs.IsLocalSyncEnabled(); -@@ -264,7 +264,7 @@ SyncServiceFactory::SyncServiceFactory() + base::UmaHistogramBoolean("Sync.Local.Enabled2", local_sync_backend_enabled); +@@ -520,7 +520,7 @@ SyncServiceFactory::SyncServiceFactory() DependsOn(ProfilePasswordStoreFactory::GetInstance()); DependsOn(PowerBookmarkServiceFactory::GetInstance()); #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ - BUILDFLAG(IS_WIN) + BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) DependsOn(tab_groups::SavedTabGroupServiceFactory::GetInstance()); - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || - // BUILDFLAG(IS_WIN) + #elif BUILDFLAG(IS_ANDROID) + DependsOn(tab_groups::TabGroupSyncServiceFactory::GetInstance()); diff --git a/www/chromium/files/patch-chrome_browser_sync_sync__service__util.cc b/www/chromium/files/patch-chrome_browser_sync_sync__service__util.cc deleted file mode 100644 index 466910d9f989..000000000000 --- a/www/chromium/files/patch-chrome_browser_sync_sync__service__util.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- chrome/browser/sync/sync_service_util.cc.orig 2023-12-10 06:10:27 UTC -+++ chrome/browser/sync/sync_service_util.cc -@@ -9,7 +9,7 @@ - #include "components/sync/base/features.h" - - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "components/variations/service/variations_service.h" - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || - // BUILDFLAG(IS_WIN) -@@ -22,7 +22,7 @@ bool IsDesktopEnUSLocaleOnlySyncPollFeatureEnabled() { - } - - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - std::string country_code; - auto* variations_service = g_browser_process->variations_service(); - if (variations_service) { diff --git a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.cc b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.cc index ca4acd938989..c2f191e6e3fa 100644 --- a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.cc +++ b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.cc @@ -1,6 +1,6 @@ ---- chrome/browser/task_manager/sampling/task_group.cc.orig 2023-01-11 09:17:16 UTC +--- chrome/browser/task_manager/sampling/task_group.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/task_manager/sampling/task_group.cc -@@ -38,7 +38,7 @@ const int kBackgroundRefreshTypesMask = +@@ -36,7 +36,7 @@ const int kBackgroundRefreshTypesMask = #if BUILDFLAG(IS_WIN) REFRESH_TYPE_START_TIME | REFRESH_TYPE_CPU_TIME | #endif // BUILDFLAG(IS_WIN) @@ -9,7 +9,7 @@ REFRESH_TYPE_FD_COUNT | #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) #if BUILDFLAG(ENABLE_NACL) -@@ -123,7 +123,7 @@ TaskGroup::TaskGroup( +@@ -117,7 +117,7 @@ TaskGroup::TaskGroup( #if BUILDFLAG(ENABLE_NACL) nacl_debug_stub_port_(nacl::kGdbDebugStubPortUnknown), #endif // BUILDFLAG(ENABLE_NACL) @@ -18,7 +18,7 @@ open_fd_count_(-1), #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) idle_wakeups_per_second_(-1), -@@ -142,7 +142,7 @@ TaskGroup::TaskGroup( +@@ -132,7 +132,7 @@ TaskGroup::TaskGroup( weak_ptr_factory_.GetWeakPtr()), base::BindRepeating(&TaskGroup::OnIdleWakeupsRefreshDone, weak_ptr_factory_.GetWeakPtr()), @@ -27,7 +27,7 @@ base::BindRepeating(&TaskGroup::OnOpenFdCountRefreshDone, weak_ptr_factory_.GetWeakPtr()), #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -@@ -322,7 +322,7 @@ void TaskGroup::OnRefreshNaClDebugStubPortDone(int nac +@@ -302,7 +302,7 @@ void TaskGroup::OnRefreshNaClDebugStubPortDone(int nac } #endif // BUILDFLAG(ENABLE_NACL) diff --git a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.h b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.h index 87e0c02326ba..2eea6fa2ee81 100644 --- a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.h +++ b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group.h @@ -1,6 +1,6 @@ ---- chrome/browser/task_manager/sampling/task_group.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/task_manager/sampling/task_group.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/task_manager/sampling/task_group.h -@@ -44,7 +44,7 @@ constexpr int kUnsupportedVMRefreshFlags = +@@ -41,7 +41,7 @@ inline constexpr int kUnsupportedVMRefreshFlags = REFRESH_TYPE_WEBCACHE_STATS | REFRESH_TYPE_NETWORK_USAGE | REFRESH_TYPE_NACL | REFRESH_TYPE_IDLE_WAKEUPS | REFRESH_TYPE_HANDLES | REFRESH_TYPE_START_TIME | REFRESH_TYPE_CPU_TIME | REFRESH_TYPE_PRIORITY | @@ -9,7 +9,7 @@ REFRESH_TYPE_FD_COUNT | #endif REFRESH_TYPE_HARD_FAULTS; -@@ -152,7 +152,7 @@ class TaskGroup { +@@ -144,7 +144,7 @@ class TaskGroup { } #endif // BUILDFLAG(ENABLE_NACL) @@ -18,7 +18,7 @@ int open_fd_count() const { return open_fd_count_; } void set_open_fd_count(int open_fd_count) { open_fd_count_ = open_fd_count; } #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -@@ -172,7 +172,7 @@ class TaskGroup { +@@ -164,7 +164,7 @@ class TaskGroup { void RefreshNaClDebugStubPort(int child_process_unique_id); void OnRefreshNaClDebugStubPortDone(int port); #endif @@ -27,7 +27,7 @@ void OnOpenFdCountRefreshDone(int open_fd_count); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -@@ -244,7 +244,7 @@ class TaskGroup { +@@ -235,7 +235,7 @@ class TaskGroup { #if BUILDFLAG(ENABLE_NACL) int nacl_debug_stub_port_; #endif // BUILDFLAG(ENABLE_NACL) diff --git a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group__sampler.cc b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group__sampler.cc index dd041af1ae02..5f2e5a908260 100644 --- a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group__sampler.cc +++ b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__group__sampler.cc @@ -1,6 +1,6 @@ ---- chrome/browser/task_manager/sampling/task_group_sampler.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/task_manager/sampling/task_group_sampler.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/task_manager/sampling/task_group_sampler.cc -@@ -46,7 +46,7 @@ TaskGroupSampler::TaskGroupSampler( +@@ -45,7 +45,7 @@ TaskGroupSampler::TaskGroupSampler( const OnCpuRefreshCallback& on_cpu_refresh, const OnSwappedMemRefreshCallback& on_swapped_mem_refresh, const OnIdleWakeupsCallback& on_idle_wakeups, @@ -9,7 +9,7 @@ const OnOpenFdCountCallback& on_open_fd_count, #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) const OnProcessPriorityCallback& on_process_priority) -@@ -56,7 +56,7 @@ TaskGroupSampler::TaskGroupSampler( +@@ -55,7 +55,7 @@ TaskGroupSampler::TaskGroupSampler( on_cpu_refresh_callback_(on_cpu_refresh), on_swapped_mem_refresh_callback_(on_swapped_mem_refresh), on_idle_wakeups_callback_(on_idle_wakeups), @@ -18,7 +18,7 @@ on_open_fd_count_callback_(on_open_fd_count), #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) on_process_priority_callback_(on_process_priority) { -@@ -86,7 +86,7 @@ void TaskGroupSampler::Refresh(int64_t refresh_flags) +@@ -85,7 +85,7 @@ void TaskGroupSampler::Refresh(int64_t refresh_flags) base::BindOnce(on_swapped_mem_refresh_callback_)); } @@ -27,7 +27,7 @@ if (TaskManagerObserver::IsResourceRefreshEnabled(REFRESH_TYPE_IDLE_WAKEUPS, refresh_flags)) { blocking_pool_runner_->PostTaskAndReplyWithResult( -@@ -96,7 +96,7 @@ void TaskGroupSampler::Refresh(int64_t refresh_flags) +@@ -95,7 +95,7 @@ void TaskGroupSampler::Refresh(int64_t refresh_flags) } #endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -36,7 +36,7 @@ if (TaskManagerObserver::IsResourceRefreshEnabled(REFRESH_TYPE_FD_COUNT, refresh_flags)) { blocking_pool_runner_->PostTaskAndReplyWithResult( -@@ -150,7 +150,7 @@ int TaskGroupSampler::RefreshIdleWakeupsPerSecond() { +@@ -152,7 +152,7 @@ int TaskGroupSampler::RefreshIdleWakeupsPerSecond() { return process_metrics_->GetIdleWakeupsPerSecond(); } diff --git a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__manager__impl.cc b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__manager__impl.cc index 3316b458e4e7..8fda8549035a 100644 --- a/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__manager__impl.cc +++ b/www/chromium/files/patch-chrome_browser_task__manager_sampling_task__manager__impl.cc @@ -1,6 +1,6 @@ ---- chrome/browser/task_manager/sampling/task_manager_impl.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/task_manager/sampling/task_manager_impl.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/task_manager/sampling/task_manager_impl.cc -@@ -218,7 +218,7 @@ void TaskManagerImpl::GetUSERHandles(TaskId task_id, +@@ -234,7 +234,7 @@ void TaskManagerImpl::GetUSERHandles(TaskId task_id, } int TaskManagerImpl::GetOpenFdCount(TaskId task_id) const { diff --git a/www/chromium/files/patch-chrome_browser_task__manager_task__manager__observer.h b/www/chromium/files/patch-chrome_browser_task__manager_task__manager__observer.h index a2f4e51049f7..c31a1c12a19f 100644 --- a/www/chromium/files/patch-chrome_browser_task__manager_task__manager__observer.h +++ b/www/chromium/files/patch-chrome_browser_task__manager_task__manager__observer.h @@ -1,6 +1,6 @@ ---- chrome/browser/task_manager/task_manager_observer.h.orig 2022-02-28 16:54:41 UTC +--- chrome/browser/task_manager/task_manager_observer.h.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/task_manager/task_manager_observer.h -@@ -47,7 +47,7 @@ enum RefreshType { +@@ -46,7 +46,7 @@ enum RefreshType { // or backgrounded. REFRESH_TYPE_PRIORITY = 1 << 13, diff --git a/www/chromium/files/patch-chrome_browser_themes_theme__helper.cc b/www/chromium/files/patch-chrome_browser_themes_theme__helper.cc index 032985e9aeae..d5b8996586fd 100644 --- a/www/chromium/files/patch-chrome_browser_themes_theme__helper.cc +++ b/www/chromium/files/patch-chrome_browser_themes_theme__helper.cc @@ -1,6 +1,6 @@ ---- chrome/browser/themes/theme_helper.cc.orig 2022-10-24 13:33:33 UTC +--- chrome/browser/themes/theme_helper.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/themes/theme_helper.cc -@@ -18,7 +18,7 @@ +@@ -16,7 +16,7 @@ #include "ui/gfx/image/image.h" #include "ui/native_theme/native_theme.h" diff --git a/www/chromium/files/patch-chrome_browser_themes_theme__service.cc b/www/chromium/files/patch-chrome_browser_themes_theme__service.cc index 2b148dfd9876..4a6a92c74a54 100644 --- a/www/chromium/files/patch-chrome_browser_themes_theme__service.cc +++ b/www/chromium/files/patch-chrome_browser_themes_theme__service.cc @@ -1,15 +1,15 @@ ---- chrome/browser/themes/theme_service.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/themes/theme_service.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/themes/theme_service.cc -@@ -74,7 +74,7 @@ +@@ -72,7 +72,7 @@ #include "extensions/browser/extension_registry_observer.h" #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "ui/linux/linux_ui.h" - #include "ui/ozone/public/ozone_platform.h" + #include "ui/ozone/public/ozone_platform.h" // nogncheck #endif -@@ -330,7 +330,7 @@ CustomThemeSupplier* ThemeService::GetThemeSupplier() +@@ -331,7 +331,7 @@ CustomThemeSupplier* ThemeService::GetThemeSupplier() } bool ThemeService::ShouldUseCustomFrame() const { diff --git a/www/chromium/files/patch-chrome_browser_themes_theme__service__aura__linux.cc b/www/chromium/files/patch-chrome_browser_themes_theme__service__aura__linux.cc index 1e9040e78ce0..f79dc5be42c2 100644 --- a/www/chromium/files/patch-chrome_browser_themes_theme__service__aura__linux.cc +++ b/www/chromium/files/patch-chrome_browser_themes_theme__service__aura__linux.cc @@ -1,6 +1,6 @@ ---- chrome/browser/themes/theme_service_aura_linux.cc.orig 2022-11-30 08:12:58 UTC +--- chrome/browser/themes/theme_service_aura_linux.cc.orig 2024-08-26 12:06:38 UTC +++ chrome/browser/themes/theme_service_aura_linux.cc -@@ -24,7 +24,7 @@ namespace { +@@ -23,7 +23,7 @@ namespace { ui::SystemTheme ValidateSystemTheme(ui::SystemTheme system_theme) { switch (system_theme) { case ui::SystemTheme::kDefault: diff --git a/www/chromium/files/patch-chrome_browser_themes_theme__service__factory.cc b/www/chromium/files/patch-chrome_browser_themes_theme__service__factory.cc index b83646b2728b..321cbbbe3aaf 100644 --- a/www/chromium/files/patch-chrome_browser_themes_theme__service__factory.cc +++ b/www/chromium/files/patch-chrome_browser_themes_theme__service__factory.cc @@ -1,37 +1,29 @@ ---- chrome/browser/themes/theme_service_factory.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/themes/theme_service_factory.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/themes/theme_service_factory.cc -@@ -27,11 +27,11 @@ - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/themes/theme_service_aura_linux.h" +@@ -25,7 +25,7 @@ + #include "chrome/browser/themes/theme_helper_win.h" #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/themes/theme_service_aura_linux.h" #include "ui/linux/linux_ui_factory.h" #endif - -@@ -103,7 +103,7 @@ ThemeServiceFactory::~ThemeServiceFactory() = default; - - KeyedService* ThemeServiceFactory::BuildServiceInstanceFor( +@@ -105,7 +105,7 @@ ThemeServiceFactory::~ThemeServiceFactory() = default; + std::unique_ptr<KeyedService> + ThemeServiceFactory::BuildServiceInstanceForBrowserContext( content::BrowserContext* profile) const { -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) using ThemeService = ThemeServiceAuraLinux; #endif -@@ -117,9 +117,9 @@ void ThemeServiceFactory::RegisterProfilePrefs( +@@ -117,7 +117,7 @@ ThemeServiceFactory::BuildServiceInstanceForBrowserCon + + void ThemeServiceFactory::RegisterProfilePrefs( user_prefs::PrefRegistrySyncable* registry) { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - ui::SystemTheme default_system_theme = ui::SystemTheme::kDefault; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - default_system_theme = ui::GetDefaultSystemTheme(); - #endif registry->RegisterIntegerPref(prefs::kSystemTheme, + static_cast<int>(ui::GetDefaultSystemTheme())); + #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_actions_chrome__action__id.h b/www/chromium/files/patch-chrome_browser_ui_actions_chrome__action__id.h index adbbc76dea07..cfb21d9103ec 100644 --- a/www/chromium/files/patch-chrome_browser_ui_actions_chrome__action__id.h +++ b/www/chromium/files/patch-chrome_browser_ui_actions_chrome__action__id.h @@ -1,9 +1,9 @@ ---- chrome/browser/ui/actions/chrome_action_id.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/actions/chrome_action_id.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/actions/chrome_action_id.h -@@ -510,7 +510,7 @@ - IDC_CONTENT_CONTEXT_QUICK_ANSWERS_INLINE_ANSWER) \ - E(kActionContentContextQuickAnswersInlineQuery, \ - IDC_CONTENT_CONTEXT_QUICK_ANSWERS_INLINE_QUERY) +@@ -503,7 +503,7 @@ + #if BUILDFLAG(IS_CHROMEOS) + #define CHROME_PLATFORM_SPECIFIC_ACTION_IDS \ + E(kToggleMultitaskMenu, IDC_TOGGLE_MULTITASK_MENU) -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #define CHROME_PLATFORM_SPECIFIC_ACTION_IDS \ diff --git a/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.cc b/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.cc index 7a0eecf699ce..9cd89c3a2142 100644 --- a/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.cc +++ b/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.cc @@ -1,20 +1,20 @@ ---- chrome/browser/ui/autofill/payments/desktop_payments_window_manager.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/autofill/payments/desktop_payments_window_manager.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/autofill/payments/desktop_payments_window_manager.cc -@@ -25,7 +25,7 @@ namespace autofill::payments { +@@ -58,7 +58,7 @@ gfx::Rect GetPopupSizeForBnpl() { DesktopPaymentsWindowManager::DesktopPaymentsWindowManager( ContentAutofillClient* client) : client_(CHECK_DEREF(client)) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) scoped_observation_.Observe(BrowserList::GetInstance()); - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) + #endif // BUILDFLAG(IS_LINUX) } -@@ -48,7 +48,7 @@ void DesktopPaymentsWindowManager::WebContentsDestroye +@@ -144,7 +144,7 @@ void DesktopPaymentsWindowManager::WebContentsDestroye } } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void DesktopPaymentsWindowManager::OnBrowserSetLastActive(Browser* browser) { // If there is an ongoing payments window manager pop-up flow, and the // original tab's WebContents become active, activate the pop-up's diff --git a/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.h b/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.h index 2561cb2fb1de..d01abd876afc 100644 --- a/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.h +++ b/www/chromium/files/patch-chrome_browser_ui_autofill_payments_desktop__payments__window__manager.h @@ -1,38 +1,38 @@ ---- chrome/browser/ui/autofill/payments/desktop_payments_window_manager.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/autofill/payments/desktop_payments_window_manager.h.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/autofill/payments/desktop_payments_window_manager.h -@@ -11,7 +11,7 @@ +@@ -14,7 +14,7 @@ #include "components/autofill/core/browser/payments/payments_window_manager.h" #include "content/public/browser/web_contents_observer.h" --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "base/scoped_observation.h" #include "chrome/browser/ui/browser_list.h" #include "chrome/browser/ui/browser_list_observer.h" -@@ -30,7 +30,7 @@ namespace payments { +@@ -39,7 +39,7 @@ class PaymentsWindowUserConsentDialogControllerImpl; // WebContents of the original tab that the pop-up is created in. If there is a // pop-up currently present, `this` will observe the WebContents of that pop-up. class DesktopPaymentsWindowManager : public PaymentsWindowManager, --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) public BrowserListObserver, - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) + #endif // BUILDFLAG(IS_LINUX) public content::WebContentsObserver { -@@ -47,7 +47,7 @@ class DesktopPaymentsWindowManager : public PaymentsWi - // content::WebContentsObserver: +@@ -59,7 +59,7 @@ class DesktopPaymentsWindowManager : public PaymentsWi + content::NavigationHandle* navigation_handle) override; void WebContentsDestroyed() override; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // BrowserListObserver: void OnBrowserSetLastActive(Browser* browser) override; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -@@ -99,7 +99,7 @@ class DesktopPaymentsWindowManager : public PaymentsWi - // ContentAutofillClient that owns `this`. - const raw_ref<ContentAutofillClient> client_; + #endif // BUILDFLAG(IS_LINUX) +@@ -165,7 +165,7 @@ class DesktopPaymentsWindowManager : public PaymentsWi + // Used in tests to notify the test infrastructure that the pop-up has closed. + base::RepeatingClosure popup_closed_closure_for_testing_; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) base::ScopedObservation<BrowserList, BrowserListObserver> scoped_observation_{ this}; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_ui_browser.h b/www/chromium/files/patch-chrome_browser_ui_browser.h index e698696bd0df..61fb590b9476 100644 --- a/www/chromium/files/patch-chrome_browser_ui_browser.h +++ b/www/chromium/files/patch-chrome_browser_ui_browser.h @@ -1,6 +1,6 @@ ---- chrome/browser/ui/browser.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/browser.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/browser.h -@@ -309,7 +309,7 @@ class Browser : public TabStripModelObserver, +@@ -300,7 +300,7 @@ class Browser : public TabStripModelObserver, std::optional<int64_t> display_id; #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_browser__command__controller.cc b/www/chromium/files/patch-chrome_browser_ui_browser__command__controller.cc index dd887960eb63..bd6c6a084f9e 100644 --- a/www/chromium/files/patch-chrome_browser_ui_browser__command__controller.cc +++ b/www/chromium/files/patch-chrome_browser_ui_browser__command__controller.cc @@ -1,15 +1,24 @@ ---- chrome/browser/ui/browser_command_controller.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/browser_command_controller.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/browser_command_controller.cc -@@ -121,7 +121,7 @@ +@@ -127,7 +127,7 @@ #include "components/user_manager/user_manager.h" #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "ui/base/ime/text_edit_commands.h" #include "ui/base/ime/text_input_flags.h" #include "ui/linux/linux_ui.h" +@@ -137,7 +137,7 @@ + #include "ui/ozone/public/ozone_platform.h" #endif -@@ -303,7 +303,7 @@ bool BrowserCommandController::IsReservedCommandOrKey( + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/shortcuts/desktop_shortcuts_utils.h" + #endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) + +@@ -363,7 +363,7 @@ bool BrowserCommandController::IsReservedCommandOrKey( #endif } @@ -18,36 +27,48 @@ // If this key was registered by the user as a content editing hotkey, then // it is not reserved. auto* linux_ui = ui::LinuxUi::instance(); -@@ -555,7 +555,7 @@ bool BrowserCommandController::ExecuteCommandWithDispo +@@ -632,7 +632,7 @@ bool BrowserCommandController::ExecuteCommandWithDispo + break; + #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) case IDC_MINIMIZE_WINDOW: browser_->window()->Minimize(); break; -@@ -567,7 +567,7 @@ bool BrowserCommandController::ExecuteCommandWithDispo +@@ -849,7 +849,7 @@ bool BrowserCommandController::ExecuteCommandWithDispo + break; + case IDC_CREATE_SHORTCUT: + base::RecordAction(base::UserMetricsAction("CreateShortcut")); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + chrome::CreateDesktopShortcutForActiveWebContents(browser_); + #else + web_app::CreateWebAppFromCurrentWebContents( +@@ -1015,7 +1015,7 @@ bool BrowserCommandController::ExecuteCommandWithDispo + #endif // BUILDFLAG(GOOGLE_CHROME_BRANDING) + case IDC_CHROME_WHATS_NEW: + #if BUILDFLAG(GOOGLE_CHROME_BRANDING) && \ +- (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX)) ++ (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) + ShowChromeWhatsNew(browser_); break; + #else +@@ -1392,7 +1392,7 @@ void BrowserCommandController::InitCommandState() { + command_updater_.UpdateCommandEnabled(IDC_VISIT_DESKTOP_OF_LRU_USER_4, true); + command_updater_.UpdateCommandEnabled(IDC_VISIT_DESKTOP_OF_LRU_USER_5, true); #endif - -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - case IDC_USE_SYSTEM_TITLE_BAR: { - PrefService* prefs = profile()->GetPrefs(); - prefs->SetBoolean(prefs::kUseCustomChromeFrame, -@@ -1231,12 +1231,12 @@ void BrowserCommandController::InitCommandState() { - #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) command_updater_.UpdateCommandEnabled(IDC_MINIMIZE_WINDOW, true); command_updater_.UpdateCommandEnabled(IDC_MAXIMIZE_WINDOW, true); command_updater_.UpdateCommandEnabled(IDC_RESTORE_WINDOW, true); - #endif --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - bool use_system_title_bar = true; - #if BUILDFLAG(IS_OZONE) - use_system_title_bar = ui::OzonePlatform::GetInstance() +@@ -1747,7 +1747,7 @@ void BrowserCommandController::UpdateCommandsForTabSta + bool can_create_web_app = web_app::CanCreateWebApp(browser_); + command_updater_.UpdateCommandEnabled(IDC_INSTALL_PWA, can_create_web_app); + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + command_updater_.UpdateCommandEnabled( + IDC_CREATE_SHORTCUT, + shortcuts::CanCreateDesktopShortcut(current_web_contents)); diff --git a/www/chromium/files/patch-chrome_browser_ui_browser__commands.cc b/www/chromium/files/patch-chrome_browser_ui_browser__commands.cc new file mode 100644 index 000000000000..c9a34d01198b --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_browser__commands.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/browser_commands.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/browser_commands.cc +@@ -2185,7 +2185,7 @@ void OpenUpdateChromeDialog(Browser* browser) { + } else if (UpgradeDetector::GetInstance()->is_outdated_install_no_au()) { + UpgradeDetector::GetInstance()->NotifyOutdatedInstallNoAutoUpdate(); + } else { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled(features::kFewerUpdateConfirmations)) { + chrome::AttemptRelaunch(); + return; diff --git a/www/chromium/files/patch-chrome_browser_ui_browser__ui__prefs.cc b/www/chromium/files/patch-chrome_browser_ui_browser__ui__prefs.cc index 3586e16b8daf..9c3d5df4696e 100644 --- a/www/chromium/files/patch-chrome_browser_ui_browser__ui__prefs.cc +++ b/www/chromium/files/patch-chrome_browser_ui_browser__ui__prefs.cc @@ -1,11 +1,20 @@ ---- chrome/browser/ui/browser_ui_prefs.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/browser_ui_prefs.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/browser_ui_prefs.cc -@@ -168,7 +168,7 @@ void RegisterBrowserUserPrefs(user_prefs::PrefRegistry +@@ -80,7 +80,7 @@ void RegisterBrowserPrefs(PrefRegistrySimple* registry + registry->RegisterTimePref(prefs::kPdfInfoBarLastShown, base::Time()); + registry->RegisterIntegerPref(prefs::kPdfInfoBarTimesShown, 0); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + registry->RegisterStringPref(prefs::kEnterpriseCustomLabelForBrowser, + std::string()); + registry->RegisterStringPref(prefs::kEnterpriseLogoUrlForBrowser, +@@ -203,7 +203,7 @@ void RegisterBrowserUserPrefs(user_prefs::PrefRegistry registry->RegisterDictionaryPref(prefs::kHttpsUpgradeFallbacks); registry->RegisterDictionaryPref(prefs::kHttpsUpgradeNavigations); registry->RegisterBooleanPref(prefs::kHttpsOnlyModeAutoEnabled, false); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - registry->RegisterStringPref(prefs::kEnterpriseLogoUrl, std::string()); - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) - } + registry->RegisterStringPref(prefs::kEnterpriseLogoUrlForProfile, + std::string()); + registry->RegisterStringPref(prefs::kEnterpriseCustomLabelForProfile, diff --git a/www/chromium/files/patch-chrome_browser_ui_browser__view__prefs.cc b/www/chromium/files/patch-chrome_browser_ui_browser__view__prefs.cc index b86b58a46dcd..ccf3a53e5f9d 100644 --- a/www/chromium/files/patch-chrome_browser_ui_browser__view__prefs.cc +++ b/www/chromium/files/patch-chrome_browser_ui_browser__view__prefs.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/browser_view_prefs.cc.orig 2023-07-16 15:47:57 UTC +--- chrome/browser/ui/browser_view_prefs.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/ui/browser_view_prefs.cc -@@ -15,7 +15,7 @@ +@@ -14,7 +14,7 @@ namespace { @@ -9,7 +9,7 @@ bool GetCustomFramePrefDefault() { #if BUILDFLAG(IS_OZONE) return ui::OzonePlatform::GetInstance() -@@ -31,7 +31,7 @@ bool GetCustomFramePrefDefault() { +@@ -30,7 +30,7 @@ bool GetCustomFramePrefDefault() { void RegisterBrowserViewProfilePrefs( user_prefs::PrefRegistrySyncable* registry) { diff --git a/www/chromium/files/patch-chrome_browser_ui_chrome__pages.cc b/www/chromium/files/patch-chrome_browser_ui_chrome__pages.cc index 087e88eacb45..0bc1586eae70 100644 --- a/www/chromium/files/patch-chrome_browser_ui_chrome__pages.cc +++ b/www/chromium/files/patch-chrome_browser_ui_chrome__pages.cc @@ -1,20 +1,29 @@ ---- chrome/browser/ui/chrome_pages.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/chrome_pages.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/chrome_pages.cc -@@ -82,7 +82,7 @@ +@@ -85,7 +85,7 @@ + #include "components/signin/public/identity_manager/identity_manager.h" #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "chrome/browser/web_applications/web_app_utils.h" #endif -@@ -716,7 +716,7 @@ void ShowShortcutCustomizationApp(Profile* profile, +@@ -382,7 +382,7 @@ void ShowChromeTips(Browser* browser) { + ShowSingletonTab(browser, GURL(kChromeTipsURL)); } - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void ShowChromeWhatsNew(Browser* browser) { + ShowSingletonTab(browser, GURL(kChromeUIWhatsNewURL)); + } +@@ -706,7 +706,7 @@ void ShowShortcutCustomizationApp(Profile* profile, + } + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void ShowWebAppSettingsImpl(Browser* browser, Profile* profile, const std::string& app_id, diff --git a/www/chromium/files/patch-chrome_browser_ui_chrome__pages.h b/www/chromium/files/patch-chrome_browser_ui_chrome__pages.h index b0a0b1cc29f9..7beb9033b7a3 100644 --- a/www/chromium/files/patch-chrome_browser_ui_chrome__pages.h +++ b/www/chromium/files/patch-chrome_browser_ui_chrome__pages.h @@ -1,20 +1,20 @@ ---- chrome/browser/ui/chrome_pages.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/chrome_pages.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/chrome_pages.h -@@ -38,7 +38,7 @@ enum class ConsentLevel; +@@ -39,7 +39,7 @@ namespace signin { + enum class ConsentLevel; } // namespace signin - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) namespace web_app { enum class AppSettingsPageEntryPoint; } // namespace web_app -@@ -262,7 +262,7 @@ void ShowShortcutCustomizationApp(Profile* profile, +@@ -177,7 +177,7 @@ void ShowShortcutCustomizationApp(Profile* profile, + const std::string& category); #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Show chrome://app-settings/<app-id> page. void ShowWebAppSettings(Browser* browser, const std::string& app_id, diff --git a/www/chromium/files/patch-chrome_browser_ui_exclusive__access_exclusive__access__bubble.cc b/www/chromium/files/patch-chrome_browser_ui_exclusive__access_exclusive__access__bubble.cc deleted file mode 100644 index d7e06cd7da05..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_exclusive__access_exclusive__access__bubble.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/ui/exclusive_access/exclusive_access_bubble.cc.orig 2023-11-03 10:09:45 UTC -+++ chrome/browser/ui/exclusive_access/exclusive_access_bubble.cc -@@ -19,7 +19,7 @@ - - // NOTE(koz): Linux doesn't use the thick shadowed border, so we add padding - // here. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const int ExclusiveAccessBubble::kPaddingPx = 8; - #else - const int ExclusiveAccessBubble::kPaddingPx = 15; diff --git a/www/chromium/files/patch-chrome_browser_ui_managed__ui.cc b/www/chromium/files/patch-chrome_browser_ui_managed__ui.cc new file mode 100644 index 000000000000..453b21e66d0e --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_managed__ui.cc @@ -0,0 +1,20 @@ +--- chrome/browser/ui/managed_ui.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/ui/managed_ui.cc +@@ -433,7 +433,7 @@ std::optional<std::string> GetDeviceManagerIdentity() + g_browser_process->platform_part()->browser_policy_connector_ash(); + return connector->GetEnterpriseDomainManager(); + #else +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled( + features::kEnterpriseManagementDisclaimerUsesCustomLabel)) { + std::string custom_management_label = +@@ -463,7 +463,7 @@ std::optional<std::string> GetAccountManagerIdentity(P + return std::nullopt; + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled( + features::kEnterpriseManagementDisclaimerUsesCustomLabel)) { + std::string custom_management_label = diff --git a/www/chromium/files/patch-chrome_browser_ui_omnibox_omnibox__pedal__implementations.cc b/www/chromium/files/patch-chrome_browser_ui_omnibox_omnibox__pedal__implementations.cc index 4c2ab86e90f7..093dfeaa8af2 100644 --- a/www/chromium/files/patch-chrome_browser_ui_omnibox_omnibox__pedal__implementations.cc +++ b/www/chromium/files/patch-chrome_browser_ui_omnibox_omnibox__pedal__implementations.cc @@ -1,11 +1,11 @@ ---- chrome/browser/ui/omnibox/omnibox_pedal_implementations.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/omnibox/omnibox_pedal_implementations.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/ui/omnibox/omnibox_pedal_implementations.cc -@@ -1989,7 +1989,7 @@ const gfx::VectorIcon& GetSharingHubVectorIcon() { - OmniboxFieldTrial::IsChromeRefreshActionChipIconsEnabled() - ? omnibox::kShareWinChromeRefreshIcon - : omnibox::kShareWinIcon; +@@ -1985,7 +1985,7 @@ const gfx::VectorIcon& GetSharingHubVectorIcon() { + return omnibox::kShareMacChromeRefreshIcon; + #elif BUILDFLAG(IS_WIN) + return omnibox::kShareWinChromeRefreshIcon; -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return OmniboxFieldTrial::IsChromeRefreshIconsEnabled() || - OmniboxFieldTrial::IsChromeRefreshActionChipIconsEnabled() - ? omnibox::kShareLinuxChromeRefreshIcon + return omnibox::kShareLinuxChromeRefreshIcon; + #else + return omnibox::kShareChromeRefreshIcon; diff --git a/www/chromium/files/patch-chrome_browser_ui_passwords_manage__passwords__ui__controller.cc b/www/chromium/files/patch-chrome_browser_ui_passwords_manage__passwords__ui__controller.cc index e3cbf96a4300..87425c047593 100644 --- a/www/chromium/files/patch-chrome_browser_ui_passwords_manage__passwords__ui__controller.cc +++ b/www/chromium/files/patch-chrome_browser_ui_passwords_manage__passwords__ui__controller.cc @@ -1,15 +1,15 @@ ---- chrome/browser/ui/passwords/manage_passwords_ui_controller.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/passwords/manage_passwords_ui_controller.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/passwords/manage_passwords_ui_controller.cc -@@ -88,7 +88,7 @@ int ManagePasswordsUIController::save_fallback_timeout +@@ -104,7 +104,7 @@ namespace { - namespace { + using Logger = autofill::SavePasswordProgressLogger; -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Should be kept in sync with constant declared in // bubble_controllers/relaunch_chrome_bubble_controller.cc. constexpr int kMaxNumberOfTimesKeychainErrorBubbleIsShown = 3; -@@ -477,7 +477,7 @@ void ManagePasswordsUIController::OnBiometricAuthBefor +@@ -562,7 +562,7 @@ void ManagePasswordsUIController::OnBiometricAuthBefor } void ManagePasswordsUIController::OnKeychainError() { diff --git a/www/chromium/files/patch-chrome_browser_ui_prefs_prefs__tab__helper.cc b/www/chromium/files/patch-chrome_browser_ui_prefs_prefs__tab__helper.cc new file mode 100644 index 000000000000..4eb8e8132d6c --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_prefs_prefs__tab__helper.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/prefs/prefs_tab_helper.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/ui/prefs/prefs_tab_helper.cc +@@ -66,7 +66,7 @@ + #include <windows.h> + #endif + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // If a font name in prefs default values starts with a comma, consider it's a + // comma-separated font list and resolve it to the first available font. + #define PREFS_FONT_LIST 1 diff --git a/www/chromium/files/patch-chrome_browser_ui_sad__tab.cc b/www/chromium/files/patch-chrome_browser_ui_sad__tab.cc index 370f2a128492..cfd4e31ac092 100644 --- a/www/chromium/files/patch-chrome_browser_ui_sad__tab.cc +++ b/www/chromium/files/patch-chrome_browser_ui_sad__tab.cc @@ -1,9 +1,9 @@ ---- chrome/browser/ui/sad_tab.cc.orig 2023-01-11 09:17:16 UTC +--- chrome/browser/ui/sad_tab.cc.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/ui/sad_tab.cc -@@ -176,7 +176,7 @@ std::vector<int> SadTab::GetSubMessages() { - // Only show Incognito suggestion if not already in Incognito mode. - if (!web_contents_->GetBrowserContext()->IsOffTheRecord()) +@@ -179,7 +179,7 @@ std::vector<int> SadTab::GetSubMessages() { + if (!web_contents_->GetBrowserContext()->IsOffTheRecord()) { message_ids.insert(message_ids.begin(), IDS_SAD_TAB_RELOAD_INCOGNITO); + } -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Note: on macOS, Linux and ChromeOS, the first bullet is either one of diff --git a/www/chromium/files/patch-chrome_browser_ui_sharing__hub_sharing__hub__bubble__controller.h b/www/chromium/files/patch-chrome_browser_ui_sharing__hub_sharing__hub__bubble__controller.h index fd03ba152ecd..4c4eb52ca760 100644 --- a/www/chromium/files/patch-chrome_browser_ui_sharing__hub_sharing__hub__bubble__controller.h +++ b/www/chromium/files/patch-chrome_browser_ui_sharing__hub_sharing__hub__bubble__controller.h @@ -1,11 +1,11 @@ ---- chrome/browser/ui/sharing_hub/sharing_hub_bubble_controller.h.orig 2023-04-05 11:05:06 UTC +--- chrome/browser/ui/sharing_hub/sharing_hub_bubble_controller.h.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/ui/sharing_hub/sharing_hub_bubble_controller.h -@@ -37,7 +37,7 @@ class SharingHubBubbleController { +@@ -36,7 +36,7 @@ class SharingHubBubbleController { + // Returns true if the omnibox icon should be shown. virtual bool ShouldOfferOmniboxIcon() = 0; - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // This method returns the set of first-party actions, which are actions // internal to Chrome. Third-party actions (those outside Chrome) are // currently not supported. diff --git a/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.cc b/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.cc index 61734cc5ff21..a12645c7dbe2 100644 --- a/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.cc +++ b/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.cc @@ -1,11 +1,20 @@ ---- chrome/browser/ui/signin/signin_view_controller.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/signin/signin_view_controller.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/signin/signin_view_controller.cc -@@ -255,7 +255,7 @@ void SigninViewController::ShowModalManagedUserNoticeD - bool show_link_data_option, - signin::SigninChoiceCallback callback) { - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +@@ -444,7 +444,7 @@ void SigninViewController::ShowModalSyncConfirmationDi + GetOnModalDialogClosedCallback()); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void SigninViewController::ShowModalHistorySyncOptInDialog() { + CHECK(base::FeatureList::IsEnabled(switches::kEnableHistorySyncOptin)); + CloseModalSignin(); +@@ -457,7 +457,7 @@ void SigninViewController::ShowModalHistorySyncOptInDi + void SigninViewController::ShowModalManagedUserNoticeDialog( + std::unique_ptr<signin::EnterpriseProfileCreationDialogParams> + create_param) { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) CloseModalSignin(); dialog_ = std::make_unique<SigninModalDialogImpl>( SigninViewControllerDelegate::CreateManagedUserNoticeDelegate( diff --git a/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.h b/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.h new file mode 100644 index 000000000000..439c5891f96d --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller.h @@ -0,0 +1,11 @@ +--- chrome/browser/ui/signin/signin_view_controller.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/signin/signin_view_controller.h +@@ -150,7 +150,7 @@ class SigninViewController { + void ShowModalSyncConfirmationDialog(bool is_signin_intercept, + bool is_sync_promo); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Shows the modal history sync opt in dialog as a browser-modal dialog on top + // of the `browser_`'s window. + void ShowModalHistorySyncOptInDialog(); diff --git a/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller__delegate.h b/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller__delegate.h index df5cd37418fe..222e0242949b 100644 --- a/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller__delegate.h +++ b/www/chromium/files/patch-chrome_browser_ui_signin_signin__view__controller__delegate.h @@ -1,11 +1,20 @@ ---- chrome/browser/ui/signin/signin_view_controller_delegate.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/signin/signin_view_controller_delegate.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/signin/signin_view_controller_delegate.h -@@ -81,7 +81,7 @@ class SigninViewControllerDelegate { - #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) || BUILDFLAG(IS_CHROMEOS_LACROS) +@@ -48,7 +48,7 @@ class SigninViewControllerDelegate { + SyncConfirmationStyle style, + bool is_sync_promo); - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Returns a platform-specific SigninViewControllerDelegate instance that + // displays the modal history sync opt in dialog. The returned object should + // delete itself when the window it's managing is closed. +@@ -87,7 +87,7 @@ class SigninViewControllerDelegate { + SignoutConfirmationCallback callback); + #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Returns a platform-specific SigninViewContolllerDelegate instance that // displays the managed user notice modal dialog. The returned object // should delete itself when the window it's managing is closed. diff --git a/www/chromium/files/patch-chrome_browser_ui_startup_bad__flags__prompt.cc b/www/chromium/files/patch-chrome_browser_ui_startup_bad__flags__prompt.cc index fb5f9199f7ca..8c49c2a1b83d 100644 --- a/www/chromium/files/patch-chrome_browser_ui_startup_bad__flags__prompt.cc +++ b/www/chromium/files/patch-chrome_browser_ui_startup_bad__flags__prompt.cc @@ -1,11 +1,11 @@ ---- chrome/browser/ui/startup/bad_flags_prompt.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/startup/bad_flags_prompt.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/ui/startup/bad_flags_prompt.cc -@@ -105,7 +105,7 @@ const char* const kBadFlags[] = { +@@ -95,7 +95,7 @@ const char* const kBadFlags[] = { + extensions::switches::kExtensionsOnChromeURLs, + #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Speech dispatcher is buggy, it can crash and it can make Chrome freeze. // http://crbug.com/327295 switches::kEnableSpeechDispatcher, diff --git a/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator.cc b/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator.cc index 2895f4aec714..b7e43507def3 100644 --- a/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator.cc +++ b/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/startup/startup_browser_creator.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/startup/startup_browser_creator.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/startup/startup_browser_creator.cc -@@ -135,7 +135,7 @@ +@@ -134,7 +134,7 @@ #include "chrome/credential_provider/common/gcp_strings.h" #endif // BUILDFLAG(IS_WIN) @@ -9,7 +9,7 @@ #include "chrome/browser/headless/headless_mode_util.h" #include "chrome/browser/ui/startup/web_app_info_recorder_utils.h" #include "components/headless/policy/headless_mode_policy.h" -@@ -962,7 +962,7 @@ bool StartupBrowserCreator::ProcessCmdLineImpl( +@@ -984,7 +984,7 @@ bool StartupBrowserCreator::ProcessCmdLineImpl( TRACE_EVENT0("startup", "StartupBrowserCreator::ProcessCmdLineImpl"); ComputeAndRecordLaunchMode(command_line); @@ -18,7 +18,7 @@ if (headless::IsHeadlessMode() && headless::HeadlessModePolicy::IsHeadlessModeDisabled( g_browser_process->local_state())) { -@@ -1060,7 +1060,7 @@ bool StartupBrowserCreator::ProcessCmdLineImpl( +@@ -1087,7 +1087,7 @@ bool StartupBrowserCreator::ProcessCmdLineImpl( silent_launch = true; } @@ -27,7 +27,7 @@ // Writes open and installed web apps to the specified file without // launching a new browser window or tab. if (base::FeatureList::IsEnabled(features::kListWebAppsSwitch) && -@@ -1270,7 +1270,7 @@ bool StartupBrowserCreator::ProcessCmdLineImpl( +@@ -1304,7 +1304,7 @@ bool StartupBrowserCreator::ProcessCmdLineImpl( CHECK_EQ(profile_info.mode, StartupProfileMode::kBrowserWindow) << "Failed launch with app: couldn't pick a profile"; std::string app_id = command_line.GetSwitchValueASCII(switches::kAppId); @@ -35,4 +35,4 @@ +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // If Chrome Apps are deprecated and |app_id| is a Chrome App, display the // deprecation UI instead of launching the app. - if (apps::OpenDeprecatedApplicationPrompt(privacy_safe_profile, app_id)) + if (apps::OpenDeprecatedApplicationPrompt(privacy_safe_profile, app_id)) { diff --git a/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator__impl.cc b/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator__impl.cc index 0c446528c9c0..1a918056de7c 100644 --- a/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator__impl.cc +++ b/www/chromium/files/patch-chrome_browser_ui_startup_startup__browser__creator__impl.cc @@ -1,6 +1,15 @@ ---- chrome/browser/ui/startup/startup_browser_creator_impl.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/startup/startup_browser_creator_impl.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/ui/startup/startup_browser_creator_impl.cc -@@ -261,7 +261,7 @@ Browser* StartupBrowserCreatorImpl::OpenTabsInBrowser( +@@ -76,7 +76,7 @@ + #include "components/app_restore/full_restore_utils.h" + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/whats_new/whats_new_fetcher.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +@@ -208,7 +208,7 @@ Browser* StartupBrowserCreatorImpl::OpenTabsInBrowser( // at the state of the MessageLoop. Browser::CreateParams params = Browser::CreateParams(profile_, false); params.creation_source = Browser::CreationSource::kStartupCreator; @@ -9,3 +18,12 @@ params.startup_id = command_line_->GetSwitchValueASCII("desktop-startup-id"); #endif +@@ -238,7 +238,7 @@ Browser* StartupBrowserCreatorImpl::OpenTabsInBrowser( + continue; + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Start the What's New fetch but don't add the tab at this point. The tab + // will open as the foreground tab only if the remote content can be + // retrieved successfully. This prevents needing to automatically close the diff --git a/www/chromium/files/patch-chrome_browser_ui_startup_startup__tab__provider.cc b/www/chromium/files/patch-chrome_browser_ui_startup_startup__tab__provider.cc index cdc34974bd8e..3d24423ea634 100644 --- a/www/chromium/files/patch-chrome_browser_ui_startup_startup__tab__provider.cc +++ b/www/chromium/files/patch-chrome_browser_ui_startup_startup__tab__provider.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/startup/startup_tab_provider.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/startup/startup_tab_provider.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/startup/startup_tab_provider.cc -@@ -61,7 +61,7 @@ +@@ -63,7 +63,7 @@ #include "extensions/browser/extension_registry.h" #endif // !BUILDFLAG(IS_ANDROID) @@ -9,12 +9,12 @@ #include "chrome/browser/headless/headless_mode_util.h" #endif -@@ -105,7 +105,7 @@ bool ValidateUrl(const GURL& url) { - #if BUILDFLAG(IS_CHROMEOS_LACROS) - // In ChromeOS, allow any URL pattern that matches chrome:// scheme. - url_scheme_is_chrome = url.SchemeIs(content::kChromeUIScheme); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +@@ -102,7 +102,7 @@ bool ValidateUrl(const GURL& url) { + #endif // BUILDFLAG(IS_CHROMEOS) + + bool url_scheme_is_chrome = false; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) // In Headless mode, allow any URL pattern that matches chrome:// scheme if // the user explicitly allowed it. if (headless::IsHeadlessMode() && url.SchemeIs(content::kChromeUIScheme)) { diff --git a/www/chromium/files/patch-chrome_browser_ui_tab__helpers.cc b/www/chromium/files/patch-chrome_browser_ui_tab__helpers.cc index 7003f7c1edb3..696199c53244 100644 --- a/www/chromium/files/patch-chrome_browser_ui_tab__helpers.cc +++ b/www/chromium/files/patch-chrome_browser_ui_tab__helpers.cc @@ -1,20 +1,20 @@ ---- chrome/browser/ui/tab_helpers.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/tab_helpers.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/tab_helpers.cc -@@ -233,7 +233,7 @@ +@@ -218,7 +218,7 @@ #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "chrome/browser/ui/blocked_content/framebust_block_tab_helper.h" #include "chrome/browser/ui/browser_finder.h" #include "chrome/browser/ui/hats/hats_helper.h" -@@ -673,12 +673,12 @@ void TabHelpers::AttachTabHelpers(WebContents* web_con - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +@@ -706,12 +706,12 @@ void TabHelpers::AttachTabHelpers(WebContents* web_con + webapps::PreRedirectionURLObserver::CreateForWebContents(web_contents); + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) metrics::DesktopSessionDurationObserver::CreateForWebContents(web_contents); #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_tabs_features.cc b/www/chromium/files/patch-chrome_browser_ui_tabs_features.cc new file mode 100644 index 000000000000..c791b36bb2e5 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_tabs_features.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/tabs/features.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/tabs/features.cc +@@ -53,7 +53,7 @@ bool CanShowTabSearchPositionSetting() { + } + // Mac and other platforms will always have the tab search position in the + // correct location, cros/linux/win git the user the option to change. +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + return base::FeatureList::IsEnabled(kTabSearchPositionSetting); + #else + return false; diff --git a/www/chromium/files/patch-chrome_browser_ui_tabs_tab__dialog__manager.cc b/www/chromium/files/patch-chrome_browser_ui_tabs_tab__dialog__manager.cc new file mode 100644 index 000000000000..92996c165205 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_tabs_tab__dialog__manager.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/tabs/tab_dialog_manager.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/ui/tabs/tab_dialog_manager.cc +@@ -83,7 +83,7 @@ bool SupportsGlobalScreenCoordinates() { + } + + bool PlatformClipsChildrenToViewport() { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return true; + #else + return false; diff --git a/www/chromium/files/patch-chrome_browser_ui_tabs_tab__features.cc b/www/chromium/files/patch-chrome_browser_ui_tabs_tab__features.cc new file mode 100644 index 000000000000..459d29b1838a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_tabs_tab__features.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/tabs/tab_features.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/tabs/tab_features.cc +@@ -340,7 +340,7 @@ void TabFeatures::Init(TabInterface& tab, Profile* pro + task_manager::WebContentsTags::CreateForTabContents(tab.GetContents()); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + inactive_window_mouse_event_controller_ = + std::make_unique<InactiveWindowMouseEventController>(); + #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_tabs_tab__strip__prefs.cc b/www/chromium/files/patch-chrome_browser_ui_tabs_tab__strip__prefs.cc new file mode 100644 index 000000000000..330721cdd694 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_tabs_tab__strip__prefs.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/tabs/tab_strip_prefs.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/ui/tabs/tab_strip_prefs.cc +@@ -21,7 +21,7 @@ namespace tabs { + + bool GetDefaultTabSearchRightAligned() { + // These platforms are all left aligned, the others should be right. +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + return false; + #else + return true; diff --git a/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__columns.cc b/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__columns.cc deleted file mode 100644 index 410884208108..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__columns.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/ui/task_manager/task_manager_columns.cc.orig 2022-04-21 18:48:31 UTC -+++ chrome/browser/ui/task_manager/task_manager_columns.cc -@@ -93,7 +93,7 @@ const TableColumnData kColumns[] = { - std::size("100000") * kCharWidth, -1, true, false, false}, - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - {IDS_TASK_MANAGER_OPEN_FD_COUNT_COLUMN, ui::TableColumn::RIGHT, -1, 0, - std::size("999") * kCharWidth, -1, true, false, false}, - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__columns.h b/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__columns.h new file mode 100644 index 000000000000..6bca2d88332b --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__columns.h @@ -0,0 +1,11 @@ +--- chrome/browser/ui/task_manager/task_manager_columns.h.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/ui/task_manager/task_manager_columns.h +@@ -277,7 +277,7 @@ inline constexpr std::array kColumns = { + .default_visibility = false}, + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + TableColumnData{.id = IDS_TASK_MANAGER_OPEN_FD_COUNT_COLUMN, + .align = ui::TableColumn::RIGHT, + .width = -1, diff --git a/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__table__model.cc b/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__table__model.cc index 5e5fa24fb11f..4f24e7558f74 100644 --- a/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__table__model.cc +++ b/www/chromium/files/patch-chrome_browser_ui_task__manager_task__manager__table__model.cc @@ -1,15 +1,24 @@ ---- chrome/browser/ui/task_manager/task_manager_table_model.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/ui/task_manager/task_manager_table_model.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/task_manager/task_manager_table_model.cc -@@ -454,7 +454,7 @@ std::u16string TaskManagerTableModel::GetText(size_t r - ? stringifier_->backgrounded_string() - : stringifier_->foregrounded_string(); +@@ -419,7 +419,7 @@ TaskManagerTableModel::~TaskManagerTableModel() { + // Note: system_total_time_ is used for both since there is no functional + // difference between browser & system (they are essentially the same tab). + // Instead, the data is routed to the platform appropriate bucket. +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + task_manager::RecordTabSwitchEvent(CategoryRecord::kBrowser, + system_total_time_); + #elif BUILDFLAG(IS_CHROMEOS) +@@ -560,7 +560,7 @@ std::u16string TaskManagerTableModel::GetText(size_t r + ? stringifier_->backgrounded_string() + : stringifier_->foregrounded_string(); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) case IDS_TASK_MANAGER_OPEN_FD_COUNT_COLUMN: { const int fd_count = observed_task_manager()->GetOpenFdCount(tasks_[row]); return fd_count >= 0 ? base::FormatNumber(fd_count) -@@ -621,7 +621,7 @@ int TaskManagerTableModel::CompareValues(size_t row1, +@@ -723,7 +723,7 @@ int TaskManagerTableModel::CompareValues(size_t row1, return BooleanCompare(is_proc1_bg, is_proc2_bg); } @@ -18,7 +27,7 @@ case IDS_TASK_MANAGER_OPEN_FD_COUNT_COLUMN: { const int proc1_fd_count = observed_task_manager()->GetOpenFdCount(tasks_[row1]); -@@ -799,7 +799,7 @@ void TaskManagerTableModel::UpdateRefreshTypes(int col +@@ -1040,7 +1040,7 @@ void TaskManagerTableModel::UpdateRefreshTypes(int col type = REFRESH_TYPE_KEEPALIVE_COUNT; break; diff --git a/www/chromium/files/patch-chrome_browser_ui_test_popup__browsertest.cc b/www/chromium/files/patch-chrome_browser_ui_test_popup__browsertest.cc index d5be3643cdb5..8d86dd76291a 100644 --- a/www/chromium/files/patch-chrome_browser_ui_test_popup__browsertest.cc +++ b/www/chromium/files/patch-chrome_browser_ui_test_popup__browsertest.cc @@ -1,20 +1,20 @@ ---- chrome/browser/ui/test/popup_browsertest.cc.orig 2023-07-16 15:47:57 UTC +--- chrome/browser/ui/test/popup_browsertest.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/test/popup_browsertest.cc -@@ -74,7 +74,7 @@ IN_PROC_BROWSER_TEST_F(PopupTest, OpenLeftAndTopZeroCo +@@ -76,7 +76,7 @@ IN_PROC_BROWSER_TEST_F(PopupTest, OpenLeftAndTopZeroCo const display::Display display = GetDisplayNearestBrowser(popup); gfx::Rect expected(popup->window()->GetBounds().size()); expected.AdjustToFit(display.work_area()); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/1286870) Desktop Linux window bounds are inaccurate. + // TODO(crbug.com/40815883) Desktop Linux window bounds are inaccurate. expected.Outset(50); EXPECT_TRUE(expected.Contains(popup->window()->GetBounds())) -@@ -106,7 +106,7 @@ IN_PROC_BROWSER_TEST_F(PopupTest, OpenClampedToCurrent +@@ -108,7 +108,7 @@ IN_PROC_BROWSER_TEST_F(PopupTest, OpenClampedToCurrent // The popup should be constrained to the opener's available display space. EXPECT_EQ(display, GetDisplayNearestBrowser(popup)); gfx::Rect work_area(display.work_area()); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/1286870) Desktop Linux bounds flakily extend outside the + // TODO(crbug.com/40815883) Desktop Linux bounds flakily extend outside the // work area on trybots, when opening with excessive width and height, e.g.: // width=${screen.availWidth+300},height=${screen.availHeight+300} yields: diff --git a/www/chromium/files/patch-chrome_browser_ui_test_test__browser__ui.cc b/www/chromium/files/patch-chrome_browser_ui_test_test__browser__ui.cc index 63ca2f127a35..72099c90af15 100644 --- a/www/chromium/files/patch-chrome_browser_ui_test_test__browser__ui.cc +++ b/www/chromium/files/patch-chrome_browser_ui_test_test__browser__ui.cc @@ -1,20 +1,20 @@ ---- chrome/browser/ui/test/test_browser_ui.cc.orig 2023-08-17 07:33:31 UTC +--- chrome/browser/ui/test/test_browser_ui.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/ui/test/test_browser_ui.cc -@@ -22,7 +22,7 @@ +@@ -19,7 +19,7 @@ + #include "ui/views/widget/widget.h" + #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "content/public/common/content_switches.h" #include "ui/base/test/skia_gold_matching_algorithm.h" -@@ -35,7 +35,7 @@ - // TODO(https://crbug.com/958242) support Mac for pixel tests. - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if BUILDFLAG(IS_WIN) || (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) + #include "ui/compositor/compositor.h" +@@ -33,7 +33,7 @@ + #endif + + // TODO(crbug.com/40625383) support Mac for pixel tests. +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #define SUPPORTS_PIXEL_TEST #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_ui__features.cc b/www/chromium/files/patch-chrome_browser_ui_ui__features.cc index 98df7877f2ef..e5c96ff7b26b 100644 --- a/www/chromium/files/patch-chrome_browser_ui_ui__features.cc +++ b/www/chromium/files/patch-chrome_browser_ui_ui__features.cc @@ -1,11 +1,20 @@ ---- chrome/browser/ui/ui_features.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/ui_features.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/ui_features.cc -@@ -410,7 +410,7 @@ BASE_FEATURE(kTopChromeWebUIUsesSpareRenderer, - "TopChromeWebUIUsesSpareRenderer", +@@ -38,7 +38,7 @@ BASE_FEATURE(kCloseOmniboxPopupOnInactiveAreaClick, + "CloseOmniboxPopupOnInactiveAreaClick", base::FEATURE_ENABLED_BY_DEFAULT); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Enables alternate update-related text to be displayed in browser app menu - // button, menu item and confirmation dialog. - BASE_FEATURE(kUpdateTextOptions, + // Enables the feature to remove the last confirmation dialog when relaunching + // to update Chrome. + BASE_FEATURE(kFewerUpdateConfirmations, +@@ -359,7 +359,7 @@ BASE_FEATURE(kViewsJSAppModalDialog, + base::FEATURE_DISABLED_BY_DEFAULT); + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kUsePortalAccentColor, + "UsePortalAccentColor", + base::FEATURE_ENABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-chrome_browser_ui_ui__features.h b/www/chromium/files/patch-chrome_browser_ui_ui__features.h index 85f143c1dd55..f58df6b23b3d 100644 --- a/www/chromium/files/patch-chrome_browser_ui_ui__features.h +++ b/www/chromium/files/patch-chrome_browser_ui_ui__features.h @@ -1,11 +1,20 @@ ---- chrome/browser/ui/ui_features.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/ui_features.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/ui_features.h -@@ -264,7 +264,7 @@ BASE_DECLARE_FEATURE(kToolbarUseHardwareBitmapDraw); +@@ -28,7 +28,7 @@ BASE_DECLARE_FEATURE(kAllowEyeDropperWGCScreenCapture) - BASE_DECLARE_FEATURE(kTopChromeWebUIUsesSpareRenderer); + BASE_DECLARE_FEATURE(kCloseOmniboxPopupOnInactiveAreaClick); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - BASE_DECLARE_FEATURE(kUpdateTextOptions); - extern const base::FeatureParam<int> kUpdateTextOptionNumber; + BASE_DECLARE_FEATURE(kFewerUpdateConfirmations); #endif + +@@ -225,7 +225,7 @@ BASE_DECLARE_FEATURE(kViewsFirstRunDialog); + BASE_DECLARE_FEATURE(kViewsJSAppModalDialog); + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + BASE_DECLARE_FEATURE(kUsePortalAccentColor); + #endif + diff --git a/www/chromium/files/patch-chrome_browser_ui_views_accelerator__table.cc b/www/chromium/files/patch-chrome_browser_ui_views_accelerator__table.cc index 3c69401f3354..67daf648cbce 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_accelerator__table.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_accelerator__table.cc @@ -1,4 +1,4 @@ ---- chrome/browser/ui/views/accelerator_table.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/views/accelerator_table.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/accelerator_table.cc @@ -72,11 +72,11 @@ const AcceleratorMapping kAcceleratorMap[] = { {ui::VKEY_S, ui::EF_PLATFORM_ACCELERATOR, IDC_SAVE_PAGE}, @@ -23,21 +23,12 @@ {ui::VKEY_1, ui::EF_ALT_DOWN, IDC_SELECT_TAB_0}, {ui::VKEY_NUMPAD1, ui::EF_ALT_DOWN, IDC_SELECT_TAB_0}, {ui::VKEY_2, ui::EF_ALT_DOWN, IDC_SELECT_TAB_1}, -@@ -154,7 +154,7 @@ const AcceleratorMapping kAcceleratorMap[] = { +@@ -156,7 +156,7 @@ const AcceleratorMapping kAcceleratorMap[] = { IDC_SHOW_AVATAR_MENU}, // Platform-specific key maps. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) {ui::VKEY_BROWSER_BACK, ui::EF_NONE, IDC_BACK}, {ui::VKEY_BROWSER_FORWARD, ui::EF_NONE, IDC_FORWARD}, {ui::VKEY_BROWSER_HOME, ui::EF_NONE, IDC_HOME}, -@@ -250,7 +250,7 @@ const AcceleratorMapping kAcceleratorMap[] = { - #endif // !BUILDFLAG(IS_CHROMEOS) - #endif // !BUILDFLAG(IS_MAC) - #if BUILDFLAG(ENABLE_SCREEN_AI_SERVICE) && \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) - {ui::VKEY_S, ui::EF_CONTROL_DOWN | ui::EF_SHIFT_DOWN, - IDC_CONTENT_CONTEXT_RUN_LAYOUT_EXTRACTION}, - #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_views_apps_chrome__native__app__window__views__aura.cc b/www/chromium/files/patch-chrome_browser_ui_views_apps_chrome__native__app__window__views__aura.cc index 4e0a6bba92a4..beec656afb97 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_apps_chrome__native__app__window__views__aura.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_apps_chrome__native__app__window__views__aura.cc @@ -1,7 +1,7 @@ ---- chrome/browser/ui/views/apps/chrome_native_app_window_views_aura.cc.orig 2022-07-22 17:30:31 UTC +--- chrome/browser/ui/views/apps/chrome_native_app_window_views_aura.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/views/apps/chrome_native_app_window_views_aura.cc @@ -19,7 +19,7 @@ - #include "ui/gfx/image/image_skia.h" + #include "ui/menus/simple_menu_model.h" #include "ui/views/widget/widget.h" -#if BUILDFLAG(IS_LINUX) @@ -9,7 +9,7 @@ #include "chrome/browser/shell_integration_linux.h" #endif -@@ -55,7 +55,7 @@ void ChromeNativeAppWindowViewsAura::OnBeforeWidgetIni +@@ -49,7 +49,7 @@ void ChromeNativeAppWindowViewsAura::OnBeforeWidgetIni const AppWindow::CreateParams& create_params, views::Widget::InitParams* init_params, views::Widget* widget) { diff --git a/www/chromium/files/patch-chrome_browser_ui_views_chrome__browser__main__extra__parts__views.cc b/www/chromium/files/patch-chrome_browser_ui_views_chrome__browser__main__extra__parts__views.cc index f25c607967a0..1da388f6b7c2 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_chrome__browser__main__extra__parts__views.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_chrome__browser__main__extra__parts__views.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/chrome_browser_main_extra_parts_views.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/views/chrome_browser_main_extra_parts_views.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/chrome_browser_main_extra_parts_views.cc -@@ -38,7 +38,7 @@ +@@ -39,7 +39,7 @@ #include "ui/wm/core/wm_state.h" #endif // defined(USE_AURA) @@ -9,7 +9,7 @@ #include <sys/stat.h> #include <sys/types.h> #include <unistd.h> -@@ -131,7 +131,7 @@ void ChromeBrowserMainExtraPartsViews::PreProfileInit( +@@ -143,7 +143,7 @@ void ChromeBrowserMainExtraPartsViews::PreProfileInit( return controller; })); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate.h b/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate.h index aa7648ca1575..84ca09c74b2c 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate.h +++ b/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate.h @@ -1,16 +1,11 @@ ---- chrome/browser/ui/views/chrome_views_delegate.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/chrome_views_delegate.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/views/chrome_views_delegate.h -@@ -59,11 +59,11 @@ class ChromeViewsDelegate : public views::ViewsDelegat +@@ -52,7 +52,7 @@ class ChromeViewsDelegate : public views::ViewsDelegat base::OnceClosure callback) override; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - bool WindowManagerProvidesTitleBar(bool maximized) override; #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + bool WindowManagerProvidesTitleBar(bool maximized) override; gfx::ImageSkia* GetDefaultWindowIcon() const override; #endif - diff --git a/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate__linux.cc b/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate__linux.cc index 3fd43d757d06..bb568d3dd833 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate__linux.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_chrome__views__delegate__linux.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/chrome_views_delegate_linux.cc.orig 2022-08-31 12:19:35 UTC +--- chrome/browser/ui/views/chrome_views_delegate_linux.cc.orig 2024-05-21 18:07:39 UTC +++ chrome/browser/ui/views/chrome_views_delegate_linux.cc -@@ -23,7 +23,7 @@ bool IsDesktopEnvironmentUnity() { +@@ -26,7 +26,7 @@ bool IsDesktopEnvironmentUnity() { return desktop_env == base::nix::DESKTOP_ENVIRONMENT_UNITY; } @@ -9,7 +9,7 @@ int GetWindowIconResourceId() { #if BUILDFLAG(GOOGLE_CHROME_BRANDING) switch (chrome::GetChannel()) { -@@ -67,7 +67,7 @@ views::NativeWidget* ChromeViewsDelegate::CreateNative +@@ -80,7 +80,7 @@ views::NativeWidget* ChromeViewsDelegate::CreateNative delegate); } diff --git a/www/chromium/files/patch-chrome_browser_ui_views_compose_compose__dialog__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_compose_compose__dialog__view.cc index fbf2fabd0fe1..7ddc659ec73a 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_compose_compose__dialog__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_compose_compose__dialog__view.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/compose/compose_dialog_view.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/views/compose/compose_dialog_view.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/views/compose/compose_dialog_view.cc -@@ -159,7 +159,7 @@ void ComposeDialogView::OnBeforeBubbleWidgetInit( +@@ -160,7 +160,7 @@ void ComposeDialogView::OnBeforeBubbleWidgetInit( views::Widget::InitParams* params, views::Widget* widget) const { WebUIBubbleDialogView::OnBeforeBubbleWidgetInit(params, widget); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.cc index 29c18de6f02c..7ee2e75debdd 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.cc @@ -1,7 +1,7 @@ ---- chrome/browser/ui/views/frame/browser_frame.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/browser_frame.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/frame/browser_frame.cc -@@ -54,7 +54,7 @@ - #include "components/user_manager/user_manager.h" +@@ -52,7 +52,7 @@ + #include "ui/aura/window.h" #endif -#if BUILDFLAG(IS_LINUX) @@ -9,7 +9,7 @@ #include "ui/display/screen.h" #include "ui/linux/linux_ui.h" #endif -@@ -89,7 +89,7 @@ class ThemeChangedObserver : public views::WidgetObser +@@ -87,7 +87,7 @@ class ThemeChangedObserver : public views::WidgetObser }; bool IsUsingLinuxSystemTheme(Profile* profile) { @@ -18,7 +18,7 @@ return ThemeServiceFactory::GetForProfile(profile)->UsingSystemTheme(); #else return false; -@@ -184,7 +184,7 @@ void BrowserFrame::InitBrowserFrame() { +@@ -185,7 +185,7 @@ void BrowserFrame::InitBrowserFrame() { Init(std::move(params)); @@ -27,7 +27,7 @@ SelectNativeTheme(); #else SetNativeTheme(ui::NativeTheme::GetInstanceForNativeUi()); -@@ -370,7 +370,7 @@ void BrowserFrame::OnNativeWidgetWorkspaceChanged() { +@@ -371,7 +371,7 @@ void BrowserFrame::OnNativeWidgetWorkspaceChanged() { chrome::SaveWindowWorkspace(browser_view_->browser(), GetWorkspace()); chrome::SaveWindowVisibleOnAllWorkspaces(browser_view_->browser(), IsVisibleOnAllWorkspaces()); @@ -36,7 +36,7 @@ // If the window was sent to a different workspace, prioritize it if // it was sent to the current workspace and deprioritize it // otherwise. This is done by MoveBrowsersInWorkspaceToFront() -@@ -563,7 +563,7 @@ void BrowserFrame::OnMenuClosed() { +@@ -569,7 +569,7 @@ void BrowserFrame::OnMenuClosed() { } void BrowserFrame::SelectNativeTheme() { @@ -45,7 +45,7 @@ // Use the regular NativeTheme instance if running incognito mode, regardless // of system theme (gtk, qt etc). ui::NativeTheme* native_theme = ui::NativeTheme::GetInstanceForNativeUi(); -@@ -604,7 +604,7 @@ void BrowserFrame::OnTouchUiChanged() { +@@ -610,7 +610,7 @@ void BrowserFrame::OnTouchUiChanged() { bool BrowserFrame::RegenerateFrameOnThemeChange( BrowserThemeChangeType theme_change_type) { bool need_regenerate = false; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.h b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.h index 3386bfb16c67..7240c51b69fa 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.h +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame.h @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/frame/browser_frame.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/browser_frame.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/views/frame/browser_frame.h -@@ -65,7 +65,7 @@ class BrowserFrame : public views::Widget, public view +@@ -66,7 +66,7 @@ class BrowserFrame : public views::Widget, public view ~BrowserFrame() override; @@ -9,7 +9,7 @@ // Returns whether the frame is in a tiled state. bool tiled() const { return tiled_; } void set_tiled(bool tiled) { tiled_ = tiled; } -@@ -225,7 +225,7 @@ class BrowserFrame : public views::Widget, public view +@@ -227,7 +227,7 @@ class BrowserFrame : public views::Widget, public view // contents for smoother dragging. TabDragKind tab_drag_kind_ = TabDragKind::kNone; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux.cc index 1a70d3466501..c46c8487e59d 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/frame/browser_frame_view_layout_linux.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/browser_frame_view_layout_linux.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/frame/browser_frame_view_layout_linux.cc -@@ -53,7 +53,7 @@ gfx::Insets BrowserFrameViewLayoutLinux::RestoredFrame +@@ -55,7 +55,7 @@ gfx::Insets BrowserFrameViewLayoutLinux::RestoredFrame OpaqueBrowserFrameViewLayout::RestoredFrameBorderInsets()); } diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux__native.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux__native.cc index ac7f01e7e27c..f465004df8cd 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux__native.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__layout__linux__native.cc @@ -1,4 +1,4 @@ ---- chrome/browser/ui/views/frame/browser_frame_view_layout_linux_native.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/browser_frame_view_layout_linux_native.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/ui/views/frame/browser_frame_view_layout_linux_native.cc @@ -18,7 +18,7 @@ BrowserFrameViewLayoutLinuxNative::~BrowserFrameViewLa @@ -7,5 +7,5 @@ -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) const bool tiled = delegate_->IsTiled(); + const bool maximized = delegate_->IsMaximized(); #else - const bool tiled = false; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__linux.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__linux.cc index 2a1ffc8d4ca0..29bf06a735bf 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__linux.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__frame__view__linux.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/frame/browser_frame_view_linux.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/frame/browser_frame_view_linux.cc.orig 2024-11-14 07:57:23 UTC +++ chrome/browser/ui/views/frame/browser_frame_view_linux.cc -@@ -60,7 +60,7 @@ gfx::ShadowValues BrowserFrameViewLinux::GetShadowValu +@@ -70,7 +70,7 @@ gfx::ShadowValues BrowserFrameViewLinux::GetShadowValu void BrowserFrameViewLinux::PaintRestoredFrameBorder( gfx::Canvas* canvas) const { @@ -9,7 +9,7 @@ const bool tiled = frame()->tiled(); #else const bool tiled = false; -@@ -104,7 +104,7 @@ void BrowserFrameViewLinux::OnWindowButtonOrderingChan +@@ -125,7 +125,7 @@ int BrowserFrameViewLinux::NonClientHitTest(const gfx: } float BrowserFrameViewLinux::GetRestoredCornerRadiusDip() const { diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__non__client__frame__view__factory__views.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__non__client__frame__view__factory__views.cc index 9c8254b6d4ea..0280c3d311eb 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__non__client__frame__view__factory__views.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__non__client__frame__view__factory__views.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_views.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_views.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/frame/browser_non_client_frame_view_factory_views.cc -@@ -16,7 +16,7 @@ +@@ -15,7 +15,7 @@ #include "chrome/browser/ui/views/frame/browser_frame_view_win.h" #endif @@ -18,3 +18,12 @@ auto* profile = browser_view->browser()->profile(); auto* linux_ui_theme = ui::LinuxUiTheme::GetForProfile(profile); auto* theme_service_factory = ThemeServiceFactory::GetForProfile(profile); +@@ -83,7 +83,7 @@ std::unique_ptr<BrowserNonClientFrameView> CreateBrows + BrowserFrame* frame, + BrowserView* browser_view) { + if (browser_view->browser()->is_type_picture_in_picture()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return std::make_unique<PictureInPictureBrowserFrameViewLinux>( + frame, browser_view); + #else diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__view.cc index f665dddc2b33..7897da458f14 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_browser__view.cc @@ -1,11 +1,20 @@ ---- chrome/browser/ui/views/frame/browser_view.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/frame/browser_view.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/frame/browser_view.cc -@@ -2234,7 +2234,7 @@ void BrowserView::TabDraggingStatusChanged(bool is_dra - // CrOS cleanup is done. - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) - contents_web_view_->SetFastResize(is_dragging); - if (!is_dragging) { - // When tab dragging is ended, we need to make sure the web contents get +@@ -2740,7 +2740,7 @@ void BrowserView::ToolbarSizeChanged(bool is_animating + } + + void BrowserView::TabDraggingStatusChanged(bool is_dragging) { +-#if !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) + GetContentsWebView()->SetFastResize(is_dragging); + if (multi_contents_view_) { + multi_contents_view_->GetInactiveContentsView()->SetFastResize(is_dragging); +@@ -6044,7 +6044,7 @@ void BrowserView::MaybeShowProfileSwitchIPH() { + } + + void BrowserView::MaybeShowSupervisedUserProfileSignInIPH() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (!ShouldShowAvatarToolbarIPH()) { + return; + } diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.cc index f8f1cbf0c151..cea54b3aa06f 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.cc @@ -1,4 +1,4 @@ ---- chrome/browser/ui/views/frame/opaque_browser_frame_view.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/opaque_browser_frame_view.cc.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/ui/views/frame/opaque_browser_frame_view.cc @@ -54,7 +54,7 @@ #include "ui/views/window/vector_icons/vector_icons.h" @@ -9,16 +9,16 @@ #include "ui/views/controls/menu/menu_runner.h" #endif -@@ -566,7 +566,7 @@ OpaqueBrowserFrameView::FrameButtonStyle +@@ -572,7 +572,7 @@ bool OpaqueBrowserFrameView::EverHasVisibleBackgroundT + + OpaqueBrowserFrameView::FrameButtonStyle OpaqueBrowserFrameView::GetFrameButtonStyle() const { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return FrameButtonStyle::kMdButton; #else return FrameButtonStyle::kImageButton; -@@ -585,7 +585,7 @@ bool OpaqueBrowserFrameView::ShouldDrawRestoredFrameSh +@@ -591,7 +591,7 @@ bool OpaqueBrowserFrameView::ShouldDrawRestoredFrameSh return false; } @@ -27,7 +27,7 @@ bool OpaqueBrowserFrameView::IsTiled() const { return frame()->tiled(); } -@@ -783,7 +783,7 @@ gfx::Rect OpaqueBrowserFrameView::GetIconBounds() cons +@@ -794,7 +794,7 @@ gfx::Rect OpaqueBrowserFrameView::GetIconBounds() cons } void OpaqueBrowserFrameView::WindowIconPressed() { diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.h b/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.h index b269b939ae9d..416d29c93ad9 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.h +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view.h @@ -1,15 +1,15 @@ ---- chrome/browser/ui/views/frame/opaque_browser_frame_view.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/opaque_browser_frame_view.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/views/frame/opaque_browser_frame_view.h -@@ -115,7 +115,7 @@ class OpaqueBrowserFrameView : public BrowserNonClient - void UpdateWindowControlsOverlay( - const gfx::Rect& bounding_rect) const override; +@@ -110,7 +110,7 @@ class OpaqueBrowserFrameView : public BrowserNonClient + FrameButtonStyle GetFrameButtonStyle() const override; + void UpdateWindowControlsOverlay(const gfx::Rect& bounding_rect) override; bool ShouldDrawRestoredFrameShadow() const override; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool IsTiled() const override; #endif int WebAppButtonHeight() const override; -@@ -232,7 +232,7 @@ class OpaqueBrowserFrameView : public BrowserNonClient +@@ -227,7 +227,7 @@ class OpaqueBrowserFrameView : public BrowserNonClient // Background painter for the window frame. std::unique_ptr<views::FrameBackground> frame_background_; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view__layout__delegate.h b/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view__layout__delegate.h index def5c143167a..be72ed0bfb28 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view__layout__delegate.h +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_opaque__browser__frame__view__layout__delegate.h @@ -1,15 +1,15 @@ ---- chrome/browser/ui/views/frame/opaque_browser_frame_view_layout_delegate.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/opaque_browser_frame_view_layout_delegate.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/views/frame/opaque_browser_frame_view_layout_delegate.h -@@ -10,7 +10,7 @@ +@@ -9,7 +9,7 @@ + #include "build/build_config.h" - #include "build/chromeos_buildflags.h" --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "ui/base/ui_base_types.h" #endif -@@ -94,7 +94,7 @@ class OpaqueBrowserFrameViewLayoutDelegate { +@@ -92,7 +92,7 @@ class OpaqueBrowserFrameViewLayoutDelegate { // Returns true if a client-side shadow should be drawn for restored windows. virtual bool ShouldDrawRestoredFrameShadow() const = 0; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.cc index 344738d48c82..1def07674bef 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.cc @@ -1,92 +1,11 @@ ---- chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc -@@ -59,7 +59,7 @@ - #include "ui/aura/window.h" - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "chrome/browser/themes/theme_service.h" - #include "chrome/browser/themes/theme_service_factory.h" - #include "chrome/browser/ui/views/frame/browser_frame_view_paint_utils_linux.h" -@@ -89,7 +89,7 @@ constexpr int kContentSettingIconSize = 16; - // The height of the controls bar at the top of the window. - constexpr int kTopControlsHeight = 34; +@@ -67,7 +67,7 @@ + // Windows, Mac and CrOS do not clip child widgets to their parents, so we + // don't have to worry about resizing quite as much. -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Frame border when window shadow is not drawn. - constexpr int kFrameBorderThickness = 4; + #define PLATFORM_CLIPS_CHILD_WINDOWS #endif -@@ -184,7 +184,7 @@ class WindowEventObserver : public ui::EventObserver { - - gfx::Rect input_bounds = pip_browser_frame_view_->GetLocalBounds(); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Calculate input bounds for Linux. This is needed because the input bounds - // is not necessary the same as the local bounds on Linux. - if (pip_browser_frame_view_->ShouldDrawFrameShadow()) { -@@ -585,7 +585,7 @@ PictureInPictureBrowserFrameView::PictureInPictureBrow - AddChildView(std::move(auto_pip_setting_overlay)); - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - auto* profile = browser_view->browser()->profile(); - auto* linux_ui_theme = ui::LinuxUiTheme::GetForProfile(profile); - auto* theme_service_factory = ThemeServiceFactory::GetForProfile(profile); -@@ -804,7 +804,7 @@ void PictureInPictureBrowserFrameView::OnThemeChanged( - for (ContentSettingImageView* view : content_setting_views_) - view->SetIconColor(color_provider->GetColor(kColorPipWindowForeground)); - --#if !BUILDFLAG(IS_LINUX) -+#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) - // On Linux the top bar background will be drawn in OnPaint(). - top_bar_container_view_->SetBackground(views::CreateSolidBackground( - color_provider->GetColor(kColorPipWindowTopBarBackground))); -@@ -886,7 +886,7 @@ void PictureInPictureBrowserFrameView::RemovedFromWidg - BrowserNonClientFrameView::RemovedFromWidget(); - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - gfx::Insets PictureInPictureBrowserFrameView::MirroredFrameBorderInsets() - const { - auto border = FrameBorderInsets(); -@@ -1147,7 +1147,7 @@ void PictureInPictureBrowserFrameView::AnimationProgre - // views::View implementations: - void PictureInPictureBrowserFrameView::OnPaint(gfx::Canvas* canvas) { --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Draw the PiP window frame borders and shadows, including the top bar - // background. - if (window_frame_provider_) { -@@ -1281,7 +1281,7 @@ void PictureInPictureBrowserFrameView::UpdateTopBarVie - } - - gfx::Insets PictureInPictureBrowserFrameView::FrameBorderInsets() const { --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (window_frame_provider_) { - const auto insets = window_frame_provider_->GetFrameThicknessDip(); - const bool tiled = frame()->tiled(); -@@ -1299,7 +1299,7 @@ gfx::Insets PictureInPictureBrowserFrameView::FrameBor - } - - gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const { --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return FrameBorderInsets(); - #elif !BUILDFLAG(IS_CHROMEOS_ASH) - return gfx::Insets(kResizeBorder); -@@ -1320,7 +1320,7 @@ gfx::Size PictureInPictureBrowserFrameView::GetNonClie - top_height + border_thickness.bottom()); - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - bool PictureInPictureBrowserFrameView::ShouldDrawFrameShadow() const { - return static_cast<DesktopBrowserFrameAuraLinux*>( - frame()->native_browser_frame()) diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.h b/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.h deleted file mode 100644 index 24ad747ec8cf..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_picture__in__picture__browser__frame__view.h +++ /dev/null @@ -1,47 +0,0 @@ ---- chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.h.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.h -@@ -27,7 +27,7 @@ - #include "ui/views/layout/flex_layout_view.h" - #include "ui/views/widget/widget_observer.h" - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "ui/linux/window_frame_provider.h" - #endif - -@@ -35,7 +35,7 @@ - // parent window, so to prevent cutting off important dialogs we resize the - // picture-in-picture window to fit them. While ChromeOS Ash also uses Aura, it - // does not have this issue so we do not resize on ChromeOS Ash. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - #define RESIZE_DOCUMENT_PICTURE_IN_PICTURE_TO_DIALOG 1 - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || - // BUILDFLAG(IS_CHROMEOS_LACROS) -@@ -101,7 +101,7 @@ class PictureInPictureBrowserFrameView - void Layout(PassKey) override; - void AddedToWidget() override; - void RemovedFromWidget() override; --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - gfx::Insets MirroredFrameBorderInsets() const override; - gfx::Insets GetInputInsets() const override; - SkRRect GetRestoredClipRegion() const override; -@@ -192,7 +192,7 @@ class PictureInPictureBrowserFrameView - // Returns true if there's an overlay view that's currently shown. - bool IsOverlayViewVisible() const; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Returns whether a client-side shadow should be drawn for the window. - bool ShouldDrawFrameShadow() const; - -@@ -368,7 +368,7 @@ class PictureInPictureBrowserFrameView - // `top_bar_color_animation_`. - std::optional<SkColor> current_foreground_color_; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Used to draw window frame borders and shadow on Linux when GTK theme is - // enabled. - raw_ptr<ui::WindowFrameProvider> window_frame_provider_ = nullptr; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__builder.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__builder.cc index 239d13d316cf..ba4a03c3d96b 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__builder.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__builder.cc @@ -1,24 +1,24 @@ ---- chrome/browser/ui/views/frame/system_menu_model_builder.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/ui/views/frame/system_menu_model_builder.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/frame/system_menu_model_builder.cc -@@ -75,7 +75,7 @@ void SystemMenuModelBuilder::BuildSystemMenuForBrowser +@@ -75,7 +75,7 @@ void SystemMenuModelBuilder::BuildMenu(ui::SimpleMenuM + + void SystemMenuModelBuilder::BuildSystemMenuForBrowserWindow( ui::SimpleMenuModel* model) { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !BUILDFLAG(IS_CHROMEOS_LACROS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) model->AddItemWithStringId(IDC_MINIMIZE_WINDOW, IDS_MINIMIZE_WINDOW_MENU); model->AddItemWithStringId(IDC_MAXIMIZE_WINDOW, IDS_MAXIMIZE_WINDOW_MENU); model->AddItemWithStringId(IDC_RESTORE_WINDOW, IDS_RESTORE_WINDOW_MENU); -@@ -91,7 +91,7 @@ void SystemMenuModelBuilder::BuildSystemMenuForBrowser +@@ -101,7 +101,7 @@ void SystemMenuModelBuilder::BuildSystemMenuForBrowser + model->AddSeparator(ui::NORMAL_SEPARATOR); + model->AddItemWithStringId(IDC_TASK_MANAGER_CONTEXT_MENU, IDS_TASK_MANAGER); } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !BUILDFLAG(IS_CHROMEOS_LACROS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) model->AddSeparator(ui::NORMAL_SEPARATOR); bool supports_server_side_decorations = true; #if BUILDFLAG(IS_OZONE) && !BUILDFLAG(IS_CHROMEOS) -@@ -147,7 +147,7 @@ void SystemMenuModelBuilder::BuildSystemMenuForAppOrPo +@@ -175,7 +175,7 @@ void SystemMenuModelBuilder::BuildSystemMenuForAppOrPo model->AddSeparator(ui::NORMAL_SEPARATOR); model->AddItemWithStringId(IDC_TASK_MANAGER, IDS_TASK_MANAGER); } diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__delegate.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__delegate.cc index 9eacbec0e371..28da5e167084 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__delegate.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_system__menu__model__delegate.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/frame/system_menu_model_delegate.cc.orig 2023-07-16 15:47:57 UTC +--- chrome/browser/ui/views/frame/system_menu_model_delegate.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/frame/system_menu_model_delegate.cc -@@ -21,7 +21,7 @@ +@@ -20,7 +20,7 @@ #include "chromeos/ui/frame/desks/move_to_desks_menu_model.h" #endif @@ -9,8 +9,8 @@ #include "chrome/common/pref_names.h" #include "components/prefs/pref_service.h" #endif -@@ -36,7 +36,7 @@ SystemMenuModelDelegate::SystemMenuModelDelegate( - SystemMenuModelDelegate::~SystemMenuModelDelegate() {} +@@ -39,7 +39,7 @@ SystemMenuModelDelegate::SystemMenuModelDelegate( + SystemMenuModelDelegate::~SystemMenuModelDelegate() = default; bool SystemMenuModelDelegate::IsCommandIdChecked(int command_id) const { -#if BUILDFLAG(IS_LINUX) @@ -18,12 +18,12 @@ if (command_id == IDC_USE_SYSTEM_TITLE_BAR) { PrefService* prefs = browser_->profile()->GetPrefs(); return !prefs->GetBoolean(prefs::kUseCustomChromeFrame); -@@ -58,7 +58,7 @@ bool SystemMenuModelDelegate::IsCommandIdEnabled(int c +@@ -65,7 +65,7 @@ bool SystemMenuModelDelegate::IsCommandIdEnabled(int c + } + bool SystemMenuModelDelegate::IsCommandIdVisible(int command_id) const { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool is_maximized = browser_->window()->IsMaximized(); switch (command_id) { case IDC_MAXIMIZE_WINDOW: diff --git a/www/chromium/files/patch-chrome_browser_ui_views_frame_tab__strip__region__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_frame_tab__strip__region__view.cc index 60d79c04bd5c..3a485c613160 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_frame_tab__strip__region__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_frame_tab__strip__region__view.cc @@ -1,11 +1,11 @@ ---- chrome/browser/ui/views/frame/tab_strip_region_view.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/frame/tab_strip_region_view.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/ui/views/frame/tab_strip_region_view.cc -@@ -196,7 +196,7 @@ TabStripRegionView::TabStripRegionView(std::unique_ptr +@@ -222,7 +222,7 @@ TabStripRegionView::TabStripRegionView(std::unique_ptr + new_tab_button_->GetViewAccessibility().SetName( + l10n_util::GetStringUTF16(IDS_ACCNAME_NEWTAB)); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag - // switch of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - // The New Tab Button can be middle-clicked on Linux. - new_tab_button_->SetTriggerableEventFlags( - new_tab_button_->GetTriggerableEventFlags() | +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // The New Tab Button can be middle-clicked on Linux. + new_tab_button_->SetTriggerableEventFlags( + new_tab_button_->GetTriggerableEventFlags() | diff --git a/www/chromium/files/patch-chrome_browser_ui_views_hung__renderer__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_hung__renderer__view.cc index ba6f0668d67d..ecb6392296d2 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_hung__renderer__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_hung__renderer__view.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/hung_renderer_view.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/hung_renderer_view.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/ui/views/hung_renderer_view.cc -@@ -406,7 +406,7 @@ void HungRendererDialogView::ForceCrashHungRenderer() +@@ -452,7 +452,7 @@ void HungRendererDialogView::ForceCrashHungRenderer() content::RenderProcessHost* rph = hung_pages_table_model_->GetRenderWidgetHost()->GetProcess(); if (rph) { diff --git a/www/chromium/files/patch-chrome_browser_ui_views_new__tab__footer_footer__controller.cc b/www/chromium/files/patch-chrome_browser_ui_views_new__tab__footer_footer__controller.cc new file mode 100644 index 000000000000..dca33b2f538a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_new__tab__footer_footer__controller.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/new_tab_footer/footer_controller.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/new_tab_footer/footer_controller.cc +@@ -55,7 +55,7 @@ NewTabFooterController::NewTabFooterController(Browser + base::BindRepeating(&NewTabFooterController::UpdateFooterVisibility, + weak_factory_.GetWeakPtr(), + /*log_on_load_metric=*/false)); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + local_state_pref_change_registrar_.Init(g_browser_process->local_state()); + local_state_pref_change_registrar_.Add( + prefs::kNTPFooterManagementNoticeEnabled, diff --git a/www/chromium/files/patch-chrome_browser_ui_views_omnibox_omnibox__view__views.cc b/www/chromium/files/patch-chrome_browser_ui_views_omnibox_omnibox__view__views.cc new file mode 100644 index 000000000000..789ef71b5c88 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_omnibox_omnibox__view__views.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/omnibox/omnibox_view_views.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/omnibox/omnibox_view_views.cc +@@ -2175,7 +2175,7 @@ void OmniboxViewViews::MaybeAddSendTabToSelfItem( + } + + void OmniboxViewViews::OnPopupOpened() { +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // It's not great for promos to overlap the omnibox if the user opens the + // drop-down after showing the promo. This especially causes issues on Mac and + // Linux due to z-order/rendering issues, see crbug.com/1225046 and diff --git a/www/chromium/files/patch-chrome_browser_ui_views_passwords_password__bubble__view__base.cc b/www/chromium/files/patch-chrome_browser_ui_views_passwords_password__bubble__view__base.cc index 390cd541a028..957a08920b46 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_passwords_password__bubble__view__base.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_passwords_password__bubble__view__base.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/passwords/password_bubble_view_base.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/browser/ui/views/passwords/password_bubble_view_base.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/ui/views/passwords/password_bubble_view_base.cc -@@ -34,7 +34,7 @@ +@@ -42,7 +42,7 @@ #include "ui/base/metadata/metadata_impl_macros.h" #include "ui/views/controls/button/button.h" @@ -9,7 +9,7 @@ #include "chrome/browser/ui/views/passwords/password_relaunch_chrome_view.h" #endif -@@ -139,7 +139,7 @@ PasswordBubbleViewBase* PasswordBubbleViewBase::Create +@@ -175,7 +175,7 @@ PasswordBubbleViewBase* PasswordBubbleViewBase::Create } else if (model_state == password_manager::ui::NOTIFY_RECEIVED_SHARED_CREDENTIALS) { view = new SharedPasswordsNotificationView(web_contents, anchor_view); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_avatar__toolbar__button.cc b/www/chromium/files/patch-chrome_browser_ui_views_profiles_avatar__toolbar__button.cc new file mode 100644 index 000000000000..76671ba6b16a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_avatar__toolbar__button.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/profiles/avatar_toolbar_button.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/profiles/avatar_toolbar_button.cc +@@ -317,7 +317,7 @@ void AvatarToolbarButton::MaybeShowProfileSwitchIPH() + } + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void AvatarToolbarButton::MaybeShowSupervisedUserSignInIPH() { + if (!base::FeatureList::IsEnabled( + feature_engagement::kIPHSupervisedUserProfileSigninFeature)) { diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_avatar__toolbar__button.h b/www/chromium/files/patch-chrome_browser_ui_views_profiles_avatar__toolbar__button.h new file mode 100644 index 000000000000..b437054a304d --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_avatar__toolbar__button.h @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/profiles/avatar_toolbar_button.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/profiles/avatar_toolbar_button.h +@@ -90,7 +90,7 @@ class AvatarToolbarButton : public ToolbarButton { + // Attempts showing the In-Produce-Help for profile Switching. + void MaybeShowProfileSwitchIPH(); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Attempts showing the In-Produce-Help when a supervised user signs-in in a + // profile. + void MaybeShowSupervisedUserSignInIPH(); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__coordinator.cc b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__coordinator.cc new file mode 100644 index 000000000000..b065e827a82a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__coordinator.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/profiles/profile_menu_coordinator.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/profiles/profile_menu_coordinator.cc +@@ -46,7 +46,7 @@ void ProfileMenuCoordinator::Show( + browser.window()->NotifyFeaturePromoFeatureUsed( + feature_engagement::kIPHProfileSwitchFeature, + FeaturePromoFeatureUsedAction::kClosePromoIfPresent); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + browser.window()->NotifyFeaturePromoFeatureUsed( + feature_engagement::kIPHSupervisedUserProfileSigninFeature, + FeaturePromoFeatureUsedAction::kClosePromoIfPresent); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view.cc new file mode 100644 index 000000000000..1e154ec51e6d --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view.cc @@ -0,0 +1,29 @@ +--- chrome/browser/ui/views/profiles/profile_menu_view.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/profiles/profile_menu_view.cc +@@ -92,7 +92,7 @@ + #include "ui/strings/grit/ui_strings.h" + #include "ui/views/accessibility/view_accessibility.h" + +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/enterprise/signin/enterprise_signin_prefs.h" + #endif + +@@ -418,7 +418,7 @@ void ProfileMenuView::OnSigninButtonClicked( + } + GetWidget()->CloseWithReason(views::Widget::ClosedReason::kUnspecified); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // TODO(crbug.com/404807488): Update the button and the dialog strings. + if (base::FeatureList::IsEnabled(switches::kEnableHistorySyncOptin)) { + browser()->signin_view_controller()->ShowModalHistorySyncOptInDialog(); +@@ -555,7 +555,7 @@ void ProfileMenuView::SetMenuTitleForAccessibility() { + case signin_util::SignedInState::kSignedOut: + case signin_util::SignedInState::kWebOnlySignedIn: { + std::string profile_user_display_name, profile_user_email; +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + profile_user_display_name = profile->GetPrefs()->GetString( + enterprise_signin::prefs::kProfileUserDisplayName); + profile_user_email = profile->GetPrefs()->GetString( diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view__base.cc b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view__base.cc index 39fcfd99ebd1..ca5852764981 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view__base.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__menu__view__base.cc @@ -1,11 +1,11 @@ ---- chrome/browser/ui/views/profiles/profile_menu_view_base.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/profiles/profile_menu_view_base.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/profiles/profile_menu_view_base.cc -@@ -726,7 +726,7 @@ void ProfileMenuViewBase::SetProfileIdentityInfo( +@@ -464,7 +464,7 @@ void ProfileMenuViewBase::SetProfileIdentityInfo( + kIdentityImageBorder, + /*has_dotted_ring=*/false); - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // crbug.com/1161166: Orca does not read the accessible window title of the // bubble, so we duplicate it in the top-level menu item. To be revisited // after considering other options, including fixes on the AT side. diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__picker__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__picker__view.cc new file mode 100644 index 000000000000..393855d2e4e3 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_profile__picker__view.cc @@ -0,0 +1,20 @@ +--- chrome/browser/ui/views/profiles/profile_picker_view.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/profiles/profile_picker_view.cc +@@ -84,7 +84,7 @@ + #include "chrome/browser/global_keyboard_shortcuts_mac.h" + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/shell_integration_linux.h" + #endif + +@@ -114,7 +114,7 @@ class ProfilePickerWidget : public views::Widget { + views::Widget::InitParams params( + views::Widget::InitParams::NATIVE_WIDGET_OWNS_WIDGET); + params.delegate = profile_picker_view_; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + params.wm_class_name = shell_integration_linux::GetProgramClassName(); + params.wm_class_class = shell_integration_linux::GetProgramClassClass(); + params.wayland_app_id = params.wm_class_class; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.cc b/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.cc index de6325f6cf96..ae3cda6f09f4 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.cc @@ -1,47 +1,73 @@ ---- chrome/browser/ui/views/profiles/signin_view_controller_delegate_views.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/profiles/signin_view_controller_delegate_views.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/profiles/signin_view_controller_delegate_views.cc -@@ -55,7 +55,7 @@ namespace { +@@ -62,14 +62,14 @@ + #include "chrome/browser/ui/webui/signin/signout_confirmation/signout_confirmation_ui.h" + #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/signin/history_sync_optin/history_sync_optin_ui.h" + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) + + namespace { const int kModalDialogWidth = 448; - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) const int kManagedUserNoticeConfirmationDialogWidth = 512; const int kManagedUserNoticeConfirmationDialogHeight = 576; - #endif -@@ -182,7 +182,7 @@ SigninViewControllerDelegateViews::CreateProfileCustom - #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) || BUILDFLAG(IS_CHROMEOS_LACROS) + const int kManagedUserNoticeConfirmationUpdatedDialogWidth = 780; +@@ -138,7 +138,7 @@ SigninViewControllerDelegateViews::CreateSyncConfirmat + kSyncConfirmationDialogWidth, InitializeSigninWebDialogUI(true)); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + std::unique_ptr<views::WebView> + SigninViewControllerDelegateViews::CreateHistorySyncOptInWebView( + Browser* browser) { +@@ -224,7 +224,7 @@ SigninViewControllerDelegateViews::CreateSignoutConfir + } + #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // static std::unique_ptr<views::WebView> SigninViewControllerDelegateViews::CreateManagedUserNoticeConfirmationWebView( -@@ -328,7 +328,7 @@ SigninViewControllerDelegateViews::SigninViewControlle - SetButtons(ui::DIALOG_BUTTON_NONE); +@@ -409,7 +409,7 @@ SigninViewControllerDelegateViews::SigninViewControlle - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) + SetButtons(static_cast<int>(ui::mojom::DialogButton::kNone)); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // On the local profile creation dialog, cancelling the dialog (for instance // through the VKEY_ESCAPE accelerator) should delete the profile. if (delete_profile_on_cancel) { -@@ -418,7 +418,7 @@ void SigninViewControllerDelegateViews::DisplayModal() +@@ -501,7 +501,7 @@ void SigninViewControllerDelegateViews::DisplayModal() + content_view_->RequestFocus(); } - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void SigninViewControllerDelegateViews::DeleteProfileOnCancel() { ProfileAttributesEntry* entry = g_browser_process->profile_manager() -@@ -491,7 +491,7 @@ SigninViewControllerDelegate::CreateProfileCustomizati - #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) || BUILDFLAG(IS_CHROMEOS_LACROS) +@@ -541,7 +541,7 @@ SigninViewControllerDelegate::CreateSyncConfirmationDe + /*animate_on_resize=*/true); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // static + SigninViewControllerDelegate* + SigninViewControllerDelegate::CreateSyncHistoryOptInDelegate(Browser* browser) { +@@ -595,7 +595,7 @@ SigninViewControllerDelegate::CreateSignoutConfirmatio + } + #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // static SigninViewControllerDelegate* SigninViewControllerDelegate::CreateManagedUserNoticeDelegate( diff --git a/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.h b/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.h index 17a9ce56b7ab..4148b24bc48d 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.h +++ b/www/chromium/files/patch-chrome_browser_ui_views_profiles_signin__view__controller__delegate__views.h @@ -1,20 +1,29 @@ ---- chrome/browser/ui/views/profiles/signin_view_controller_delegate_views.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/views/profiles/signin_view_controller_delegate_views.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/profiles/signin_view_controller_delegate_views.h -@@ -73,7 +73,7 @@ class SigninViewControllerDelegateViews - #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) || BUILDFLAG(IS_CHROMEOS_LACROS) +@@ -57,7 +57,7 @@ class SigninViewControllerDelegateViews + SyncConfirmationStyle style, + bool is_sync_promo); - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + static std::unique_ptr<views::WebView> CreateHistorySyncOptInWebView( + Browser* browser); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +@@ -78,7 +78,7 @@ class SigninViewControllerDelegateViews + SignoutConfirmationCallback callback); + #endif // BUILDFLAG(ENABLE_DICE_SUPPORT) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) static std::unique_ptr<views::WebView> CreateManagedUserNoticeConfirmationWebView( Browser* browser, -@@ -138,7 +138,7 @@ class SigninViewControllerDelegateViews +@@ -149,7 +149,7 @@ class SigninViewControllerDelegateViews + std::optional<int> dialog_width, InitializeSigninWebDialogUI initialize_signin_web_dialog_ui); - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Deletes the ephemeral profile when cancelling the local profile creation // dialog. void DeleteProfileOnCancel(); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tab__search__bubble__host.cc b/www/chromium/files/patch-chrome_browser_ui_views_tab__search__bubble__host.cc deleted file mode 100644 index 3d29bcf1be90..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_views_tab__search__bubble__host.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/ui/views/tab_search_bubble_host.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/ui/views/tab_search_bubble_host.cc -@@ -263,7 +263,7 @@ bool TabSearchBubbleHost::ShouldTabSearchRenderBeforeT - // Mac should have tabsearch on the right side. Windows >= Win10 has the - // Tab Search button as a FrameCaptionButton, but it still needs to be on the - // left if it exists. --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - return features::IsChromeRefresh2023(); - #else - return false; diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tabs_dragging_tab__drag__controller.cc b/www/chromium/files/patch-chrome_browser_ui_views_tabs_dragging_tab__drag__controller.cc new file mode 100644 index 000000000000..7b05a8019709 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_tabs_dragging_tab__drag__controller.cc @@ -0,0 +1,47 @@ +--- chrome/browser/ui/views/tabs/dragging/tab_drag_controller.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/tabs/dragging/tab_drag_controller.cc +@@ -193,7 +193,7 @@ bool IsWindowDragUsingSystemDragDropAllowed() { + + void UpdateSystemDnDDragImage(TabDragContext* attached_context, + const gfx::ImageSkia& image) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + VLOG(1) << __func__ << " image size=" << image.size().ToString(); + aura::Window* root_window = + attached_context->GetWidget()->GetNativeWindow()->GetRootWindow(); +@@ -384,7 +384,7 @@ TabDragController::Liveness TabDragController::Init( + // synchronous on desktop Linux, so use that. + // - ChromeOS Ash + // Releasing capture on Ash cancels gestures so avoid it. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + ref->can_release_capture_ = false; + #endif + ref->start_point_in_screen_ = +@@ -892,7 +892,7 @@ TabDragController::Liveness TabDragController::DragBro + CHECK_EQ(SetCapture(target_context), Liveness::ALIVE); + } + +-#if !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) + // EndMoveLoop is going to snap the window back to its original location. + // Hide it so users don't see this. Hiding a window in Linux aura causes + // it to lose capture so skip it. +@@ -2024,7 +2024,7 @@ void TabDragController::CompleteDrag() { + } + + // If source window was maximized - maximize the new window as well. +-#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_MAC) ++#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_BSD) + // Keeping maximized state breaks snap to Grid on Windows when dragging + // tabs from maximized windows. TODO:(crbug.com/727051) Explore doing this + // for other desktop OS's. kMaximizedStateRetainedOnTabDrag in +@@ -2441,7 +2441,7 @@ TabDragController::Liveness TabDragController::GetLoca + } + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Exclude windows which are pending deletion via Browser::TabStripEmpty(). + // These windows can be returned in the Linux Aura port because the browser + // window which was used for dragging is not hidden once all of its tabs are diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab.cc b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab.cc index b84d4925f3dc..6ba6877a4874 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/tabs/tab.cc.orig 2024-04-25 21:17:54 UTC +--- chrome/browser/ui/views/tabs/tab.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/views/tabs/tab.cc -@@ -621,7 +621,7 @@ void Tab::MaybeUpdateHoverStatus(const ui::MouseEvent& +@@ -644,7 +644,7 @@ void Tab::MaybeUpdateHoverStatus(const ui::MouseEvent& return; } @@ -8,4 +8,4 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Move the hit test area for hovering up so that it is not overlapped by tab // hover cards when they are shown. - // TODO(crbug.com/978134): Once Linux/CrOS widget transparency is solved, + // TODO(crbug.com/41467565): Once Linux/CrOS widget transparency is solved, diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__drag__controller.cc b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__drag__controller.cc deleted file mode 100644 index 6bdbb6c8a919..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__drag__controller.cc +++ /dev/null @@ -1,56 +0,0 @@ ---- chrome/browser/ui/views/tabs/tab_drag_controller.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/ui/views/tabs/tab_drag_controller.cc -@@ -93,7 +93,7 @@ - #include "components/remote_cocoa/browser/window.h" - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "ui/aura/client/drag_drop_client.h" - #endif - -@@ -213,7 +213,7 @@ bool IsWindowDragUsingSystemDragDropAllowed() { - - void UpdateSystemDnDDragImage(TabDragContext* attached_context, - const gfx::ImageSkia& image) { --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - aura::Window* root_window = - attached_context->GetWidget()->GetNativeWindow()->GetRootWindow(); - if (aura::client::GetDragDropClient(root_window)) { -@@ -403,7 +403,7 @@ TabDragController::Liveness TabDragController::Init( - // synchronous on desktop Linux, so use that. - // - ChromeOS Ash - // Releasing capture on Ash cancels gestures so avoid it. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - ref->can_release_capture_ = false; - #endif - ref->start_point_in_screen_ = -@@ -1051,7 +1051,7 @@ TabDragController::DragBrowserToNewTabStrip(TabDragCon - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) - // EndMoveLoop is going to snap the window back to its original location. - // Hide it so users don't see this. Hiding a window in Linux aura causes - // it to lose capture so skip it. -@@ -2103,7 +2103,7 @@ void TabDragController::CompleteDrag() { - } - - // If source window was maximized - maximize the new window as well. --#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_MAC) -+#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_BSD) - // Keeping maximized state breaks snap to Grid on Windows when dragging - // tabs from maximized windows. TODO:(crbug.com/727051) Explore doing this - // for other desktop OS's. kMaximizedStateRetainedOnTabDrag in -@@ -2533,7 +2533,7 @@ TabDragController::Liveness TabDragController::GetLoca - } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - // Exclude windows which are pending deletion via Browser::TabStripEmpty(). - // These windows can be returned in the Linux Aura port because the browser - // window which was used for dragging is not hidden once all of its tabs are diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__hover__card__bubble__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__hover__card__bubble__view.cc index aa24b62b85dd..3137975c2d68 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__hover__card__bubble__view.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__hover__card__bubble__view.cc @@ -1,11 +1,11 @@ ---- chrome/browser/ui/views/tabs/tab_hover_card_bubble_view.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/tabs/tab_hover_card_bubble_view.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/ui/views/tabs/tab_hover_card_bubble_view.cc -@@ -371,7 +371,7 @@ TabHoverCardBubbleView::TabHoverCardBubbleView(Tab* ta +@@ -380,7 +380,7 @@ TabHoverCardBubbleView::TabHoverCardBubbleView(Tab* ta // not become active. Setting this to false creates the need to explicitly // hide the hovercard on press, touch, and keyboard events. SetCanActivate(false); --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) set_accept_events(false); #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__strip__combo__button.cc b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__strip__combo__button.cc new file mode 100644 index 000000000000..a40b3a551ca8 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__strip__combo__button.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/tabs/tab_strip_combo_button.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/views/tabs/tab_strip_combo_button.cc +@@ -94,7 +94,7 @@ TabStripComboButton::TabStripComboButton(BrowserWindow + base::BindRepeating(&TabStripComboButton::OnNewTabButtonStateChanged, + base::Unretained(this)))); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // The New Tab Button can be middle-clicked on Linux. + new_tab_button->SetTriggerableEventFlags( + new_tab_button->GetTriggerableEventFlags() | ui::EF_MIDDLE_MOUSE_BUTTON); diff --git a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__style__views.cc b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__style__views.cc index 98b3c483863e..80f8ce5107db 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__style__views.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_tabs_tab__style__views.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/views/tabs/tab_style_views.cc.orig 2023-10-11 18:22:24 UTC +--- chrome/browser/ui/views/tabs/tab_style_views.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/tabs/tab_style_views.cc -@@ -490,7 +490,7 @@ float GM2TabStyleViews::GetCurrentActiveOpacity() cons +@@ -573,7 +573,7 @@ float TabStyleViewsImpl::GetCurrentActiveOpacity() con if (!IsHoverAnimationActive()) { return base_opacity; } @@ -8,4 +8,4 @@ + return std::lerp(base_opacity, GetHoverOpacity(), static_cast<float>(GetHoverAnimationValue())); } - TabActive GM2TabStyleViews::GetApparentActiveState() const { + TabActive TabStyleViewsImpl::GetApparentActiveState() const { diff --git a/www/chromium/files/patch-chrome_browser_ui_views_task__manager__search__bar__view.cc b/www/chromium/files/patch-chrome_browser_ui_views_task__manager__search__bar__view.cc new file mode 100644 index 000000000000..ec0d38e359dc --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_views_task__manager__search__bar__view.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/views/task_manager_search_bar_view.cc.orig 2025-02-19 07:43:18 UTC ++++ chrome/browser/ui/views/task_manager_search_bar_view.cc +@@ -27,7 +27,7 @@ TaskManagerSearchBarView::TaskManagerSearchBarView( + const gfx::Insets& margins, + Delegate& delegate) + : delegate_(delegate) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + , + textfield_placeholder_color_id_(kColorTaskManagerSearchBarPlaceholderText) + #endif diff --git a/www/chromium/files/patch-chrome_browser_ui_views_user__education_browser__user__education__service.cc b/www/chromium/files/patch-chrome_browser_ui_views_user__education_browser__user__education__service.cc index 3beeeac49d80..f607ad0ca066 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_user__education_browser__user__education__service.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_user__education_browser__user__education__service.cc @@ -1,8 +1,17 @@ ---- chrome/browser/ui/views/user_education/browser_user_education_service.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/user_education/browser_user_education_service.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/user_education/browser_user_education_service.cc -@@ -790,7 +790,7 @@ void MaybeRegisterChromeFeaturePromos( - FeaturePromoSpecification::AcceleratorInfo()) - .SetBubbleArrow(HelpBubbleArrow::kTopLeft))); +@@ -1059,7 +1059,7 @@ void MaybeRegisterChromeFeaturePromos( + "Triggered when a shared tab becomes the active tab."))); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // kIPHSupervisedUserProfileSigninFeature + registry.RegisterFeature(std::move( + FeaturePromoSpecification::CreateForCustomAction( +@@ -1317,7 +1317,7 @@ void MaybeRegisterChromeFeaturePromos( + "Triggered to inform users of the availability of the " + "new translate screen feature on the Lens Overlay."))); -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_ui_views_web__apps_web__app__integration__test__driver.cc b/www/chromium/files/patch-chrome_browser_ui_views_web__apps_web__app__integration__test__driver.cc index 3d1d5c2b844b..ba7968b3da66 100644 --- a/www/chromium/files/patch-chrome_browser_ui_views_web__apps_web__app__integration__test__driver.cc +++ b/www/chromium/files/patch-chrome_browser_ui_views_web__apps_web__app__integration__test__driver.cc @@ -1,42 +1,42 @@ ---- chrome/browser/ui/views/web_apps/web_app_integration_test_driver.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/views/web_apps/web_app_integration_test_driver.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/views/web_apps/web_app_integration_test_driver.cc -@@ -514,7 +514,7 @@ std::string GetFileExtension(FileExtension file_extens +@@ -511,7 +511,7 @@ std::string GetFileExtension(FileExtension file_extens } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) || BUILDFLAG(IS_BSD) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) SiteConfig GetSiteConfigurationFromAppName(const std::string& app_name) { SiteConfig config; bool is_app_found = false; -@@ -2101,7 +2101,7 @@ void WebAppIntegrationTestDriver::DeletePlatformShortc +@@ -2069,7 +2069,7 @@ void WebAppIntegrationTestDriver::DeletePlatformShortc if (app_name.empty()) { app_name = GetSiteConfiguration(site).app_name; } -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - ASSERT_TRUE(override_registration_->test_override->IsShortcutCreated( + ASSERT_TRUE(override_registration_->test_override().IsShortcutCreated( profile(), app_id, app_name)); ASSERT_TRUE( -@@ -3415,7 +3415,7 @@ void WebAppIntegrationTestDriver::CheckRunOnOsLoginEna +@@ -3389,7 +3389,7 @@ void WebAppIntegrationTestDriver::CheckRunOnOsLoginEna app_state->id, app_state->name); ASSERT_TRUE(icon_color.has_value()); ASSERT_THAT(site_config.icon_color, testing::Eq(icon_color.value())); -#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - ASSERT_TRUE(override_registration_->test_override->IsRunOnOsLoginEnabled( + ASSERT_TRUE(override_registration_->test_override().IsRunOnOsLoginEnabled( profile(), app_state->id, app_state->name)); #endif -@@ -3430,7 +3430,7 @@ void WebAppIntegrationTestDriver::CheckRunOnOsLoginDis +@@ -3404,7 +3404,7 @@ void WebAppIntegrationTestDriver::CheckRunOnOsLoginDis GetAppBySiteMode(after_state_change_action_state_.get(), profile(), site); ASSERT_TRUE(app_state); base::ScopedAllowBlockingForTesting allow_blocking; -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - ASSERT_FALSE(override_registration_->test_override->IsRunOnOsLoginEnabled( + ASSERT_FALSE(override_registration_->test_override().IsRunOnOsLoginEnabled( profile(), app_state->id, app_state->name)); #endif -@@ -3440,7 +3440,7 @@ void WebAppIntegrationTestDriver::CheckRunOnOsLoginDis +@@ -3414,7 +3414,7 @@ void WebAppIntegrationTestDriver::CheckRunOnOsLoginDis void WebAppIntegrationTestDriver::CheckSiteHandlesFile( Site site, FileExtension file_extension) { @@ -45,7 +45,7 @@ if (!BeforeStateCheckAction(__FUNCTION__)) { return; } -@@ -3456,7 +3456,7 @@ void WebAppIntegrationTestDriver::CheckSiteHandlesFile +@@ -3430,7 +3430,7 @@ void WebAppIntegrationTestDriver::CheckSiteHandlesFile void WebAppIntegrationTestDriver::CheckSiteNotHandlesFile( Site site, FileExtension file_extension) { @@ -54,25 +54,25 @@ if (!BeforeStateCheckAction(__FUNCTION__)) { return; } -@@ -4279,7 +4279,7 @@ base::FilePath WebAppIntegrationTestDriver::GetShortcu +@@ -4255,7 +4255,7 @@ base::FilePath WebAppIntegrationTestDriver::GetShortcu base::FilePath shortcut_dir, const std::string& app_name, const webapps::AppId& app_id) { -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - return override_registration_->test_override->GetShortcutPath( + return override_registration_->test_override().GetShortcutPath( profile(), shortcut_dir, app_id, app_name); #else -@@ -4479,7 +4479,7 @@ bool WebAppIntegrationTestDriver::IsShortcutAndIconCre +@@ -4455,7 +4455,7 @@ bool WebAppIntegrationTestDriver::IsShortcutAndIconCre const webapps::AppId& id) { base::ScopedAllowBlockingForTesting allow_blocking; bool is_shortcut_and_icon_correct = false; -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool is_shortcut_correct = - override_registration_->test_override->IsShortcutCreated(profile, id, - name); -@@ -4523,7 +4523,7 @@ bool WebAppIntegrationTestDriver::DoIconColorsMatch(Pr + override_registration_->test_override().IsShortcutCreated(profile, id, + name); +@@ -4499,7 +4499,7 @@ bool WebAppIntegrationTestDriver::DoIconColorsMatch(Pr do_icon_colors_match = (expected_icon_pixel_color == shortcut_pixel_color_apps_folder.value()); } diff --git a/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__dialogs.h b/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__dialogs.h index b98497cb15ac..8ad9eeb10923 100644 --- a/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__dialogs.h +++ b/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__dialogs.h @@ -1,11 +1,11 @@ ---- chrome/browser/ui/web_applications/web_app_dialogs.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/web_applications/web_app_dialogs.h.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/web_applications/web_app_dialogs.h -@@ -22,7 +22,7 @@ +@@ -21,7 +21,7 @@ #include "ui/gfx/native_widget_types.h" static_assert(BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA)); -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD)); +- BUILDFLAG(IS_CHROMEOS)); ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)); class GURL; class Profile; diff --git a/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.cc b/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.cc index 489ecd4cbf54..18054983ad6b 100644 --- a/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.cc +++ b/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.cc @@ -1,7 +1,7 @@ ---- chrome/browser/ui/web_applications/web_app_ui_manager_impl.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/web_applications/web_app_ui_manager_impl.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/web_applications/web_app_ui_manager_impl.cc -@@ -586,7 +586,7 @@ void WebAppUiManagerImpl::MaybeShowIPHPromoForAppsLaun - content::WebContents* web_contents, +@@ -531,7 +531,7 @@ void WebAppUiManagerImpl::MaybeShowIPHPromoForAppsLaun + Browser* browser, Profile* profile, const std::string& app_id) { -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) @@ -9,12 +9,12 @@ WebAppProvider* provider = WebAppProvider::GetForWebApps(profile); CHECK(provider); -@@ -806,7 +806,7 @@ void WebAppUiManagerImpl::ClearWebAppSiteDataIfNeeded( +@@ -760,7 +760,7 @@ void WebAppUiManagerImpl::ClearWebAppSiteDataIfNeeded( } } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void WebAppUiManagerImpl::ShowIPHPromoForAppsLaunchedViaLinkCapturing( - const Browser* browser, - const webapps::AppId& app_id, + + const base::Feature& GetPromoFeatureEngagementFromBrowser( + const Browser* browser) { diff --git a/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.h b/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.h index ec1b77b95154..abfdb47b38af 100644 --- a/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.h +++ b/www/chromium/files/patch-chrome_browser_ui_web__applications_web__app__ui__manager__impl.h @@ -1,6 +1,6 @@ ---- chrome/browser/ui/web_applications/web_app_ui_manager_impl.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/web_applications/web_app_ui_manager_impl.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/web_applications/web_app_ui_manager_impl.h -@@ -222,7 +222,7 @@ class WebAppUiManagerImpl : public BrowserListObserver +@@ -231,7 +231,7 @@ class WebAppUiManagerImpl : public BrowserListObserver UninstallCompleteCallback uninstall_complete_callback, webapps::UninstallResultCode uninstall_code); diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.cc b/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.cc index 158b2c83da35..d192a16ffb1f 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.cc @@ -1,15 +1,24 @@ ---- chrome/browser/ui/webui/about/about_ui.cc.orig 2024-01-30 07:53:34 UTC +--- chrome/browser/ui/webui/about/about_ui.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/webui/about/about_ui.cc -@@ -592,7 +592,7 @@ std::string ChromeURLs(content::BrowserContext* browse - return html; - } +@@ -416,7 +416,7 @@ using about_ui::AppendHeader; + + namespace { -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OPENBSD) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) std::string AboutLinuxProxyConfig() { std::string data; AppendHeader(&data, -@@ -646,7 +646,7 @@ void AboutUIHTMLSource::StartDataRequest( +@@ -446,7 +446,7 @@ TermsUIConfig::TermsUIConfig() + : AboutUIConfigBase(chrome::kChromeUITermsHost) {} + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OPENBSD) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + LinuxProxyConfigUI::LinuxProxyConfigUI() + : AboutUIConfigBase(chrome::kChromeUILinuxProxyConfigHost) {} + #endif +@@ -496,7 +496,7 @@ void AboutUIHTMLSource::StartDataRequest( response = ui::ResourceBundle::GetSharedInstance().LoadDataResourceString(idr); } diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.h b/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.h new file mode 100644 index 000000000000..b51fd5a256b1 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_about_about__ui.h @@ -0,0 +1,11 @@ +--- chrome/browser/ui/webui/about/about_ui.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/about/about_ui.h +@@ -43,7 +43,7 @@ class TermsUIConfig : public AboutUIConfigBase { + }; + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OPENBSD) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // chrome://linux-proxy-config + class LinuxProxyConfigUI : public AboutUIConfigBase { + public: diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.cc index f3075d8e0560..97d2237b14cf 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.cc @@ -1,20 +1,11 @@ ---- chrome/browser/ui/webui/app_home/app_home_page_handler.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/webui/app_home/app_home_page_handler.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/webui/app_home/app_home_page_handler.cc -@@ -391,7 +391,7 @@ app_home::mojom::AppInfoPtr AppHomePageHandler::Create - app_info->start_url = start_url; +@@ -62,7 +62,7 @@ + #include "ui/base/window_open_disposition_utils.h" + #include "url/gurl.h" - bool deprecated_app = false; --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - auto* context = extension_system_->extension_service()->GetBrowserContext(); - deprecated_app = - extensions::IsExtensionUnsupportedDeprecatedApp(context, extension->id()); -@@ -454,7 +454,7 @@ void AppHomePageHandler::FillExtensionInfoList( - continue; - } +-static_assert(BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX)); ++static_assert(BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - auto* context = extension_system_->extension_service()->GetBrowserContext(); - const bool is_deprecated_app = - extensions::IsExtensionUnsupportedDeprecatedApp(context, + using content::WebUI; + using extensions::Extension; diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.h b/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.h new file mode 100644 index 000000000000..681645e54952 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_app__home_app__home__page__handler.h @@ -0,0 +1,11 @@ +--- chrome/browser/ui/webui/app_home/app_home_page_handler.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/app_home/app_home_page_handler.h +@@ -23,7 +23,7 @@ + #include "mojo/public/cpp/bindings/receiver.h" + #include "mojo/public/cpp/bindings/remote.h" + +-static_assert(BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX)); ++static_assert(BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)); + + class Browser; + class ExtensionEnableFlow; diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_app__settings_web__app__settings__ui.h b/www/chromium/files/patch-chrome_browser_ui_webui_app__settings_web__app__settings__ui.h new file mode 100644 index 000000000000..c9a6b86f7715 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_app__settings_web__app__settings__ui.h @@ -0,0 +1,18 @@ +--- chrome/browser/ui/webui/app_settings/web_app_settings_ui.h.orig 2024-11-14 07:57:23 UTC ++++ chrome/browser/ui/webui/app_settings/web_app_settings_ui.h +@@ -14,13 +14,13 @@ + #include "ui/webui/mojo_web_ui_controller.h" + #include "ui/webui/resources/cr_components/app_management/app_management.mojom-forward.h" + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/common/webui_url_constants.h" + #include "content/public/browser/webui_config.h" + #include "content/public/common/url_constants.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + class WebAppSettingsUI; + + class WebAppSettingsUIConfig diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_certificate__manager__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_certificate__manager__handler.cc new file mode 100644 index 000000000000..33b4bd9f04ea --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_certificate__manager__handler.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/webui/certificate_manager/certificate_manager_handler.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/ui/webui/certificate_manager/certificate_manager_handler.cc +@@ -221,7 +221,7 @@ CertificateManagerPageHandler::GetCertSource( + CERTIFICATE_TRUST_TYPE_DISTRUSTED, + profile_, &remote_client_); + break; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + case certificate_manager_v2::mojom::CertificateSource:: + kProvisionedClientCert: + source_ptr = CreateProvisionedClientCertSource(profile_); diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_client__cert__sources.cc b/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_client__cert__sources.cc new file mode 100644 index 000000000000..7aaf7b187f85 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_client__cert__sources.cc @@ -0,0 +1,65 @@ +--- chrome/browser/ui/webui/certificate_manager/client_cert_sources.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/certificate_manager/client_cert_sources.cc +@@ -54,7 +54,7 @@ + #include "net/ssl/client_cert_store_mac.h" + #endif // BUILDFLAG(IS_MAC) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/browser_process.h" + #include "chrome/browser/enterprise/client_certificates/certificate_provisioning_service_factory.h" + #include "chrome/browser/policy/chrome_browser_policy_connector.h" +@@ -177,7 +177,7 @@ class ClientCertStoreFactoryMac : public ClientCertSto + }; + #endif + +-#if !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) + std::unique_ptr<ClientCertStoreLoader> CreatePlatformClientCertLoader( + Profile* profile) { + #if BUILDFLAG(IS_WIN) +@@ -192,7 +192,7 @@ std::unique_ptr<ClientCertStoreLoader> CreatePlatformC + } + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // ClientCertStore implementation that always returns an empty list. The + // CertificateProvisioningService implementation expects to wrap a platform + // cert store, but here we only want to get results from the provisioning +@@ -368,7 +368,7 @@ class ClientCertSource : public CertificateManagerPage + std::optional<net::CertificateList> certs_; + }; + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // ChromeOS currently can use either Kcer or NSS for listing client certs, and + // Linux uses NSS only. This interface provides an abstraction to hide that + // from WritableClientCertSource. Currently this class only handles reading +@@ -1099,7 +1099,7 @@ CreatePlatformClientCertSource( + mojo::Remote<certificate_manager_v2::mojom::CertificateManagerPage>* + remote_client, + Profile* profile) { +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return std::make_unique<WritableClientCertSource>(remote_client, profile); + #else + return std::make_unique<ClientCertSource>( +@@ -1107,7 +1107,7 @@ CreatePlatformClientCertSource( + #endif + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<CertificateManagerPageHandler::CertSource> + CreateProvisionedClientCertSource(Profile* profile) { + return std::make_unique<ClientCertSource>( +@@ -1157,7 +1157,7 @@ bool ClientCertManagementAccessControls::IsChangeAllow + + return client_cert_policy_ == ClientCertificateManagementPermission::kAll; + } +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + ClientCertManagementAccessControls::ClientCertManagementAccessControls( + Profile* profile) {} + diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_client__cert__sources.h b/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_client__cert__sources.h new file mode 100644 index 000000000000..7b28c8bc727e --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_certificate__manager_client__cert__sources.h @@ -0,0 +1,20 @@ +--- chrome/browser/ui/webui/certificate_manager/client_cert_sources.h.orig 2025-03-05 08:14:56 UTC ++++ chrome/browser/ui/webui/certificate_manager/client_cert_sources.h +@@ -19,7 +19,7 @@ CreatePlatformClientCertSource( + remote_client, + Profile* profile); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<CertificateManagerPageHandler::CertSource> + CreateProvisionedClientCertSource(Profile* profile); + #endif +@@ -29,7 +29,7 @@ std::unique_ptr<CertificateManagerPageHandler::CertSou + CreateExtensionsClientCertSource(Profile* profile); + #endif + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + class ClientCertManagementAccessControls { + public: + enum KeyStorage { diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__configs.cc b/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__configs.cc new file mode 100644 index 000000000000..415b28486f88 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__configs.cc @@ -0,0 +1,85 @@ +--- chrome/browser/ui/webui/chrome_web_ui_configs.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/chrome_web_ui_configs.cc +@@ -148,7 +148,7 @@ + #include "chrome/browser/ui/webui/conflicts/conflicts_ui.h" + #endif // BUILDFLAG(IS_WIN) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/app_settings/web_app_settings_ui.h" + #include "chrome/browser/ui/webui/browser_switch/browser_switch_ui.h" + #include "chrome/browser/ui/webui/signin/history_sync_optin/history_sync_optin_ui.h" +@@ -156,19 +156,19 @@ + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ +- BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/sandbox/sandbox_internals_ui.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || + // BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/connectors_internals/connectors_internals_ui.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/discards/discards_ui.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) +@@ -196,7 +196,7 @@ + #include "chrome/browser/ui/webui/signin/signin_error_ui.h" + #endif // !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/on_device_translation_internals/on_device_translation_internals_ui.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +@@ -340,7 +340,7 @@ void RegisterChromeWebUIConfigs() { + map.AddWebUIConfig(std::make_unique<WebUIJsErrorUIConfig>()); + #endif // BUILDFLAG(IS_ANDROID) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OPENBSD) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + map.AddWebUIConfig(std::make_unique<LinuxProxyConfigUI>()); + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || + // BUILDFLAG(IS_OPENBSD) +@@ -370,7 +370,7 @@ void RegisterChromeWebUIConfigs() { + map.AddWebUIConfig(std::make_unique<ConflictsUIConfig>()); + #endif // BUILDFLAG(IS_WIN) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + map.AddWebUIConfig(std::make_unique<BrowserSwitchUIConfig>()); + map.AddWebUIConfig(std::make_unique<HistorySyncOptinUIConfig>()); + map.AddWebUIConfig(std::make_unique<OnDeviceTranslationInternalsUIConfig>()); +@@ -379,20 +379,20 @@ void RegisterChromeWebUIConfigs() { + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ +- BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + map.AddWebUIConfig(std::make_unique<SandboxInternalsUIConfig>()); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || + // BUILDFLAG(IS_ANDROID) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + map.AddWebUIConfig( + std::make_unique<enterprise_connectors::ConnectorsInternalsUIConfig>()); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) || BUILDFLAG(IS_BSD) + map.AddWebUIConfig(std::make_unique<DiscardsUIConfig>()); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__controller__factory.cc b/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__controller__factory.cc index ed18e457674c..e7baae19468a 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__controller__factory.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_chrome__web__ui__controller__factory.cc @@ -1,21 +1,12 @@ ---- chrome/browser/ui/webui/chrome_web_ui_controller_factory.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/webui/chrome_web_ui_controller_factory.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/webui/chrome_web_ui_controller_factory.cc -@@ -201,7 +201,7 @@ - #include "chrome/browser/ui/webui/chromeos/chrome_url_disabled/chrome_url_disabled_ui.h" - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/webui/webui_js_error/webui_js_error_ui.h" - #endif - -@@ -227,17 +227,17 @@ +@@ -117,16 +117,16 @@ #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/webui/discards/discards_ui.h" + #include "chrome/browser/ui/webui/commerce/product_specifications_ui.h" #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -24,69 +15,26 @@ #include "chrome/browser/ui/webui/sandbox/sandbox_internals_ui.h" #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "chrome/browser/ui/webui/connectors_internals/connectors_internals_ui.h" +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/webui/whats_new/whats_new_ui.h" #endif -@@ -389,7 +389,7 @@ bool IsAboutUI(const GURL& url) { - #if !BUILDFLAG(IS_ANDROID) - || url.host_piece() == chrome::kChromeUITermsHost - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OPENBSD) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - || url.host_piece() == chrome::kChromeUILinuxProxyConfigHost - #endif - #if BUILDFLAG(IS_CHROMEOS_ASH) -@@ -627,7 +627,7 @@ WebUIFactoryFunction GetWebUIFactoryFunction(WebUI* we - if (url.host_piece() == chrome::kChromeUIMobileSetupHost) - return &NewWebUI<ash::cellular_setup::MobileSetupUI>; - #endif // BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (url.host_piece() == chrome::kChromeUIWebUIJsErrorHost) - return &NewWebUI<WebUIJsErrorUI>; - #endif -@@ -683,7 +683,7 @@ WebUIFactoryFunction GetWebUIFactoryFunction(WebUI* we - if (url.host_piece() == chrome::kChromeUINaClHost) - return &NewWebUI<NaClUI>; - #endif --#if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ -+#if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && \ - defined(TOOLKIT_VIEWS)) || \ - defined(USE_AURA) - if (url.host_piece() == chrome::kChromeUITabModalConfirmDialogHost) -@@ -738,27 +738,27 @@ WebUIFactoryFunction GetWebUIFactoryFunction(WebUI* we +@@ -410,7 +410,7 @@ base::RefCountedMemory* ChromeWebUIControllerFactory:: + return NewTabPageUI::GetFaviconResourceBytes(scale_factor); } - #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - if (url.host_piece() == chrome::kChromeUISandboxHost) { - return &NewWebUI<SandboxInternalsUI>; + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (page_url.host_piece() == chrome::kChromeUIWhatsNewHost) { + return WhatsNewUI::GetFaviconResourceBytes(scale_factor); } - #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - if (url.host_piece() == chrome::kChromeUIConnectorsInternalsHost) - return &NewWebUI<enterprise_connectors::ConnectorsInternalsUI>; - #endif +@@ -449,7 +449,7 @@ base::RefCountedMemory* ChromeWebUIControllerFactory:: + } + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (url.host_piece() == chrome::kChromeUIDiscardsHost) - return &NewWebUI<DiscardsUI>; - #endif --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (url.host_piece() == chrome::kChromeUIBrowserSwitchHost) - return &NewWebUI<BrowserSwitchUI>; - #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - if (url.host_piece() == chrome::kChromeUIWebAppSettingsHost) - return &NewWebUI<WebAppSettingsUI>; - #endif + if (page_url.host_piece() == commerce::kChromeUICompareHost) { + return commerce::ProductSpecificationsUI::GetFaviconResourceBytes( + scale_factor); diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_connectors__internals__page__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_connectors__internals__page__handler.cc new file mode 100644 index 000000000000..6a928be33f93 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_connectors__internals__page__handler.cc @@ -0,0 +1,20 @@ +--- chrome/browser/ui/webui/connectors_internals/connectors_internals_page_handler.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/browser/ui/webui/connectors_internals/connectors_internals_page_handler.cc +@@ -81,7 +81,7 @@ connectors_internals::mojom::ClientIdentityPtr GetIden + } + #endif // BUILDFLAG(ENTERPRISE_CLIENT_CERTIFICATES) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::string GetStringFromTimestamp(base::Time timestamp) { + return (timestamp == base::Time()) ? std::string() + : base::UnlocalizedTimeFormatWithPattern( +@@ -190,7 +190,7 @@ void ConnectorsInternalsPageHandler::GetClientCertific + + void ConnectorsInternalsPageHandler::GetSignalsReportingState( + GetSignalsReportingStateCallback callback) { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + auto* profile_prefs = profile_->GetPrefs(); + + std::string last_upload_attempt_time_string = diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_device__trust__utils.cc b/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_device__trust__utils.cc index 6a43726189a2..09f96200046b 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_device__trust__utils.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_connectors__internals_device__trust__utils.cc @@ -1,4 +1,4 @@ ---- chrome/browser/ui/webui/connectors_internals/device_trust_utils.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/webui/connectors_internals/device_trust_utils.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/webui/connectors_internals/device_trust_utils.cc @@ -7,7 +7,7 @@ #include "build/build_config.h" @@ -9,7 +9,7 @@ #include "base/base64url.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/policy/chrome_browser_policy_connector.h" -@@ -38,7 +38,7 @@ namespace enterprise_connectors::utils { +@@ -39,7 +39,7 @@ namespace enterprise_connectors::utils { namespace { @@ -18,7 +18,7 @@ connectors_internals::mojom::KeyTrustLevel ParseTrustLevel( BPKUR::KeyTrustLevel trust_level) { -@@ -189,7 +189,7 @@ connectors_internals::mojom::CertificateMetadataPtr Co +@@ -176,7 +176,7 @@ connectors_internals::mojom::CertificateMetadataPtr Co } // namespace connectors_internals::mojom::KeyInfoPtr GetKeyInfo() { diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_interstitials_interstitial__ui.cc b/www/chromium/files/patch-chrome_browser_ui_webui_interstitials_interstitial__ui.cc new file mode 100644 index 000000000000..60a15121d8a4 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_interstitials_interstitial__ui.cc @@ -0,0 +1,29 @@ +--- chrome/browser/ui/webui/interstitials/interstitial_ui.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/interstitials/interstitial_ui.cc +@@ -77,7 +77,7 @@ + #include "components/security_interstitials/content/captive_portal_blocking_page.h" + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "chrome/browser/supervised_user/supervised_user_verification_controller_client.h" + #include "chrome/browser/supervised_user/supervised_user_verification_page_blocked_sites.h" + #include "chrome/browser/supervised_user/supervised_user_verification_page_youtube.h" +@@ -413,7 +413,7 @@ std::unique_ptr<EnterpriseWarnPage> CreateEnterpriseWa + } + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + std::unique_ptr<SupervisedUserVerificationPageForYouTube> + CreateSupervisedUserVerificationPageForYouTube( + content::WebContents* web_contents, +@@ -640,7 +640,7 @@ void InterstitialHTMLSource::StartDataRequest( + interstitial_delegate = CreateInsecureFormPage(web_contents); + } else if (path_without_query == "/https_only") { + interstitial_delegate = CreateHttpsOnlyModePage(web_contents); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + } else if (path_without_query == "/supervised-user-verify") { + interstitial_delegate = CreateSupervisedUserVerificationPageForYouTube( + web_contents, /*is_main_frame=*/true); diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui.cc b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui.cc index 2fab48becb48..1a2a23e2d105 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui.cc @@ -1,8 +1,8 @@ ---- chrome/browser/ui/webui/management/management_ui.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/webui/management/management_ui.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/browser/ui/webui/management/management_ui.cc -@@ -98,11 +98,11 @@ content::WebUIDataSource* CreateAndAddManagementUIHtml - {kManagementOnFileTransferVisibleData, +@@ -181,11 +181,11 @@ void ManagementUI::GetLocalizedStrings( IDS_MANAGEMENT_FILE_TRANSFER_VISIBLE_DATA}, + {kManagementReportFileEvents, IDS_MANAGEMENT_REPORT_FILE_EVENTS}, #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__constants.cc b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__constants.cc new file mode 100644 index 000000000000..815960a09d92 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__constants.cc @@ -0,0 +1,17 @@ +--- chrome/browser/ui/webui/management/management_ui_constants.cc.orig 2024-11-14 07:57:23 UTC ++++ chrome/browser/ui/webui/management/management_ui_constants.cc +@@ -89,12 +89,12 @@ const char kProfileReportingExtension[] = "profileRepo + const char kProfileReportingPolicy[] = "profileReportingPolicy"; + const char kProfileReportingLearnMore[] = "profileReportingLearnMore"; + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char kManagementScreenCaptureEvent[] = "managementScreenCaptureEvent"; + const char kManagementScreenCaptureData[] = "managementScreenCaptureData"; + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char kManagementDeviceSignalsDisclosure[] = + "managementDeviceSignalsDisclosure"; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__constants.h b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__constants.h new file mode 100644 index 000000000000..6af7774f39c1 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__constants.h @@ -0,0 +1,19 @@ +--- chrome/browser/ui/webui/management/management_ui_constants.h.orig 2025-02-19 07:43:18 UTC ++++ chrome/browser/ui/webui/management/management_ui_constants.h +@@ -7,14 +7,14 @@ + + #include "build/build_config.h" + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Constants defining the IDs for the localized strings sent to the page as + // load time data. + extern const char kManagementScreenCaptureEvent[]; + extern const char kManagementScreenCaptureData[]; + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extern const char kManagementDeviceSignalsDisclosure[]; + #endif // #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.cc index 340597042cc1..8cfe7622ce14 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.cc @@ -1,48 +1,33 @@ ---- chrome/browser/ui/webui/management/management_ui_handler.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/webui/management/management_ui_handler.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/ui/webui/management/management_ui_handler.cc -@@ -95,7 +95,7 @@ - #include "components/policy/core/common/cloud/user_cloud_policy_manager.h" - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +@@ -58,7 +58,7 @@ + #include "ui/base/l10n/l10n_util.h" + #include "ui/base/webui/web_ui_util.h" -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "chrome/browser/enterprise/signals/user_permission_service_factory.h" #include "components/device_signals/core/browser/user_permission_service.h" // nogncheck #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -@@ -191,12 +191,12 @@ enum class ReportingType { - kLegacyTech, - }; - --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const char kManagementScreenCaptureEvent[] = "managementScreenCaptureEvent"; - const char kManagementScreenCaptureData[] = "managementScreenCaptureData"; - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +@@ -359,7 +359,7 @@ void ManagementUIHandler::AddReportingInfo(base::Value + report_sources->Append(std::move(data)); + } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const char kManagementDeviceSignalsDisclosure[] = - "managementDeviceSignalsDisclosure"; - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -@@ -830,7 +830,7 @@ void ManagementUIHandler::AddReportingInfo(base::Value - GetReportingTypeValue(report_definition.reporting_type)); - report_sources->Append(std::move(data)); - } + auto device_signal_data = GetDeviceSignalGrantedMessage(); + if (!device_signal_data.empty()) { + report_sources->Append(std::move(device_signal_data)); +@@ -381,7 +381,7 @@ void ManagementUIHandler::AddReportingInfo(base::Value + report_sources->Append(std::move(data)); + } + -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Insert the device signals consent disclosure at the end of browser - // reporting section. - auto* user_permission_service = GetUserPermissionService(); -@@ -1118,7 +1118,7 @@ base::Value::Dict ManagementUIHandler::GetThreatProtec - kManagementOnPageVisitedVisibleData, &info); - } - --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (capture_policy::IsGetAllScreensMediaAllowedForAnySite(profile)) { - AddThreatProtectionPermission(kManagementScreenCaptureEvent, - kManagementScreenCaptureData, &info); -@@ -1202,7 +1202,7 @@ policy::PolicyService* ManagementUIHandler::GetPolicyS + auto device_signal_data = GetDeviceSignalGrantedMessage(); + if (!device_signal_data.empty()) { + report_sources->Append(std::move(device_signal_data)); +@@ -567,7 +567,7 @@ policy::PolicyService* ManagementUIHandler::GetPolicyS ->policy_service(); } diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.h b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.h index 0b93311c4f4b..ed4fe91cb02c 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.h +++ b/www/chromium/files/patch-chrome_browser_ui_webui_management_management__ui__handler.h @@ -1,24 +1,7 @@ ---- chrome/browser/ui/webui/management/management_ui_handler.h.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/webui/management/management_ui_handler.h.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/webui/management/management_ui_handler.h -@@ -24,14 +24,14 @@ - #include "extensions/common/extension_id.h" - #include "url/gurl.h" - --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Constants defining the IDs for the localized strings sent to the page as - // load time data. - extern const char kManagementScreenCaptureEvent[]; - extern const char kManagementScreenCaptureData[]; - #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - extern const char kManagementDeviceSignalsDisclosure[]; - #endif // #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - -@@ -119,7 +119,7 @@ class StatusCollector; - class SystemLogUploader; +@@ -29,7 +29,7 @@ namespace policy { + class PolicyService; } // namespace policy -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) @@ -26,12 +9,12 @@ namespace device_signals { class UserPermissionService; } // namespace device_signals -@@ -179,7 +179,7 @@ class ManagementUIHandler : public content::WebUIMessa +@@ -70,7 +70,7 @@ class ManagementUIHandler : public content::WebUIMessa base::Value::List GetManagedWebsitesInfo(Profile* profile) const; base::Value::List GetApplicationsInfo(Profile* profile) const; virtual policy::PolicyService* GetPolicyService(); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) virtual device_signals::UserPermissionService* GetUserPermissionService(); + base::Value::Dict GetDeviceSignalGrantedMessage(); #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_password__manager_promo__cards__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_password__manager_promo__cards__handler.cc index e12a440b44db..9b1f8e5dd826 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_password__manager_promo__cards__handler.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_password__manager_promo__cards__handler.cc @@ -1,4 +1,4 @@ ---- chrome/browser/ui/webui/password_manager/promo_cards_handler.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/ui/webui/password_manager/promo_cards_handler.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/ui/webui/password_manager/promo_cards_handler.cc @@ -28,7 +28,7 @@ #include "chrome/browser/ui/webui/password_manager/promo_cards/web_password_manager_promo.h" diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_searchbox_searchbox__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_searchbox_searchbox__handler.cc new file mode 100644 index 000000000000..a349bf185a40 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_searchbox_searchbox__handler.cc @@ -0,0 +1,29 @@ +--- chrome/browser/ui/webui/searchbox/searchbox_handler.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/searchbox/searchbox_handler.cc +@@ -120,7 +120,7 @@ const char* kMacShareIconResourceName = + #elif BUILDFLAG(IS_WIN) + const char* kWinShareIconResourceName = + "//resources/cr_components/searchbox/icons/win_share.svg"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + const char* kLinuxShareIconResourceName = + "//resources/cr_components/searchbox/icons/share.svg"; + #else +@@ -180,7 +180,7 @@ static void DefineChromeRefreshRealboxIcons() { + #elif BUILDFLAG(IS_WIN) + kWinShareIconResourceName = + "//resources/cr_components/searchbox/icons/win_share_cr23.svg"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + kLinuxShareIconResourceName = + "//resources/cr_components/searchbox/icons/share_cr23.svg"; + #else +@@ -634,7 +634,7 @@ std::string SearchboxHandler::ActionVectorIconToResour + icon.name == omnibox::kShareWinChromeRefreshIcon.name) { + return kWinShareIconResourceName; + } +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (icon.name == omnibox::kShareIcon.name || + icon.name == omnibox::kShareLinuxChromeRefreshIcon.name) { + return kLinuxShareIconResourceName; diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_settings_accessibility__main__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_settings_accessibility__main__handler.cc deleted file mode 100644 index 754f256ed6a3..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_webui_settings_accessibility__main__handler.cc +++ /dev/null @@ -1,46 +0,0 @@ ---- chrome/browser/ui/webui/settings/accessibility_main_handler.cc.orig 2024-02-23 21:04:38 UTC -+++ chrome/browser/ui/webui/settings/accessibility_main_handler.cc -@@ -19,7 +19,7 @@ - #include "content/public/browser/web_contents.h" - #include "content/public/browser/web_ui.h" - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - #include "ui/accessibility/accessibility_features.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) - -@@ -39,7 +39,7 @@ void AccessibilityMainHandler::RegisterMessages() { - base::BindRepeating( - &AccessibilityMainHandler::HandleCheckAccessibilityImageLabels, - base::Unretained(this))); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - web_ui()->RegisterMessageCallback( - "getScreenAiInstallState", - base::BindRepeating( -@@ -56,7 +56,7 @@ void AccessibilityMainHandler::OnJavascriptAllowed() { - base::Unretained(this))); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - if (features::IsPdfOcrEnabled()) { - CHECK(!component_ready_observer_.IsObserving()); - component_ready_observer_.Observe( -@@ -70,14 +70,14 @@ void AccessibilityMainHandler::OnJavascriptDisallowed( - accessibility_subscription_ = {}; - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - if (features::IsPdfOcrEnabled()) { - component_ready_observer_.Reset(); - } - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) - } - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - void AccessibilityMainHandler::DownloadProgressChanged(double progress) { - CHECK_GE(progress, 0.0); - CHECK_LE(progress, 1.0); diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_settings_accessibility__main__handler.h b/www/chromium/files/patch-chrome_browser_ui_webui_settings_accessibility__main__handler.h deleted file mode 100644 index b9ec3bafed68..000000000000 --- a/www/chromium/files/patch-chrome_browser_ui_webui_settings_accessibility__main__handler.h +++ /dev/null @@ -1,47 +0,0 @@ ---- chrome/browser/ui/webui/settings/accessibility_main_handler.h.orig 2024-02-23 21:04:38 UTC -+++ chrome/browser/ui/webui/settings/accessibility_main_handler.h -@@ -13,7 +13,7 @@ - #include "chrome/browser/ash/accessibility/accessibility_manager.h" - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - #include "base/scoped_observation.h" - #include "chrome/browser/screen_ai/screen_ai_install_state.h" - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -@@ -24,7 +24,7 @@ namespace settings { - // chrome://settings/accessibility. - class AccessibilityMainHandler - : public ::settings::SettingsPageUIHandler --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - , - public screen_ai::ScreenAIInstallState::Observer - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -@@ -40,7 +40,7 @@ class AccessibilityMainHandler - void OnJavascriptAllowed() override; - void OnJavascriptDisallowed() override; - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - // screen_ai::ScreenAIInstallState::Observer: - void DownloadProgressChanged(double progress) override; - void StateChanged(screen_ai::ScreenAIInstallState::State state) override; -@@ -50,7 +50,7 @@ class AccessibilityMainHandler - void HandleGetScreenReaderState(const base::Value::List& args); - void HandleCheckAccessibilityImageLabels(const base::Value::List& args); - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - void HandleGetScreenAIInstallState(const base::Value::List& args); - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) - -@@ -63,7 +63,7 @@ class AccessibilityMainHandler - base::CallbackListSubscription accessibility_subscription_; - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - base::ScopedObservation<screen_ai::ScreenAIInstallState, - screen_ai::ScreenAIInstallState::Observer> - component_ready_observer_{this}; diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_settings_appearance__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_settings_appearance__handler.cc index f744fa8fd2d3..b46aa2088327 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_settings_appearance__handler.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_settings_appearance__handler.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/webui/settings/appearance_handler.cc.orig 2022-10-24 13:33:33 UTC +--- chrome/browser/ui/webui/settings/appearance_handler.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/browser/ui/webui/settings/appearance_handler.cc -@@ -28,7 +28,7 @@ void AppearanceHandler::RegisterMessages() { +@@ -32,7 +32,7 @@ void AppearanceHandler::RegisterMessages() { "useDefaultTheme", base::BindRepeating(&AppearanceHandler::HandleUseTheme, base::Unretained(this), ui::SystemTheme::kDefault)); diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_settings_settings__localized__strings__provider.cc b/www/chromium/files/patch-chrome_browser_ui_webui_settings_settings__localized__strings__provider.cc index ac49a8f73a28..4149426a1653 100644 --- a/www/chromium/files/patch-chrome_browser_ui_webui_settings_settings__localized__strings__provider.cc +++ b/www/chromium/files/patch-chrome_browser_ui_webui_settings_settings__localized__strings__provider.cc @@ -1,65 +1,65 @@ ---- chrome/browser/ui/webui/settings/settings_localized_strings_provider.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/ui/webui/settings/settings_localized_strings_provider.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/webui/settings/settings_localized_strings_provider.cc -@@ -138,7 +138,7 @@ - #include "ash/webui/settings/public/constants/routes.mojom.h" +@@ -139,7 +139,7 @@ + #include "chrome/browser/ui/webui/settings/system_handler.h" #endif --#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !BUILDFLAG(IS_CHROMEOS_LACROS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "ui/display/screen.h" #endif -@@ -157,7 +157,7 @@ - #include "chrome/browser/ui/webui/certificate_manager_localized_strings_provider.h" - #endif +@@ -154,7 +154,7 @@ + #endif // BUILDFLAG(GOOGLE_CHROME_BRANDING) + #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "ui/linux/linux_ui_factory.h" #include "ui/ozone/public/ozone_platform.h" #endif -@@ -260,7 +260,7 @@ void AddCommonStrings(content::WebUIDataSource* html_s - - html_source->AddBoolean("isChildAccount", profile->IsChild()); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - bool allow_qt_theme = base::FeatureList::IsEnabled(ui::kAllowQt); - #else - bool allow_qt_theme = false; -@@ -290,7 +290,7 @@ void AddA11yStrings(content::WebUIDataSource* html_sou - {"focusHighlightLabel", - IDS_SETTINGS_ACCESSIBILITY_FOCUS_HIGHLIGHT_DESCRIPTION}, +@@ -283,7 +283,7 @@ void AddA11yStrings(content::WebUIDataSource* html_sou + {"toastAlertLevelDescription", + IDS_SETTINGS_ACCESSIBILITY_TOAST_FREQUENCY_DESCRIPTION}, #endif -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) {"overscrollHistoryNavigationTitle", IDS_SETTINGS_OVERSCROLL_HISTORY_NAVIGATION_TITLE}, {"overscrollHistoryNavigationSubtitle", -@@ -433,7 +433,7 @@ void AddAppearanceStrings(content::WebUIDataSource* ht - {"huge", IDS_SETTINGS_HUGE_FONT_SIZE}, - {"sidePanelAlignLeft", IDS_SETTINGS_SIDE_PANEL_ALIGN_LEFT}, - {"sidePanelAlignRight", IDS_SETTINGS_SIDE_PANEL_ALIGN_RIGHT}, +@@ -553,7 +553,7 @@ void AddAppearanceStrings(content::WebUIDataSource* ht + {"uiFeatureAlignLeft", IDS_SETTINGS_UI_FEATURE_ALIGN_LEFT}, + {"uiFeatureAlignRight", IDS_SETTINGS_UI_FEATURE_ALIGN_RIGHT}, + {"resetToDefault", IDS_SETTINGS_RESET_TO_DEFAULT}, -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) {"gtkTheme", IDS_SETTINGS_GTK_THEME}, {"useGtkTheme", IDS_SETTINGS_USE_GTK_THEME}, {"qtTheme", IDS_SETTINGS_QT_THEME}, -@@ -443,7 +443,7 @@ void AddAppearanceStrings(content::WebUIDataSource* ht - #else - {"resetToDefaultTheme", IDS_SETTINGS_RESET_TO_DEFAULT_THEME}, +@@ -561,7 +561,7 @@ void AddAppearanceStrings(content::WebUIDataSource* ht + {"classicTheme", IDS_SETTINGS_CLASSIC_THEME}, + {"useClassicTheme", IDS_SETTINGS_USE_CLASSIC_THEME}, #endif --#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !BUILDFLAG(IS_CHROMEOS_LACROS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) {"showWindowDecorations", IDS_SHOW_WINDOW_DECORATIONS}, #endif #if BUILDFLAG(IS_MAC) -@@ -468,7 +468,7 @@ void AddAppearanceStrings(content::WebUIDataSource* ht +@@ -583,7 +583,7 @@ void AddAppearanceStrings(content::WebUIDataSource* ht + html_source->AddBoolean("tabSearchIsRightAlignedAtStartup", + tabs::GetTabSearchTrailingTabstrip(profile)); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !BUILDFLAG(IS_CHROMEOS_LACROS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool show_custom_chrome_frame = ui::OzonePlatform::GetInstance() ->GetPlatformRuntimeProperties() .supports_server_side_window_decorations; +@@ -1513,7 +1513,7 @@ void AddSignOutDialogStrings(content::WebUIDataSource* + g_browser_process->GetApplicationLocale()) + .spec(); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + html_source->AddString( + "syncDisconnectManagedProfileExplanation", + l10n_util::GetStringFUTF8( diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_signin_profile__picker__handler.cc b/www/chromium/files/patch-chrome_browser_ui_webui_signin_profile__picker__handler.cc new file mode 100644 index 000000000000..a5d7e4950cde --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_signin_profile__picker__handler.cc @@ -0,0 +1,11 @@ +--- chrome/browser/ui/webui/signin/profile_picker_handler.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/ui/webui/signin/profile_picker_handler.cc +@@ -165,7 +165,7 @@ base::Value::Dict CreateProfileEntry(const ProfileAttr + IDS_PROFILE_PICKER_PROFILE_CARD_LABEL, local_profile_name); + if (AccountInfo::IsManaged(entry->GetHostedDomain())) { + profile_entry.Set("avatarBadge", "cr:domain"); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + } else if (base::FeatureList::IsEnabled( + supervised_user::kShowKiteForSupervisedUsers) && + entry->IsSupervised()) { diff --git a/www/chromium/files/patch-chrome_browser_ui_webui_user__education__internals_user__education__internals__page__handler__impl.cc b/www/chromium/files/patch-chrome_browser_ui_webui_user__education__internals_user__education__internals__page__handler__impl.cc new file mode 100644 index 000000000000..109de189f155 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_ui_webui_user__education__internals_user__education__internals__page__handler__impl.cc @@ -0,0 +1,29 @@ +--- chrome/browser/ui/webui/user_education_internals/user_education_internals_page_handler_impl.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/ui/webui/user_education_internals/user_education_internals_page_handler_impl.cc +@@ -45,7 +45,7 @@ + #include "ui/base/l10n/l10n_util.h" + #include "ui/base/webui/resource_path.h" + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "chrome/browser/ui/browser_navigator.h" + #include "chrome/browser/ui/browser_navigator_params.h" + #include "net/base/url_util.h" +@@ -85,7 +85,7 @@ user_education::NewBadgeRegistry* GetNewBadgeRegistry( + } + + whats_new::WhatsNewRegistry* GetWhatsNewRegistry() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return g_browser_process->GetFeatures()->whats_new_registry(); + #else + return nullptr; +@@ -821,7 +821,7 @@ void UserEducationInternalsPageHandlerImpl::ClearWhats + } + + void UserEducationInternalsPageHandlerImpl::LaunchWhatsNewStaging() { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + GURL url = net::AppendQueryParameter(GURL(chrome::kChromeUIWhatsNewURL), + "staging", "true"); + NavigateParams params(profile_, url, ui::PAGE_TRANSITION_TYPED); diff --git a/www/chromium/files/patch-chrome_browser_ui_window__sizer_window__sizer.cc b/www/chromium/files/patch-chrome_browser_ui_window__sizer_window__sizer.cc index c5ca00256bad..75565d9ac98c 100644 --- a/www/chromium/files/patch-chrome_browser_ui_window__sizer_window__sizer.cc +++ b/www/chromium/files/patch-chrome_browser_ui_window__sizer_window__sizer.cc @@ -1,6 +1,6 @@ ---- chrome/browser/ui/window_sizer/window_sizer.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/ui/window_sizer/window_sizer.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/ui/window_sizer/window_sizer.cc -@@ -216,7 +216,7 @@ void WindowSizer::GetBrowserWindowBoundsAndShowState( +@@ -219,7 +219,7 @@ void WindowSizer::GetBrowserWindowBoundsAndShowState( browser, window_bounds, show_state); } diff --git a/www/chromium/files/patch-chrome_browser_upgrade__detector_version__history__client.cc b/www/chromium/files/patch-chrome_browser_upgrade__detector_version__history__client.cc new file mode 100644 index 000000000000..6f46683174aa --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_upgrade__detector_version__history__client.cc @@ -0,0 +1,11 @@ +--- chrome/browser/upgrade_detector/version_history_client.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/upgrade_detector/version_history_client.cc +@@ -175,7 +175,7 @@ GURL GetVersionReleasesUrl(base::Version version) { + #define CURRENT_PLATFORM "win" + #endif + +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + + #define CURRENT_PLATFORM "linux" + diff --git a/www/chromium/files/patch-chrome_browser_visited__url__ranking_visited__url__ranking__service__factory.cc b/www/chromium/files/patch-chrome_browser_visited__url__ranking_visited__url__ranking__service__factory.cc new file mode 100644 index 000000000000..31b5b76c76ca --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_visited__url__ranking_visited__url__ranking__service__factory.cc @@ -0,0 +1,20 @@ +--- chrome/browser/visited_url_ranking/visited_url_ranking_service_factory.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/visited_url_ranking/visited_url_ranking_service_factory.cc +@@ -45,7 +45,7 @@ + #include "components/visited_url_ranking/public/visited_url_ranking_service.h" + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "chrome/browser/visited_url_ranking/desktop_tab_model_url_visit_data_fetcher.h" + #elif BUILDFLAG(IS_ANDROID) + #include "chrome/browser/visited_url_ranking/android_tab_model_url_visit_data_fetcher.h" +@@ -119,7 +119,7 @@ VisitedURLRankingServiceFactory::BuildServiceInstanceF + + std::map<Fetcher, std::unique_ptr<URLVisitDataFetcher>> data_fetchers; + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + data_fetchers.emplace( + Fetcher::kTabModel, + std::make_unique<visited_url_ranking::DesktopTabModelURLVisitDataFetcher>( diff --git a/www/chromium/files/patch-chrome_browser_web__applications_commands_install__app__locally__command.cc b/www/chromium/files/patch-chrome_browser_web__applications_commands_install__app__locally__command.cc deleted file mode 100644 index a5b3ad64c4d7..000000000000 --- a/www/chromium/files/patch-chrome_browser_web__applications_commands_install__app__locally__command.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/browser/web_applications/commands/install_app_locally_command.cc.orig 2024-02-23 21:04:38 UTC -+++ chrome/browser/web_applications/commands/install_app_locally_command.cc -@@ -75,7 +75,7 @@ void InstallAppLocallyCommand::StartWithLock( - options.os_hooks[OsHookType::kUninstallationViaOsSettings] = - web_app->CanUserUninstallWebApp(); - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS)) - options.os_hooks[web_app::OsHookType::kUrlHandlers] = true; - #else diff --git a/www/chromium/files/patch-chrome_browser_web__applications_commands_launch__web__app__command.cc b/www/chromium/files/patch-chrome_browser_web__applications_commands_launch__web__app__command.cc new file mode 100644 index 000000000000..34a86c58746a --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_web__applications_commands_launch__web__app__command.cc @@ -0,0 +1,11 @@ +--- chrome/browser/web_applications/commands/launch_web_app_command.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/browser/web_applications/commands/launch_web_app_command.cc +@@ -101,7 +101,7 @@ void LaunchWebAppCommand::StartWithLock(std::unique_pt + // OsIntegrationTestOverride can use the xdg install command to detect + // install. + SynchronizeOsOptions options; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + options.add_shortcut_to_desktop = true; + #endif + lock_->os_integration_manager().Synchronize( diff --git a/www/chromium/files/patch-chrome_browser_web__applications_commands_set__user__display__mode__command.cc b/www/chromium/files/patch-chrome_browser_web__applications_commands_set__user__display__mode__command.cc new file mode 100644 index 000000000000..80efce56a6b2 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_web__applications_commands_set__user__display__mode__command.cc @@ -0,0 +1,11 @@ +--- chrome/browser/web_applications/commands/set_user_display_mode_command.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/web_applications/commands/set_user_display_mode_command.cc +@@ -56,7 +56,7 @@ void SetUserDisplayModeCommand::StartWithLock( + // OsIntegrationTestOverride can use the xdg install command to detect + // install. + SynchronizeOsOptions options; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + options.add_shortcut_to_desktop = true; + #endif + app_lock_->os_integration_manager().Synchronize( diff --git a/www/chromium/files/patch-chrome_browser_web__applications_extension__status__utils.h b/www/chromium/files/patch-chrome_browser_web__applications_extension__status__utils.h index 4e4891829d10..e71a34daeccb 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_extension__status__utils.h +++ b/www/chromium/files/patch-chrome_browser_web__applications_extension__status__utils.h @@ -1,8 +1,8 @@ ---- chrome/browser/web_applications/extension_status_utils.h.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/web_applications/extension_status_utils.h.orig 2024-09-30 07:45:04 UTC +++ chrome/browser/web_applications/extension_status_utils.h -@@ -55,7 +55,7 @@ bool IsExternalExtensionUninstalled(content::BrowserCo - bool ClearExternalExtensionUninstalled(content::BrowserContext* context, - const std::string& extension_id); +@@ -50,7 +50,7 @@ bool IsExtensionDefaultInstalled(content::BrowserConte + bool IsExternalExtensionUninstalled(content::BrowserContext* context, + const std::string& extension_id); -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_web__applications_extensions_extension__status__utils.cc b/www/chromium/files/patch-chrome_browser_web__applications_extensions_extension__status__utils.cc index daa2195539c9..f587fdcba7b4 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_extensions_extension__status__utils.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_extensions_extension__status__utils.cc @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/extensions/extension_status_utils.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/web_applications/extensions/extension_status_utils.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/web_applications/extensions/extension_status_utils.cc -@@ -25,7 +25,7 @@ namespace { +@@ -26,7 +26,7 @@ namespace { const char* g_preinstalled_app_for_testing = nullptr; @@ -9,8 +9,8 @@ // TODO(b/268221237): Remove this allow-list. const char kDefaultAllowedExtensionIds[] = "alhngdkjgnedakdlnamimgfihgkmenbh," -@@ -114,7 +114,7 @@ bool ClearExternalExtensionUninstalled(content::Browse - extension_id); +@@ -105,7 +105,7 @@ bool IsExternalExtensionUninstalled(content::BrowserCo + return prefs && prefs->IsExternalExtensionUninstalled(extension_id); } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut__manager.cc b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_os__integration__manager.cc index 80cf5431f7c3..5c54ea96019d 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut__manager.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_os__integration__manager.cc @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/os_integration/web_app_shortcut_manager.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/web_applications/os_integration/web_app_shortcut_manager.cc -@@ -441,7 +441,7 @@ std::unique_ptr<ShortcutInfo> WebAppShortcutManager::B +--- chrome/browser/web_applications/os_integration/os_integration_manager.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/web_applications/os_integration/os_integration_manager.cc +@@ -662,7 +662,7 @@ std::unique_ptr<ShortcutInfo> OsIntegrationManager::Bu } } diff --git a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_os__integration__test__override.h b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_os__integration__test__override.h index 34caa5afede8..0c8c0325709e 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_os__integration__test__override.h +++ b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_os__integration__test__override.h @@ -1,11 +1,11 @@ ---- chrome/browser/web_applications/os_integration/os_integration_test_override.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/web_applications/os_integration/os_integration_test_override.h.orig 2024-06-17 12:56:06 UTC +++ chrome/browser/web_applications/os_integration/os_integration_test_override.h -@@ -92,7 +92,7 @@ class OsIntegrationTestOverride - virtual const base::FilePath& chrome_apps_folder() = 0; +@@ -99,7 +99,7 @@ class OsIntegrationTestOverride + virtual base::FilePath chrome_apps_folder() = 0; virtual void EnableOrDisablePathOnLogin(const base::FilePath& file_path, bool enable_on_login) = 0; -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - virtual const base::FilePath& desktop() = 0; - virtual const base::FilePath& startup() = 0; - virtual const base::FilePath& applications_dir() = 0; + virtual base::Environment* environment() = 0; + #endif + diff --git a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_run__on__os__login__sub__manager.cc b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_run__on__os__login__sub__manager.cc index cbb89ec1b21f..f15b08428f30 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_run__on__os__login__sub__manager.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_run__on__os__login__sub__manager.cc @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/os_integration/run_on_os_login_sub_manager.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/web_applications/os_integration/run_on_os_login_sub_manager.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/web_applications/os_integration/run_on_os_login_sub_manager.cc -@@ -54,7 +54,7 @@ proto::RunOnOsLoginMode ConvertWebAppRunOnOsLoginModeT +@@ -54,7 +54,7 @@ proto::os_state::RunOnOsLogin::Mode ConvertWebAppRunOn // different from other platforms, see web_app_run_on_os_login_manager.h for // more info. bool DoesRunOnOsLoginRequireExecution() { diff --git a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_shortcut__sub__manager.cc b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_shortcut__sub__manager.cc index 358621e94919..a6bba21078ae 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_shortcut__sub__manager.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_shortcut__sub__manager.cc @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/os_integration/shortcut_sub_manager.cc.orig 2023-10-11 18:22:24 UTC +--- chrome/browser/web_applications/os_integration/shortcut_sub_manager.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/browser/web_applications/os_integration/shortcut_sub_manager.cc -@@ -182,7 +182,7 @@ void ShortcutSubManager::Execute( +@@ -199,7 +199,7 @@ void ShortcutSubManager::Execute( return; } diff --git a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.cc b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.cc index 37de3416c8b8..cd0347154641 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.cc @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/os_integration/web_app_shortcut.cc.orig 2023-09-13 12:11:42 UTC +--- chrome/browser/web_applications/os_integration/web_app_shortcut.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/browser/web_applications/os_integration/web_app_shortcut.cc -@@ -65,7 +65,7 @@ namespace { +@@ -71,7 +71,7 @@ namespace { #if BUILDFLAG(IS_MAC) const int kDesiredIconSizesForShortcut[] = {16, 32, 128, 256, 512}; @@ -9,9 +9,9 @@ // Linux supports icons of any size. FreeDesktop Icon Theme Specification states // that "Minimally you should install a 48x48 icon in the hicolor theme." const int kDesiredIconSizesForShortcut[] = {16, 32, 48, 128, 256, 512}; -@@ -227,7 +227,7 @@ std::unique_ptr<ShortcutInfo> BuildShortcutInfoWithout +@@ -253,7 +253,7 @@ std::unique_ptr<ShortcutInfo> BuildShortcutInfoWithout - // TODO(crbug.com/1416965): Implement tests on Linux for using shortcuts_menu + // TODO(crbug.com/40257107): Implement tests on Linux for using shortcuts_menu // actions. -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.h b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.h index bbeea69bfa93..e5f9174dad34 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.h +++ b/www/chromium/files/patch-chrome_browser_web__applications_os__integration_web__app__shortcut.h @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/os_integration/web_app_shortcut.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/web_applications/os_integration/web_app_shortcut.h.orig 2025-05-05 10:57:53 UTC +++ chrome/browser/web_applications/os_integration/web_app_shortcut.h -@@ -21,7 +21,7 @@ +@@ -22,7 +22,7 @@ #include "ui/gfx/image/image_family.h" #include "url/gurl.h" @@ -9,10 +9,10 @@ #include "chrome/browser/web_applications/os_integration/web_app_shortcut_linux.h" #endif // BUILDFLAG(IS_LINUX) -@@ -70,7 +70,7 @@ struct ShortcutInfo { - std::set<std::string> file_handler_extensions; - std::set<std::string> file_handler_mime_types; - std::set<std::string> protocol_handlers; +@@ -77,7 +77,7 @@ struct ShortcutInfo { + // the installed PWA experience and thus the icons are not designed to be + // displayed on an OS dock. + bool is_diy_app = false; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) std::set<DesktopActionInfo> actions; diff --git a/www/chromium/files/patch-chrome_browser_web__applications_policy_web__app__policy__manager.cc b/www/chromium/files/patch-chrome_browser_web__applications_policy_web__app__policy__manager.cc index 0745dcde1a70..3aa180b6d795 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_policy_web__app__policy__manager.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_policy_web__app__policy__manager.cc @@ -1,4 +1,4 @@ ---- chrome/browser/web_applications/policy/web_app_policy_manager.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/web_applications/policy/web_app_policy_manager.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/web_applications/policy/web_app_policy_manager.cc @@ -111,7 +111,7 @@ namespace web_app { diff --git a/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.cc b/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.cc index c2a25f4fb3d6..07e313dd77c3 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.cc @@ -1,15 +1,24 @@ ---- chrome/browser/web_applications/test/os_integration_test_override_impl.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/browser/web_applications/test/os_integration_test_override_impl.cc.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/web_applications/test/os_integration_test_override_impl.cc -@@ -127,7 +127,7 @@ std::vector<std::wstring> GetFileExtensionsForProgId( +@@ -45,7 +45,7 @@ + #include "third_party/skia/include/core/SkBitmap.h" + #include "third_party/skia/include/core/SkColor.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "base/nix/xdg_util.h" + #endif + +@@ -130,7 +130,7 @@ std::vector<std::wstring> GetFileExtensionsForProgId( } #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Performs a blocking read of app icons from the disk. - SkColor IconManagerReadIconTopLeftColorForSize(WebAppIconManager& icon_manager, - const webapps::AppId& app_id, -@@ -224,7 +224,7 @@ bool OsIntegrationTestOverrideImpl::SimulateDeleteShor + std::optional<SkBitmap> IconManagerReadIconForSize( + WebAppIconManager& icon_manager, +@@ -315,7 +315,7 @@ bool OsIntegrationTestOverrideImpl::SimulateDeleteShor GetShortcutPath(profile, chrome_apps_folder(), app_id, app_name); CHECK(base::PathExists(app_folder_shortcut_path)); return base::DeletePathRecursively(app_folder_shortcut_path); @@ -18,7 +27,7 @@ base::FilePath desktop_shortcut_path = GetShortcutPath(profile, desktop(), app_id, app_name); LOG(INFO) << desktop_shortcut_path; -@@ -264,7 +264,7 @@ bool OsIntegrationTestOverrideImpl::DeleteApplicationM +@@ -362,7 +362,7 @@ bool OsIntegrationTestOverrideImpl::DeleteApplicationM } #endif // BUILDFLAG(IS_WIN) @@ -27,7 +36,7 @@ bool OsIntegrationTestOverrideImpl::DeleteDesktopDirOnLinux() { if (desktop_.IsValid()) { return desktop_.Delete(); -@@ -278,7 +278,7 @@ bool OsIntegrationTestOverrideImpl::IsRunOnOsLoginEnab +@@ -376,7 +376,7 @@ bool OsIntegrationTestOverrideImpl::IsRunOnOsLoginEnab Profile* profile, const webapps::AppId& app_id, const std::string& app_name) { @@ -36,25 +45,25 @@ std::string shortcut_filename = "chrome-" + app_id + "-" + profile->GetBaseName().value() + ".desktop"; return base::PathExists(startup().Append(shortcut_filename)); -@@ -334,7 +334,7 @@ bool OsIntegrationTestOverrideImpl::IsFileExtensionHan +@@ -431,7 +431,7 @@ bool OsIntegrationTestOverrideImpl::IsFileExtensionHan is_file_handled = shell_integration::CanApplicationHandleURL(app_path, test_file_url); base::DeleteFile(test_file_path); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FilePath user_applications_dir = - applications_dir().Append("applications"); + base::FilePath user_applications_dir = applications(); bool database_update_called = false; -@@ -378,7 +378,7 @@ OsIntegrationTestOverrideImpl::GetShortcutIconTopLeftC + for (const LinuxFileRegistration& command : linux_file_registration_) { +@@ -481,7 +481,7 @@ std::optional<SkBitmap> OsIntegrationTestOverrideImpl: return std::nullopt; } - return GetIconTopLeftColorFromShortcutFile(shortcut_path); + return GetIconFromShortcutFile(shortcut_path); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) WebAppProvider* provider = WebAppProvider::GetForLocalAppsUnchecked(profile); if (!provider) { return std::nullopt; -@@ -428,7 +428,7 @@ base::FilePath OsIntegrationTestOverrideImpl::GetShort +@@ -547,7 +547,7 @@ base::FilePath OsIntegrationTestOverrideImpl::GetShort app_installed_profiles.end()) { return shortcut_path; } @@ -63,7 +72,7 @@ std::string shortcut_filename = "chrome-" + app_id + "-" + profile->GetBaseName().value() + ".desktop"; base::FilePath shortcut_path = shortcut_dir.Append(shortcut_filename); -@@ -454,7 +454,7 @@ bool OsIntegrationTestOverrideImpl::IsShortcutCreated( +@@ -572,7 +572,7 @@ bool OsIntegrationTestOverrideImpl::IsShortcutCreated( base::FilePath app_shortcut_path = GetShortcutPath(profile, chrome_apps_folder(), app_id, app_name); return base::PathExists(app_shortcut_path); @@ -72,48 +81,39 @@ base::FilePath desktop_shortcut_path = GetShortcutPath(profile, desktop(), app_id, app_name); return base::PathExists(desktop_shortcut_path); -@@ -643,7 +643,7 @@ void OsIntegrationTestOverrideImpl::EnableOrDisablePat +@@ -764,7 +764,7 @@ void OsIntegrationTestOverrideImpl::EnableOrDisablePat } #endif // BUILDFLAG(IS_MAC) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const base::FilePath& OsIntegrationTestOverrideImpl::desktop() { + base::FilePath OsIntegrationTestOverrideImpl::desktop() { return desktop_.GetPath(); } -@@ -678,7 +678,7 @@ OsIntegrationTestOverrideImpl::OsIntegrationTestOverri - #elif BUILDFLAG(IS_MAC) - bool success = chrome_apps_folder_.CreateUniqueTempDirUnderPath(base_path); - CHECK(success); +@@ -815,7 +815,7 @@ OsIntegrationTestOverrideImpl::OsIntegrationTestOverri + success = chrome_apps_folder_.CreateUniqueTempDirUnderPath( + outer_temp_dir_.GetPath()); + CHECK(success); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - bool success = desktop_.CreateUniqueTempDirUnderPath(base_path); - CHECK(success); - success = startup_.CreateUniqueTempDirUnderPath(base_path); -@@ -699,7 +699,7 @@ OsIntegrationTestOverrideImpl::OsIntegrationTestOverri - #elif BUILDFLAG(IS_MAC) - bool success = chrome_apps_folder_.CreateUniqueTempDir(); - CHECK(success); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - bool success = desktop_.CreateUniqueTempDir(); - CHECK(success); - success = startup_.CreateUniqueTempDir(); -@@ -709,7 +709,7 @@ OsIntegrationTestOverrideImpl::OsIntegrationTestOverri + success = desktop_.CreateUniqueTempDirUnderPath(outer_temp_dir_.GetPath()); + CHECK(success); + success = startup_.CreateUniqueTempDirUnderPath(outer_temp_dir_.GetPath()); +@@ -828,7 +828,7 @@ OsIntegrationTestOverrideImpl::OsIntegrationTestOverri + CHECK(success); #endif - } -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) auto callback = base::BindRepeating([](base::FilePath filename_in, std::string xdg_command, std::string file_contents) { -@@ -756,7 +756,7 @@ OsIntegrationTestOverrideImpl::~OsIntegrationTestOverr - } - } - } +@@ -900,7 +900,7 @@ OsIntegrationTestOverrideImpl::~OsIntegrationTestOverr + EXPECT_TRUE(!startup_.IsValid() || startup_.Delete()); + #elif BUILDFLAG(IS_MAC) + EXPECT_TRUE(!chrome_apps_folder_.IsValid() || DeleteChromeAppsDir()); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Reset the file handling callback. - SetUpdateMimeInfoDatabaseOnLinuxCallbackForTesting( - UpdateMimeInfoDatabaseOnLinuxCallback()); + EXPECT_TRUE(!desktop_.IsValid() || desktop_.Delete()); + EXPECT_TRUE(!startup_.IsValid() || startup_.Delete()); + EXPECT_TRUE(!xdg_data_home_dir_.IsValid() || xdg_data_home_dir_.Delete()); diff --git a/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.h b/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.h index 1b98f5226b73..50a38db9973b 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.h +++ b/www/chromium/files/patch-chrome_browser_web__applications_test_os__integration__test__override__impl.h @@ -1,6 +1,6 @@ ---- chrome/browser/web_applications/test/os_integration_test_override_impl.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/web_applications/test/os_integration_test_override_impl.h.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/web_applications/test/os_integration_test_override_impl.h -@@ -38,7 +38,7 @@ class ShellLinkItem; +@@ -40,7 +40,7 @@ class ShellLinkItem; namespace web_app { @@ -9,7 +9,7 @@ struct LinuxFileRegistration { base::FilePath file_name; std::string xdg_command; -@@ -112,7 +112,7 @@ class OsIntegrationTestOverrideImpl : public OsIntegra +@@ -122,7 +122,7 @@ class OsIntegrationTestOverrideImpl : public OsIntegra bool DeleteApplicationMenuDirOnWin(); #endif // BUILDFLAG(IS_WIN) @@ -18,16 +18,16 @@ bool DeleteDesktopDirOnLinux(); #endif // BUILDFLAG(IS_LINUX) -@@ -231,7 +231,7 @@ class OsIntegrationTestOverrideImpl : public OsIntegra - const base::FilePath& chrome_apps_folder() override; +@@ -250,7 +250,7 @@ class OsIntegrationTestOverrideImpl : public OsIntegra + base::FilePath chrome_apps_folder() override; void EnableOrDisablePathOnLogin(const base::FilePath& file_path, bool enable_on_login) override; -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const base::FilePath& desktop() override; - const base::FilePath& startup() override; - const base::FilePath& applications_dir() override; -@@ -278,7 +278,7 @@ class OsIntegrationTestOverrideImpl : public OsIntegra + base::FilePath desktop(); + base::FilePath startup(); + base::FilePath applications(); +@@ -323,7 +323,7 @@ class OsIntegrationTestOverrideImpl : public OsIntegra base::ScopedTempDir chrome_apps_folder_; std::map<base::FilePath, bool> startup_enabled_; @@ -35,4 +35,4 @@ +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) base::ScopedTempDir desktop_; base::ScopedTempDir startup_; - base::ScopedTempDir applications_dir_; + base::ScopedTempDir xdg_data_home_dir_; diff --git a/www/chromium/files/patch-chrome_browser_web__applications_web__app__helpers.cc b/www/chromium/files/patch-chrome_browser_web__applications_web__app__helpers.cc index 023e12c1a417..be864e058154 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_web__app__helpers.cc +++ b/www/chromium/files/patch-chrome_browser_web__applications_web__app__helpers.cc @@ -1,11 +1,11 @@ ---- chrome/browser/web_applications/web_app_helpers.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/web_applications/web_app_helpers.cc.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/web_applications/web_app_helpers.cc -@@ -146,7 +146,7 @@ bool IsValidWebAppUrl(const GURL& app_url) { +@@ -145,7 +145,7 @@ bool IsValidWebAppUrl(const GURL& app_url) { + return false; bool allow_extension_apps = true; - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Stop allowing apps to be extension urls when the shortcuts are separated - // they can be extension urls instead. - allow_extension_apps = + allow_extension_apps = false; diff --git a/www/chromium/files/patch-chrome_browser_web__applications_web__app__install__info.h b/www/chromium/files/patch-chrome_browser_web__applications_web__app__install__info.h index df98f637be12..c28ff43cb03c 100644 --- a/www/chromium/files/patch-chrome_browser_web__applications_web__app__install__info.h +++ b/www/chromium/files/patch-chrome_browser_web__applications_web__app__install__info.h @@ -1,11 +1,11 @@ ---- chrome/browser/web_applications/web_app_install_info.h.orig 2023-12-10 06:10:27 UTC +--- chrome/browser/web_applications/web_app_install_info.h.orig 2025-02-19 07:43:18 UTC +++ chrome/browser/web_applications/web_app_install_info.h -@@ -35,7 +35,7 @@ +@@ -38,7 +38,7 @@ #include "url/gurl.h" static_assert(BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA)); -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD)); +- BUILDFLAG(IS_CHROMEOS)); ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)); namespace web_app { diff --git a/www/chromium/files/patch-chrome_browser_webauthn_chrome__authenticator__request__delegate.cc b/www/chromium/files/patch-chrome_browser_webauthn_chrome__authenticator__request__delegate.cc index d8a012492279..079c5ea84035 100644 --- a/www/chromium/files/patch-chrome_browser_webauthn_chrome__authenticator__request__delegate.cc +++ b/www/chromium/files/patch-chrome_browser_webauthn_chrome__authenticator__request__delegate.cc @@ -1,6 +1,6 @@ ---- chrome/browser/webauthn/chrome_authenticator_request_delegate.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/browser/webauthn/chrome_authenticator_request_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/browser/webauthn/chrome_authenticator_request_delegate.cc -@@ -859,7 +859,7 @@ void ChromeAuthenticatorRequestDelegate::ConfigureDisc +@@ -578,7 +578,7 @@ void ChromeAuthenticatorRequestDelegate::ConfigureDisc g_observer->ConfiguringCable(request_type); } diff --git a/www/chromium/files/patch-chrome_browser_webauthn_enclave__manager.cc b/www/chromium/files/patch-chrome_browser_webauthn_enclave__manager.cc new file mode 100644 index 000000000000..bd45efaef0d3 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_webauthn_enclave__manager.cc @@ -0,0 +1,20 @@ +--- chrome/browser/webauthn/enclave_manager.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/browser/webauthn/enclave_manager.cc +@@ -687,7 +687,7 @@ base::flat_set<GaiaId> GetGaiaIDs( + + std::string UserVerifyingLabelToString(crypto::UserVerifyingKeyLabel label) { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return label; + #else + return std::string("placeholder"); +@@ -697,7 +697,7 @@ std::string UserVerifyingLabelToString(crypto::UserVer + std::optional<crypto::UserVerifyingKeyLabel> UserVerifyingKeyLabelFromString( + std::string saved_label) { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return saved_label; + #else + return std::nullopt; diff --git a/www/chromium/files/patch-chrome_browser_webauthn_gpm__user__verification__policy.cc b/www/chromium/files/patch-chrome_browser_webauthn_gpm__user__verification__policy.cc new file mode 100644 index 000000000000..c4f1b807af46 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_webauthn_gpm__user__verification__policy.cc @@ -0,0 +1,11 @@ +--- chrome/browser/webauthn/gpm_user_verification_policy.cc.orig 2024-08-26 12:06:38 UTC ++++ chrome/browser/webauthn/gpm_user_verification_policy.cc +@@ -17,7 +17,7 @@ bool GpmWillDoUserVerification(device::UserVerificatio + return platform_has_biometrics; + #elif BUILDFLAG(IS_MAC) + return platform_has_biometrics; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return false; + #else + // This default is for unit tests. diff --git a/www/chromium/files/patch-chrome_browser_webauthn_password__credential__controller.cc b/www/chromium/files/patch-chrome_browser_webauthn_password__credential__controller.cc new file mode 100644 index 000000000000..4b32bb40e936 --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_webauthn_password__credential__controller.cc @@ -0,0 +1,11 @@ +--- chrome/browser/webauthn/password_credential_controller.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/webauthn/password_credential_controller.cc +@@ -46,7 +46,7 @@ password_manager::PasswordManagerClient* GetPasswordMa + } + + std::u16string GetAuthenticationMessage(std::string_view rp_id) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return u""; + #else + return l10n_util::GetStringFUTF16(IDS_PASSWORD_MANAGER_FILLING_REAUTH, diff --git a/www/chromium/files/patch-chrome_browser_webauthn_unexportable__key__utils.cc b/www/chromium/files/patch-chrome_browser_webauthn_unexportable__key__utils.cc new file mode 100644 index 000000000000..8a6c0b6258fd --- /dev/null +++ b/www/chromium/files/patch-chrome_browser_webauthn_unexportable__key__utils.cc @@ -0,0 +1,11 @@ +--- chrome/browser/webauthn/unexportable_key_utils.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/browser/webauthn/unexportable_key_utils.cc +@@ -33,7 +33,7 @@ GetWebAuthnUnexportableKeyProvider() { + // If there is a scoped UnexportableKeyProvider configured, we always use + // that so that tests can still override the key provider. + const bool use_software_provider = +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + !crypto::internal::HasScopedUnexportableKeyProvider(); + #else + false; diff --git a/www/chromium/files/patch-chrome_common_channel__info.h b/www/chromium/files/patch-chrome_common_channel__info.h index a6c8d6364e88..9d9370a08672 100644 --- a/www/chromium/files/patch-chrome_common_channel__info.h +++ b/www/chromium/files/patch-chrome_common_channel__info.h @@ -1,18 +1,20 @@ ---- chrome/common/channel_info.h.orig 2023-04-28 17:01:32 UTC +--- chrome/common/channel_info.h.orig 2025-04-04 08:52:13 UTC +++ chrome/common/channel_info.h -@@ -104,13 +104,13 @@ void ClearChannelForTesting(); +@@ -11,7 +11,7 @@ + #include "build/branding_buildflags.h" + #include "build/build_config.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + namespace base { + class Environment; + } +@@ -99,7 +99,7 @@ void ClearChannelIdForTesting(); std::string GetChannelSuffixForDataDir(); #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) std::string GetChannelSuffixForExtraFlagsEnvVarName(); - #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) // Returns the channel-specific filename of the desktop shortcut used to launch - // the browser. - std::string GetDesktopName(base::Environment* env); diff --git a/www/chromium/files/patch-chrome_common_channel__info__posix.cc b/www/chromium/files/patch-chrome_common_channel__info__posix.cc index 80ac1fc7cc26..56720d9b5906 100644 --- a/www/chromium/files/patch-chrome_common_channel__info__posix.cc +++ b/www/chromium/files/patch-chrome_common_channel__info__posix.cc @@ -1,6 +1,6 @@ ---- chrome/common/channel_info_posix.cc.orig 2023-04-28 17:01:32 UTC +--- chrome/common/channel_info_posix.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/common/channel_info_posix.cc -@@ -92,7 +92,7 @@ std::string GetChannelSuffixForDataDir() { +@@ -95,7 +95,7 @@ std::string GetChannelSuffixForDataDir() { } } @@ -9,12 +9,12 @@ std::string GetChannelSuffixForExtraFlagsEnvVarName() { #if BUILDFLAG(GOOGLE_CHROME_BRANDING) const auto channel_state = GetChannelImpl(); -@@ -118,7 +118,7 @@ std::string GetChannelSuffixForExtraFlagsEnvVarName() +@@ -121,7 +121,7 @@ std::string GetChannelSuffixForExtraFlagsEnvVarName() + } + #endif // BUILDFLAG(IS_LINUX) - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) std::string GetDesktopName(base::Environment* env) { #if BUILDFLAG(GOOGLE_CHROME_BRANDING) // Google Chrome packaged as a snap is a special case: the application name diff --git a/www/chromium/files/patch-chrome_common_chrome__features.cc b/www/chromium/files/patch-chrome_common_chrome__features.cc index 9c08a42d5dc8..4c46706cda00 100644 --- a/www/chromium/files/patch-chrome_common_chrome__features.cc +++ b/www/chromium/files/patch-chrome_common_chrome__features.cc @@ -1,11 +1,11 @@ ---- chrome/common/chrome_features.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/common/chrome_features.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/common/chrome_features.cc @@ -81,7 +81,7 @@ BASE_FEATURE(kUseAdHocSigningForWebAppShims, #endif // BUILDFLAG(IS_MAC) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Enables or disables the Autofill survey triggered by opening a prompt to // save address info. BASE_FEATURE(kAutofillAddressSurvey, @@ -18,7 +18,7 @@ // Enables the Restart background mode optimization. When all Chrome UI is // closed and it goes in the background, allows to restart the browser to // discard memory. -@@ -302,7 +302,7 @@ BASE_FEATURE(kDesktopPWAsEnforceWebAppSettingsPolicy, +@@ -249,7 +249,7 @@ BASE_FEATURE(kDesktopPWAsElidedExtensionsMenu, BASE_FEATURE(kDesktopPWAsRunOnOsLogin, "DesktopPWAsRunOnOsLogin", #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ @@ -27,43 +27,25 @@ base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -341,7 +341,7 @@ BASE_FEATURE(kDesktopPWAsTabStripSettings, +@@ -282,7 +282,7 @@ BASE_FEATURE(kDisplayEdgeToEdgeFullscreen, base::FEATURE_DISABLED_BY_DEFAULT); + #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Controls whether Chrome Apps are supported. See https://crbug.com/1221251. // If the feature is disabled, Chrome Apps continue to work. If enabled, Chrome // Apps will not launch and will be marked in the UI as deprecated. -@@ -364,7 +364,7 @@ BASE_FEATURE(kDisruptiveNotificationPermissionRevocati - BASE_FEATURE(kDnsOverHttps, - "DnsOverHttps", - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT -@@ -380,7 +380,7 @@ const base::FeatureParam<bool> kDnsOverHttpsFallbackPa - const base::FeatureParam<bool> kDnsOverHttpsShowUiParam{&kDnsOverHttps, - "ShowUi", - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - true - #else - false -@@ -918,7 +918,7 @@ BASE_FEATURE(kLacrosSharedComponentsDir, +@@ -995,7 +995,7 @@ BASE_FEATURE(kKAnonymityServiceStorage, + "KAnonymityServiceStorage", base::FEATURE_ENABLED_BY_DEFAULT); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) -#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) +#if (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS)) || BUILDFLAG(IS_BSD) BASE_FEATURE(kLinuxLowMemoryMonitor, "LinuxLowMemoryMonitor", base::FEATURE_DISABLED_BY_DEFAULT); -@@ -931,7 +931,7 @@ constexpr base::FeatureParam<int> kLinuxLowMemoryMonit +@@ -1008,7 +1008,7 @@ constexpr base::FeatureParam<int> kLinuxLowMemoryMonit &kLinuxLowMemoryMonitor, "critical_level", 255}; #endif // BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-chrome_common_chrome__features.h b/www/chromium/files/patch-chrome_common_chrome__features.h index 34deb0d43a6a..d3a02a97ac4a 100644 --- a/www/chromium/files/patch-chrome_common_chrome__features.h +++ b/www/chromium/files/patch-chrome_common_chrome__features.h @@ -1,11 +1,11 @@ ---- chrome/common/chrome_features.h.orig 2024-04-19 13:02:56 UTC +--- chrome/common/chrome_features.h.orig 2025-07-02 06:08:04 UTC +++ chrome/common/chrome_features.h -@@ -60,13 +60,13 @@ BASE_DECLARE_FEATURE(kUseAdHocSigningForWebAppShims); +@@ -50,13 +50,13 @@ BASE_DECLARE_FEATURE(kUseAdHocSigningForWebAppShims); #endif // BUILDFLAG(IS_MAC) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kAutofillAddressSurvey); COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kAutofillCardSurvey); COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kAutofillPasswordSurvey); @@ -16,25 +16,25 @@ COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kBackgroundModeAllowRestart); #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -216,7 +216,7 @@ COMPONENT_EXPORT(CHROME_FEATURES) +@@ -150,7 +150,7 @@ BASE_DECLARE_FEATURE(kDesktopPWAsPreventClose); + COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kDesktopPWAsTabStripSettings); - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kChromeAppsDeprecation); COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kShortcutsNotApps); -@@ -543,7 +543,7 @@ COMPONENT_EXPORT(CHROME_FEATURES) - BASE_DECLARE_FEATURE(kLacrosSharedComponentsDir); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) +@@ -578,7 +578,7 @@ BASE_DECLARE_FEATURE(kKAnonymityServiceOHTTPRequests); + COMPONENT_EXPORT(CHROME_FEATURES) + BASE_DECLARE_FEATURE(kKAnonymityServiceStorage); -#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) +#if (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS)) || BUILDFLAG(IS_BSD) COMPONENT_EXPORT(CHROME_FEATURES) BASE_DECLARE_FEATURE(kLinuxLowMemoryMonitor); COMPONENT_EXPORT(CHROME_FEATURES) extern const base::FeatureParam<int> kLinuxLowMemoryMonitorModerateLevel; -@@ -551,7 +551,7 @@ COMPONENT_EXPORT(CHROME_FEATURES) +@@ -586,7 +586,7 @@ COMPONENT_EXPORT(CHROME_FEATURES) extern const base::FeatureParam<int> kLinuxLowMemoryMonitorCriticalLevel; #endif // BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-chrome_common_chrome__paths.cc b/www/chromium/files/patch-chrome_common_chrome__paths.cc index b8f02a72325e..a26f97e94a41 100644 --- a/www/chromium/files/patch-chrome_common_chrome__paths.cc +++ b/www/chromium/files/patch-chrome_common_chrome__paths.cc @@ -1,6 +1,6 @@ ---- chrome/common/chrome_paths.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/common/chrome_paths.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/common/chrome_paths.cc -@@ -30,7 +30,7 @@ +@@ -32,7 +32,7 @@ #include "base/apple/foundation_util.h" #endif @@ -9,9 +9,9 @@ #include "components/policy/core/common/policy_paths.h" #endif -@@ -52,14 +52,14 @@ +@@ -48,14 +48,14 @@ namespace { - namespace { + std::optional<bool> g_override_using_default_data_directory_for_testing; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) @@ -27,7 +27,7 @@ #endif // BUILDFLAG(GOOGLE_CHROME_BRANDING) #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -225,7 +225,7 @@ bool PathProvider(int key, base::FilePath* result) { +@@ -212,7 +212,7 @@ bool PathProvider(int key, base::FilePath* result) { } break; case chrome::DIR_DEFAULT_DOWNLOADS_SAFE: @@ -36,25 +36,23 @@ if (!GetUserDownloadsDirectorySafe(&cur)) { return false; } -@@ -544,7 +544,7 @@ bool PathProvider(int key, base::FilePath* result) { - return false; - } +@@ -504,13 +504,13 @@ bool PathProvider(int key, base::FilePath* result) { break; + } + #endif -#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_OPENBSD) +#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) case chrome::DIR_POLICY_FILES: { cur = base::FilePath(policy::kPolicyPath); break; -@@ -555,7 +555,7 @@ bool PathProvider(int key, base::FilePath* result) { - #if BUILDFLAG(IS_CHROMEOS_ASH) || \ - ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ - BUILDFLAG(CHROMIUM_BRANDING)) || \ -- BUILDFLAG(IS_MAC) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + } + #endif +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ + (BUILDFLAG(IS_LINUX) && BUILDFLAG(CHROMIUM_BRANDING)) case chrome::DIR_USER_EXTERNAL_EXTENSIONS: { if (!base::PathService::Get(chrome::DIR_USER_DATA, &cur)) { - return false; -@@ -564,7 +564,7 @@ bool PathProvider(int key, base::FilePath* result) { +@@ -520,7 +520,7 @@ bool PathProvider(int key, base::FilePath* result) { break; } #endif @@ -63,8 +61,8 @@ case chrome::DIR_STANDALONE_EXTERNAL_EXTENSIONS: { cur = base::FilePath(kFilepathSinglePrefExtensions); break; -@@ -612,7 +612,7 @@ bool PathProvider(int key, base::FilePath* result) { - #endif +@@ -558,7 +558,7 @@ bool PathProvider(int key, base::FilePath* result) { + break; #if BUILDFLAG(ENABLE_EXTENSIONS) && \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC)) @@ -72,7 +70,7 @@ case chrome::DIR_NATIVE_MESSAGING: #if BUILDFLAG(IS_MAC) #if BUILDFLAG(GOOGLE_CHROME_BRANDING) -@@ -626,6 +626,9 @@ bool PathProvider(int key, base::FilePath* result) { +@@ -572,6 +572,9 @@ bool PathProvider(int key, base::FilePath* result) { #if BUILDFLAG(GOOGLE_CHROME_BRANDING) cur = base::FilePath( FILE_PATH_LITERAL("/etc/opt/chrome/native-messaging-hosts")); diff --git a/www/chromium/files/patch-chrome_common_chrome__paths.h b/www/chromium/files/patch-chrome_common_chrome__paths.h index 5f4a03df043e..52b0f38757ed 100644 --- a/www/chromium/files/patch-chrome_common_chrome__paths.h +++ b/www/chromium/files/patch-chrome_common_chrome__paths.h @@ -1,15 +1,15 @@ ---- chrome/common/chrome_paths.h.orig 2024-02-23 21:04:38 UTC +--- chrome/common/chrome_paths.h.orig 2025-04-04 08:52:13 UTC +++ chrome/common/chrome_paths.h -@@ -59,7 +59,7 @@ enum { - #if BUILDFLAG(IS_CHROMEOS_ASH) || \ - ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ - BUILDFLAG(CHROMIUM_BRANDING)) || \ -- BUILDFLAG(IS_MAC) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) +@@ -56,7 +56,7 @@ enum { + // to set policies for chrome. This directory + // contains subdirectories. + #endif +-#if BUILDFLAG(IS_CHROMEOS) || \ ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) || \ + (BUILDFLAG(IS_LINUX) && BUILDFLAG(CHROMIUM_BRANDING)) || BUILDFLAG(IS_MAC) DIR_USER_EXTERNAL_EXTENSIONS, // Directory for per-user external extensions // on Chrome Mac and Chromium Linux. - // On Chrome OS, this path is used for OEM -@@ -67,7 +67,7 @@ enum { +@@ -65,7 +65,7 @@ enum { // create it. #endif @@ -18,7 +18,7 @@ DIR_STANDALONE_EXTERNAL_EXTENSIONS, // Directory for 'per-extension' // definition manifest files that // describe extensions which are to be -@@ -126,7 +126,7 @@ enum { +@@ -112,7 +112,7 @@ enum { #endif #if BUILDFLAG(ENABLE_EXTENSIONS) && \ diff --git a/www/chromium/files/patch-chrome_common_chrome__paths__internal.h b/www/chromium/files/patch-chrome_common_chrome__paths__internal.h index 4e039448a59a..ad5a1cfe0f26 100644 --- a/www/chromium/files/patch-chrome_common_chrome__paths__internal.h +++ b/www/chromium/files/patch-chrome_common_chrome__paths__internal.h @@ -1,6 +1,6 @@ ---- chrome/common/chrome_paths_internal.h.orig 2023-05-31 08:12:17 UTC +--- chrome/common/chrome_paths_internal.h.orig 2025-05-05 10:57:53 UTC +++ chrome/common/chrome_paths_internal.h -@@ -43,7 +43,7 @@ void GetUserCacheDirectory(const base::FilePath& profi +@@ -53,7 +53,7 @@ void GetUserCacheDirectory(const base::FilePath& profi // Get the path to the user's documents directory. bool GetUserDocumentsDirectory(base::FilePath* result); diff --git a/www/chromium/files/patch-chrome_common_chrome__switches.cc b/www/chromium/files/patch-chrome_common_chrome__switches.cc index fa4d6225172b..f34b78586fb6 100644 --- a/www/chromium/files/patch-chrome_common_chrome__switches.cc +++ b/www/chromium/files/patch-chrome_common_chrome__switches.cc @@ -1,15 +1,16 @@ ---- chrome/common/chrome_switches.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/common/chrome_switches.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/common/chrome_switches.cc -@@ -881,14 +881,14 @@ const char kAllowNaClSocketAPI[] = "allow-nacl-socket- +@@ -892,7 +892,7 @@ const char kAllowNaClSocketAPI[] = "allow-nacl-socket- #endif #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) const char kEnableNewAppMenuIcon[] = "enable-new-app-menu-icon"; // Causes the browser to launch directly in guest mode. - const char kGuest[] = "guest"; +@@ -921,7 +921,7 @@ const char kGlicDev[] = "glic-dev"; + const char kGlicHostLogging[] = "glic-host-logging"; #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-chrome_common_chrome__switches.h b/www/chromium/files/patch-chrome_common_chrome__switches.h index 84ac2cd95949..bc899c2fadb7 100644 --- a/www/chromium/files/patch-chrome_common_chrome__switches.h +++ b/www/chromium/files/patch-chrome_common_chrome__switches.h @@ -1,13 +1,16 @@ ---- chrome/common/chrome_switches.h.orig 2024-04-19 13:02:56 UTC +--- chrome/common/chrome_switches.h.orig 2025-07-02 06:08:04 UTC +++ chrome/common/chrome_switches.h -@@ -277,12 +277,12 @@ extern const char kAllowNaClSocketAPI[]; +@@ -275,7 +275,7 @@ extern const char kAllowNaClSocketAPI[]; #endif #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) extern const char kEnableNewAppMenuIcon[]; extern const char kGuest[]; + extern const char kForceNtpMobilePromo[]; +@@ -293,7 +293,7 @@ extern const char kGlicDev[]; + extern const char kGlicHostLogging[]; #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-chrome_common_crash__keys.cc b/www/chromium/files/patch-chrome_common_crash__keys.cc new file mode 100644 index 000000000000..b84744159f4e --- /dev/null +++ b/www/chromium/files/patch-chrome_common_crash__keys.cc @@ -0,0 +1,28 @@ +--- chrome/common/crash_keys.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/common/crash_keys.cc +@@ -51,7 +51,9 @@ class CrashKeyWithName { + ~CrashKeyWithName() = delete; + + std::string_view Name() const { return name_; } ++#if BUILDFLAG(USE_CRASHPAD_ANNOTATION) + std::string_view Value() const { return crash_key_.value(); } ++#endif + void Clear() { crash_key_.Clear(); } + void Set(std::string_view value) { crash_key_.Set(value); } + +@@ -196,6 +198,7 @@ void AllocateCrashKeyInBrowserAndChildren(std::string_ + GetCommandLineStringAnnotations().emplace_back(std::string(key)).Set(value); + } + ++#if BUILDFLAG(USE_CRASHPAD_ANNOTATION) + void AppendStringAnnotationsCommandLineSwitch(base::CommandLine* command_line) { + std::string string_annotations; + for (const auto& crash_key : GetCommandLineStringAnnotations()) { +@@ -210,6 +213,7 @@ void AppendStringAnnotationsCommandLineSwitch(base::Co + } + command_line->AppendSwitchASCII(kStringAnnotationsSwitch, string_annotations); + } ++#endif + + void SetCrashKeysFromCommandLine(const base::CommandLine& command_line) { + SetStringAnnotations(command_line); diff --git a/www/chromium/files/patch-chrome_common_extensions_extension__constants.cc b/www/chromium/files/patch-chrome_common_extensions_extension__constants.cc new file mode 100644 index 000000000000..df318ec5cac1 --- /dev/null +++ b/www/chromium/files/patch-chrome_common_extensions_extension__constants.cc @@ -0,0 +1,11 @@ +--- chrome/common/extensions/extension_constants.cc.orig 2025-04-04 08:52:13 UTC ++++ chrome/common/extensions/extension_constants.cc +@@ -38,7 +38,7 @@ const char* const kBuiltInFirstPartyExtensionIds[] = { + kGoogleSpeechSynthesisExtensionId, + #endif // BUILDFLAG(IS_CHROMEOS) + kReadingModeGDocsHelperExtensionId, +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + kTTSEngineExtensionId, + kComponentUpdaterTTSEngineExtensionId, + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-chrome_common_extensions_extension__constants.h b/www/chromium/files/patch-chrome_common_extensions_extension__constants.h new file mode 100644 index 000000000000..89a9b4015664 --- /dev/null +++ b/www/chromium/files/patch-chrome_common_extensions_extension__constants.h @@ -0,0 +1,11 @@ +--- chrome/common/extensions/extension_constants.h.orig 2025-07-02 06:08:04 UTC ++++ chrome/common/extensions/extension_constants.h +@@ -311,7 +311,7 @@ inline constexpr char kReadingModeGDocsHelperExtension + inline constexpr base::FilePath::CharType + kReadingModeGDocsHelperManifestFilename[] = + FILE_PATH_LITERAL("reading_mode_gdocs_helper_manifest.json"); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + // The extension id of the google tts engine extension to use on-device natural + // Google voices. + inline constexpr char kTTSEngineExtensionId[] = diff --git a/www/chromium/files/patch-chrome_common_extensions_permissions_chrome__permission__message__rules.cc b/www/chromium/files/patch-chrome_common_extensions_permissions_chrome__permission__message__rules.cc index 80a2b15f15dd..e16c9458ccdf 100644 --- a/www/chromium/files/patch-chrome_common_extensions_permissions_chrome__permission__message__rules.cc +++ b/www/chromium/files/patch-chrome_common_extensions_permissions_chrome__permission__message__rules.cc @@ -1,7 +1,7 @@ ---- chrome/common/extensions/permissions/chrome_permission_message_rules.cc.orig 2022-11-30 08:12:58 UTC +--- chrome/common/extensions/permissions/chrome_permission_message_rules.cc.orig 2025-03-05 08:14:56 UTC +++ chrome/common/extensions/permissions/chrome_permission_message_rules.cc -@@ -285,7 +285,7 @@ int GetEnterpriseReportingPrivatePermissionMessageId() - } +@@ -280,7 +280,7 @@ class USBDevicesFormatter : public ChromePermissionMes + int GetEnterpriseReportingPrivatePermissionMessageId() { #if BUILDFLAG(IS_WIN) return IDS_EXTENSION_PROMPT_WARNING_ENTERPRISE_REPORTING_PRIVATE_ENABLED_WIN; -#elif BUILDFLAG(IS_LINUX) or BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-chrome_common_media_cdm__host__file__path.cc b/www/chromium/files/patch-chrome_common_media_cdm__host__file__path.cc index af6ceaa32452..fd67989842e5 100644 --- a/www/chromium/files/patch-chrome_common_media_cdm__host__file__path.cc +++ b/www/chromium/files/patch-chrome_common_media_cdm__host__file__path.cc @@ -1,4 +1,4 @@ ---- chrome/common/media/cdm_host_file_path.cc.orig 2023-02-08 09:03:45 UTC +--- chrome/common/media/cdm_host_file_path.cc.orig 2025-01-15 09:18:26 UTC +++ chrome/common/media/cdm_host_file_path.cc @@ -90,7 +90,7 @@ void AddCdmHostFilePaths( cdm_host_file_paths->emplace_back(chrome_framework_path, @@ -8,4 +8,4 @@ +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) base::FilePath chrome_exe_dir; - if (!base::PathService::Get(base::DIR_EXE, &chrome_exe_dir)) + if (!base::PathService::Get(base::DIR_EXE, &chrome_exe_dir)) { diff --git a/www/chromium/files/patch-chrome_common_media_cdm__registration.cc b/www/chromium/files/patch-chrome_common_media_cdm__registration.cc index b0e90719d0d0..30396285b858 100644 --- a/www/chromium/files/patch-chrome_common_media_cdm__registration.cc +++ b/www/chromium/files/patch-chrome_common_media_cdm__registration.cc @@ -1,20 +1,15 @@ ---- chrome/common/media/cdm_registration.cc.orig 2024-03-27 13:31:02 UTC +--- chrome/common/media/cdm_registration.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/common/media/cdm_registration.cc -@@ -26,11 +26,11 @@ - +@@ -34,7 +34,7 @@ #if BUILDFLAG(ENABLE_WIDEVINE) + #include "components/cdm/common/cdm_manifest.h" #include "third_party/widevine/cdm/widevine_cdm_common.h" // nogncheck --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - #include "base/native_library.h" - #include "chrome/common/chrome_paths.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "base/no_destructor.h" + #include "base/native_library.h" + #include "chrome/common/chrome_paths.h" #include "chrome/common/media/component_widevine_cdm_hint_file_linux.h" - #include "media/cdm/supported_audio_codecs.h" -@@ -56,7 +56,7 @@ using Robustness = content::CdmInfo::Robustness; +@@ -59,7 +59,7 @@ using Robustness = content::CdmInfo::Robustness; #if BUILDFLAG(ENABLE_WIDEVINE) #if (BUILDFLAG(BUNDLE_WIDEVINE_CDM) || \ BUILDFLAG(ENABLE_WIDEVINE_CDM_COMPONENT)) && \ @@ -30,23 +25,32 @@ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) + (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) // On Linux/ChromeOS we have to preload the CDM since it uses the zygote - // sandbox. On Windows and Mac, the bundled CDM is handled by the component - // updater. -@@ -125,7 +125,7 @@ content::CdmInfo* GetBundledWidevine() { + // sandbox. On Windows and Mac, CDM registration is handled by Component + // Update (as the CDM can be loaded only when needed). +@@ -125,7 +125,7 @@ std::unique_ptr<content::CdmInfo> GetBundledWidevine() // (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) - #if BUILDFLAG(ENABLE_WIDEVINE_CDM_COMPONENT) && \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) - // This code checks to see if a component updated Widevine CDM can be found. If - // there is one and it looks valid, return the CdmInfo for that CDM. Otherwise - // return nullptr. -@@ -160,7 +160,7 @@ void AddSoftwareSecureWidevine(std::vector<content::Cd + #if (BUILDFLAG(ENABLE_WIDEVINE_CDM_COMPONENT) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS))) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD))) + // This code checks to see if Component Updater picked a version of the Widevine + // CDM to be used last time it ran. (Component Updater may choose the bundled + // CDM if there is not a new version available for download.) If there is one +@@ -167,7 +167,7 @@ void AddSoftwareSecureWidevine(std::vector<content::Cd /*supports_sub_key_systems=*/false, kWidevineCdmDisplayName, - kWidevineCdmType, base::Version(), base::FilePath()); + kWidevineCdmType, base::FilePath()); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #if defined(WIDEVINE_CDM_MIN_GLIBC_VERSION) - base::Version glibc_version(gnu_get_libc_version()); - DCHECK(glibc_version.IsValid()); + // The Widevine CDM on Linux/ChromeOS needs to be registered (and loaded) + // before the zygote is locked down. The CDM can be found from the version + // bundled with Chrome (if BUNDLE_WIDEVINE_CDM = true) and/or the version +@@ -434,7 +434,7 @@ void RegisterCdmInfo(std::vector<content::CdmInfo>* cd + } + + #if BUILDFLAG(ENABLE_WIDEVINE) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) + std::vector<content::CdmInfo> GetSoftwareSecureWidevine() { + std::vector<content::CdmInfo> cdms; + AddSoftwareSecureWidevine(&cdms); diff --git a/www/chromium/files/patch-chrome_common_media_cdm__registration.h b/www/chromium/files/patch-chrome_common_media_cdm__registration.h new file mode 100644 index 000000000000..edb3dc3caee2 --- /dev/null +++ b/www/chromium/files/patch-chrome_common_media_cdm__registration.h @@ -0,0 +1,11 @@ +--- chrome/common/media/cdm_registration.h.orig 2025-04-04 08:52:13 UTC ++++ chrome/common/media/cdm_registration.h +@@ -15,7 +15,7 @@ + void RegisterCdmInfo(std::vector<content::CdmInfo>* cdms); + + #if BUILDFLAG(ENABLE_WIDEVINE) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) + // Returns the software secure Widevine CDM, if one exists. + std::vector<content::CdmInfo> GetSoftwareSecureWidevine(); + #endif diff --git a/www/chromium/files/patch-chrome_common_media_component__widevine__cdm__hint__file__linux.h b/www/chromium/files/patch-chrome_common_media_component__widevine__cdm__hint__file__linux.h index 0f655eb82788..9a8e5043664b 100644 --- a/www/chromium/files/patch-chrome_common_media_component__widevine__cdm__hint__file__linux.h +++ b/www/chromium/files/patch-chrome_common_media_component__widevine__cdm__hint__file__linux.h @@ -1,9 +1,9 @@ ---- chrome/common/media/component_widevine_cdm_hint_file_linux.h.orig 2024-03-27 13:31:02 UTC +--- chrome/common/media/component_widevine_cdm_hint_file_linux.h.orig 2025-04-04 08:52:13 UTC +++ chrome/common/media/component_widevine_cdm_hint_file_linux.h -@@ -15,7 +15,7 @@ +@@ -14,7 +14,7 @@ + #error "This file only applies when Widevine used." + #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. -#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) +#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) #error "This file only applies to desktop Linux and ChromeOS." diff --git a/www/chromium/files/patch-chrome_common_pref__names.h b/www/chromium/files/patch-chrome_common_pref__names.h index 3f8d14cc4b97..13df9870ad50 100644 --- a/www/chromium/files/patch-chrome_common_pref__names.h +++ b/www/chromium/files/patch-chrome_common_pref__names.h @@ -1,15 +1,15 @@ ---- chrome/common/pref_names.h.orig 2024-04-19 13:02:56 UTC +--- chrome/common/pref_names.h.orig 2025-07-02 06:08:04 UTC +++ chrome/common/pref_names.h -@@ -1288,7 +1288,7 @@ inline constexpr char kUseAshProxy[] = "lacros.proxy.u +@@ -1334,7 +1334,7 @@ inline constexpr char kGeminiSettings[] = "browser.gem + inline constexpr char kAllowedDomainsForApps[] = + "settings.allowed_domains_for_apps"; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Linux specific preference on whether we should match the system theme. inline constexpr char kSystemTheme[] = "extensions.theme.system_theme"; #endif -@@ -1428,7 +1428,7 @@ inline constexpr char kShowUpdatePromotionInfoBar[] = +@@ -1504,7 +1504,7 @@ inline constexpr char kShowUpdatePromotionInfoBar[] = "browser.show_update_promotion_info_bar"; #endif @@ -18,7 +18,7 @@ // Boolean that is false if we should show window manager decorations. If // true, we draw a custom chrome frame (thicker title bar and blue border). inline constexpr char kUseCustomChromeFrame[] = "browser.custom_chrome_frame"; -@@ -1997,7 +1997,7 @@ inline constexpr char kDownloadDefaultDirectory[] = +@@ -2151,7 +2151,7 @@ inline constexpr char kDownloadDefaultDirectory[] = inline constexpr char kDownloadDirUpgraded[] = "download.directory_upgrade"; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -27,7 +27,7 @@ inline constexpr char kOpenPdfDownloadInSystemReader[] = "download.open_pdf_in_system_reader"; #endif -@@ -2431,14 +2431,14 @@ inline constexpr char kMediaStorageIdSalt[] = "media.s +@@ -2654,14 +2654,14 @@ inline constexpr char kMediaStorageIdSalt[] = "media.s inline constexpr char kMediaCdmOriginData[] = "media.cdm.origin_data"; #endif // BUILDFLAG(IS_WIN) @@ -44,25 +44,25 @@ // Records whether the user has seen an HTTP auth "negotiate" header. inline constexpr char kReceivedHttpAuthNegotiateHeader[] = "net.received_http_auth_negotiate_headers"; -@@ -2516,7 +2516,7 @@ inline constexpr char kAmbientAuthenticationInPrivateM - inline constexpr char kBasicAuthOverHttpEnabled[] = - "auth.basic_over_http_enabled"; +@@ -2753,7 +2753,7 @@ inline constexpr char kIsolatedWebAppInstallForceList[ + inline constexpr char kIsolatedWebAppPendingInitializationCount[] = + "profile.isolated_web_app.install.pending_initialization_count"; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Boolean that specifies whether OK-AS-DELEGATE flag from KDC is respected // along with kAuthNegotiateDelegateAllowlist. inline constexpr char kAuthNegotiateDelegateByKdcPolicy[] = -@@ -3034,7 +3034,7 @@ inline constexpr char kDeviceWeeklyScheduledSuspend[] - +@@ -3271,7 +3271,7 @@ inline constexpr char kKioskChromeAppsForceAllowed[] = #endif // BUILDFLAG(IS_CHROMEOS) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) // Defines administrator-set availability of Chrome for Testing. inline constexpr char kChromeForTestingAllowed[] = "chrome_for_testing.allowed"; #endif -@@ -3584,7 +3584,7 @@ inline constexpr char kFileOrDirectoryPickerWithoutGes +@@ -3797,7 +3797,7 @@ inline constexpr char kScreenCaptureWithoutGestureAllo inline constexpr char kSandboxExternalProtocolBlocked[] = "profile.sandbox_external_protocol_blocked"; @@ -71,18 +71,18 @@ // Boolean that indicates if system notifications are allowed to be used in // place of Chrome notifications. inline constexpr char kAllowSystemNotifications[] = -@@ -3633,7 +3633,7 @@ inline constexpr char kCACertificateManagementAllowed[ +@@ -3995,7 +3995,7 @@ inline constexpr char kLensDesktopNTPSearchEnabled[] = + "policy.lens_desktop_ntp_search_enabled"; #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - inline constexpr char kEnforceLocalAnchorConstraintsEnabled[] = - "enforce_local_anchor_constraints_enabled"; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // A dict mapping the edition name with the major version it was shown. + inline constexpr char kWhatsNewEditionUsed[] = "browser.whats_new.edition_used"; + // A list containing the features of each module in order of when they +@@ -4092,7 +4092,7 @@ inline constexpr char kPrintingOAuth2AuthorizationServ + "printing.oauth2_authorization_servers"; #endif -@@ -3941,7 +3941,7 @@ inline constexpr char kPrintingOAuth2AuthorizationServ - inline constexpr char kNewBaseUrlInheritanceBehaviorAllowed[] = - "new_base_url_inheritance_behavior_allowed"; -#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_common_url__constants.h b/www/chromium/files/patch-chrome_common_url__constants.h index 798d05061d7d..b1ecc8fff477 100644 --- a/www/chromium/files/patch-chrome_common_url__constants.h +++ b/www/chromium/files/patch-chrome_common_url__constants.h @@ -1,11 +1,11 @@ ---- chrome/common/url_constants.h.orig 2024-04-19 13:02:56 UTC +--- chrome/common/url_constants.h.orig 2025-07-02 06:08:04 UTC +++ chrome/common/url_constants.h -@@ -848,7 +848,7 @@ inline constexpr char kPhoneHubPermissionLearnMoreURL[ +@@ -997,7 +997,7 @@ inline constexpr char kOutdatedPluginLearnMoreURL[] = + inline constexpr char kPhoneHubPermissionLearnMoreURL[] = "https://support.google.com/chromebook?p=multidevice"; - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // "Learn more" URL for the chrome apps deprecation dialog. inline constexpr char kChromeAppsDeprecationLearnMoreURL[] = "https://support.google.com/chrome?p=chrome_app_deprecation"; diff --git a/www/chromium/files/patch-chrome_common_webui__url__constants.cc b/www/chromium/files/patch-chrome_common_webui__url__constants.cc index c0adbb4040a8..505a9ed754d6 100644 --- a/www/chromium/files/patch-chrome_common_webui__url__constants.cc +++ b/www/chromium/files/patch-chrome_common_webui__url__constants.cc @@ -1,68 +1,28 @@ ---- chrome/common/webui_url_constants.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/common/webui_url_constants.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/common/webui_url_constants.cc -@@ -518,18 +518,18 @@ const char kOsUISystemURL[] = "os://system"; - const char kOsUIVersionURL[] = "os://version"; +@@ -193,21 +193,21 @@ base::span<const base::cstring_view> ChromeURLHosts() + kChromeUIAssistantOptInHost, #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const char kChromeUIWebUIJsErrorHost[] = "webuijserror"; - const char kChromeUIWebUIJsErrorURL[] = "chrome://webuijserror/"; - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - const char kChromeUIConnectorsInternalsHost[] = "connectors-internals"; - #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const char kChromeUIDiscardsHost[] = "discards"; - const char kChromeUIDiscardsURL[] = "chrome://discards/"; + kChromeUIConnectorsInternalsHost, + #endif + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) || BUILDFLAG(IS_BSD) + kChromeUIDiscardsHost, + #endif +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + kChromeUIWebAppSettingsHost, #endif -@@ -544,14 +544,14 @@ const char kChromeUILinuxProxyConfigHost[] = "linux-pr + #if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_ANDROID) + kChromeUILinuxProxyConfigHost, #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_ANDROID) + BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - const char kChromeUISandboxHost[] = "sandbox"; - #endif - - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) - const char kChromeUIBrowserSwitchHost[] = "browser-switch"; - const char kChromeUIBrowserSwitchURL[] = "chrome://browser-switch/"; - const char kChromeUIIntroHost[] = "intro"; -@@ -570,7 +570,7 @@ const char kChromeUIProfilePickerUrl[] = "chrome://pro - const char kChromeUIProfilePickerStartupQuery[] = "startup"; - #endif - --#if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ -+#if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && \ - defined(TOOLKIT_VIEWS)) || \ - defined(USE_AURA) - const char kChromeUITabModalConfirmDialogHost[] = "tab-modal-confirm-dialog"; -@@ -650,7 +650,7 @@ const char kCookiesSubPagePath[] = "/cookies"; - #endif - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - const char kChromeUIWebAppSettingsURL[] = "chrome://app-settings/"; - const char kChromeUIWebAppSettingsHost[] = "app-settings"; - #endif -@@ -879,7 +879,7 @@ const char* const kChromeDebugURLs[] = { - blink::kChromeUIGpuJavaCrashURL, - kChromeUIJavaCrashURL, - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - kChromeUIWebUIJsErrorURL, + kChromeUISandboxHost, #endif - kChromeUIQuitURL, + #if BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-chrome_common_webui__url__constants.h b/www/chromium/files/patch-chrome_common_webui__url__constants.h index cdb49c4775ac..a41e27245484 100644 --- a/www/chromium/files/patch-chrome_common_webui__url__constants.h +++ b/www/chromium/files/patch-chrome_common_webui__url__constants.h @@ -1,57 +1,47 @@ ---- chrome/common/webui_url_constants.h.orig 2024-04-19 13:02:56 UTC +--- chrome/common/webui_url_constants.h.orig 2025-07-02 06:08:04 UTC +++ chrome/common/webui_url_constants.h -@@ -437,24 +437,24 @@ extern const char kOsUISystemURL[]; - extern const char kOsUIVersionURL[]; - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - extern const char kChromeUIWebUIJsErrorHost[]; - extern const char kChromeUIWebUIJsErrorURL[]; - #endif +@@ -540,18 +540,18 @@ inline constexpr char kChromeUIOsUrlAppURL[] = "chrome + #endif // BUILDFLAG(IS_CHROMEOS) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - extern const char kChromeUIConnectorsInternalsHost[]; +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + inline constexpr char kChromeUIConnectorsInternalsHost[] = + "connectors-internals"; #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - extern const char kChromeUIDiscardsHost[]; - extern const char kChromeUIDiscardsURL[]; +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_DESKTOP_ANDROID) || BUILDFLAG(IS_BSD) + inline constexpr char kChromeUIDiscardsHost[] = "discards"; + inline constexpr char kChromeUIDiscardsURL[] = "chrome://discards/"; #endif - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - extern const char kChromeUIWebAppSettingsURL[]; - extern const char kChromeUIWebAppSettingsHost[]; - #endif -@@ -469,14 +469,14 @@ extern const char kChromeUILinuxProxyConfigHost[]; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + inline constexpr char kChromeUIWebAppSettingsHost[] = "app-settings"; + inline constexpr char kChromeUIWebAppSettingsURL[] = "chrome://app-settings/"; + inline constexpr char kChromeUIWhatsNewHost[] = "whats-new"; +@@ -563,11 +563,11 @@ inline constexpr char kChromeUILinuxProxyConfigHost[] #endif #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_ANDROID) + BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - extern const char kChromeUISandboxHost[]; + inline constexpr char kChromeUISandboxHost[] = "sandbox"; #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_BSD) - extern const char kChromeUIBrowserSwitchHost[]; - extern const char kChromeUIBrowserSwitchURL[]; - extern const char kChromeUIIntroHost[]; -@@ -492,7 +492,7 @@ extern const char kChromeUIProfilePickerUrl[]; - extern const char kChromeUIProfilePickerStartupQuery[]; +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + inline constexpr char kChromeUIBrowserSwitchHost[] = "browser-switch"; + inline constexpr char kChromeUIBrowserSwitchURL[] = "chrome://browser-switch/"; + inline constexpr char kChromeUIIntroDefaultBrowserSubPage[] = "default-browser"; +@@ -592,7 +592,7 @@ inline constexpr char kChromeUIHistorySyncOptinURL[] = + "chrome://history-sync-optin/"; #endif -#if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ +#if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && \ defined(TOOLKIT_VIEWS)) || \ defined(USE_AURA) - extern const char kChromeUITabModalConfirmDialogHost[]; + inline constexpr char kChromeUITabModalConfirmDialogHost[] = diff --git a/www/chromium/files/patch-chrome_enterprise__companion_enterprise__companion__client.cc b/www/chromium/files/patch-chrome_enterprise__companion_enterprise__companion__client.cc new file mode 100644 index 000000000000..c7f4870fe30d --- /dev/null +++ b/www/chromium/files/patch-chrome_enterprise__companion_enterprise__companion__client.cc @@ -0,0 +1,11 @@ +--- chrome/enterprise_companion/enterprise_companion_client.cc.orig 2025-03-05 08:14:56 UTC ++++ chrome/enterprise_companion/enterprise_companion_client.cc +@@ -35,7 +35,7 @@ namespace { + + #if BUILDFLAG(IS_MAC) + constexpr char kServerName[] = MAC_BUNDLE_IDENTIFIER_STRING ".service"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr char kServerName[] = + "/run/" COMPANY_SHORTNAME_STRING "/" PRODUCT_FULLNAME_STRING "/service.sk"; + #elif BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-chrome_enterprise__companion_event__logger.cc b/www/chromium/files/patch-chrome_enterprise__companion_event__logger.cc new file mode 100644 index 000000000000..6ba96cbb251f --- /dev/null +++ b/www/chromium/files/patch-chrome_enterprise__companion_event__logger.cc @@ -0,0 +1,11 @@ +--- chrome/enterprise_companion/event_logger.cc.orig 2025-05-05 10:57:53 UTC ++++ chrome/enterprise_companion/event_logger.cc +@@ -126,7 +126,7 @@ proto::EnterpriseCompanionMetadata GetMetadata() { + metadata.set_application_arch(proto::ARM64); + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + metadata.set_os_platform(proto::LINUX); + #elif BUILDFLAG(IS_MAC) + metadata.set_os_platform(proto::MAC); diff --git a/www/chromium/files/patch-chrome_enterprise__companion_lock.cc b/www/chromium/files/patch-chrome_enterprise__companion_lock.cc new file mode 100644 index 000000000000..d552b9f60ce3 --- /dev/null +++ b/www/chromium/files/patch-chrome_enterprise__companion_lock.cc @@ -0,0 +1,20 @@ +--- chrome/enterprise_companion/lock.cc.orig 2024-08-26 12:06:38 UTC ++++ chrome/enterprise_companion/lock.cc +@@ -17,7 +17,7 @@ + + namespace { + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr char kLockName[] = "/" PRODUCT_FULLNAME_STRING ".lock"; + #elif BUILDFLAG(IS_MAC) + constexpr char kLockName[] = MAC_BUNDLE_IDENTIFIER_STRING ".lock"; +@@ -42,7 +42,7 @@ CSecurityDesc GetAdminDaclSecurityDescriptor() { + namespace enterprise_companion { + + std::unique_ptr<ScopedLock> CreateScopedLock(base::TimeDelta timeout) { +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return named_system_lock::ScopedLock::Create(kLockName, timeout); + #elif BUILDFLAG(IS_WIN) + CSecurityAttributes sa = diff --git a/www/chromium/files/patch-chrome_renderer_chrome__render__frame__observer.cc b/www/chromium/files/patch-chrome_renderer_chrome__render__frame__observer.cc deleted file mode 100644 index ecb4426cda6b..000000000000 --- a/www/chromium/files/patch-chrome_renderer_chrome__render__frame__observer.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/renderer/chrome_render_frame_observer.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/renderer/chrome_render_frame_observer.cc -@@ -358,7 +358,7 @@ void ChromeRenderFrameObserver::WillDetach(blink::Deta - - void ChromeRenderFrameObserver::DraggableRegionsChanged() { - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Only the main frame is allowed to control draggable regions, to avoid other - // frames manipulate the regions in the browser process. - if (!render_frame()->IsMainFrame()) diff --git a/www/chromium/files/patch-chrome_services_file__util_public_mojom_safe__document__analyzer__mojom__traits.h b/www/chromium/files/patch-chrome_services_file__util_public_mojom_safe__document__analyzer__mojom__traits.h deleted file mode 100644 index 89d477a9c262..000000000000 --- a/www/chromium/files/patch-chrome_services_file__util_public_mojom_safe__document__analyzer__mojom__traits.h +++ /dev/null @@ -1,11 +0,0 @@ ---- chrome/services/file_util/public/mojom/safe_document_analyzer_mojom_traits.h.orig 2023-04-05 11:05:06 UTC -+++ chrome/services/file_util/public/mojom/safe_document_analyzer_mojom_traits.h -@@ -16,7 +16,7 @@ - #include "mojo/public/cpp/bindings/struct_traits.h" - - #if !BUILDFLAG(FULL_SAFE_BROWSING) || \ -- (!BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_WIN)) -+ (!BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_BSD)) - #error FULL_SAFE_BROWSING should be set and either IS_LINUX or IS_WIN set. - #endif - diff --git a/www/chromium/files/patch-chrome_services_printing_print__backend__service__impl.cc b/www/chromium/files/patch-chrome_services_printing_print__backend__service__impl.cc index d40b51e2da49..1934911d37a4 100644 --- a/www/chromium/files/patch-chrome_services_printing_print__backend__service__impl.cc +++ b/www/chromium/files/patch-chrome_services_printing_print__backend__service__impl.cc @@ -1,6 +1,6 @@ ---- chrome/services/printing/print_backend_service_impl.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/services/printing/print_backend_service_impl.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/services/printing/print_backend_service_impl.cc -@@ -49,7 +49,7 @@ +@@ -48,7 +48,7 @@ #include "printing/backend/cups_connection_pool.h" #endif @@ -9,16 +9,16 @@ #include "base/no_destructor.h" #include "ui/linux/linux_ui.h" #include "ui/linux/linux_ui_delegate_stub.h" -@@ -76,7 +76,7 @@ namespace printing { +@@ -75,7 +75,7 @@ namespace printing { namespace { -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void InstantiateLinuxUiDelegate() { - // TODO(crbug.com/809738) Until a real UI can be used in a utility process, + // TODO(crbug.com/40561724) Until a real UI can be used in a utility process, // need to use the stub version. -@@ -85,7 +85,7 @@ void InstantiateLinuxUiDelegate() { +@@ -84,7 +84,7 @@ void InstantiateLinuxUiDelegate() { #endif scoped_refptr<base::SequencedTaskRunner> GetPrintingTaskRunner() { @@ -27,7 +27,7 @@ // Use task runner associated with equivalent of UI thread. Needed for calls // made through `PrintDialogLinuxInterface` to properly execute. CHECK(base::SequencedTaskRunner::HasCurrentDefault()); -@@ -469,7 +469,7 @@ void PrintBackendServiceImpl::Init( +@@ -467,7 +467,7 @@ void PrintBackendServiceImpl::Init( // `InitCommon()`. InitializeProcessForPrinting(); print_backend_ = PrintBackend::CreateInstance(locale); @@ -36,7 +36,7 @@ // Test framework already initializes the UI, so this should not go in // `InitCommon()`. Additionally, low-level Linux UI is not needed when tests // are using `TestPrintingContext`. -@@ -690,7 +690,7 @@ void PrintBackendServiceImpl::UpdatePrintSettings( +@@ -688,7 +688,7 @@ void PrintBackendServiceImpl::UpdatePrintSettings( crash_keys_ = std::make_unique<crash_keys::ScopedPrinterInfo>( *printer_name, print_backend_->GetPrinterDriverInfo(*printer_name)); diff --git a/www/chromium/files/patch-chrome_services_speech_audio__source__fetcher__impl.cc b/www/chromium/files/patch-chrome_services_speech_audio__source__fetcher__impl.cc index 167d26944f95..22cc612f4c4d 100644 --- a/www/chromium/files/patch-chrome_services_speech_audio__source__fetcher__impl.cc +++ b/www/chromium/files/patch-chrome_services_speech_audio__source__fetcher__impl.cc @@ -1,8 +1,8 @@ ---- chrome/services/speech/audio_source_fetcher_impl.cc.orig 2024-04-19 13:02:56 UTC +--- chrome/services/speech/audio_source_fetcher_impl.cc.orig 2024-06-17 12:56:06 UTC +++ chrome/services/speech/audio_source_fetcher_impl.cc @@ -132,7 +132,7 @@ void AudioSourceFetcherImpl::Start( - // TODO(crbug.com/1185978): Check implementation / sandbox policy on Mac and + // TODO(crbug.com/40753481): Check implementation / sandbox policy on Mac and // Windows. -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-chrome_test_base_scoped__channel__override__posix.cc b/www/chromium/files/patch-chrome_test_base_scoped__channel__override__posix.cc new file mode 100644 index 000000000000..8b9b73a4daf3 --- /dev/null +++ b/www/chromium/files/patch-chrome_test_base_scoped__channel__override__posix.cc @@ -0,0 +1,11 @@ +--- chrome/test/base/scoped_channel_override_posix.cc.orig 2025-05-28 14:55:43 UTC ++++ chrome/test/base/scoped_channel_override_posix.cc +@@ -43,7 +43,7 @@ std::string GetVersionExtra(ScopedChannelOverride::Cha + return "beta"; + case ScopedChannelOverride::Channel::kDev: + return "unstable"; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + case ScopedChannelOverride::Channel::kCanary: + return "canary"; + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-chrome_test_chromedriver_chrome__launcher.cc b/www/chromium/files/patch-chrome_test_chromedriver_chrome__launcher.cc index c4d029edcf6d..a566027a861c 100644 --- a/www/chromium/files/patch-chrome_test_chromedriver_chrome__launcher.cc +++ b/www/chromium/files/patch-chrome_test_chromedriver_chrome__launcher.cc @@ -1,6 +1,6 @@ ---- chrome/test/chromedriver/chrome_launcher.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/test/chromedriver/chrome_launcher.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/test/chromedriver/chrome_launcher.cc -@@ -73,6 +73,7 @@ +@@ -74,6 +74,7 @@ #include <fcntl.h> #include <sys/stat.h> #include <sys/types.h> diff --git a/www/chromium/files/patch-chrome_test_chromedriver_chrome_chrome__finder.cc b/www/chromium/files/patch-chrome_test_chromedriver_chrome_chrome__finder.cc index 7cd002633b15..d1202e4d20c8 100644 --- a/www/chromium/files/patch-chrome_test_chromedriver_chrome_chrome__finder.cc +++ b/www/chromium/files/patch-chrome_test_chromedriver_chrome_chrome__finder.cc @@ -1,6 +1,6 @@ ---- chrome/test/chromedriver/chrome/chrome_finder.cc.orig 2023-12-10 06:10:27 UTC +--- chrome/test/chromedriver/chrome/chrome_finder.cc.orig 2025-05-28 14:55:43 UTC +++ chrome/test/chromedriver/chrome/chrome_finder.cc -@@ -58,7 +58,7 @@ void GetApplicationDirs(std::vector<base::FilePath>* l +@@ -59,7 +59,7 @@ void GetApplicationDirs(std::vector<base::FilePath>* l installation_locations[i].Append(L"Chromium\\Application")); } } @@ -9,7 +9,7 @@ void GetApplicationDirs(std::vector<base::FilePath>* locations) { // TODO: Respect users' PATH variables. // Until then, we use an approximation of the most common defaults. -@@ -125,7 +125,7 @@ std::vector<base::FilePath> GetChromeProgramNames() { +@@ -126,7 +126,7 @@ std::vector<base::FilePath> GetChromeProgramNames() { chrome::kGoogleChromeForTestingBrowserProcessExecutablePath), base::FilePath(chrome::kGoogleChromeBrowserProcessExecutablePath), base::FilePath(chrome::kChromiumBrowserProcessExecutablePath), @@ -18,7 +18,7 @@ base::FilePath(chrome::kBrowserProcessExecutablePath), base::FilePath("chrome"), // Chrome for Testing or Google Chrome base::FilePath("google-chrome"), base::FilePath("chromium"), -@@ -141,7 +141,7 @@ std::vector<base::FilePath> GetHeadlessShellProgramNam +@@ -142,7 +142,7 @@ std::vector<base::FilePath> GetHeadlessShellProgramNam return { #if BUILDFLAG(IS_WIN) base::FilePath(FILE_PATH_LITERAL("chrome-headless-shell.exe")), diff --git a/www/chromium/files/patch-chrome_test_chromedriver_key__converter__unittest.cc b/www/chromium/files/patch-chrome_test_chromedriver_key__converter__unittest.cc index 656e8e79e233..a3ffb2e37b9e 100644 --- a/www/chromium/files/patch-chrome_test_chromedriver_key__converter__unittest.cc +++ b/www/chromium/files/patch-chrome_test_chromedriver_key__converter__unittest.cc @@ -1,6 +1,6 @@ ---- chrome/test/chromedriver/key_converter_unittest.cc.orig 2022-03-25 21:59:56 UTC +--- chrome/test/chromedriver/key_converter_unittest.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/test/chromedriver/key_converter_unittest.cc -@@ -246,7 +246,7 @@ TEST(KeyConverter, ToggleModifiers) { +@@ -248,7 +248,7 @@ TEST(KeyConverter, ToggleModifiers) { CheckEventsReleaseModifiers(keys, key_events); } @@ -9,12 +9,12 @@ // Fails on bots: crbug.com/174962 #define MAYBE_AllEnglishKeyboardSymbols DISABLED_AllEnglishKeyboardSymbols #else -@@ -303,7 +303,7 @@ TEST(KeyConverter, AllEnglishKeyboardTextChars) { +@@ -306,7 +306,7 @@ TEST(KeyConverter, AllEnglishKeyboardTextChars) { TEST(KeyConverter, AllSpecialWebDriverKeysOnEnglishKeyboard) { ui::ScopedKeyboardLayout keyboard_layout(ui::KEYBOARD_LAYOUT_ENGLISH_US); - const char kTextForKeys[] = { + const auto kTextForKeys = std::to_array<char>({ -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - 0, 0, 0, 0, '\t', 0, '\r', '\r', 0, 0, 0, 0, 0, + 0, 0, 0, 0, '\t', 0, '\r', '\r', 0, 0, 0, 0, 0, #else - 0, 0, 0, 0, 0, 0, '\r', '\r', 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, '\r', '\r', 0, 0, 0, 0, 0, diff --git a/www/chromium/files/patch-chrome_test_chromedriver_keycode__text__conversion__unittest.cc b/www/chromium/files/patch-chrome_test_chromedriver_keycode__text__conversion__unittest.cc index 41305b1e68f5..596e7b11a967 100644 --- a/www/chromium/files/patch-chrome_test_chromedriver_keycode__text__conversion__unittest.cc +++ b/www/chromium/files/patch-chrome_test_chromedriver_keycode__text__conversion__unittest.cc @@ -1,20 +1,20 @@ ---- chrome/test/chromedriver/keycode_text_conversion_unittest.cc.orig 2022-09-24 10:57:32 UTC +--- chrome/test/chromedriver/keycode_text_conversion_unittest.cc.orig 2025-04-04 08:52:13 UTC +++ chrome/test/chromedriver/keycode_text_conversion_unittest.cc -@@ -67,7 +67,7 @@ std::string ConvertKeyCodeToTextNoError(ui::KeyboardCo +@@ -64,7 +64,7 @@ std::string ConvertKeyCodeToTextNoError(ui::KeyboardCo - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) + } // namespace + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Fails on bots: crbug.com/174962 #define MAYBE_KeyCodeToText DISABLED_KeyCodeToText #else -@@ -104,7 +104,7 @@ TEST(KeycodeTextConversionTest, MAYBE_KeyCodeToText) { +@@ -98,7 +98,7 @@ TEST(KeycodeTextConversionTest, MAYBE_KeyCodeToText) { + ConvertKeyCodeToTextNoError(ui::VKEY_SHIFT, kShiftKeyModifierMask)); + } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Fails on bots: crbug.com/174962 #define MAYBE_CharToKeyCode DISABLED_CharToKeyCode #else diff --git a/www/chromium/files/patch-chrome_test_supervised__user_google__auth__state__waiter__mixin.cc b/www/chromium/files/patch-chrome_test_supervised__user_google__auth__state__waiter__mixin.cc new file mode 100644 index 000000000000..759cce42ba71 --- /dev/null +++ b/www/chromium/files/patch-chrome_test_supervised__user_google__auth__state__waiter__mixin.cc @@ -0,0 +1,11 @@ +--- chrome/test/supervised_user/google_auth_state_waiter_mixin.cc.orig 2024-10-22 08:31:56 UTC ++++ chrome/test/supervised_user/google_auth_state_waiter_mixin.cc +@@ -24,7 +24,7 @@ GoogleAuthStateWaiterMixin::GoogleAuthStateWaiterMixin + GoogleAuthStateWaiterMixin::~GoogleAuthStateWaiterMixin() = default; + + void GoogleAuthStateWaiterMixin::SetUpOnMainThread() { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + ChildAccountService* child_account_service = + ChildAccountServiceFactory::GetForProfile( + test_base_->browser()->profile()); diff --git a/www/chromium/files/patch-chrome_updater_app_app__uninstall.cc b/www/chromium/files/patch-chrome_updater_app_app__uninstall.cc new file mode 100644 index 000000000000..e855e7b73646 --- /dev/null +++ b/www/chromium/files/patch-chrome_updater_app_app__uninstall.cc @@ -0,0 +1,11 @@ +--- chrome/updater/app/app_uninstall.cc.orig 2025-07-02 06:08:04 UTC ++++ chrome/updater/app/app_uninstall.cc +@@ -181,7 +181,7 @@ void UninstallInThreadPool(UpdaterScope scope, + } + if (int result = UninstallOtherVersions(scope); + result != kErrorOk) { +-#if !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) + // TODO(crbug.com/366249606): Ignores the errors when uninstalls + // the other versions, because currently older Linux updater on + // CIPD exits with error `kErrorFailedToDeleteFolder`. diff --git a/www/chromium/files/patch-chrome_updater_configurator.cc b/www/chromium/files/patch-chrome_updater_configurator.cc index 4832e36163ac..74b73c1460a4 100644 --- a/www/chromium/files/patch-chrome_updater_configurator.cc +++ b/www/chromium/files/patch-chrome_updater_configurator.cc @@ -1,6 +1,6 @@ ---- chrome/updater/configurator.cc.orig 2024-02-23 21:04:38 UTC +--- chrome/updater/configurator.cc.orig 2025-07-02 06:08:04 UTC +++ chrome/updater/configurator.cc -@@ -67,7 +67,7 @@ Configurator::Configurator(scoped_refptr<UpdaterPrefs> +@@ -91,7 +91,7 @@ Configurator::Configurator(scoped_refptr<UpdaterPrefs> return std::nullopt; #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) }()) { diff --git a/www/chromium/files/patch-chrome_updater_lock.cc b/www/chromium/files/patch-chrome_updater_lock.cc new file mode 100644 index 000000000000..ecd75e63de6c --- /dev/null +++ b/www/chromium/files/patch-chrome_updater_lock.cc @@ -0,0 +1,11 @@ +--- chrome/updater/lock.cc.orig 2024-07-30 11:12:21 UTC ++++ chrome/updater/lock.cc +@@ -26,7 +26,7 @@ namespace updater { + std::unique_ptr<ScopedLock> CreateScopedLock(const std::string& name, + UpdaterScope scope, + base::TimeDelta timeout) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return named_system_lock::ScopedLock::Create( + base::StrCat({"/" PRODUCT_FULLNAME_STRING, name, + UpdaterScopeToString(scope), ".lock"}), diff --git a/www/chromium/files/patch-chrome_utility_services.cc b/www/chromium/files/patch-chrome_utility_services.cc index c897d782f2e7..35e58e5cfdc3 100644 --- a/www/chromium/files/patch-chrome_utility_services.cc +++ b/www/chromium/files/patch-chrome_utility_services.cc @@ -1,6 +1,6 @@ ---- chrome/utility/services.cc.orig 2024-03-22 08:19:40 UTC +--- chrome/utility/services.cc.orig 2025-05-05 10:57:53 UTC +++ chrome/utility/services.cc -@@ -55,7 +55,7 @@ +@@ -48,7 +48,7 @@ #include "chrome/services/system_signals/mac/mac_system_signals_service.h" #endif // BUILDFLAG(IS_MAC) @@ -9,16 +9,7 @@ #include "chrome/services/system_signals/linux/linux_system_signals_service.h" #endif // BUILDFLAG(IS_LINUX) -@@ -81,7 +81,7 @@ - #include "chrome/services/file_util/file_util_service.h" // nogncheck - #endif - --#if BUILDFLAG(FULL_SAFE_BROWSING) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN)) -+#if BUILDFLAG(FULL_SAFE_BROWSING) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) - #include "chrome/services/file_util/document_analysis_service.h" // nogncheck - #endif - -@@ -212,7 +212,7 @@ auto RunMacNotificationService( +@@ -205,7 +205,7 @@ auto RunMacNotificationService( } #endif // BUILDFLAG(IS_MAC) @@ -27,16 +18,7 @@ auto RunSystemSignalsService( mojo::PendingReceiver<device_signals::mojom::SystemSignalsService> receiver) { -@@ -272,7 +272,7 @@ auto RunCupsIppParser( - } - #endif - --#if BUILDFLAG(FULL_SAFE_BROWSING) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN)) -+#if BUILDFLAG(FULL_SAFE_BROWSING) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) - auto RunDocumentAnalysis( - mojo::PendingReceiver<chrome::mojom::DocumentAnalysisService> receiver) { - return std::make_unique<DocumentAnalysisService>(std::move(receiver)); -@@ -465,7 +465,7 @@ void RegisterMainThreadServices(mojo::ServiceFactory& +@@ -479,7 +479,7 @@ void RegisterMainThreadServices(mojo::ServiceFactory& services.Add(RunWindowsIconReader); #endif // BUILDFLAG(IS_WIN) @@ -45,12 +27,3 @@ services.Add(RunSystemSignalsService); #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -@@ -481,7 +481,7 @@ void RegisterMainThreadServices(mojo::ServiceFactory& - services.Add(RunFileUtil); - #endif - --#if BUILDFLAG(FULL_SAFE_BROWSING) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN)) -+#if BUILDFLAG(FULL_SAFE_BROWSING) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) - services.Add(RunDocumentAnalysis); - #endif - diff --git a/www/chromium/files/patch-chromecast_browser_cast__browser__main__parts.cc b/www/chromium/files/patch-chromecast_browser_cast__browser__main__parts.cc index 06e27b938b36..d35852ea340a 100644 --- a/www/chromium/files/patch-chromecast_browser_cast__browser__main__parts.cc +++ b/www/chromium/files/patch-chromecast_browser_cast__browser__main__parts.cc @@ -1,15 +1,15 @@ ---- chromecast/browser/cast_browser_main_parts.cc.orig 2023-07-16 15:47:57 UTC +--- chromecast/browser/cast_browser_main_parts.cc.orig 2025-07-02 06:08:04 UTC +++ chromecast/browser/cast_browser_main_parts.cc -@@ -90,7 +90,7 @@ - #include "ui/base/ui_base_switches.h" - #include "ui/gl/gl_switches.h" +@@ -100,7 +100,7 @@ + #include "ui/ozone/public/ozone_platform.h" + #endif // BUILDFLAG(IS_OZONE) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include <fontconfig/fontconfig.h> #include <signal.h> #include <sys/prctl.h> -@@ -263,7 +263,7 @@ class CastViewsDelegate : public views::ViewsDelegate +@@ -282,7 +282,7 @@ class CastViewsDelegate : public views::ViewsDelegate #endif // defined(USE_AURA) @@ -18,8 +18,8 @@ base::FilePath GetApplicationFontsDir() { std::unique_ptr<base::Environment> env(base::Environment::Create()); -@@ -309,7 +309,7 @@ const DefaultCommandLineSwitch kDefaultSwitches[] = { - {cc::switches::kDisableThreadedAnimation, ""}, +@@ -327,7 +327,7 @@ const DefaultCommandLineSwitch kDefaultSwitches[] = { + {switches::kDisableThreadedAnimation, ""}, #endif // BUILDFLAG(IS_ANDROID) #endif // BUILDFLAG(IS_CAST_AUDIO_ONLY) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -27,7 +27,7 @@ #if defined(ARCH_CPU_X86_FAMILY) // This is needed for now to enable the x11 Ozone platform to work with // current Linux/NVidia OpenGL drivers. -@@ -479,7 +479,7 @@ void CastBrowserMainParts::ToolkitInitialized() { +@@ -504,7 +504,7 @@ void CastBrowserMainParts::ToolkitInitialized() { views_delegate_ = std::make_unique<CastViewsDelegate>(); #endif // defined(USE_AURA) diff --git a/www/chromium/files/patch-chromecast_browser_cast__content__browser__client.cc b/www/chromium/files/patch-chromecast_browser_cast__content__browser__client.cc index d38b3db68c50..f736455c31eb 100644 --- a/www/chromium/files/patch-chromecast_browser_cast__content__browser__client.cc +++ b/www/chromium/files/patch-chromecast_browser_cast__content__browser__client.cc @@ -1,4 +1,4 @@ ---- chromecast/browser/cast_content_browser_client.cc.orig 2024-03-22 08:19:40 UTC +--- chromecast/browser/cast_content_browser_client.cc.orig 2025-04-04 08:52:13 UTC +++ chromecast/browser/cast_content_browser_client.cc @@ -434,7 +434,7 @@ void CastContentBrowserClient::AppendExtraCommandLineS switches::kAudioOutputChannels)); diff --git a/www/chromium/files/patch-chromecast_cast__core_runtime_browser_runtime__application__service__impl.cc b/www/chromium/files/patch-chromecast_cast__core_runtime_browser_runtime__application__service__impl.cc new file mode 100644 index 000000000000..a74d22743de4 --- /dev/null +++ b/www/chromium/files/patch-chromecast_cast__core_runtime_browser_runtime__application__service__impl.cc @@ -0,0 +1,11 @@ +--- chromecast/cast_core/runtime/browser/runtime_application_service_impl.cc.orig 2025-04-04 08:52:13 UTC ++++ chromecast/cast_core/runtime/browser/runtime_application_service_impl.cc +@@ -352,7 +352,7 @@ CastWebView::Scoped RuntimeApplicationServiceImpl::Cre + params->force_720p_resolution = + GetFlagEntry(feature::kCastCoreForce720p, config_.extra_features(), + /*default_value=*/false); +-#if BUILDFLAG(ENABLE_CAST_RECEIVER) && BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(ENABLE_CAST_RECEIVER) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) + // Starboard-based (linux) cast receivers may not render their UI at 720p, so + // we need to scale to the proper resolution. For example, a 4k TV may render + // the window at 1920x1080, so a scaling factor of 1.5 is necessary for a 720p diff --git a/www/chromium/files/patch-components_BUILD.gn b/www/chromium/files/patch-components_BUILD.gn new file mode 100644 index 000000000000..2b277a5e2219 --- /dev/null +++ b/www/chromium/files/patch-components_BUILD.gn @@ -0,0 +1,28 @@ +--- components/BUILD.gn.orig 2025-07-02 06:08:04 UTC ++++ components/BUILD.gn +@@ -211,7 +211,6 @@ test("components_unittests") { + "//components/content_settings/core/browser:unit_tests", + "//components/content_settings/core/common:unit_tests", + "//components/country_codes:unit_tests", +- "//components/crash/core/common:unit_tests", + "//components/cross_device/logging:unit_tests", + "//components/crx_file:unit_tests", + "//components/data_sharing:unit_tests", +@@ -616,7 +615,7 @@ test("components_unittests") { + deps += [ "//components/cast:unit_tests" ] + } + +- if (!is_fuchsia) { #!iOS and!Fuchsia ++ if (!is_fuchsia && !is_bsd) { #!iOS and!Fuchsia + deps += [ + "//components/crash/content/browser:unit_tests", + "//components/crash/core/app:unit_tests", +@@ -780,7 +779,7 @@ test("components_unittests") { + deps += [ "//components/constrained_window:unit_tests" ] + } + +- if (is_win || is_linux || is_chromeos || is_mac) { ++ if (is_win || (is_linux && !is_bsd) || is_chromeos || is_mac) { + deps += [ "//components/stability_report:unit_tests" ] + } + diff --git a/www/chromium/files/patch-components_autofill_core_browser_data__manager_payments_payments__data__manager.cc b/www/chromium/files/patch-components_autofill_core_browser_data__manager_payments_payments__data__manager.cc new file mode 100644 index 000000000000..e60d357bd42a --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_data__manager_payments_payments__data__manager.cc @@ -0,0 +1,47 @@ +--- components/autofill/core/browser/data_manager/payments/payments_data_manager.cc.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/browser/data_manager/payments/payments_data_manager.cc +@@ -472,7 +472,7 @@ void PaymentsDataManager::OnWebDataServiceRequestDone( + + bool PaymentsDataManager::ShouldShowBnplSettings() const { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Check `kAutofillEnableBuyNowPayLater` only if the user has seen a BNPL + // suggestion before, or there are already linked issuers present, to avoid + // unnecessary feature flag checks. The linked issuer check is due to the fact +@@ -983,7 +983,7 @@ void PaymentsDataManager::SetPrefService(PrefService* + &PaymentsDataManager::OnAutofillPaymentsCardBenefitsPrefChange, + base::Unretained(this))); + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + pref_registrar_.Add( + prefs::kAutofillBnplEnabled, + base::BindRepeating(&PaymentsDataManager::OnBnplEnabledPrefChange, +@@ -1067,7 +1067,7 @@ void PaymentsDataManager::SetAutofillHasSeenIban() { + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + bool PaymentsDataManager::IsAutofillHasSeenBnplPrefEnabled() const { + return prefs::HasSeenBnpl(pref_service_); + } +@@ -2060,7 +2060,7 @@ bool PaymentsDataManager::AreEwalletAccountsSupported( + + bool PaymentsDataManager::AreBnplIssuersSupported() const { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return app_locale_ == "en-US" && GetCountryCodeForExperimentGroup() == "US" && + base::FeatureList::IsEnabled( + features::kAutofillEnableBuyNowPayLaterSyncing); +@@ -2093,7 +2093,7 @@ void PaymentsDataManager::ClearAllCreditCardBenefits() + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void PaymentsDataManager::OnBnplEnabledPrefChange() { + // On pref change to `false`, clearing BNPL issuers is implicitly handled by + // `GetBnplIssuers()`, since it returns an empty vector when diff --git a/www/chromium/files/patch-components_autofill_core_browser_data__manager_payments_payments__data__manager.h b/www/chromium/files/patch-components_autofill_core_browser_data__manager_payments_payments__data__manager.h new file mode 100644 index 000000000000..39bd47289926 --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_data__manager_payments_payments__data__manager.h @@ -0,0 +1,20 @@ +--- components/autofill/core/browser/data_manager/payments/payments_data_manager.h.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/browser/data_manager/payments/payments_data_manager.h +@@ -365,7 +365,7 @@ class PaymentsDataManager : public AutofillWebDataServ + void SetAutofillHasSeenIban(); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Returns the value of the kAutofillHasSeenBnpl pref. + bool IsAutofillHasSeenBnplPrefEnabled() const; + +@@ -685,7 +685,7 @@ class PaymentsDataManager : public AutofillWebDataServ + void ClearAllCreditCardBenefits(); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Monitors the `kAutofillBnplEnabled` preference for changes and controls the + // clearing/loading of payment instruments accordingly. Will also log the + // `Autofill.SettingsPage.BnplToggled` metric. diff --git a/www/chromium/files/patch-components_autofill_core_browser_foundations_browser__autofill__manager.cc b/www/chromium/files/patch-components_autofill_core_browser_foundations_browser__autofill__manager.cc new file mode 100644 index 000000000000..f63dc61e3a3c --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_foundations_browser__autofill__manager.cc @@ -0,0 +1,11 @@ +--- components/autofill/core/browser/foundations/browser_autofill_manager.cc.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/browser/foundations/browser_autofill_manager.cc +@@ -740,7 +740,7 @@ BrowserAutofillManager::GetCreditCardAccessManager() c + + payments::BnplManager* BrowserAutofillManager::GetPaymentsBnplManager() { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (!bnpl_manager_) { + bnpl_manager_ = std::make_unique<payments::BnplManager>(this); + } diff --git a/www/chromium/files/patch-components_autofill_core_browser_integrators_optimization__guide_autofill__optimization__guide.cc b/www/chromium/files/patch-components_autofill_core_browser_integrators_optimization__guide_autofill__optimization__guide.cc new file mode 100644 index 000000000000..947f4d1dedd7 --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_integrators_optimization__guide_autofill__optimization__guide.cc @@ -0,0 +1,11 @@ +--- components/autofill/core/browser/integrators/optimization_guide/autofill_optimization_guide.cc.orig 2025-05-28 14:55:43 UTC ++++ components/autofill/core/browser/integrators/optimization_guide/autofill_optimization_guide.cc +@@ -232,7 +232,7 @@ void AutofillOptimizationGuide::OnDidParseForm( + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + auto bnpl_issuer_allowlist_can_be_loaded = + [&payments_data_manager](BnplIssuer::IssuerId issuer_id) { + return base::Contains(payments_data_manager.GetBnplIssuers(), issuer_id, diff --git a/www/chromium/files/patch-components_autofill_core_browser_payments_amount__extraction__manager.cc b/www/chromium/files/patch-components_autofill_core_browser_payments_amount__extraction__manager.cc new file mode 100644 index 000000000000..5246dc8a8727 --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_payments_amount__extraction__manager.cc @@ -0,0 +1,38 @@ +--- components/autofill/core/browser/payments/amount_extraction_manager.cc.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/browser/payments/amount_extraction_manager.cc +@@ -109,7 +109,7 @@ AmountExtractionManager::GetEligibleFeatures(const Sug + } + + if constexpr (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || +- BUILDFLAG(IS_CHROMEOS)) { ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) { + if (base::FeatureList::IsEnabled( + ::autofill::features:: + kAutofillEnableAmountExtractionDesktopLogging)) { +@@ -188,7 +188,7 @@ void AmountExtractionManager::OnCheckoutAmountReceived + bnpl_manager->OnAmountExtractionReturned(parsed_extracted_amount); + } + if constexpr (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || +- BUILDFLAG(IS_CHROMEOS)) { ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) { + if (base::FeatureList::IsEnabled( + ::autofill::features:: + kAutofillEnableAmountExtractionDesktopLogging)) { +@@ -212,7 +212,7 @@ void AmountExtractionManager::OnTimeoutReached() { + autofill_metrics::AmountExtractionResult::kTimeout); + // TODO(crbug.com/378517983): Add BNPL flow action logic here. + if constexpr (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || +- BUILDFLAG(IS_CHROMEOS)) { ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) { + if (base::FeatureList::IsEnabled( + ::autofill::features:: + kAutofillEnableAmountExtractionDesktopLogging)) { +@@ -232,7 +232,7 @@ AmountExtractionManager::CheckEligiblilityForFeaturesR + // Check eligibility of BNPL feature. + // Currently, BNPL is only offered for desktop platforms. + if constexpr (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || +- BUILDFLAG(IS_CHROMEOS)) { ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) { + if (BnplManager* bnpl_manager = autofill_manager_->GetPaymentsBnplManager(); + bnpl_manager && bnpl_manager->IsEligibleForBnpl()) { + eligible_features.insert(EligibleFeature::kBnpl); diff --git a/www/chromium/files/patch-components_autofill_core_browser_payments_bnpl__manager.cc b/www/chromium/files/patch-components_autofill_core_browser_payments_bnpl__manager.cc new file mode 100644 index 000000000000..cf9b5a65ab0a --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_payments_bnpl__manager.cc @@ -0,0 +1,11 @@ +--- components/autofill/core/browser/payments/bnpl_manager.cc.orig 2025-05-28 14:55:43 UTC ++++ components/autofill/core/browser/payments/bnpl_manager.cc +@@ -466,7 +466,7 @@ void BnplManager::MaybeUpdateSuggestionsWithBnpl( + .OnBnplSuggestionShown(); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + payments_autofill_client().GetPaymentsDataManager().SetAutofillHasSeenBnpl(); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-components_autofill_core_browser_personal__data__manager.cc b/www/chromium/files/patch-components_autofill_core_browser_personal__data__manager.cc deleted file mode 100644 index fe4ae096f6a0..000000000000 --- a/www/chromium/files/patch-components_autofill_core_browser_personal__data__manager.cc +++ /dev/null @@ -1,12 +0,0 @@ ---- components/autofill/core/browser/personal_data_manager.cc.orig 2024-04-19 13:02:56 UTC -+++ components/autofill/core/browser/personal_data_manager.cc -@@ -1063,7 +1063,8 @@ bool PersonalDataManager::ShouldShowCardsFromAccountOp - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) || \ -+ BUILDFLAG(IS_BSD) - // This option should only be shown for users that have not enabled the Sync - // Feature and that have server credit cards available. - // TODO(crbug.com/40066949): Simplify once ConsentLevel::kSync and diff --git a/www/chromium/files/patch-components_autofill_core_browser_webdata_payments_payments__sync__bridge__util.cc b/www/chromium/files/patch-components_autofill_core_browser_webdata_payments_payments__sync__bridge__util.cc new file mode 100644 index 000000000000..8310a08bf8b7 --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_browser_webdata_payments_payments__sync__bridge__util.cc @@ -0,0 +1,11 @@ +--- components/autofill/core/browser/webdata/payments/payments_sync_bridge_util.cc.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/browser/webdata/payments/payments_sync_bridge_util.cc +@@ -1261,7 +1261,7 @@ bool AreMaskedBankAccountSupported() { + + bool IsBnplIssuerSupported() { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return base::FeatureList::IsEnabled( + features::kAutofillEnableBuyNowPayLaterSyncing); + #else diff --git a/www/chromium/files/patch-components_autofill_core_common_autofill__payments__features.cc b/www/chromium/files/patch-components_autofill_core_common_autofill__payments__features.cc index b21eb54a1cf2..0c520495559d 100644 --- a/www/chromium/files/patch-components_autofill_core_common_autofill__payments__features.cc +++ b/www/chromium/files/patch-components_autofill_core_common_autofill__payments__features.cc @@ -1,11 +1,11 @@ ---- components/autofill/core/common/autofill_payments_features.cc.orig 2024-04-19 13:02:56 UTC +--- components/autofill/core/common/autofill_payments_features.cc.orig 2025-07-02 06:08:04 UTC +++ components/autofill/core/common/autofill_payments_features.cc -@@ -276,7 +276,7 @@ BASE_FEATURE(kAutofillEnableVirtualCards, +@@ -326,7 +326,7 @@ BASE_FEATURE(kAutofillSyncEwalletAccounts, + #endif // BUILDFLAG(IS_ANDROID) + bool ShouldShowImprovedUserConsentForCreditCardSave() { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // The new user consent UI is fully launched on MacOS, Windows and Linux. return true; + #else diff --git a/www/chromium/files/patch-components_autofill_core_common_autofill__prefs.cc b/www/chromium/files/patch-components_autofill_core_common_autofill__prefs.cc new file mode 100644 index 000000000000..d22f8a1e7ba4 --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_common_autofill__prefs.cc @@ -0,0 +1,38 @@ +--- components/autofill/core/common/autofill_prefs.cc.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/common/autofill_prefs.cc +@@ -101,7 +101,7 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySync + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + registry->RegisterBooleanPref( + kAutofillBnplEnabled, true, + user_prefs::PrefRegistrySyncable::SYNCABLE_PREF); +@@ -280,7 +280,7 @@ bool IsFacilitatedPaymentsEwalletEnabled(const PrefSer + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void SetAutofillBnplEnabled(PrefService* prefs, bool value) { + prefs->SetBoolean(kAutofillBnplEnabled, value); + } +@@ -289,7 +289,7 @@ void SetAutofillBnplEnabled(PrefService* prefs, bool v + + bool IsAutofillBnplEnabled(const PrefService* prefs) { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return prefs->GetBoolean(kAutofillBnplEnabled); + #else + return false; +@@ -298,7 +298,7 @@ bool IsAutofillBnplEnabled(const PrefService* prefs) { + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // If called, always sets the pref to true, and once true, it will follow the + // user around forever. + void SetAutofillHasSeenBnpl(PrefService* prefs) { diff --git a/www/chromium/files/patch-components_autofill_core_common_autofill__prefs.h b/www/chromium/files/patch-components_autofill_core_common_autofill__prefs.h new file mode 100644 index 000000000000..d179d2dcb9fb --- /dev/null +++ b/www/chromium/files/patch-components_autofill_core_common_autofill__prefs.h @@ -0,0 +1,29 @@ +--- components/autofill/core/common/autofill_prefs.h.orig 2025-07-02 06:08:04 UTC ++++ components/autofill/core/common/autofill_prefs.h +@@ -32,7 +32,7 @@ inline constexpr std::string_view kAutofillAblationSee + inline constexpr char kAutofillAiOptInStatus[] = + "autofill.autofill_ai.opt_in_status"; + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Boolean that is true if BNPL on Autofill is enabled. + inline constexpr char kAutofillBnplEnabled[] = "autofill.bnpl_enabled"; + // Boolean that is true if the user has ever seen a BNPL suggestion. +@@ -220,7 +220,7 @@ void SetFacilitatedPaymentsEwallet(PrefService* prefs, + bool IsFacilitatedPaymentsEwalletEnabled(const PrefService* prefs); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void SetAutofillBnplEnabled(PrefService* prefs, bool value); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_CHROMEOS) +@@ -228,7 +228,7 @@ void SetAutofillBnplEnabled(PrefService* prefs, bool v + bool IsAutofillBnplEnabled(const PrefService* prefs); + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void SetAutofillHasSeenBnpl(PrefService* prefs); + + bool HasSeenBnpl(const PrefService* prefs); diff --git a/www/chromium/files/patch-components_autofill_core_common_autofill__util.cc b/www/chromium/files/patch-components_autofill_core_common_autofill__util.cc deleted file mode 100644 index 13366843dfe4..000000000000 --- a/www/chromium/files/patch-components_autofill_core_common_autofill__util.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/autofill/core/common/autofill_util.cc.orig 2024-03-22 08:19:40 UTC -+++ components/autofill/core/common/autofill_util.cc -@@ -131,7 +131,7 @@ bool SanitizedFieldIsEmpty(const std::u16string& value - - bool ShouldAutoselectFirstSuggestionOnArrowDown() { - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - return true; - #else - return false; diff --git a/www/chromium/files/patch-components_commerce_core_commerce__feature__list.cc b/www/chromium/files/patch-components_commerce_core_commerce__feature__list.cc index 6feb47965aea..71ddede40ea4 100644 --- a/www/chromium/files/patch-components_commerce_core_commerce__feature__list.cc +++ b/www/chromium/files/patch-components_commerce_core_commerce__feature__list.cc @@ -1,20 +1,39 @@ ---- components/commerce/core/commerce_feature_list.cc.orig 2024-03-22 08:19:40 UTC +--- components/commerce/core/commerce_feature_list.cc.orig 2025-07-02 06:08:04 UTC +++ components/commerce/core/commerce_feature_list.cc -@@ -168,7 +168,7 @@ BASE_FEATURE(kPriceInsights, +@@ -157,7 +157,8 @@ BASE_FEATURE(kPriceInsights, "PriceInsights", base::FEATURE_DISABLED_BY_DEFAULT); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_ANDROID) || \ ++ BUILDFLAG(IS_BSD) BASE_FEATURE(kPriceInsightsRegionLaunched, "PriceInsightsRegionLaunched", base::FEATURE_ENABLED_BY_DEFAULT); -@@ -244,7 +244,7 @@ const base::FeatureParam<bool> kDeleteAllMerchantsOnCl +@@ -230,7 +231,7 @@ BASE_FEATURE(kEnableDiscountInfoApi, + const char kDiscountOnShoppyPageParam[] = "discount-on-shoppy-page"; + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + const base::FeatureParam<bool> kDiscountOnShoppyPage{ + &kEnableDiscountInfoApi, kDiscountOnShoppyPageParam, true}; + #else +@@ -239,7 +240,7 @@ const base::FeatureParam<bool> kDiscountOnShoppyPage{ + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kEnableDiscountInfoApiRegionLaunched, + "EnableDiscountInfoApiRegionLaunched", + base::FEATURE_ENABLED_BY_DEFAULT); +@@ -254,7 +255,7 @@ const char kMerchantWideBehaviorParam[] = "merchant-wi + const char kNonMerchantWideBehaviorParam[] = "non-merchant-wide-behavior"; - BASE_FEATURE(kShoppingList, "ShoppingList", base::FEATURE_DISABLED_BY_DEFAULT); - #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_IOS) -+ BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) - BASE_FEATURE(kShoppingListRegionLaunched, - "ShoppingListRegionLaunched", + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kDiscountDialogAutoPopupBehaviorSetting, + "DiscountDialogAutoPopupBehaviorSetting", base::FEATURE_ENABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-components_constrained__window_constrained__window__views.cc b/www/chromium/files/patch-components_constrained__window_constrained__window__views.cc index 62f87c529226..28e32aa3ee58 100644 --- a/www/chromium/files/patch-components_constrained__window_constrained__window__views.cc +++ b/www/chromium/files/patch-components_constrained__window_constrained__window__views.cc @@ -1,11 +1,11 @@ ---- components/constrained_window/constrained_window_views.cc.orig 2024-03-22 08:19:40 UTC +--- components/constrained_window/constrained_window_views.cc.orig 2025-07-02 06:08:04 UTC +++ components/constrained_window/constrained_window_views.cc -@@ -324,7 +324,7 @@ bool SupportsGlobalScreenCoordinates() { +@@ -392,7 +392,7 @@ bool SupportsGlobalScreenCoordinates() { } bool PlatformClipsChildrenToViewport() { --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return true; #else return false; diff --git a/www/chromium/files/patch-components_content__settings_core_browser_website__settings__registry.cc b/www/chromium/files/patch-components_content__settings_core_browser_website__settings__registry.cc index 82d5060e2a76..64b99b1dbde8 100644 --- a/www/chromium/files/patch-components_content__settings_core_browser_website__settings__registry.cc +++ b/www/chromium/files/patch-components_content__settings_core_browser_website__settings__registry.cc @@ -1,6 +1,6 @@ ---- components/content_settings/core/browser/website_settings_registry.cc.orig 2024-02-23 21:04:38 UTC +--- components/content_settings/core/browser/website_settings_registry.cc.orig 2025-02-19 07:43:18 UTC +++ components/content_settings/core/browser/website_settings_registry.cc -@@ -67,7 +67,7 @@ const WebsiteSettingsInfo* WebsiteSettingsRegistry::Re +@@ -66,7 +66,7 @@ const WebsiteSettingsInfo* WebsiteSettingsRegistry::Re #if BUILDFLAG(IS_WIN) if (!(platform & PLATFORM_WINDOWS)) return nullptr; diff --git a/www/chromium/files/patch-components_crash_core_app_BUILD.gn b/www/chromium/files/patch-components_crash_core_app_BUILD.gn index 4145bd618de1..3424a92d29d0 100644 --- a/www/chromium/files/patch-components_crash_core_app_BUILD.gn +++ b/www/chromium/files/patch-components_crash_core_app_BUILD.gn @@ -1,6 +1,6 @@ ---- components/crash/core/app/BUILD.gn.orig 2024-03-22 08:19:40 UTC +--- components/crash/core/app/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ components/crash/core/app/BUILD.gn -@@ -82,6 +82,10 @@ static_library("app") { +@@ -70,6 +70,10 @@ static_library("app") { ] } @@ -11,7 +11,7 @@ defines = [ "CRASH_IMPLEMENTATION" ] public_deps = [ ":lib" ] -@@ -95,7 +99,7 @@ static_library("app") { +@@ -83,7 +87,7 @@ static_library("app") { "//third_party/crashpad/crashpad/util", ] @@ -20,7 +20,7 @@ sources += [ "crashpad_linux.cc" ] data_deps = [ ":chrome_crashpad_handler" ] } -@@ -115,7 +119,7 @@ static_library("app") { +@@ -105,7 +109,7 @@ static_library("app") { libs = [ "log" ] } @@ -29,7 +29,7 @@ deps += [ "//base:base_static", "//components/crash/core/common", -@@ -243,11 +247,6 @@ if (is_mac || is_android || is_linux || is_chromeos) { +@@ -237,11 +241,6 @@ if (is_mac || is_android || is_linux || is_chromeos) { # define custom UserStreamDataSources. executable("chrome_crashpad_handler") { sources = [ "chrome_crashpad_handler.cc" ] @@ -39,5 +39,5 @@ - "//third_party/crashpad/crashpad/handler", - ] - if (is_mac && (is_component_build || is_asan)) { + if (is_mac && (is_component_build || is_asan || is_ubsan_any)) { ldflags = [ diff --git a/www/chromium/files/patch-components_crash_core_browser_crash__upload__list__crashpad.cc b/www/chromium/files/patch-components_crash_core_browser_crash__upload__list__crashpad.cc index 2246b881031b..c25771fc71f4 100644 --- a/www/chromium/files/patch-components_crash_core_browser_crash__upload__list__crashpad.cc +++ b/www/chromium/files/patch-components_crash_core_browser_crash__upload__list__crashpad.cc @@ -1,6 +1,6 @@ ---- components/crash/core/browser/crash_upload_list_crashpad.cc.orig 2023-09-13 12:11:42 UTC +--- components/crash/core/browser/crash_upload_list_crashpad.cc.orig 2025-02-19 07:43:18 UTC +++ components/crash/core/browser/crash_upload_list_crashpad.cc -@@ -38,7 +38,9 @@ CrashUploadListCrashpad::~CrashUploadListCrashpad() = +@@ -37,7 +37,9 @@ CrashUploadListCrashpad::~CrashUploadListCrashpad() = std::vector<std::unique_ptr<UploadList::UploadInfo>> CrashUploadListCrashpad::LoadUploadList() { std::vector<crash_reporter::Report> reports; @@ -10,7 +10,7 @@ std::vector<std::unique_ptr<UploadInfo>> uploads; for (const crash_reporter::Report& report : reports) { -@@ -52,9 +54,13 @@ CrashUploadListCrashpad::LoadUploadList() { +@@ -51,9 +53,13 @@ CrashUploadListCrashpad::LoadUploadList() { void CrashUploadListCrashpad::ClearUploadList(const base::Time& begin, const base::Time& end) { diff --git a/www/chromium/files/patch-components_device__signals_core_browser_browser__utils.h b/www/chromium/files/patch-components_device__signals_core_browser_browser__utils.h new file mode 100644 index 000000000000..9343582483ab --- /dev/null +++ b/www/chromium/files/patch-components_device__signals_core_browser_browser__utils.h @@ -0,0 +1,20 @@ +--- components/device_signals/core/browser/browser_utils.h.orig 2025-05-28 14:55:43 UTC ++++ components/device_signals/core/browser/browser_utils.h +@@ -36,7 +36,7 @@ bool GetSiteIsolationEnabled(); + // Returns the hostname of the current machine. + std::string GetHostName(); + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Returns the hostname of the current machine. + std::vector<std::string> GetSystemDnsServers(); + +@@ -44,7 +44,7 @@ std::vector<std::string> GetSystemDnsServers(); + SettingValue GetOSFirewall(); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Returns the path to the ufw configuration file. + const char** GetUfwConfigPath(); + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.cc b/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.cc index d8ca5ca16826..4b6e2d5d0ad0 100644 --- a/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.cc +++ b/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.cc @@ -1,6 +1,6 @@ ---- components/device_signals/core/browser/signals_aggregator_impl.cc.orig 2023-07-16 15:47:57 UTC +--- components/device_signals/core/browser/signals_aggregator_impl.cc.orig 2025-02-19 07:43:18 UTC +++ components/device_signals/core/browser/signals_aggregator_impl.cc -@@ -65,7 +65,7 @@ SignalsAggregatorImpl::SignalsAggregatorImpl( +@@ -64,7 +64,7 @@ SignalsAggregatorImpl::SignalsAggregatorImpl( SignalsAggregatorImpl::~SignalsAggregatorImpl() = default; diff --git a/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.h b/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.h index 908af99c54d0..8d0c9a8ecb36 100644 --- a/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.h +++ b/www/chromium/files/patch-components_device__signals_core_browser_signals__aggregator__impl.h @@ -1,6 +1,6 @@ ---- components/device_signals/core/browser/signals_aggregator_impl.h.orig 2023-07-16 15:47:57 UTC +--- components/device_signals/core/browser/signals_aggregator_impl.h.orig 2025-04-04 08:52:13 UTC +++ components/device_signals/core/browser/signals_aggregator_impl.h -@@ -29,7 +29,7 @@ class SignalsAggregatorImpl : public SignalsAggregator +@@ -30,7 +30,7 @@ class SignalsAggregatorImpl : public SignalsAggregator ~SignalsAggregatorImpl() override; // SignalsAggregator: diff --git a/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.cc b/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.cc index a4cb305fab8c..0b379b47a2a2 100644 --- a/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.cc +++ b/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.cc @@ -1,6 +1,6 @@ ---- components/device_signals/core/browser/user_permission_service_impl.cc.orig 2023-10-11 18:22:24 UTC +--- components/device_signals/core/browser/user_permission_service_impl.cc.orig 2024-07-30 11:12:21 UTC +++ components/device_signals/core/browser/user_permission_service_impl.cc -@@ -92,7 +92,7 @@ bool UserPermissionServiceImpl::ShouldCollectConsent() +@@ -87,7 +87,7 @@ bool UserPermissionServiceImpl::ShouldCollectConsent() consent_required_by_dependent_policy; } diff --git a/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.h b/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.h index 8bdca220f354..ab0dfa7da42a 100644 --- a/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.h +++ b/www/chromium/files/patch-components_device__signals_core_browser_user__permission__service__impl.h @@ -1,6 +1,6 @@ ---- components/device_signals/core/browser/user_permission_service_impl.h.orig 2023-07-16 15:47:57 UTC +--- components/device_signals/core/browser/user_permission_service_impl.h.orig 2024-07-30 11:12:21 UTC +++ components/device_signals/core/browser/user_permission_service_impl.h -@@ -39,7 +39,7 @@ class UserPermissionServiceImpl : public UserPermissio +@@ -38,7 +38,7 @@ class UserPermissionServiceImpl : public UserPermissio // UserPermissionService: bool ShouldCollectConsent() const override; diff --git a/www/chromium/files/patch-chrome_browser_enterprise_signals_device__info__fetcher__linux.cc b/www/chromium/files/patch-components_device__signals_core_common_linux_platform__utils__linux.cc index e24ecb3238a2..8a9d3dc9ea51 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_signals_device__info__fetcher__linux.cc +++ b/www/chromium/files/patch-components_device__signals_core_common_linux_platform__utils__linux.cc @@ -1,8 +1,8 @@ ---- chrome/browser/enterprise/signals/device_info_fetcher_linux.cc.orig 2023-09-13 12:11:42 UTC -+++ chrome/browser/enterprise/signals/device_info_fetcher_linux.cc +--- components/device_signals/core/common/linux/platform_utils_linux.cc.orig 2025-05-28 14:55:43 UTC ++++ components/device_signals/core/common/linux/platform_utils_linux.cc @@ -4,12 +4,23 @@ - #include "chrome/browser/enterprise/signals/device_info_fetcher_linux.h" + #include "components/device_signals/core/common/platform_utils.h" +#include "build/build_config.h" + @@ -21,18 +21,18 @@ +#include <net/if_dl.h> +#endif + + #include <algorithm> + #include <optional> #include <string> - - #include "base/environment.h" -@@ -118,6 +129,7 @@ SettingValue GetScreenlockSecured() { +@@ -98,6 +109,7 @@ SettingValue GetScreenlockSecured() { // Implements the logic from the native host installation script. First find the // root device identifier, then locate its parent and get its type. SettingValue GetDiskEncrypted() { +#if !BUILDFLAG(IS_BSD) struct stat info; // First figure out the device identifier. Fail fast if this fails. - if (stat("/", &info) != 0) -@@ -139,11 +151,35 @@ SettingValue GetDiskEncrypted() { + if (stat("/", &info) != 0) { +@@ -120,11 +132,35 @@ SettingValue GetDiskEncrypted() { } return SettingValue::UNKNOWN; } @@ -66,9 +66,9 @@ + } +#else base::DirReaderPosix reader("/sys/class/net"); - if (!reader.IsValid()) + if (!reader.IsValid()) { return result; -@@ -166,6 +202,7 @@ std::vector<std::string> GetMacAddresses() { +@@ -149,6 +185,7 @@ std::vector<std::string> GetMacAddresses() { &address); result.push_back(address); } diff --git a/www/chromium/files/patch-components_device__signals_core_common_signals__features.cc b/www/chromium/files/patch-components_device__signals_core_common_signals__features.cc index 776994b16213..16418c1fe4c9 100644 --- a/www/chromium/files/patch-components_device__signals_core_common_signals__features.cc +++ b/www/chromium/files/patch-components_device__signals_core_common_signals__features.cc @@ -1,11 +1,11 @@ ---- components/device_signals/core/common/signals_features.cc.orig 2023-08-17 07:33:31 UTC +--- components/device_signals/core/common/signals_features.cc.orig 2025-05-28 14:55:43 UTC +++ components/device_signals/core/common/signals_features.cc -@@ -46,7 +46,7 @@ bool IsNewFunctionEnabled(NewEvFunction new_ev_functio +@@ -43,7 +43,7 @@ bool IsBrowserSignalsReportingEnabled() { } #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Enables the triggering of device signals consent dialog when conditions met // This feature also requires UnmanagedDeviceSignalsConsentFlowEnabled policy to // be enabled diff --git a/www/chromium/files/patch-components_device__signals_core_common_signals__features.h b/www/chromium/files/patch-components_device__signals_core_common_signals__features.h index 14669ecc9c48..4b3a60a02309 100644 --- a/www/chromium/files/patch-components_device__signals_core_common_signals__features.h +++ b/www/chromium/files/patch-components_device__signals_core_common_signals__features.h @@ -1,11 +1,11 @@ ---- components/device_signals/core/common/signals_features.h.orig 2023-08-17 07:33:31 UTC +--- components/device_signals/core/common/signals_features.h.orig 2025-05-28 14:55:43 UTC +++ components/device_signals/core/common/signals_features.h -@@ -28,7 +28,7 @@ enum class NewEvFunction { kFileSystemInfo, kSettings, - bool IsNewFunctionEnabled(NewEvFunction new_ev_function); +@@ -29,7 +29,7 @@ bool IsProfileSignalsReportingEnabled(); + bool IsBrowserSignalsReportingEnabled(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_CHROMEOS_ASH) -+ BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) BASE_DECLARE_FEATURE(kDeviceSignalsConsentDialog); // Returns true if device signals consent dialog has been enabled for diff --git a/www/chromium/files/patch-components_device__signals_test_signals__contract.cc b/www/chromium/files/patch-components_device__signals_test_signals__contract.cc index 83f39d471640..d69bafda3cef 100644 --- a/www/chromium/files/patch-components_device__signals_test_signals__contract.cc +++ b/www/chromium/files/patch-components_device__signals_test_signals__contract.cc @@ -1,11 +1,11 @@ ---- components/device_signals/test/signals_contract.cc.orig 2023-09-13 12:11:42 UTC +--- components/device_signals/test/signals_contract.cc.orig 2025-04-04 08:52:13 UTC +++ components/device_signals/test/signals_contract.cc -@@ -212,7 +212,7 @@ GetSignalsContract() { +@@ -221,7 +221,7 @@ GetSignalsContract(bool is_av_signal_enabled) { base::BindRepeating(VerifyUnset, names::kCrowdStrike); #endif -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUIDLFLAG(IS_BSD) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) contract[names::kAllowScreenLock] = base::BindRepeating(VerifyUnset, names::kAllowScreenLock); contract[names::kImei] = base::BindRepeating(VerifyUnset, names::kImei); diff --git a/www/chromium/files/patch-components_discardable__memory_service_discardable__shared__memory__manager.cc b/www/chromium/files/patch-components_discardable__memory_service_discardable__shared__memory__manager.cc index 9c336db88172..8ea108cff3b0 100644 --- a/www/chromium/files/patch-components_discardable__memory_service_discardable__shared__memory__manager.cc +++ b/www/chromium/files/patch-components_discardable__memory_service_discardable__shared__memory__manager.cc @@ -1,4 +1,4 @@ ---- components/discardable_memory/service/discardable_shared_memory_manager.cc.orig 2023-12-10 06:10:27 UTC +--- components/discardable_memory/service/discardable_shared_memory_manager.cc.orig 2024-09-30 07:45:04 UTC +++ components/discardable_memory/service/discardable_shared_memory_manager.cc @@ -172,7 +172,7 @@ uint64_t GetDefaultMemoryLimit() { // Limits the number of FDs used to 32, assuming a 4MB allocation size. diff --git a/www/chromium/files/patch-components_embedder__support_user__agent__utils.cc b/www/chromium/files/patch-components_embedder__support_user__agent__utils.cc index 8f75a93a7c7a..6d5b1b90ad10 100644 --- a/www/chromium/files/patch-components_embedder__support_user__agent__utils.cc +++ b/www/chromium/files/patch-components_embedder__support_user__agent__utils.cc @@ -1,12 +1,56 @@ ---- components/embedder_support/user_agent_utils.cc.orig 2024-01-30 07:53:34 UTC +--- components/embedder_support/user_agent_utils.cc.orig 2025-05-28 14:55:43 UTC +++ components/embedder_support/user_agent_utils.cc -@@ -445,6 +445,9 @@ std::string GetPlatformForUAMetadata() { - # else +@@ -318,7 +318,7 @@ std::string GetUserAgentPlatform() { + return ""; + #elif BUILDFLAG(IS_MAC) + return "Macintosh; "; +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return "X11; "; // strange, but that's what Firefox uses + #elif BUILDFLAG(IS_ANDROID) + return "Linux; "; +@@ -344,7 +344,7 @@ std::string GetUnifiedPlatform() { + return "Windows NT 10.0; Win64; x64"; + #elif BUILDFLAG(IS_FUCHSIA) + return "Fuchsia"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return "X11; Linux x86_64"; + #elif BUILDFLAG(IS_IOS) + if (ui::GetDeviceFormFactor() == ui::DEVICE_FORM_FACTOR_TABLET) { +@@ -601,6 +601,9 @@ std::string GetPlatformForUAMetadata() { + #else return "Chromium OS"; - # endif + #endif +#elif BUILDFLAG(IS_BSD) + // The internet is weird... + return "Linux"; #else return std::string(version_info::GetOSType()); #endif +@@ -660,7 +663,7 @@ blink::UserAgentMetadata GetUserAgentMetadata(const Pr + base::StringPrintf("%d.%d.%d", major, minor, bugfix); + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // TODO(crbug.com/40245146): Remove this Blink feature + if (base::FeatureList::IsEnabled( + blink::features::kReduceUserAgentDataLinuxPlatformVersion)) { +@@ -821,6 +824,16 @@ std::string BuildOSCpuInfoFromOSVersionAndCpuType(cons + "Android %s", os_version.c_str() + #elif BUILDFLAG(IS_FUCHSIA) + "Fuchsia" ++#elif BUILDFLAG(IS_BSD) ++#if defined(__x86_64__) ++ "Linux x86_64; %s %s", ++#elif defined(__aarch64__) ++ "Linux aarch64; %s %s", ++#else ++ "Linux i686; %s %s", ++#endif ++ unixinfo.sysname, // e.g. Linux ++ cpu_type.c_str() // e.g. i686 + #elif BUILDFLAG(IS_IOS) + "CPU %s OS %s like Mac OS X", cpu_type.c_str(), + os_version.c_str() diff --git a/www/chromium/files/patch-components_embedder__support_user__agent__utils__unittest.cc b/www/chromium/files/patch-components_embedder__support_user__agent__utils__unittest.cc index 0fd37b4abc1a..8c8d17df3333 100644 --- a/www/chromium/files/patch-components_embedder__support_user__agent__utils__unittest.cc +++ b/www/chromium/files/patch-components_embedder__support_user__agent__utils__unittest.cc @@ -1,20 +1,29 @@ ---- components/embedder_support/user_agent_utils_unittest.cc.orig 2023-09-13 12:11:42 UTC +--- components/embedder_support/user_agent_utils_unittest.cc.orig 2025-05-28 14:55:43 UTC +++ components/embedder_support/user_agent_utils_unittest.cc -@@ -84,7 +84,7 @@ const char kDesktop[] = - "Safari/537.36"; - #endif // BUILDFLAG(IS_ANDROID) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - std::string GetMachine() { - struct utsname unixinfo; - uname(&unixinfo); -@@ -192,7 +192,7 @@ void CheckUserAgentStringOrdering(bool mobile_device) - int value; - ASSERT_TRUE(base::StringToInt(pieces[i], &value)); - } +@@ -148,7 +148,7 @@ void CheckUserAgentStringOrdering(bool mobile_device) + ASSERT_EQ("CrOS", pieces[0]); + ASSERT_EQ("x86_64", pieces[1]); + ASSERT_EQ("14541.0.0", pieces[2]); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Post-UA Reduction there is a single <unifiedPlatform> value for Linux: // X11; Linux x86_64 ASSERT_EQ(2u, pieces.size()); - ASSERT_EQ("X11", pieces[0]); +@@ -336,7 +336,7 @@ class UserAgentUtilsTest : public testing::Test, + "X11; CrOS x86_64 14541.0.0"; + #elif BUILDFLAG(IS_FUCHSIA) + "Fuchsia"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + "X11; Linux x86_64"; + #elif BUILDFLAG(IS_MAC) + "Macintosh; Intel Mac OS X 10_15_7"; +@@ -716,7 +716,7 @@ TEST_F(UserAgentUtilsTest, UserAgentMetadata) { + #endif + #elif BUILDFLAG(IS_ANDROID) + EXPECT_EQ(metadata.platform, "Android"); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + EXPECT_EQ(metadata.platform, "Linux"); + #elif BUILDFLAG(IS_FREEBSD) + EXPECT_EQ(metadata.platform, "FreeBSD"); diff --git a/www/chromium/files/patch-components_enterprise_connectors_core_realtime__reporting__client__base.cc b/www/chromium/files/patch-components_enterprise_connectors_core_realtime__reporting__client__base.cc new file mode 100644 index 000000000000..bc9e20f6709d --- /dev/null +++ b/www/chromium/files/patch-components_enterprise_connectors_core_realtime__reporting__client__base.cc @@ -0,0 +1,20 @@ +--- components/enterprise/connectors/core/realtime_reporting_client_base.cc.orig 2025-07-02 06:08:04 UTC ++++ components/enterprise/connectors/core/realtime_reporting_client_base.cc +@@ -191,7 +191,7 @@ void RealtimeReportingClientBase::ReportEvent( + *event.mutable_time() = ToProtoTimestamp(base::Time::Now()); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(notyet) + MaybeCollectDeviceSignalsAndReportEvent(std::move(event), client, settings); + #else + // Regardless of collecting device signals or not, upload the security event +@@ -240,7 +240,7 @@ void RealtimeReportingClientBase::ReportEventWithTimes + if (include_profile_user_name) { + event.Set(kKeyProfileUserName, GetProfileUserName()); + } +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(notyet) + MaybeCollectDeviceSignalsAndReportEventDeprecated(std::move(event), client, + name, settings, time); + #else diff --git a/www/chromium/files/patch-chrome_browser_enterprise_watermark_watermark__view.cc b/www/chromium/files/patch-components_enterprise_watermarking_watermark.cc index 3ae6cb960840..418e0e580df8 100644 --- a/www/chromium/files/patch-chrome_browser_enterprise_watermark_watermark__view.cc +++ b/www/chromium/files/patch-components_enterprise_watermarking_watermark.cc @@ -1,6 +1,6 @@ ---- chrome/browser/enterprise/watermark/watermark_view.cc.orig 2024-04-19 13:02:56 UTC -+++ chrome/browser/enterprise/watermark/watermark_view.cc -@@ -33,7 +33,7 @@ const gfx::Font& WatermarkFont() { +--- components/enterprise/watermarking/watermark.cc.orig 2025-02-19 07:43:18 UTC ++++ components/enterprise/watermarking/watermark.cc +@@ -31,7 +31,7 @@ gfx::Font WatermarkFont() { "Segoe UI", #elif BUILDFLAG(IS_MAC) "SF Pro Text", @@ -9,7 +9,7 @@ "Ubuntu", #elif BUILDFLAG(IS_CHROMEOS) "Google Sans", -@@ -45,7 +45,7 @@ const gfx::Font& WatermarkFont() { +@@ -47,7 +47,7 @@ const gfx::FontList& WatermarkFontList() { } gfx::Font::Weight WatermarkFontWeight() { diff --git a/www/chromium/files/patch-components_error__page_common_localized__error.cc b/www/chromium/files/patch-components_error__page_common_localized__error.cc new file mode 100644 index 000000000000..7844d837d242 --- /dev/null +++ b/www/chromium/files/patch-components_error__page_common_localized__error.cc @@ -0,0 +1,11 @@ +--- components/error_page/common/localized_error.cc.orig 2025-02-19 07:43:18 UTC ++++ components/error_page/common/localized_error.cc +@@ -901,7 +901,7 @@ void AddSuggestionsDetails(int error_code, + if (suggestions & SUGGEST_PROXY_CONFIG) { + // Custom body string. + std::u16string inner = +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + l10n_util::GetStringFUTF16( + IDS_ERRORPAGES_SUGGESTION_PROXY_DISABLE_PLATFORM, + l10n_util::GetStringUTF16(IDS_SETTINGS_TITLE), diff --git a/www/chromium/files/patch-components_eye__dropper_eye__dropper__view.cc b/www/chromium/files/patch-components_eye__dropper_eye__dropper__view.cc index a1261651b91e..3caf694fff16 100644 --- a/www/chromium/files/patch-components_eye__dropper_eye__dropper__view.cc +++ b/www/chromium/files/patch-components_eye__dropper_eye__dropper__view.cc @@ -1,11 +1,11 @@ ---- components/eye_dropper/eye_dropper_view.cc.orig 2024-02-23 21:04:38 UTC +--- components/eye_dropper/eye_dropper_view.cc.orig 2025-05-28 14:55:43 UTC +++ components/eye_dropper/eye_dropper_view.cc -@@ -200,7 +200,7 @@ EyeDropperView::EyeDropperView(gfx::NativeView parent, +@@ -206,7 +206,7 @@ EyeDropperView::EyeDropperView(gfx::NativeView parent, // EyeDropper/WidgetDelegate. - set_owned_by_client(); + set_owned_by_client(OwnedByClientPassKey()); SetPreferredSize(GetSize()); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Use TYPE_MENU for Linux to ensure that the eye dropper view is displayed // above the color picker. - views::Widget::InitParams params(views::Widget::InitParams::TYPE_MENU); + views::Widget::InitParams params( diff --git a/www/chromium/files/patch-components_feature__engagement_public_event__constants.cc b/www/chromium/files/patch-components_feature__engagement_public_event__constants.cc index e2eaf62b7d02..7d0fe1c50202 100644 --- a/www/chromium/files/patch-components_feature__engagement_public_event__constants.cc +++ b/www/chromium/files/patch-components_feature__engagement_public_event__constants.cc @@ -1,4 +1,4 @@ ---- components/feature_engagement/public/event_constants.cc.orig 2022-02-28 16:54:41 UTC +--- components/feature_engagement/public/event_constants.cc.orig 2024-11-14 07:57:23 UTC +++ components/feature_engagement/public/event_constants.cc @@ -11,7 +11,7 @@ namespace feature_engagement { namespace events { @@ -8,4 +8,4 @@ + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) const char kNewTabOpened[] = "new_tab_opened"; const char kSixthTabOpened[] = "sixth_tab_opened"; - const char kTabGroupCreated[] = "tab_group_created"; + const char kReadingListItemAdded[] = "reading_list_item_added"; diff --git a/www/chromium/files/patch-components_feature__engagement_public_feature__configurations.cc b/www/chromium/files/patch-components_feature__engagement_public_feature__configurations.cc index 940471bcf112..3b623983a6d6 100644 --- a/www/chromium/files/patch-components_feature__engagement_public_feature__configurations.cc +++ b/www/chromium/files/patch-components_feature__engagement_public_feature__configurations.cc @@ -1,6 +1,6 @@ ---- components/feature_engagement/public/feature_configurations.cc.orig 2024-04-19 13:02:56 UTC +--- components/feature_engagement/public/feature_configurations.cc.orig 2025-07-02 06:08:04 UTC +++ components/feature_engagement/public/feature_configurations.cc -@@ -94,7 +94,7 @@ std::optional<FeatureConfig> CreateNewUserGestureInPro +@@ -100,7 +100,7 @@ std::optional<FeatureConfig> CreateNewUserGestureInPro std::optional<FeatureConfig> GetClientSideFeatureConfig( const base::Feature* feature) { @@ -9,16 +9,16 @@ // The IPH bubble for link capturing has a trigger set to ANY so that it // always shows up. The per app specific guardrails are independently stored -@@ -113,7 +113,7 @@ std::optional<FeatureConfig> GetClientSideFeatureConfi +@@ -119,7 +119,7 @@ std::optional<FeatureConfig> GetClientSideFeatureConfi #endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (kIPHPasswordsAccountStorageFeature.name == feature->name) { - std::optional<FeatureConfig> config = FeatureConfig(); - config->valid = true; -@@ -1393,7 +1393,8 @@ std::optional<FeatureConfig> GetClientSideFeatureConfi + if (kIPHPasswordsManagementBubbleAfterSaveFeature.name == feature->name) { + FeatureConfig config; + config.valid = true; +@@ -1885,7 +1885,8 @@ std::optional<FeatureConfig> GetClientSideFeatureConfi #endif // BUILDFLAG(IS_ANDROID) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ @@ -26,14 +26,5 @@ + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || \ + BUILDFLAG(IS_BSD) - if (kIPHAutofillExternalAccountProfileSuggestionFeature.name == - feature->name) { -@@ -1965,7 +1966,7 @@ std::optional<FeatureConfig> GetClientSideFeatureConfi - } - - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - if (kIPHDeepScanPromptRemovalFeature.name == feature->name) { - std::optional<FeatureConfig> config = FeatureConfig(); - config->valid = true; + if (kIPHAutofillCreditCardBenefitFeature.name == feature->name) { + // The credit card benefit IPH appears up to three times over 10 years and diff --git a/www/chromium/files/patch-components_feature__engagement_public_feature__constants.cc b/www/chromium/files/patch-components_feature__engagement_public_feature__constants.cc index ebc4d1c30bf0..357bf3681d78 100644 --- a/www/chromium/files/patch-components_feature__engagement_public_feature__constants.cc +++ b/www/chromium/files/patch-components_feature__engagement_public_feature__constants.cc @@ -1,25 +1,24 @@ ---- components/feature_engagement/public/feature_constants.cc.orig 2024-04-19 13:02:56 UTC +--- components/feature_engagement/public/feature_constants.cc.orig 2025-07-02 06:08:04 UTC +++ components/feature_engagement/public/feature_constants.cc -@@ -18,7 +18,7 @@ BASE_FEATURE(kIPHDemoMode, "IPH_DemoMode", base::FEATU - BASE_FEATURE(kIPHDummyFeature, "IPH_Dummy", base::FEATURE_DISABLED_BY_DEFAULT); +@@ -28,7 +28,7 @@ bool IsOnDeviceStorageEnabled() { + } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - BASE_FEATURE(kIPHBatterySaverModeFeature, - "IPH_BatterySaverMode", - base::FEATURE_ENABLED_BY_DEFAULT); -@@ -584,7 +584,8 @@ BASE_FEATURE(kDefaultBrowserTriggerCriteriaExperiment, + #if BUILDFLAG(GOOGLE_CHROME_BRANDING) + BASE_FEATURE(kEsbDownloadRowPromoFeature, + "EsbDownloadRowPromo", +@@ -793,7 +793,7 @@ BASE_FEATURE(kDefaultBrowserTriggerCriteriaExperiment, + #endif // BUILDFLAG(IS_IOS) - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || \ -+ BUILDFLAG(IS_BSD) - BASE_FEATURE(kIPHAutofillExternalAccountProfileSuggestionFeature, - "IPH_AutofillExternalAccountProfileSuggestion", - base::FEATURE_ENABLED_BY_DEFAULT); -@@ -712,7 +713,7 @@ BASE_FEATURE(kIPHScalableIphGamingFeature, +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) + BASE_FEATURE(kIPHAutofillBnplAffirmOrZipSuggestionFeature, + "IPH_AutofillBnplAffirmOrZipSuggestion", +@@ -943,7 +943,7 @@ BASE_FEATURE(kIPHScalableIphGamingFeature, base::FEATURE_DISABLED_BY_DEFAULT); #endif diff --git a/www/chromium/files/patch-components_feature__engagement_public_feature__constants.h b/www/chromium/files/patch-components_feature__engagement_public_feature__constants.h index a2694ce6d6d7..1722652f0e15 100644 --- a/www/chromium/files/patch-components_feature__engagement_public_feature__constants.h +++ b/www/chromium/files/patch-components_feature__engagement_public_feature__constants.h @@ -1,29 +1,29 @@ ---- components/feature_engagement/public/feature_constants.h.orig 2024-04-19 13:02:56 UTC +--- components/feature_engagement/public/feature_constants.h.orig 2025-07-02 06:08:04 UTC +++ components/feature_engagement/public/feature_constants.h -@@ -20,7 +20,7 @@ BASE_DECLARE_FEATURE(kIPHDemoMode); - BASE_DECLARE_FEATURE(kIPHDummyFeature); +@@ -30,7 +30,7 @@ FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHDemoMode); + FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHDummyFeature); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - BASE_DECLARE_FEATURE(kIPHBatterySaverModeFeature); - BASE_DECLARE_FEATURE(kIPHCompanionSidePanelFeature); - BASE_DECLARE_FEATURE(kIPHCompanionSidePanelRegionSearchFeature); -@@ -244,7 +244,7 @@ BASE_DECLARE_FEATURE(kDefaultBrowserTriggerCriteriaExp + #if BUILDFLAG(GOOGLE_CHROME_BRANDING) + FEATURE_CONSTANTS_DECLARE_FEATURE(kEsbDownloadRowPromoFeature); + #endif +@@ -358,7 +358,7 @@ FEATURE_CONSTANTS_DECLARE_FEATURE(kDefaultBrowserTrigg #endif // BUILDFLAG(IS_IOS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) - BASE_DECLARE_FEATURE(kIPHAutofillExternalAccountProfileSuggestionFeature); - BASE_DECLARE_FEATURE(kIPHAutofillManualFallbackFeature); -@@ -293,7 +293,7 @@ BASE_DECLARE_FEATURE(kIPHScalableIphHelpAppBasedTenFea - BASE_DECLARE_FEATURE(kIPHScalableIphGamingFeature); + FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHAutofillBnplAffirmOrZipSuggestionFeature); + FEATURE_CONSTANTS_DECLARE_FEATURE( +@@ -419,7 +419,7 @@ FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHScalableIphHelpA + FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHScalableIphGamingFeature); #endif -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - BASE_DECLARE_FEATURE(kIPHDesktopPWAsLinkCapturingLaunch); - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - + FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHDesktopPWAsLinkCapturingLaunch); + FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHDesktopPWAsLinkCapturingLaunchAppInTab); + FEATURE_CONSTANTS_DECLARE_FEATURE(kIPHSupervisedUserProfileSigninFeature); diff --git a/www/chromium/files/patch-components_feature__engagement_public_feature__list.cc b/www/chromium/files/patch-components_feature__engagement_public_feature__list.cc index 4e8fc171317d..7b3da6813e8e 100644 --- a/www/chromium/files/patch-components_feature__engagement_public_feature__list.cc +++ b/www/chromium/files/patch-components_feature__engagement_public_feature__list.cc @@ -1,29 +1,29 @@ ---- components/feature_engagement/public/feature_list.cc.orig 2024-04-19 13:02:56 UTC +--- components/feature_engagement/public/feature_list.cc.orig 2025-07-02 06:08:04 UTC +++ components/feature_engagement/public/feature_list.cc -@@ -147,7 +147,7 @@ const base::Feature* const kAllFeatures[] = { - &kIPHiOSOverflowMenuCustomizationFeature, +@@ -189,7 +189,7 @@ const base::Feature* const kAllFeatures[] = { + &kIPHIOSGLICPromoFeature, #endif // BUILDFLAG(IS_IOS) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - &kIPHBatterySaverModeFeature, - &kIPHCompanionSidePanelFeature, - &kIPHCompanionSidePanelRegionSearchFeature, -@@ -203,7 +203,7 @@ const base::Feature* const kAllFeatures[] = { + #if BUILDFLAG(GOOGLE_CHROME_BRANDING) + &kEsbDownloadRowPromoFeature, + #endif +@@ -264,7 +264,7 @@ const base::Feature* const kAllFeatures[] = { #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) - &kIPHAutofillExternalAccountProfileSuggestionFeature, - &kIPHAutofillManualFallbackFeature, -@@ -252,7 +252,7 @@ const base::Feature* const kAllFeatures[] = { + &kIPHAutofillAiOptInFeature, + &kIPHAutofillBnplAffirmOrZipSuggestionFeature, +@@ -319,7 +319,7 @@ const base::Feature* const kAllFeatures[] = { &kIPHScalableIphGamingFeature, - #endif // BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) &kIPHDesktopPWAsLinkCapturingLaunch, - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - + &kIPHDesktopPWAsLinkCapturingLaunchAppInTab, + &kIPHSupervisedUserProfileSigninFeature, diff --git a/www/chromium/files/patch-components_feature__engagement_public_feature__list.h b/www/chromium/files/patch-components_feature__engagement_public_feature__list.h index e0887e68c85f..8e3bc8cac25e 100644 --- a/www/chromium/files/patch-components_feature__engagement_public_feature__list.h +++ b/www/chromium/files/patch-components_feature__engagement_public_feature__list.h @@ -1,56 +1,58 @@ ---- components/feature_engagement/public/feature_list.h.orig 2024-04-19 13:02:56 UTC +--- components/feature_engagement/public/feature_list.h.orig 2025-07-02 06:08:04 UTC +++ components/feature_engagement/public/feature_list.h -@@ -266,7 +266,7 @@ DEFINE_VARIATION_PARAM(kIPHiOSOverflowMenuCustomizatio +@@ -336,7 +336,7 @@ DEFINE_VARIATION_PARAM(kIPHIOSGLICPromoFeature, "IPH_I #endif // BUILDFLAG(IS_IOS) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - DEFINE_VARIATION_PARAM(kIPHBatterySaverModeFeature, "IPH_BatterySaverMode"); - DEFINE_VARIATION_PARAM(kIPHCompanionSidePanelFeature, "IPH_CompanionSidePanel"); - DEFINE_VARIATION_PARAM(kIPHCompanionSidePanelRegionSearchFeature, -@@ -362,7 +362,7 @@ DEFINE_VARIATION_PARAM(kIPHBackNavigationMenuFeature, - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || + #if BUILDFLAG(GOOGLE_CHROME_BRANDING) + DEFINE_VARIATION_PARAM(kEsbDownloadRowPromoFeature, "EsbDownloadRowPromo"); + #endif +@@ -458,7 +458,8 @@ DEFINE_VARIATION_PARAM(kIPHTabGroupsSharedTabFeedbackF // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) - DEFINE_VARIATION_PARAM(kIPHAutofillExternalAccountProfileSuggestionFeature, - "IPH_AutofillExternalAccountProfileSuggestion"); -@@ -448,7 +448,7 @@ DEFINE_VARIATION_PARAM(kIPHScalableIphHelpAppBasedTenF + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || \ ++ BUILDFLAG(IS_BSD) + DEFINE_VARIATION_PARAM(kIPHAutofillAiOptInFeature, "IPH_AutofillAiOptIn"); + DEFINE_VARIATION_PARAM(kIPHAutofillBnplAffirmOrZipSuggestionFeature, + "IPH_AutofillBnplAffirmOrZipSuggestion"); +@@ -554,7 +555,7 @@ DEFINE_VARIATION_PARAM(kIPHScalableIphHelpAppBasedTenF DEFINE_VARIATION_PARAM(kIPHScalableIphGamingFeature, "IPH_ScalableIphGaming"); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) DEFINE_VARIATION_PARAM(kIPHDesktopPWAsLinkCapturingLaunch, "IPH_DesktopPWAsLinkCapturingLaunch"); - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -@@ -598,7 +598,7 @@ constexpr flags_ui::FeatureEntry::FeatureVariation - VARIATION_ENTRY(kIPHiOSPromoGenericDefaultBrowserFeature), - VARIATION_ENTRY(kIPHiOSOverflowMenuCustomizationFeature), + DEFINE_VARIATION_PARAM(kIPHDesktopPWAsLinkCapturingLaunchAppInTab, +@@ -742,7 +743,7 @@ inline constexpr flags_ui::FeatureEntry::FeatureVariat + VARIATION_ENTRY(kIPHiOSWelcomeBackFeature), + VARIATION_ENTRY(kIPHIOSGLICPromoFeature), #elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + VARIATION_ENTRY(kIPHAutofillEnableLoyaltyCardsFeature), VARIATION_ENTRY(kIPHBatterySaverModeFeature), VARIATION_ENTRY(kIPHCompanionSidePanelFeature), - VARIATION_ENTRY(kIPHCompanionSidePanelRegionSearchFeature), -@@ -654,7 +654,7 @@ constexpr flags_ui::FeatureEntry::FeatureVariation - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || +@@ -804,7 +805,8 @@ inline constexpr flags_ui::FeatureEntry::FeatureVariat // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) - VARIATION_ENTRY(kIPHAutofillExternalAccountProfileSuggestionFeature), - VARIATION_ENTRY(kIPHAutofillManualFallbackFeature), -@@ -703,7 +703,7 @@ constexpr flags_ui::FeatureEntry::FeatureVariation + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || \ ++ BUILDFLAG(IS_BSD) + VARIATION_ENTRY(kIPHAutofillAiOptInFeature), + VARIATION_ENTRY(kIPHAutofillCreditCardBenefitFeature), + VARIATION_ENTRY(kIPHAutofillCardInfoRetrievalSuggestionFeature), +@@ -857,7 +859,7 @@ inline constexpr flags_ui::FeatureEntry::FeatureVariat VARIATION_ENTRY(kIPHScalableIphGamingFeature), - #endif // BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) VARIATION_ENTRY(kIPHDesktopPWAsLinkCapturingLaunch), - #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) - + VARIATION_ENTRY(kIPHDesktopPWAsLinkCapturingLaunchAppInTab), + VARIATION_ENTRY(kIPHSupervisedUserProfileSigninFeature), diff --git a/www/chromium/files/patch-components_feed_core_v2_feed__network__impl__unittest.cc b/www/chromium/files/patch-components_feed_core_v2_feed__network__impl__unittest.cc index 444725e2acc4..05d49cbe5e38 100644 --- a/www/chromium/files/patch-components_feed_core_v2_feed__network__impl__unittest.cc +++ b/www/chromium/files/patch-components_feed_core_v2_feed__network__impl__unittest.cc @@ -1,6 +1,6 @@ ---- components/feed/core/v2/feed_network_impl_unittest.cc.orig 2023-12-10 06:10:27 UTC +--- components/feed/core/v2/feed_network_impl_unittest.cc.orig 2024-09-30 07:45:04 UTC +++ components/feed/core/v2/feed_network_impl_unittest.cc -@@ -781,8 +781,8 @@ TEST_F(FeedNetworkTest, SendApiRequest_DecodesClientIn +@@ -747,8 +747,8 @@ TEST_F(FeedNetworkTest, SendApiRequest_DecodesClientIn EXPECT_EQ(feedwire::ClientInfo::CHROME_ANDROID, client_info.app_type()); EXPECT_EQ(feedwire::Version::RELEASE, client_info.app_version().build_type()); diff --git a/www/chromium/files/patch-components_feed_core_v2_proto__util.cc b/www/chromium/files/patch-components_feed_core_v2_proto__util.cc index 73d5ec0eb760..89112dbb99b7 100644 --- a/www/chromium/files/patch-components_feed_core_v2_proto__util.cc +++ b/www/chromium/files/patch-components_feed_core_v2_proto__util.cc @@ -1,6 +1,6 @@ ---- components/feed/core/v2/proto_util.cc.orig 2023-07-16 15:47:57 UTC +--- components/feed/core/v2/proto_util.cc.orig 2025-07-02 06:08:04 UTC +++ components/feed/core/v2/proto_util.cc -@@ -93,8 +93,8 @@ feedwire::Version GetPlatformVersionMessage() { +@@ -92,8 +92,8 @@ feedwire::Version GetPlatformVersionMessage() { int32_t major, minor, revision; base::SysInfo::OperatingSystemVersionNumbers(&major, &minor, &revision); @@ -11,7 +11,7 @@ result.set_revision(revision); #if BUILDFLAG(IS_ANDROID) result.set_api_version(base::android::BuildInfo::GetInstance()->sdk_int()); -@@ -109,8 +109,8 @@ feedwire::Version GetAppVersionMessage(const ChromeInf +@@ -108,8 +108,8 @@ feedwire::Version GetAppVersionMessage(const ChromeInf // Chrome's version is in the format: MAJOR,MINOR,BUILD,PATCH. const std::vector<uint32_t>& numbers = chrome_info.version.components(); if (numbers.size() > 3) { diff --git a/www/chromium/files/patch-components_feed_core_v2_proto__util__unittest.cc b/www/chromium/files/patch-components_feed_core_v2_proto__util__unittest.cc index a73206578bde..24c72d1b4031 100644 --- a/www/chromium/files/patch-components_feed_core_v2_proto__util__unittest.cc +++ b/www/chromium/files/patch-components_feed_core_v2_proto__util__unittest.cc @@ -1,6 +1,6 @@ ---- components/feed/core/v2/proto_util_unittest.cc.orig 2023-09-13 12:11:42 UTC +--- components/feed/core/v2/proto_util_unittest.cc.orig 2025-07-02 06:08:04 UTC +++ components/feed/core/v2/proto_util_unittest.cc -@@ -44,8 +44,8 @@ TEST(ProtoUtilTest, CreateClientInfo) { +@@ -42,8 +42,8 @@ TEST(ProtoUtilTest, CreateClientInfo) { feedwire::ClientInfo result = CreateClientInfo(request_metadata); EXPECT_EQ(feedwire::ClientInfo::CHROME_ANDROID, result.app_type()); EXPECT_EQ(feedwire::Version::RELEASE, result.app_version().build_type()); @@ -10,4 +10,4 @@ + EXPECT_EQ(2, result.app_version().gminor()); EXPECT_EQ(3, result.app_version().build()); EXPECT_EQ(4, result.app_version().revision()); - EXPECT_FALSE(result.chrome_client_info().start_surface()); + diff --git a/www/chromium/files/patch-components_flags__ui_flags__state.cc b/www/chromium/files/patch-components_flags__ui_flags__state.cc deleted file mode 100644 index 881eddd1ed45..000000000000 --- a/www/chromium/files/patch-components_flags__ui_flags__state.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/flags_ui/flags_state.cc.orig 2023-09-13 12:11:42 UTC -+++ components/flags_ui/flags_state.cc -@@ -741,7 +741,7 @@ unsigned short FlagsState::GetCurrentPlatform() { - return kOsCrOS; - #elif BUILDFLAG(IS_CHROMEOS_LACROS) - return kOsLacros; --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_OPENBSD) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return kOsLinux; - #elif BUILDFLAG(IS_ANDROID) - return kOsAndroid; diff --git a/www/chromium/files/patch-components_gcm__driver_gcm__desktop__utils.cc b/www/chromium/files/patch-components_gcm__driver_gcm__desktop__utils.cc new file mode 100644 index 000000000000..a5053caa4239 --- /dev/null +++ b/www/chromium/files/patch-components_gcm__driver_gcm__desktop__utils.cc @@ -0,0 +1,11 @@ +--- components/gcm_driver/gcm_desktop_utils.cc.orig 2025-02-19 07:43:18 UTC ++++ components/gcm_driver/gcm_desktop_utils.cc +@@ -32,7 +32,7 @@ GCMClient::ChromePlatform GetPlatform() { + return GCMClient::PLATFORM_ANDROID; + #elif BUILDFLAG(IS_CHROMEOS) + return GCMClient::PLATFORM_CROS; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return GCMClient::PLATFORM_LINUX; + #else + // For all other platforms, return as LINUX. diff --git a/www/chromium/files/patch-components_gwp__asan_BUILD.gn b/www/chromium/files/patch-components_gwp__asan_BUILD.gn index 416067b4053b..c1d3ccf17770 100644 --- a/www/chromium/files/patch-components_gwp__asan_BUILD.gn +++ b/www/chromium/files/patch-components_gwp__asan_BUILD.gn @@ -1,11 +1,11 @@ ---- components/gwp_asan/BUILD.gn.orig 2022-11-30 08:12:58 UTC +--- components/gwp_asan/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ components/gwp_asan/BUILD.gn @@ -15,7 +15,7 @@ test("gwp_asan_unittests") { "//testing/gtest", "//third_party/boringssl", ] -- if (is_win || is_mac || is_linux || is_chromeos || is_android) { -+ if ((is_win || is_mac || is_linux || is_chromeos || is_android) && !is_bsd) { +- if (is_win || is_mac || is_linux || is_chromeos || is_android || is_ios) { ++ if ((is_win || is_mac || is_linux || is_chromeos || is_android || is_ios) && !is_bsd) { deps += [ "//components/gwp_asan/client:unit_tests", "//components/gwp_asan/crash_handler:unit_tests", diff --git a/www/chromium/files/patch-components_gwp__asan_buildflags_buildflags.gni b/www/chromium/files/patch-components_gwp__asan_buildflags_buildflags.gni new file mode 100644 index 000000000000..b75aa63b069e --- /dev/null +++ b/www/chromium/files/patch-components_gwp__asan_buildflags_buildflags.gni @@ -0,0 +1,14 @@ +--- components/gwp_asan/buildflags/buildflags.gni.orig 2025-05-05 10:57:53 UTC ++++ components/gwp_asan/buildflags/buildflags.gni +@@ -10,10 +10,7 @@ import("//build/config/compiler/compiler.gni") + # Android component builds are disabled due to https://crbug.com/976399 + # Android requires frame pointers for unwinding, unwind tables aren't shipped in + # official builds. +-supported_platform = +- is_linux || is_chromeos || is_mac || is_ios || +- (is_win && (current_cpu == "x64" || current_cpu == "arm64")) || +- (is_android && !is_component_build && enable_frame_pointers) ++supported_platform = false + + declare_args() { + # Is GWP-ASan malloc/PartitionAlloc hooking enabled for chrome/ on a given diff --git a/www/chromium/files/patch-components_gwp__asan_client_gwp__asan.cc b/www/chromium/files/patch-components_gwp__asan_client_gwp__asan.cc index 61de4efc0c09..e733ef46f884 100644 --- a/www/chromium/files/patch-components_gwp__asan_client_gwp__asan.cc +++ b/www/chromium/files/patch-components_gwp__asan_client_gwp__asan.cc @@ -1,6 +1,6 @@ ---- components/gwp_asan/client/gwp_asan.cc.orig 2024-04-19 13:02:56 UTC +--- components/gwp_asan/client/gwp_asan.cc.orig 2025-05-05 10:57:53 UTC +++ components/gwp_asan/client/gwp_asan.cc -@@ -72,7 +72,7 @@ namespace { +@@ -76,7 +76,7 @@ namespace { // ProcessSamplingBoost is the multiplier to increase the // ProcessSamplingProbability in scenarios where we want to perform additional // testing (e.g., on canary/dev builds). diff --git a/www/chromium/files/patch-components_gwp__asan_crash__handler_crash__analyzer.cc b/www/chromium/files/patch-components_gwp__asan_crash__handler_crash__analyzer.cc index e1d7a7024019..83f9da6b0bf5 100644 --- a/www/chromium/files/patch-components_gwp__asan_crash__handler_crash__analyzer.cc +++ b/www/chromium/files/patch-components_gwp__asan_crash__handler_crash__analyzer.cc @@ -1,6 +1,6 @@ ---- components/gwp_asan/crash_handler/crash_analyzer.cc.orig 2024-04-19 13:02:56 UTC +--- components/gwp_asan/crash_handler/crash_analyzer.cc.orig 2025-05-05 10:57:53 UTC +++ components/gwp_asan/crash_handler/crash_analyzer.cc -@@ -30,7 +30,7 @@ +@@ -35,7 +35,7 @@ #include "third_party/crashpad/crashpad/snapshot/process_snapshot.h" #include "third_party/crashpad/crashpad/util/process/process_memory.h" @@ -9,7 +9,7 @@ #include <signal.h> #elif BUILDFLAG(IS_APPLE) #include <mach/exception_types.h> -@@ -90,7 +90,7 @@ bool CrashAnalyzer::GetExceptionInfo( +@@ -113,7 +113,7 @@ bool CrashAnalyzer::GetExceptionInfo( crashpad::VMAddress CrashAnalyzer::GetAccessAddress( const crashpad::ExceptionSnapshot& exception) { diff --git a/www/chromium/files/patch-components_live__caption_caption__util.cc b/www/chromium/files/patch-components_live__caption_caption__util.cc index 05d2735d02ec..90d1b744149a 100644 --- a/www/chromium/files/patch-components_live__caption_caption__util.cc +++ b/www/chromium/files/patch-components_live__caption_caption__util.cc @@ -1,20 +1,11 @@ ---- components/live_caption/caption_util.cc.orig 2023-07-16 15:47:57 UTC +--- components/live_caption/caption_util.cc.orig 2025-05-28 14:55:43 UTC +++ components/live_caption/caption_util.cc -@@ -145,7 +145,7 @@ bool IsLiveCaptionFeatureSupported() { - return false; - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Check if the CPU has the required instruction set to run the Speech - // On-Device API (SODA) library. - static bool has_sse41 = base::CPU().has_sse41(); -@@ -167,7 +167,7 @@ std::string GetCaptionSettingsUrl() { +@@ -141,7 +141,7 @@ bool IsHeadlessCaptionFeatureSupported() { + std::string GetCaptionSettingsUrl() { + #if BUILDFLAG(IS_CHROMEOS) return "chrome://os-settings/audioAndCaptions"; - #endif // BUILDFLAG(IS_CHROMEOS) - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return "chrome://settings/captions"; - #endif // BUILDFLAG(IS_LINUX) - + #elif BUILDFLAG(IS_WIN) + return base::win::GetVersion() >= base::win::Version::WIN10 diff --git a/www/chromium/files/patch-components_media__router_common_media__source.cc b/www/chromium/files/patch-components_media__router_common_media__source.cc index 11630a22c275..62a615b35871 100644 --- a/www/chromium/files/patch-components_media__router_common_media__source.cc +++ b/www/chromium/files/patch-components_media__router_common_media__source.cc @@ -1,11 +1,11 @@ ---- components/media_router/common/media_source.cc.orig 2024-02-23 21:04:38 UTC +--- components/media_router/common/media_source.cc.orig 2025-05-28 14:55:43 UTC +++ components/media_router/common/media_source.cc -@@ -59,7 +59,7 @@ bool IsSystemAudioCaptureSupported() { +@@ -58,7 +58,7 @@ bool IsSystemAudioCaptureSupported() { + if (!media::IsSystemLoopbackCaptureSupported()) { + return false; } - #if BUILDFLAG(IS_MAC) - return base::FeatureList::IsEnabled(media::kMacLoopbackAudioForCast); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return base::FeatureList::IsEnabled(media::kPulseaudioLoopbackForCast); #else return true; diff --git a/www/chromium/files/patch-components_media__router_common_providers_cast_channel_cast__message__util.cc b/www/chromium/files/patch-components_media__router_common_providers_cast_channel_cast__message__util.cc index f0f3c160aa6d..6e97488bb8f1 100644 --- a/www/chromium/files/patch-components_media__router_common_providers_cast_channel_cast__message__util.cc +++ b/www/chromium/files/patch-components_media__router_common_providers_cast_channel_cast__message__util.cc @@ -1,11 +1,11 @@ ---- components/media_router/common/providers/cast/channel/cast_message_util.cc.orig 2023-11-03 10:09:45 UTC +--- components/media_router/common/providers/cast/channel/cast_message_util.cc.orig 2025-02-19 07:43:18 UTC +++ components/media_router/common/providers/cast/channel/cast_message_util.cc -@@ -169,7 +169,7 @@ int GetVirtualConnectPlatformValue() { +@@ -168,7 +168,7 @@ int GetVirtualConnectPlatformValue() { return 4; - #elif BUILDFLAG(IS_CHROMEOS_ASH) + #elif BUILDFLAG(IS_CHROMEOS) return 5; --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return 6; #else return 0; diff --git a/www/chromium/files/patch-components_media__router_common_providers_cast_channel_enum__table.h b/www/chromium/files/patch-components_media__router_common_providers_cast_channel_enum__table.h new file mode 100644 index 000000000000..8bd9513ed9a1 --- /dev/null +++ b/www/chromium/files/patch-components_media__router_common_providers_cast_channel_enum__table.h @@ -0,0 +1,15 @@ +--- components/media_router/common/providers/cast/channel/enum_table.h.orig 2025-02-19 07:43:18 UTC ++++ components/media_router/common/providers/cast/channel/enum_table.h +@@ -368,7 +368,12 @@ class EnumTable { + + private: + #ifdef ARCH_CPU_64_BITS ++#ifdef __cpp_lib_hardware_interference_size + alignas(std::hardware_destructive_interference_size) ++#else ++ static constexpr std::size_t hardware_destructive_interference_size = 64; ++ alignas(hardware_destructive_interference_size) ++#endif + #endif + std::initializer_list<Entry> data_; + bool is_sorted_; diff --git a/www/chromium/files/patch-components_metrics_drive__metrics__provider.cc b/www/chromium/files/patch-components_metrics_drive__metrics__provider.cc new file mode 100644 index 000000000000..853a28804499 --- /dev/null +++ b/www/chromium/files/patch-components_metrics_drive__metrics__provider.cc @@ -0,0 +1,20 @@ +--- components/metrics/drive_metrics_provider.cc.orig 2025-05-05 10:57:53 UTC ++++ components/metrics/drive_metrics_provider.cc +@@ -21,7 +21,7 @@ + namespace metrics { + + namespace { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void RecordTriStateMetric(const char* name, std::optional<bool> sample) { + base::UmaHistogramEnumeration( + name, !sample.has_value() +@@ -106,7 +106,7 @@ void DriveMetricsProvider::FillDriveMetrics( + drive->set_has_seek_penalty(*response.has_seek_penalty); + } + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + RecordTriStateMetric("UMA.DriveIsRemovableResult", response.is_removable); + #endif + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-components_metrics_drive__metrics__provider__linux.cc b/www/chromium/files/patch-components_metrics_drive__metrics__provider__linux.cc deleted file mode 100644 index 0bfcf36cc857..000000000000 --- a/www/chromium/files/patch-components_metrics_drive__metrics__provider__linux.cc +++ /dev/null @@ -1,16 +0,0 @@ ---- components/metrics/drive_metrics_provider_linux.cc.orig 2023-09-13 12:11:42 UTC -+++ components/metrics/drive_metrics_provider_linux.cc -@@ -4,7 +4,13 @@ - - #include "components/metrics/drive_metrics_provider.h" - -+#if BUILDFLAG(IS_BSD) -+#include <sys/types.h> -+#define MAJOR(dev) major(dev) -+#define MINOR(dev) minor(dev) -+#else - #include <linux/kdev_t.h> // For MAJOR()/MINOR(). -+#endif - #include <sys/stat.h> - #include <string> - diff --git a/www/chromium/files/patch-components_metrics_dwa_dwa__service.cc b/www/chromium/files/patch-components_metrics_dwa_dwa__service.cc new file mode 100644 index 000000000000..e0413d739385 --- /dev/null +++ b/www/chromium/files/patch-components_metrics_dwa_dwa__service.cc @@ -0,0 +1,11 @@ +--- components/metrics/dwa/dwa_service.cc.orig 2025-04-04 08:52:13 UTC ++++ components/metrics/dwa/dwa_service.cc +@@ -162,7 +162,7 @@ void DwaService::RecordCoarseSystemInformation( + coarse_system_info->set_platform(::dwa::CoarseSystemInfo::PLATFORM_WINDOWS); + #elif BUILDFLAG(IS_MAC) + coarse_system_info->set_platform(::dwa::CoarseSystemInfo::PLATFORM_MACOS); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + coarse_system_info->set_platform(::dwa::CoarseSystemInfo::PLATFORM_LINUX); + #elif BUILDFLAG(IS_ANDROID) + // TODO(b/366276323): Populate set_platform using more granular diff --git a/www/chromium/files/patch-components_metrics_metrics__log.cc b/www/chromium/files/patch-components_metrics_metrics__log.cc index dbf14443fba7..b3c42657cd0b 100644 --- a/www/chromium/files/patch-components_metrics_metrics__log.cc +++ b/www/chromium/files/patch-components_metrics_metrics__log.cc @@ -1,6 +1,6 @@ ---- components/metrics/metrics_log.cc.orig 2024-01-30 07:53:34 UTC +--- components/metrics/metrics_log.cc.orig 2025-07-02 06:08:04 UTC +++ components/metrics/metrics_log.cc -@@ -53,7 +53,7 @@ +@@ -58,7 +58,7 @@ #include "base/win/current_module.h" #endif @@ -9,7 +9,7 @@ #include "base/environment.h" #include "base/nix/xdg_util.h" #endif -@@ -142,7 +142,7 @@ void RecordCurrentTime( +@@ -154,7 +154,7 @@ void RecordCurrentTime( } } @@ -18,16 +18,16 @@ metrics::SystemProfileProto::OS::XdgSessionType ToProtoSessionType( base::nix::SessionType session_type) { switch (session_type) { -@@ -393,7 +393,7 @@ void MetricsLog::RecordCoreSystemProfile( +@@ -437,7 +437,7 @@ void MetricsLog::RecordCoreSystemProfile( // OperatingSystemVersion refers to the ChromeOS release version. - #if BUILDFLAG(IS_CHROMEOS_ASH) + #if BUILDFLAG(IS_CHROMEOS) os->set_kernel_version(base::SysInfo::KernelVersion()); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Linux operating system version is copied over into kernel version to be // consistent. os->set_kernel_version(base::SysInfo::OperatingSystemVersion()); -@@ -410,7 +410,7 @@ void MetricsLog::RecordCoreSystemProfile( +@@ -454,7 +454,7 @@ void MetricsLog::RecordCoreSystemProfile( os->set_build_number(base::SysInfo::GetIOSBuildNumber()); #endif diff --git a/www/chromium/files/patch-components_named__mojo__ipc__server_connection__info.h b/www/chromium/files/patch-components_named__mojo__ipc__server_connection__info.h index a8974c4f65ca..adb4fd894427 100644 --- a/www/chromium/files/patch-components_named__mojo__ipc__server_connection__info.h +++ b/www/chromium/files/patch-components_named__mojo__ipc__server_connection__info.h @@ -1,20 +1,23 @@ ---- components/named_mojo_ipc_server/connection_info.h.orig 2024-03-22 08:19:40 UTC +--- components/named_mojo_ipc_server/connection_info.h.orig 2025-04-04 08:52:13 UTC +++ components/named_mojo_ipc_server/connection_info.h -@@ -14,7 +14,7 @@ +@@ -12,7 +12,10 @@ #include "base/win/scoped_handle.h" #elif BUILDFLAG(IS_MAC) #include <bsm/libbsm.h> -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ++#if BUILDFLAG(IS_OPENBSD) ++#include <sys/ucred.h> ++#endif #include <sys/socket.h> #endif -@@ -33,7 +33,7 @@ struct ConnectionInfo { - std::optional<base::win::ScopedHandle> impersonation_token{}; - #elif BUILDFLAG(IS_MAC) +@@ -29,7 +32,7 @@ struct ConnectionInfo { + base::ProcessId pid{}; + #if BUILDFLAG(IS_MAC) audit_token_t audit_token{}; -#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_OPENBSD) ucred credentials{}; #endif }; diff --git a/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__ipc__server__client__util.cc b/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__ipc__server__client__util.cc index d588c07870e1..1d494b113ce9 100644 --- a/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__ipc__server__client__util.cc +++ b/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__ipc__server__client__util.cc @@ -1,6 +1,6 @@ ---- components/named_mojo_ipc_server/named_mojo_ipc_server_client_util.cc.orig 2023-02-08 09:03:45 UTC +--- components/named_mojo_ipc_server/named_mojo_ipc_server_client_util.cc.orig 2024-10-22 08:31:56 UTC +++ components/named_mojo_ipc_server/named_mojo_ipc_server_client_util.cc -@@ -22,7 +22,7 @@ namespace named_mojo_ipc_server { +@@ -23,7 +23,7 @@ namespace named_mojo_ipc_server { // static mojo::PlatformChannelEndpoint ConnectToServer( const mojo::NamedPlatformChannel::ServerName& server_name) { diff --git a/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__server__endpoint__connector__linux.cc b/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__server__endpoint__connector__linux.cc new file mode 100644 index 000000000000..278a5aed19e7 --- /dev/null +++ b/www/chromium/files/patch-components_named__mojo__ipc__server_named__mojo__server__endpoint__connector__linux.cc @@ -0,0 +1,12 @@ +--- components/named_mojo_ipc_server/named_mojo_server_endpoint_connector_linux.cc.orig 2025-04-04 08:52:13 UTC ++++ components/named_mojo_ipc_server/named_mojo_server_endpoint_connector_linux.cc +@@ -89,7 +89,9 @@ void NamedMojoServerEndpointConnectorLinux::OnSocketRe + PLOG(ERROR) << "getsockopt failed."; + return; + } ++#if !BUILDFLAG(IS_OPENBSD) + info->pid = info->credentials.pid; ++#endif + + mojo::PlatformChannelEndpoint endpoint( + mojo::PlatformHandle(std::move(connection_fd))); diff --git a/www/chromium/files/patch-components_named__system__lock_BUILD.gn b/www/chromium/files/patch-components_named__system__lock_BUILD.gn new file mode 100644 index 000000000000..662c32cc99de --- /dev/null +++ b/www/chromium/files/patch-components_named__system__lock_BUILD.gn @@ -0,0 +1,20 @@ +--- components/named_system_lock/BUILD.gn.orig 2025-04-04 08:52:13 UTC ++++ components/named_system_lock/BUILD.gn +@@ -5,7 +5,7 @@ + static_library("named_system_lock") { + sources = [ "lock.h" ] + deps = [ "//base" ] +- if (is_linux) { ++ if (!is_bsd && is_linux) { + sources += [ "lock_linux.cc" ] + } else if (is_mac) { + sources += [ "lock_mac.mm" ] +@@ -20,7 +20,7 @@ source_set("unit_tests") { + sources = [] + + # Disable NamedSystemLockTest on unsupported platforms. +- if (is_linux || is_win || is_mac) { ++ if (!is_bsd && (is_linux || is_win || is_mac)) { + sources += [ "lock_unittest.cc" ] + } + diff --git a/www/chromium/files/patch-components_named__system__lock_lock.h b/www/chromium/files/patch-components_named__system__lock_lock.h new file mode 100644 index 000000000000..113783611cd1 --- /dev/null +++ b/www/chromium/files/patch-components_named__system__lock_lock.h @@ -0,0 +1,11 @@ +--- components/named_system_lock/lock.h.orig 2024-07-30 11:12:21 UTC ++++ components/named_system_lock/lock.h +@@ -38,7 +38,7 @@ class ScopedLock { + // may acquire that lock. The lock name has different meanings per platform: + // Linux: A shared memory object name starting with `/`. E.g. `/MyApp.lock`. + // Mac: A bootstrap service name (see `man bootstrap_check_in`). +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + static std::unique_ptr<ScopedLock> Create(const std::string& name, + base::TimeDelta timeout); + #elif BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-components_named__system__lock_lock__unittest.cc b/www/chromium/files/patch-components_named__system__lock_lock__unittest.cc new file mode 100644 index 000000000000..e5eaefad0463 --- /dev/null +++ b/www/chromium/files/patch-components_named__system__lock_lock__unittest.cc @@ -0,0 +1,29 @@ +--- components/named_system_lock/lock_unittest.cc.orig 2025-04-04 08:52:13 UTC ++++ components/named_system_lock/lock_unittest.cc +@@ -18,7 +18,7 @@ + #include "build/build_config.h" + #include "testing/gtest/include/gtest/gtest.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include <fcntl.h> + #include <sys/mman.h> + +@@ -45,7 +45,7 @@ class NamedSystemLockTest : public ::testing::Test { + const std::string lock_name_ = base::UnguessableToken::Create().ToString(); + + std::unique_ptr<ScopedLock> CreateLock() { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + return ScopedLock::Create(lock_name_, base::Seconds(0)); + #else + CSecurityAttributes sa; +@@ -95,7 +95,7 @@ TEST_F(NamedSystemLockTest, TryLockInThreadSuccess) { + EXPECT_TRUE(CreateLock()); + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + TEST_F(NamedSystemLockTest, SharedMemoryWrongPermissions) { + // Create a shared memory region with overpermissive perms. + int shm_fd = shm_open(lock_name_.c_str(), O_RDWR | O_CREAT | O_EXCL, diff --git a/www/chromium/files/patch-components_neterror_resources_neterror.js b/www/chromium/files/patch-components_neterror_resources_neterror.js deleted file mode 100644 index 7a5f79a58b2b..000000000000 --- a/www/chromium/files/patch-components_neterror_resources_neterror.js +++ /dev/null @@ -1,11 +0,0 @@ ---- components/neterror/resources/neterror.js.orig 2024-01-30 07:53:34 UTC -+++ components/neterror/resources/neterror.js -@@ -142,7 +142,7 @@ function detailsButtonClick() { - - let primaryControlOnLeft = true; - // clang-format off --// <if expr="is_macosx or is_ios or is_linux or is_chromeos or is_android"> -+// <if expr="is_macosx or is_ios or is_posix or is_chromeos or is_android"> - // clang-format on - primaryControlOnLeft = false; - // </if> diff --git a/www/chromium/files/patch-components_network__session__configurator_browser_network__session__configurator.cc b/www/chromium/files/patch-components_network__session__configurator_browser_network__session__configurator.cc deleted file mode 100644 index 30fba75b837a..000000000000 --- a/www/chromium/files/patch-components_network__session__configurator_browser_network__session__configurator.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/network_session_configurator/browser/network_session_configurator.cc.orig 2024-04-19 13:02:56 UTC -+++ components/network_session_configurator/browser/network_session_configurator.cc -@@ -817,7 +817,7 @@ net::URLRequestContextBuilder::HttpCacheParams::Type C - // backport, having it behave differently than in stable would be a bigger - // problem. TODO: Does this work in later macOS releases? - #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_MAC) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - return net::URLRequestContextBuilder::HttpCacheParams::DISK_SIMPLE; - #else - return net::URLRequestContextBuilder::HttpCacheParams::DISK_BLOCKFILE; diff --git a/www/chromium/files/patch-components_network__session__configurator_browser_network__session__configurator__unittest.cc b/www/chromium/files/patch-components_network__session__configurator_browser_network__session__configurator__unittest.cc deleted file mode 100644 index 6f82591d441f..000000000000 --- a/www/chromium/files/patch-components_network__session__configurator_browser_network__session__configurator__unittest.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/network_session_configurator/browser/network_session_configurator_unittest.cc.orig 2024-04-19 13:02:56 UTC -+++ components/network_session_configurator/browser/network_session_configurator_unittest.cc -@@ -781,7 +781,7 @@ TEST_F(NetworkSessionConfiguratorTest, HostRules) { - - TEST_F(NetworkSessionConfiguratorTest, DefaultCacheBackend) { - #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_MAC) -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - EXPECT_EQ(net::URLRequestContextBuilder::HttpCacheParams::DISK_SIMPLE, - ChooseCacheType()); - #else diff --git a/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__features.cc b/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__features.cc new file mode 100644 index 000000000000..08f09641c572 --- /dev/null +++ b/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__features.cc @@ -0,0 +1,11 @@ +--- components/optimization_guide/core/optimization_guide_features.cc.orig 2025-02-19 07:43:18 UTC ++++ components/optimization_guide/core/optimization_guide_features.cc +@@ -136,7 +136,7 @@ BASE_FEATURE(kOptimizationGuideModelExecution, + // Whether to use the on device model service in optimization guide. + BASE_FEATURE(kOptimizationGuideOnDeviceModel, + "OptimizationGuideOnDeviceModel", +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT); + #else + base::FEATURE_DISABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__util.cc b/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__util.cc index b66b9cb72bea..bfd5088276d5 100644 --- a/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__util.cc +++ b/www/chromium/files/patch-components_optimization__guide_core_optimization__guide__util.cc @@ -1,6 +1,6 @@ ---- components/optimization_guide/core/optimization_guide_util.cc.orig 2024-01-30 07:53:34 UTC +--- components/optimization_guide/core/optimization_guide_util.cc.orig 2024-11-14 07:57:23 UTC +++ components/optimization_guide/core/optimization_guide_util.cc -@@ -39,7 +39,7 @@ optimization_guide::proto::Platform GetPlatform() { +@@ -37,7 +37,7 @@ optimization_guide::proto::Platform GetPlatform() { return optimization_guide::proto::PLATFORM_CHROMEOS; #elif BUILDFLAG(IS_ANDROID) return optimization_guide::proto::PLATFORM_ANDROID; diff --git a/www/chromium/files/patch-components_os__crypt_async_browser_secret__portal__key__provider.cc b/www/chromium/files/patch-components_os__crypt_async_browser_secret__portal__key__provider.cc new file mode 100644 index 000000000000..22691d376adb --- /dev/null +++ b/www/chromium/files/patch-components_os__crypt_async_browser_secret__portal__key__provider.cc @@ -0,0 +1,12 @@ +--- components/os_crypt/async/browser/secret_portal_key_provider.cc.orig 2024-10-22 08:31:56 UTC ++++ components/os_crypt/async/browser/secret_portal_key_provider.cc +@@ -5,7 +5,9 @@ + #include "components/os_crypt/async/browser/secret_portal_key_provider.h" + + #include <fcntl.h> ++#if BUILDFLAG(IS_LINUX) + #include <linux/limits.h> ++#endif + + #include <array> + #include <utility> diff --git a/www/chromium/files/patch-components_os__crypt_sync_libsecret__util__linux.cc b/www/chromium/files/patch-components_os__crypt_sync_libsecret__util__linux.cc index 020622f12c96..1e6502041dea 100644 --- a/www/chromium/files/patch-components_os__crypt_sync_libsecret__util__linux.cc +++ b/www/chromium/files/patch-components_os__crypt_sync_libsecret__util__linux.cc @@ -1,6 +1,6 @@ ---- components/os_crypt/sync/libsecret_util_linux.cc.orig 2023-04-28 17:01:32 UTC +--- components/os_crypt/sync/libsecret_util_linux.cc.orig 2024-10-22 08:31:56 UTC +++ components/os_crypt/sync/libsecret_util_linux.cc -@@ -99,16 +99,22 @@ bool LibsecretLoader::EnsureLibsecretLoaded() { +@@ -185,16 +185,22 @@ bool LibsecretLoader::EnsureLibsecretLoaded() { // static bool LibsecretLoader::LoadLibsecret() { @@ -19,9 +19,9 @@ // We wanted to use libsecret, but we couldn't load it. Warn, because // either the user asked for this, or we autodetected it incorrectly. (Or // the system has broken libraries, which is also good to warn about.) - // TODO(crbug.com/607435): Channel this message to the user-facing log + // TODO(crbug.com/40467093): Channel this message to the user-facing log - VLOG(1) << "Could not load libsecret-1.so.0: " << dlerror(); -+ VLOG(1) << "Could not load << " << kSecretLib << ": " << dlerror(); ++ VLOG(1) << "Could not load " << kSecretLib << ": " << dlerror(); return false; } diff --git a/www/chromium/files/patch-components_os__crypt_sync_os__crypt.h b/www/chromium/files/patch-components_os__crypt_sync_os__crypt.h index 7fdad41682db..b71296e7b06e 100644 --- a/www/chromium/files/patch-components_os__crypt_sync_os__crypt.h +++ b/www/chromium/files/patch-components_os__crypt_sync_os__crypt.h @@ -1,24 +1,15 @@ ---- components/os_crypt/sync/os_crypt.h.orig 2023-04-28 17:01:32 UTC +--- components/os_crypt/sync/os_crypt.h.orig 2025-07-02 06:08:04 UTC +++ components/os_crypt/sync/os_crypt.h -@@ -14,7 +14,7 @@ - #include "build/build_config.h" - #include "build/chromecast_buildflags.h" +@@ -22,7 +22,7 @@ class AppleKeychain; + } + #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) class KeyStorageLinux; #endif // BUILDFLAG(IS_LINUX) -@@ -23,7 +23,7 @@ class PrefRegistrySimple; - class PrefService; - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_APPLE) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_BSD) - namespace crypto { - class SymmetricKey; - } -@@ -36,7 +36,7 @@ struct Config; +@@ -38,7 +38,7 @@ struct Config; // Temporary interface due to OSCrypt refactor. See OSCryptImpl for descriptions // of what each function does. namespace OSCrypt { @@ -27,7 +18,7 @@ COMPONENT_EXPORT(OS_CRYPT) void SetConfig(std::unique_ptr<os_crypt::Config> config); #endif // BUILDFLAG(IS_LINUX) -@@ -81,7 +81,7 @@ COMPONENT_EXPORT(OS_CRYPT) void UseMockKeyForTesting(b +@@ -83,7 +83,7 @@ COMPONENT_EXPORT(OS_CRYPT) void UseMockKeyForTesting(b COMPONENT_EXPORT(OS_CRYPT) void SetLegacyEncryptionForTesting(bool legacy); COMPONENT_EXPORT(OS_CRYPT) void ResetStateForTesting(); #endif // BUILDFLAG(IS_WIN) @@ -36,7 +27,7 @@ COMPONENT_EXPORT(OS_CRYPT) void UseMockKeyStorageForTesting( base::OnceCallback<std::unique_ptr<KeyStorageLinux>()> -@@ -108,7 +108,7 @@ class COMPONENT_EXPORT(OS_CRYPT) OSCryptImpl { +@@ -117,7 +117,7 @@ class COMPONENT_EXPORT(OS_CRYPT) OSCryptImpl { // Returns singleton instance of OSCryptImpl. static OSCryptImpl* GetInstance(); @@ -45,7 +36,7 @@ // Set the configuration of OSCryptImpl. // This method, or SetRawEncryptionKey(), must be called before using // EncryptString() and DecryptString(). -@@ -200,7 +200,7 @@ class COMPONENT_EXPORT(OS_CRYPT) OSCryptImpl { +@@ -213,7 +213,7 @@ class COMPONENT_EXPORT(OS_CRYPT) OSCryptImpl { void ResetStateForTesting(); #endif @@ -54,8 +45,8 @@ // For unit testing purposes, inject methods to be used. // |storage_provider_factory| provides the desired |KeyStorage| // implementation. If the provider returns |nullptr|, a hardcoded password -@@ -225,13 +225,13 @@ class COMPONENT_EXPORT(OS_CRYPT) OSCryptImpl { - crypto::SymmetricKey* GetEncryptionKey(); +@@ -240,13 +240,13 @@ class COMPONENT_EXPORT(OS_CRYPT) OSCryptImpl { + bool DeriveKey(); #endif // BUILDFLAG(IS_APPLE) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_APPLE) @@ -67,6 +58,6 @@ -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Create the KeyStorage. Will be null if no service is found. A Config must - // be set before every call to this method. - std::unique_ptr<KeyStorageLinux> CreateKeyStorage(); + static constexpr size_t kDerivedKeyBytes = 16; + + crypto::SubtlePassKey MakeCryptoPassKey(); diff --git a/www/chromium/files/patch-components_paint__preview_browser_paint__preview__client.cc b/www/chromium/files/patch-components_paint__preview_browser_paint__preview__client.cc index 38bdbeb90465..067b2bf8cc83 100644 --- a/www/chromium/files/patch-components_paint__preview_browser_paint__preview__client.cc +++ b/www/chromium/files/patch-components_paint__preview_browser_paint__preview__client.cc @@ -1,6 +1,6 @@ ---- components/paint_preview/browser/paint_preview_client.cc.orig 2024-01-30 07:53:34 UTC +--- components/paint_preview/browser/paint_preview_client.cc.orig 2024-10-22 08:31:56 UTC +++ components/paint_preview/browser/paint_preview_client.cc -@@ -313,8 +313,8 @@ void PaintPreviewClient::CapturePaintPreview( +@@ -326,8 +326,8 @@ void PaintPreviewClient::CapturePaintPreview( metadata->set_version(kPaintPreviewVersion); auto* chromeVersion = metadata->mutable_chrome_version(); const auto& current_chrome_version = version_info::GetVersion(); diff --git a/www/chromium/files/patch-components_paint__preview_player_player__compositor__delegate.cc b/www/chromium/files/patch-components_paint__preview_player_player__compositor__delegate.cc index 7339f754fb98..9c645f7afd2d 100644 --- a/www/chromium/files/patch-components_paint__preview_player_player__compositor__delegate.cc +++ b/www/chromium/files/patch-components_paint__preview_player_player__compositor__delegate.cc @@ -1,6 +1,6 @@ ---- components/paint_preview/player/player_compositor_delegate.cc.orig 2024-01-30 07:53:34 UTC +--- components/paint_preview/player/player_compositor_delegate.cc.orig 2025-02-19 07:43:18 UTC +++ components/paint_preview/player/player_compositor_delegate.cc -@@ -455,8 +455,8 @@ void PlayerCompositorDelegate::ValidateProtoAndLoadAXT +@@ -433,8 +433,8 @@ void PlayerCompositorDelegate::ValidateProtoAndLoadAXT auto chrome_version = capture_result_->proto.metadata().chrome_version(); const auto& current_chrome_version = version_info::GetVersion(); if (capture_result_->proto.metadata().has_chrome_version() && diff --git a/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.cc b/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.cc index c6578afcb5ee..290372f263c1 100644 --- a/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.cc +++ b/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.cc @@ -1,20 +1,20 @@ ---- components/password_manager/core/browser/features/password_features.cc.orig 2024-04-19 13:02:56 UTC +--- components/password_manager/core/browser/features/password_features.cc.orig 2025-07-02 06:08:04 UTC +++ components/password_manager/core/browser/features/password_features.cc -@@ -30,7 +30,7 @@ BASE_FEATURE(kButterOnDesktopFollowup, - +@@ -47,7 +47,7 @@ BASE_FEATURE(kClearUndecryptablePasswords, BASE_FEATURE(kClearUndecryptablePasswordsOnSync, "ClearUndecryptablePasswordsInSync", --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_IOS) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_IOS) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -99,7 +99,7 @@ BASE_FEATURE(kPasswordManualFallbackAvailable, - "PasswordManualFallbackAvailable", - base::FEATURE_DISABLED_BY_DEFAULT); +@@ -120,7 +120,7 @@ BASE_FEATURE(kReuseDetectionBasedOnPasswordHashes, + "ReuseDetectionBasedOnPasswordHashes", + base::FEATURE_ENABLED_BY_DEFAULT); -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) BASE_FEATURE(kRestartToGainAccessToKeychain, "RestartToGainAccessToKeychain", - base::FEATURE_ENABLED_BY_DEFAULT); + #if BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.h b/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.h index 049bf94129ef..a47850fd900e 100644 --- a/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.h +++ b/www/chromium/files/patch-components_password__manager_core_browser_features_password__features.h @@ -1,8 +1,8 @@ ---- components/password_manager/core/browser/features/password_features.h.orig 2024-04-19 13:02:56 UTC +--- components/password_manager/core/browser/features/password_features.h.orig 2025-07-02 06:08:04 UTC +++ components/password_manager/core/browser/features/password_features.h -@@ -94,7 +94,7 @@ BASE_DECLARE_FEATURE(kPasswordManagerLogToTerminal); - // Enables triggering password suggestions through the context menu. - BASE_DECLARE_FEATURE(kPasswordManualFallbackAvailable); +@@ -115,7 +115,7 @@ BASE_DECLARE_FEATURE(kPasswordManagerLogToTerminal); + // Detects password reuse based on hashed password values. + BASE_DECLARE_FEATURE(kReuseDetectionBasedOnPasswordHashes); -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__form__filling.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__form__filling.cc new file mode 100644 index 000000000000..37414ef9b9b1 --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__form__filling.cc @@ -0,0 +1,11 @@ +--- components/password_manager/core/browser/password_form_filling.cc.orig 2025-05-28 14:55:43 UTC ++++ components/password_manager/core/browser/password_form_filling.cc +@@ -165,7 +165,7 @@ LikelyFormFilling SendFillInformationToRenderer( + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (!should_show_popup_without_passwords) { + client->MaybeShowSavePasswordPrimingPromo(observed_form.url); + } diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__form__manager.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__form__manager.cc index 9dee653dd7cc..7d987e3f8dcd 100644 --- a/www/chromium/files/patch-components_password__manager_core_browser_password__form__manager.cc +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__form__manager.cc @@ -1,6 +1,6 @@ ---- components/password_manager/core/browser/password_form_manager.cc.orig 2024-04-19 13:02:56 UTC +--- components/password_manager/core/browser/password_form_manager.cc.orig 2025-05-05 10:57:53 UTC +++ components/password_manager/core/browser/password_form_manager.cc -@@ -58,7 +58,7 @@ +@@ -64,7 +64,7 @@ #include "components/webauthn/android/webauthn_cred_man_delegate.h" #endif // BUILDFLAG(IS_ANDROID) @@ -9,7 +9,7 @@ #include "components/os_crypt/sync/os_crypt.h" #endif -@@ -229,7 +229,7 @@ bool ShouldUploadCrowdsourcingVotes(const FormOrDigest +@@ -240,7 +240,7 @@ bool ShouldUploadCrowdsourcingVotes(const FormOrDigest return false; } @@ -18,7 +18,7 @@ bool ShouldShowKeychainErrorBubble( std::optional<PasswordStoreBackendError> backend_error) { if (!backend_error.has_value()) { -@@ -833,7 +833,7 @@ void PasswordFormManager::OnFetchCompleted() { +@@ -913,7 +913,7 @@ void PasswordFormManager::OnFetchCompleted() { error.value().type); } diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__manager.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__manager.cc index 99848778c074..419129b5c5e7 100644 --- a/www/chromium/files/patch-components_password__manager_core_browser_password__manager.cc +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__manager.cc @@ -1,7 +1,7 @@ ---- components/password_manager/core/browser/password_manager.cc.orig 2024-04-19 13:02:56 UTC +--- components/password_manager/core/browser/password_manager.cc.orig 2025-07-02 06:08:04 UTC +++ components/password_manager/core/browser/password_manager.cc -@@ -363,7 +363,7 @@ void PasswordManager::RegisterProfilePrefs( - registry->RegisterListPref(prefs::kPasswordManagerPromoCardsList); +@@ -507,7 +507,7 @@ void PasswordManager::RegisterProfilePrefs( + prefs::kAutofillableCredentialsAccountStoreLoginDatabase, false); #endif // BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_IOS) registry->RegisterBooleanPref(prefs::kPasswordSharingEnabled, true); -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) @@ -9,3 +9,12 @@ registry->RegisterIntegerPref(prefs::kRelaunchChromeBubbleDismissedCounter, 0); #endif +@@ -520,7 +520,7 @@ void PasswordManager::RegisterProfilePrefs( + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_IOS) ++ BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) + registry->RegisterBooleanPref(prefs::kDeletingUndecryptablePasswordsEnabled, + true); + #endif diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__manager__client.h b/www/chromium/files/patch-components_password__manager_core_browser_password__manager__client.h new file mode 100644 index 000000000000..a2b83e110097 --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__manager__client.h @@ -0,0 +1,20 @@ +--- components/password_manager/core/browser/password_manager_client.h.orig 2025-07-02 06:08:04 UTC ++++ components/password_manager/core/browser/password_manager_client.h +@@ -31,7 +31,7 @@ + #include "net/cert/cert_status_flags.h" + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "base/i18n/rtl.h" + #include "components/password_manager/core/browser/password_cross_domain_confirmation_popup_controller.h" + #include "ui/gfx/geometry/rect_f.h" +@@ -540,7 +540,7 @@ class PasswordManagerClient { + virtual void TriggerSignIn(signin_metrics::AccessPoint access_point) const; + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Shows the bubble with the details of the `form`. + virtual void OpenPasswordDetailsBubble( + const password_manager::PasswordForm& form) = 0; diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__manager__switches.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__manager__switches.cc new file mode 100644 index 000000000000..d68dde383abf --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__manager__switches.cc @@ -0,0 +1,11 @@ +--- components/password_manager/core/browser/password_manager_switches.cc.orig 2024-06-17 12:56:06 UTC ++++ components/password_manager/core/browser/password_manager_switches.cc +@@ -6,7 +6,7 @@ + + namespace password_manager { + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Specifies which encryption storage backend to use. Possible values are + // kwallet, kwallet5, kwallet6, gnome-libsecret, basic. + // Any other value will lead to Chrome detecting the best backend automatically. diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__manager__switches.h b/www/chromium/files/patch-components_password__manager_core_browser_password__manager__switches.h new file mode 100644 index 000000000000..0ba62316219f --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__manager__switches.h @@ -0,0 +1,11 @@ +--- components/password_manager/core/browser/password_manager_switches.h.orig 2025-02-19 07:43:18 UTC ++++ components/password_manager/core/browser/password_manager_switches.h +@@ -9,7 +9,7 @@ + + namespace password_manager { + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + extern const char kPasswordStore[]; + extern const char kEnableEncryptionSelection[]; + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__manual__fallback__flow.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__manual__fallback__flow.cc new file mode 100644 index 000000000000..cc9594688b2f --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__manual__fallback__flow.cc @@ -0,0 +1,29 @@ +--- components/password_manager/core/browser/password_manual_fallback_flow.cc.orig 2025-05-28 14:55:43 UTC ++++ components/password_manager/core/browser/password_manual_fallback_flow.cc +@@ -46,7 +46,7 @@ std::u16string GetUsernameFromLabel(const std::u16stri + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Returns the password form corresponding to the `payload` data. In most + // cases there is only one such form stored, but having more than one or no + // forms is also possible. If there is more than one form, showing any of them +@@ -297,7 +297,7 @@ void PasswordManualFallbackFlow::DidAcceptSuggestion( + } + case autofill::SuggestionType::kViewPasswordDetails: { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + std::optional<password_manager::PasswordForm> credentials = + GetCorrespondingPasswordForm( + suggestion.GetPayload<Suggestion::PasswordSuggestionDetails>(), +@@ -427,7 +427,7 @@ void PasswordManualFallbackFlow::EnsureCrossDomainPass + const Suggestion::PasswordSuggestionDetails& payload, + base::OnceClosure on_allowed) { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (payload.is_cross_domain) { + cross_domain_confirmation_popup_controller_ = + password_client_->ShowCrossDomainConfirmationPopup( diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__manual__fallback__flow.h b/www/chromium/files/patch-components_password__manager_core_browser_password__manual__fallback__flow.h new file mode 100644 index 000000000000..504ccff1fbd8 --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__manual__fallback__flow.h @@ -0,0 +1,20 @@ +--- components/password_manager/core/browser/password_manual_fallback_flow.h.orig 2025-05-05 10:57:53 UTC ++++ components/password_manager/core/browser/password_manual_fallback_flow.h +@@ -19,7 +19,7 @@ + #include "components/password_manager/core/browser/ui/saved_passwords_presenter.h" + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "components/password_manager/core/browser/password_cross_domain_confirmation_popup_controller.h" + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || + // BUILDFLAG(IS_CHROMEOS) +@@ -180,7 +180,7 @@ class PasswordManualFallbackFlow : public autofill::Au + std::unique_ptr<device_reauth::DeviceAuthenticator> authenticator_; + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + std::unique_ptr<PasswordCrossDomainConfirmationPopupController> + cross_domain_confirmation_popup_controller_; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__store__factory__util.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__store__factory__util.cc new file mode 100644 index 000000000000..3e535601d642 --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__store__factory__util.cc @@ -0,0 +1,11 @@ +--- components/password_manager/core/browser/password_store_factory_util.cc.orig 2024-10-22 08:31:56 UTC ++++ components/password_manager/core/browser/password_store_factory_util.cc +@@ -29,7 +29,7 @@ namespace { + LoginDatabase::DeletingUndecryptablePasswordsEnabled GetPolicyFromPrefs( + PrefService* prefs) { + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_IOS) ++ BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) + return LoginDatabase::DeletingUndecryptablePasswordsEnabled( + prefs->GetBoolean(prefs::kDeletingUndecryptablePasswordsEnabled)); + #else diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database.cc new file mode 100644 index 000000000000..c750c21cb26a --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database.cc @@ -0,0 +1,20 @@ +--- components/password_manager/core/browser/password_store/login_database.cc.orig 2025-05-05 10:57:53 UTC ++++ components/password_manager/core/browser/password_store/login_database.cc +@@ -1030,7 +1030,7 @@ bool ShouldDeleteUndecryptablePasswords( + bool is_user_data_dir_policy_set, + bool is_enabled_by_policy, + IsAccountStore is_account_store) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<base::Environment> environment(base::Environment::Create()); + // On Linux user data directory ca be specified using an env variable. If it + // exists, passwords shouldn't be deleted. +@@ -1048,7 +1048,7 @@ bool ShouldDeleteUndecryptablePasswords( + return false; + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (command_line->HasSwitch(password_manager::kPasswordStore)) { + RecordShouldDeleteUndecryptablePasswordsMetric( + ShouldDeleteUndecryptablePasswordsResult:: diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__async__helper.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__async__helper.cc index e0fd6e5b6ad8..79a02a3e7b8d 100644 --- a/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__async__helper.cc +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__async__helper.cc @@ -1,6 +1,6 @@ ---- components/password_manager/core/browser/password_store/login_database_async_helper.cc.orig 2024-02-23 21:04:38 UTC +--- components/password_manager/core/browser/password_store/login_database_async_helper.cc.orig 2024-09-30 07:45:04 UTC +++ components/password_manager/core/browser/password_store/login_database_async_helper.cc -@@ -135,7 +135,7 @@ LoginsResultOrError LoginDatabaseAsyncHelper::FillMatc +@@ -154,7 +154,7 @@ LoginsResultOrError LoginDatabaseAsyncHelper::FillMatc std::vector<PasswordForm> matched_forms; if (!login_db_ || !login_db_->GetLogins(form, include_psl, &matched_forms)) { diff --git a/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__unittest.cc b/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__unittest.cc index 9b73c604369f..34974871cb06 100644 --- a/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__unittest.cc +++ b/www/chromium/files/patch-components_password__manager_core_browser_password__store_login__database__unittest.cc @@ -1,11 +1,11 @@ ---- components/password_manager/core/browser/password_store/login_database_unittest.cc.orig 2024-03-22 08:19:40 UTC +--- components/password_manager/core/browser/password_store/login_database_unittest.cc.orig 2025-05-28 14:55:43 UTC +++ components/password_manager/core/browser/password_store/login_database_unittest.cc -@@ -2105,7 +2105,7 @@ INSTANTIATE_TEST_SUITE_P(MigrationToVCurrent, - LoginDatabaseMigrationTestBroken, - testing::Values(1, 2, 3, 24)); +@@ -2303,7 +2303,7 @@ INSTANTIATE_TEST_SUITE_P(MigrationToVCurrent, + testing::Bool())); --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_IOS) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_IOS) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) class LoginDatabaseUndecryptableLoginsTest : public testing::Test { protected: LoginDatabaseUndecryptableLoginsTest() = default; diff --git a/www/chromium/files/patch-components_password__manager_core_browser_stub__password__manager__client.cc b/www/chromium/files/patch-components_password__manager_core_browser_stub__password__manager__client.cc new file mode 100644 index 000000000000..1b86a75f0b11 --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_stub__password__manager__client.cc @@ -0,0 +1,11 @@ +--- components/password_manager/core/browser/stub_password_manager_client.cc.orig 2025-05-28 14:55:43 UTC ++++ components/password_manager/core/browser/stub_password_manager_client.cc +@@ -206,7 +206,7 @@ version_info::Channel StubPasswordManagerClient::GetCh + } + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void StubPasswordManagerClient::OpenPasswordDetailsBubble( + const password_manager::PasswordForm& form) {} + void StubPasswordManagerClient::MaybeShowSavePasswordPrimingPromo( diff --git a/www/chromium/files/patch-components_password__manager_core_browser_stub__password__manager__client.h b/www/chromium/files/patch-components_password__manager_core_browser_stub__password__manager__client.h new file mode 100644 index 000000000000..43db56835a2f --- /dev/null +++ b/www/chromium/files/patch-components_password__manager_core_browser_stub__password__manager__client.h @@ -0,0 +1,11 @@ +--- components/password_manager/core/browser/stub_password_manager_client.h.orig 2025-05-28 14:55:43 UTC ++++ components/password_manager/core/browser/stub_password_manager_client.h +@@ -77,7 +77,7 @@ class StubPasswordManagerClient : public PasswordManag + MockPasswordFeatureManager* GetPasswordFeatureManager(); + version_info::Channel GetChannel() const override; + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void OpenPasswordDetailsBubble( + const password_manager::PasswordForm& form) override; + void MaybeShowSavePasswordPrimingPromo(const GURL& current_url) override; diff --git a/www/chromium/files/patch-components_password__manager_core_browser_sync_password__sync__bridge.cc b/www/chromium/files/patch-components_password__manager_core_browser_sync_password__sync__bridge.cc deleted file mode 100644 index b9bbf7aa08ea..000000000000 --- a/www/chromium/files/patch-components_password__manager_core_browser_sync_password__sync__bridge.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/password_manager/core/browser/sync/password_sync_bridge.cc.orig 2024-03-22 08:19:40 UTC -+++ components/password_manager/core/browser/sync/password_sync_bridge.cc -@@ -195,7 +195,7 @@ bool ShouldRecoverPasswordsDuringMerge() { - } - - bool ShouldCleanSyncMetadataDuringStartupWhenDecryptionFails() { --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return ShouldRecoverPasswordsDuringMerge() && - base::FeatureList::IsEnabled( - features::kForceInitialSyncWhenDecryptionFails); diff --git a/www/chromium/files/patch-components_password__manager_core_common_password__manager__features.cc b/www/chromium/files/patch-components_password__manager_core_common_password__manager__features.cc deleted file mode 100644 index 969ecb439ebe..000000000000 --- a/www/chromium/files/patch-components_password__manager_core_common_password__manager__features.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/password_manager/core/common/password_manager_features.cc.orig 2023-10-27 05:38:38 UTC -+++ components/password_manager/core/common/password_manager_features.cc -@@ -18,7 +18,7 @@ BASE_FEATURE(kEnableOverwritingPlaceholderUsernames, - "EnableOverwritingPlaceholderUsernames", - base::FEATURE_DISABLED_BY_DEFAULT); - --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // When enabled, initial sync will be forced during startup if the password - // store has encryption service failures. - BASE_FEATURE(kForceInitialSyncWhenDecryptionFails, diff --git a/www/chromium/files/patch-components_password__manager_core_common_password__manager__features.h b/www/chromium/files/patch-components_password__manager_core_common_password__manager__features.h deleted file mode 100644 index 857af97aa0e4..000000000000 --- a/www/chromium/files/patch-components_password__manager_core_common_password__manager__features.h +++ /dev/null @@ -1,11 +0,0 @@ ---- components/password_manager/core/common/password_manager_features.h.orig 2023-12-10 06:10:27 UTC -+++ components/password_manager/core/common/password_manager_features.h -@@ -19,7 +19,7 @@ namespace password_manager::features { - // alongside the definition of their values in the .cc file. - BASE_DECLARE_FEATURE(kEnableOverwritingPlaceholderUsernames); - --#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - BASE_DECLARE_FEATURE(kForceInitialSyncWhenDecryptionFails); - #endif - BASE_DECLARE_FEATURE(kForgotPasswordFormSupport); diff --git a/www/chromium/files/patch-components_password__manager_core_common_password__manager__pref__names.h b/www/chromium/files/patch-components_password__manager_core_common_password__manager__pref__names.h index 1db403eb1809..a16f5a0c0d0e 100644 --- a/www/chromium/files/patch-components_password__manager_core_common_password__manager__pref__names.h +++ b/www/chromium/files/patch-components_password__manager_core_common_password__manager__pref__names.h @@ -1,6 +1,15 @@ ---- components/password_manager/core/common/password_manager_pref_names.h.orig 2024-04-19 13:02:56 UTC +--- components/password_manager/core/common/password_manager_pref_names.h.orig 2025-07-02 06:08:04 UTC +++ components/password_manager/core/common/password_manager_pref_names.h -@@ -332,7 +332,7 @@ inline constexpr char kPasswordManagerPromoCardsList[] +@@ -59,7 +59,7 @@ inline constexpr char kCredentialProviderEnabledOnStar + #endif + + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_IOS) ++ BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) + // Boolean pref controlled by the DeletingUndecryptablePasswordsEnabled policy. + // If set to false it blocks deleting undecryptable passwords, otherwise the + // deletion can happen. +@@ -346,7 +346,7 @@ inline constexpr char kAutofillableCredentialsAccountS inline constexpr char kPasswordSharingEnabled[] = "password_manager.password_sharing_enabled"; diff --git a/www/chromium/files/patch-components_performance__manager_decorators_process__metrics__decorator.cc b/www/chromium/files/patch-components_performance__manager_decorators_process__metrics__decorator.cc new file mode 100644 index 000000000000..8031f0f8627d --- /dev/null +++ b/www/chromium/files/patch-components_performance__manager_decorators_process__metrics__decorator.cc @@ -0,0 +1,11 @@ +--- components/performance_manager/decorators/process_metrics_decorator.cc.orig 2024-11-14 07:57:23 UTC ++++ components/performance_manager/decorators/process_metrics_decorator.cc +@@ -264,7 +264,7 @@ void ProcessMetricsDecorator::DidGetMemoryUsage( + // RSS and PMF to each node proportionally to its V8 heap size. + uint64_t process_rss = process_dump_iter.os_dump().resident_set_kb; + process_node->set_resident_set_kb(process_rss); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + process_node->set_private_swap_kb( + process_dump_iter.os_dump().private_footprint_swap_kb); + #endif diff --git a/www/chromium/files/patch-components_performance__manager_public_features.h b/www/chromium/files/patch-components_performance__manager_public_features.h index d890abe6f25a..26b46028bcb5 100644 --- a/www/chromium/files/patch-components_performance__manager_public_features.h +++ b/www/chromium/files/patch-components_performance__manager_public_features.h @@ -1,6 +1,6 @@ ---- components/performance_manager/public/features.h.orig 2023-11-03 10:09:45 UTC +--- components/performance_manager/public/features.h.orig 2025-05-05 10:57:53 UTC +++ components/performance_manager/public/features.h -@@ -28,7 +28,7 @@ BASE_DECLARE_FEATURE(kRunOnDedicatedThreadPoolThread); +@@ -19,7 +19,7 @@ namespace performance_manager::features { #if !BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-components_permissions_prediction__service_prediction__common.cc b/www/chromium/files/patch-components_permissions_prediction__service_prediction__common.cc index 049516814c6a..bda26ddbd358 100644 --- a/www/chromium/files/patch-components_permissions_prediction__service_prediction__common.cc +++ b/www/chromium/files/patch-components_permissions_prediction__service_prediction__common.cc @@ -1,6 +1,6 @@ ---- components/permissions/prediction_service/prediction_common.cc.orig 2022-08-31 12:19:35 UTC +--- components/permissions/prediction_service/prediction_common.cc.orig 2025-07-02 06:08:04 UTC +++ components/permissions/prediction_service/prediction_common.cc -@@ -33,7 +33,7 @@ int BucketizeValue(int count) { +@@ -36,7 +36,7 @@ int BucketizeValue(int count) { ClientFeatures_Platform GetCurrentPlatformProto() { #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ @@ -9,7 +9,7 @@ return permissions::ClientFeatures_Platform_PLATFORM_DESKTOP; #elif BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) return permissions::ClientFeatures_Platform_PLATFORM_MOBILE; -@@ -44,7 +44,7 @@ ClientFeatures_Platform GetCurrentPlatformProto() { +@@ -47,7 +47,7 @@ ClientFeatures_Platform GetCurrentPlatformProto() { ClientFeatures_PlatformEnum GetCurrentPlatformEnumProto() { #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ diff --git a/www/chromium/files/patch-components_policy_core_browser_policy__pref__mapping__test.cc b/www/chromium/files/patch-components_policy_core_browser_policy__pref__mapping__test.cc index 2b2a34c5e735..c22147a09fcc 100644 --- a/www/chromium/files/patch-components_policy_core_browser_policy__pref__mapping__test.cc +++ b/www/chromium/files/patch-components_policy_core_browser_policy__pref__mapping__test.cc @@ -1,7 +1,7 @@ ---- components/policy/core/browser/policy_pref_mapping_test.cc.orig 2024-04-19 13:02:56 UTC +--- components/policy/core/browser/policy_pref_mapping_test.cc.orig 2025-05-05 10:57:53 UTC +++ components/policy/core/browser/policy_pref_mapping_test.cc -@@ -413,7 +413,7 @@ class PolicyTestCase { - const std::string os("chromeos_lacros"); +@@ -432,7 +432,7 @@ class PolicyTestCase { + const std::string os("chromeos"); #elif BUILDFLAG(IS_IOS) const std::string os("ios"); -#elif BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-components_policy_core_browser_url__blocklist__manager.cc b/www/chromium/files/patch-components_policy_core_browser_url__blocklist__manager.cc new file mode 100644 index 000000000000..dfa041dc7fde --- /dev/null +++ b/www/chromium/files/patch-components_policy_core_browser_url__blocklist__manager.cc @@ -0,0 +1,11 @@ +--- components/policy/core/browser/url_blocklist_manager.cc.orig 2025-07-02 06:08:04 UTC ++++ components/policy/core/browser/url_blocklist_manager.cc +@@ -377,7 +377,7 @@ void URLBlocklistManager::RegisterProfilePrefs( + policy_prefs::kSafeSitesFilterBehavior, + static_cast<int>(SafeSitesFilterBehavior::kSafeSitesFilterDisabled)); + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + registry->RegisterListPref(policy_prefs::kPasswordManagerBlocklist); + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || + // BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__client.cc b/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__client.cc index 5b90f912cdf3..bc46407c78c3 100644 --- a/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__client.cc +++ b/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__client.cc @@ -1,6 +1,6 @@ ---- components/policy/core/common/cloud/cloud_policy_client.cc.orig 2024-04-19 13:02:56 UTC +--- components/policy/core/common/cloud/cloud_policy_client.cc.orig 2025-07-02 06:08:04 UTC +++ components/policy/core/common/cloud/cloud_policy_client.cc -@@ -594,7 +594,7 @@ void CloudPolicyClient::FetchPolicy(PolicyFetchReason +@@ -762,7 +762,7 @@ void CloudPolicyClient::FetchPolicy(PolicyFetchReason fetch_request->set_invalidation_payload(invalidation_payload_); } } diff --git a/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__refresh__scheduler.cc b/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__refresh__scheduler.cc new file mode 100644 index 000000000000..ebb61849368b --- /dev/null +++ b/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__refresh__scheduler.cc @@ -0,0 +1,20 @@ +--- components/policy/core/common/cloud/cloud_policy_refresh_scheduler.cc.orig 2024-10-22 08:31:56 UTC ++++ components/policy/core/common/cloud/cloud_policy_refresh_scheduler.cc +@@ -25,7 +25,7 @@ namespace policy { + + namespace { + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kRetryWithKeyReset, + "RetryWithKeyReset", + base::FEATURE_ENABLED_BY_DEFAULT); +@@ -220,7 +220,7 @@ void CloudPolicyRefreshScheduler::OnStoreError(CloudPo + // continue using the stale information. Thus, no specific response to a store + // error is required. NB: Changes to is_managed fire OnStoreLoaded(). + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Client is registered means we have successfully get policy key once. However, + // a following policy fetch request is failed because we can't verified + // signature. Delete the policy key so that we can get it again with next diff --git a/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__util.cc b/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__util.cc index b1538650647f..9a6914c32190 100644 --- a/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__util.cc +++ b/www/chromium/files/patch-components_policy_core_common_cloud_cloud__policy__util.cc @@ -1,20 +1,20 @@ ---- components/policy/core/common/cloud/cloud_policy_util.cc.orig 2024-03-22 08:19:40 UTC +--- components/policy/core/common/cloud/cloud_policy_util.cc.orig 2025-05-05 10:57:53 UTC +++ components/policy/core/common/cloud/cloud_policy_util.cc -@@ -20,7 +20,7 @@ +@@ -21,7 +21,7 @@ + #include "base/win/wincred_shim.h" #endif - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || \ -- BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) #include <pwd.h> #include <sys/types.h> #include <unistd.h> -@@ -35,10 +35,15 @@ +@@ -36,10 +36,15 @@ #import <SystemConfiguration/SCDynamicStoreCopySpecific.h> #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include <limits.h> // For HOST_NAME_MAX #endif @@ -26,16 +26,16 @@ #include <algorithm> #include <utility> -@@ -88,7 +93,7 @@ namespace em = enterprise_management; +@@ -84,7 +89,7 @@ namespace policy { + namespace em = enterprise_management; std::string GetMachineName() { - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) char hostname[HOST_NAME_MAX]; if (gethostname(hostname, HOST_NAME_MAX) == 0) // Success. return hostname; -@@ -145,7 +150,7 @@ std::string GetMachineName() { +@@ -140,7 +145,7 @@ std::string GetMachineName() { std::string GetOSVersion() { #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_APPLE) || \ @@ -44,7 +44,7 @@ return base::SysInfo::OperatingSystemVersion(); #elif BUILDFLAG(IS_WIN) base::win::OSInfo::VersionNumber version_number = -@@ -168,7 +173,7 @@ std::string GetOSArchitecture() { +@@ -162,7 +167,7 @@ std::string GetOSArchitecture() { } std::string GetOSUsername() { diff --git a/www/chromium/files/patch-components_policy_core_common_policy__loader__common.cc b/www/chromium/files/patch-components_policy_core_common_policy__loader__common.cc index baaa101fe2f8..ae34bd0beb49 100644 --- a/www/chromium/files/patch-components_policy_core_common_policy__loader__common.cc +++ b/www/chromium/files/patch-components_policy_core_common_policy__loader__common.cc @@ -1,4 +1,4 @@ ---- components/policy/core/common/policy_loader_common.cc.orig 2024-01-30 07:53:34 UTC +--- components/policy/core/common/policy_loader_common.cc.orig 2025-01-15 09:18:26 UTC +++ components/policy/core/common/policy_loader_common.cc @@ -46,7 +46,7 @@ const char* kSensitivePolicies[] = { key::kDefaultSearchProviderEnabled, @@ -7,9 +7,9 @@ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) key::kAutoOpenFileTypes, + key::kEnterpriseSearchAggregatorSettings, key::kHomepageIsNewTabPage, - key::kPasswordProtectionChangePasswordURL, -@@ -56,7 +56,7 @@ const char* kSensitivePolicies[] = { +@@ -57,7 +57,7 @@ const char* kSensitivePolicies[] = { key::kSafeBrowsingAllowlistDomains, key::kSiteSearchSettings, #endif diff --git a/www/chromium/files/patch-components_policy_core_common_policy__pref__names.cc b/www/chromium/files/patch-components_policy_core_common_policy__pref__names.cc new file mode 100644 index 000000000000..45c534994983 --- /dev/null +++ b/www/chromium/files/patch-components_policy_core_common_policy__pref__names.cc @@ -0,0 +1,11 @@ +--- components/policy/core/common/policy_pref_names.cc.orig 2025-07-02 06:08:04 UTC ++++ components/policy/core/common/policy_pref_names.cc +@@ -191,7 +191,7 @@ const char kFloatingWorkspaceEnabled[] = "ash.floating + // A boolean value indicating whether the built-in AI APIs are enabled. + const char kBuiltInAIAPIsEnabled[] = "policy.built_in_ai_apis_enabled"; + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + // List of urls for which password manager is disabled/blocked. + const char kPasswordManagerBlocklist[] = "policy.password_manager_blocklist"; + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || diff --git a/www/chromium/files/patch-components_policy_core_common_policy__pref__names.h b/www/chromium/files/patch-components_policy_core_common_policy__pref__names.h new file mode 100644 index 000000000000..3d3f80beb506 --- /dev/null +++ b/www/chromium/files/patch-components_policy_core_common_policy__pref__names.h @@ -0,0 +1,11 @@ +--- components/policy/core/common/policy_pref_names.h.orig 2025-07-02 06:08:04 UTC ++++ components/policy/core/common/policy_pref_names.h +@@ -91,7 +91,7 @@ extern const char kFloatingWorkspaceEnabled[]; + #endif + extern const char kBuiltInAIAPIsEnabled[]; + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + extern const char kPasswordManagerBlocklist[]; + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) diff --git a/www/chromium/files/patch-components_policy_core_common_policy__utils.cc b/www/chromium/files/patch-components_policy_core_common_policy__utils.cc deleted file mode 100644 index a56805241601..000000000000 --- a/www/chromium/files/patch-components_policy_core_common_policy__utils.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/policy/core/common/policy_utils.cc.orig 2024-01-30 07:53:34 UTC -+++ components/policy/core/common/policy_utils.cc -@@ -28,7 +28,7 @@ bool IsPolicyTestingEnabled(PrefService* pref_service, - return true; - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (channel == version_info::Channel::DEV) { - return true; - } diff --git a/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__service.cc b/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__service.cc new file mode 100644 index 000000000000..b3714212d457 --- /dev/null +++ b/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__service.cc @@ -0,0 +1,11 @@ +--- components/regional_capabilities/regional_capabilities_service.cc.orig 2025-05-28 14:55:43 UTC ++++ components/regional_capabilities/regional_capabilities_service.cc +@@ -235,7 +235,7 @@ std::optional<CountryId> RegionalCapabilitiesService:: + return persisted_country_id; + } + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled(switches::kClearPrefForUnknownCountry)) { + profile_prefs_->ClearPref(country_codes::kCountryIDAtInstall); + base::UmaHistogramEnumeration(kUnknownCountryIdStored, diff --git a/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__switches.cc b/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__switches.cc new file mode 100644 index 000000000000..14ed09484399 --- /dev/null +++ b/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__switches.cc @@ -0,0 +1,11 @@ +--- components/regional_capabilities/regional_capabilities_switches.cc.orig 2025-05-05 10:57:53 UTC ++++ components/regional_capabilities/regional_capabilities_switches.cc +@@ -6,7 +6,7 @@ + + namespace switches { + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kClearPrefForUnknownCountry, + "ClearCountryPrefForStoredUnknownCountry", + base::FEATURE_ENABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__switches.h b/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__switches.h new file mode 100644 index 000000000000..f29cd663c85b --- /dev/null +++ b/www/chromium/files/patch-components_regional__capabilities_regional__capabilities__switches.h @@ -0,0 +1,11 @@ +--- components/regional_capabilities/regional_capabilities_switches.h.orig 2025-05-05 10:57:53 UTC ++++ components/regional_capabilities/regional_capabilities_switches.h +@@ -25,7 +25,7 @@ inline constexpr char kSearchEngineChoiceCountry[] = + inline constexpr char kDefaultListCountryOverride[] = "DEFAULT_EEA"; + inline constexpr char kEeaListCountryOverride[] = "EEA_ALL"; + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // When an invalid `country_codes::CountryId` is stored in prefs and this + // feature is enabled the pref will be cleared allowing a valid country to be + // set again. diff --git a/www/chromium/files/patch-components_safe__browsing_content_common_file__type__policies__unittest.cc b/www/chromium/files/patch-components_safe__browsing_content_common_file__type__policies__unittest.cc index 92f539f394ef..72edfdf5e9dd 100644 --- a/www/chromium/files/patch-components_safe__browsing_content_common_file__type__policies__unittest.cc +++ b/www/chromium/files/patch-components_safe__browsing_content_common_file__type__policies__unittest.cc @@ -1,9 +1,9 @@ ---- components/safe_browsing/content/common/file_type_policies_unittest.cc.orig 2022-03-25 21:59:56 UTC +--- components/safe_browsing/content/common/file_type_policies_unittest.cc.orig 2025-02-19 07:43:18 UTC +++ components/safe_browsing/content/common/file_type_policies_unittest.cc -@@ -139,7 +139,7 @@ TEST_F(FileTypePoliciesTest, UnpackResourceBundle) { +@@ -146,7 +146,7 @@ TEST_F(FileTypePoliciesTest, UnpackResourceBundle) { + EXPECT_EQ(142, file_type.uma_value()); + EXPECT_FALSE(file_type.is_archive()); EXPECT_EQ(DownloadFileType::FULL_PING, file_type.ping_setting()); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) EXPECT_EQ(DownloadFileType::ALLOW_ON_USER_GESTURE, diff --git a/www/chromium/files/patch-components_safe__browsing_content_resources_gen__file__type__proto.py b/www/chromium/files/patch-components_safe__browsing_content_resources_gen__file__type__proto.py index d1c6f061aef3..a813c3e8087a 100644 --- a/www/chromium/files/patch-components_safe__browsing_content_resources_gen__file__type__proto.py +++ b/www/chromium/files/patch-components_safe__browsing_content_resources_gen__file__type__proto.py @@ -1,15 +1,15 @@ ---- components/safe_browsing/content/resources/gen_file_type_proto.py.orig 2023-01-11 09:17:16 UTC +--- components/safe_browsing/content/resources/gen_file_type_proto.py.orig 2024-08-26 12:06:38 UTC +++ components/safe_browsing/content/resources/gen_file_type_proto.py -@@ -38,6 +38,8 @@ def PlatformTypes(): - "fuchsia": - download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_FUCHSIA, +@@ -37,6 +37,8 @@ def PlatformTypes(): + "chromeos": + download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_CHROME_OS, "linux": download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_LINUX, + "openbsd": download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_LINUX, + "freebsd": download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_LINUX, "mac": download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_MAC, "win": download_file_types_pb2.DownloadFileType.PLATFORM_TYPE_WINDOWS, - } -@@ -181,7 +183,7 @@ class DownloadFileTypeProtoGenerator(BinaryProtoGenera + # LINT.ThenChange(BUILD.gn:PlatformTypes) +@@ -179,7 +181,7 @@ class DownloadFileTypeProtoGenerator(BinaryProtoGenera '-t', '--type', help='The platform type. One of android, chromeos, ' + diff --git a/www/chromium/files/patch-components_safe__browsing_core_browser_db_v4__protocol__manager__util.cc b/www/chromium/files/patch-components_safe__browsing_core_browser_db_v4__protocol__manager__util.cc index 9025606b4732..4d30499476f8 100644 --- a/www/chromium/files/patch-components_safe__browsing_core_browser_db_v4__protocol__manager__util.cc +++ b/www/chromium/files/patch-components_safe__browsing_core_browser_db_v4__protocol__manager__util.cc @@ -1,6 +1,6 @@ ---- components/safe_browsing/core/browser/db/v4_protocol_manager_util.cc.orig 2023-12-10 06:10:27 UTC +--- components/safe_browsing/core/browser/db/v4_protocol_manager_util.cc.orig 2024-09-30 07:45:04 UTC +++ components/safe_browsing/core/browser/db/v4_protocol_manager_util.cc -@@ -116,7 +116,7 @@ std::ostream& operator<<(std::ostream& os, const ListI +@@ -119,7 +119,7 @@ std::ostream& operator<<(std::ostream& os, const ListI PlatformType GetCurrentPlatformType() { #if BUILDFLAG(IS_WIN) return WINDOWS_PLATFORM; diff --git a/www/chromium/files/patch-components_safe__browsing_core_browser_realtime_url__lookup__service__base.cc b/www/chromium/files/patch-components_safe__browsing_core_browser_realtime_url__lookup__service__base.cc index 93c14e64b7f7..7415d5e7665e 100644 --- a/www/chromium/files/patch-components_safe__browsing_core_browser_realtime_url__lookup__service__base.cc +++ b/www/chromium/files/patch-components_safe__browsing_core_browser_realtime_url__lookup__service__base.cc @@ -1,7 +1,7 @@ ---- components/safe_browsing/core/browser/realtime/url_lookup_service_base.cc.orig 2022-02-28 16:54:41 UTC +--- components/safe_browsing/core/browser/realtime/url_lookup_service_base.cc.orig 2025-07-02 06:08:04 UTC +++ components/safe_browsing/core/browser/realtime/url_lookup_service_base.cc -@@ -109,7 +109,7 @@ RTLookupRequest::OSType GetRTLookupRequestOSType() { - return RTLookupRequest::OS_TYPE_FUCHSIA; +@@ -112,7 +112,7 @@ RTLookupRequest::OSType GetRTLookupRequestOSType() { + return RTLookupRequest::OS_TYPE_CHROME_OS; #elif BUILDFLAG(IS_IOS) return RTLookupRequest::OS_TYPE_IOS; -#elif BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-components_search__engines_search__engine__choice_search__engine__choice__service.cc b/www/chromium/files/patch-components_search__engines_search__engine__choice_search__engine__choice__service.cc deleted file mode 100644 index 73a9a89910bb..000000000000 --- a/www/chromium/files/patch-components_search__engines_search__engine__choice_search__engine__choice__service.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/search_engines/search_engine_choice/search_engine_choice_service.cc.orig 2024-04-19 13:02:56 UTC -+++ components/search_engines/search_engine_choice/search_engine_choice_service.cc -@@ -437,7 +437,7 @@ void SearchEngineChoiceService::PreprocessPrefsForRepr - - int SearchEngineChoiceService::GetCountryIdInternal() { - // `country_codes::kCountryIDAtInstall` may not be set yet. --#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // On Android, ChromeOS and Linux, `country_codes::kCountryIDAtInstall` is - // computed asynchronously using platform-specific signals, and may not be - // available yet. diff --git a/www/chromium/files/patch-components_search__engines_template__url__service.cc b/www/chromium/files/patch-components_search__engines_template__url__service.cc index 318b49f0155c..bb8d6a340eb9 100644 --- a/www/chromium/files/patch-components_search__engines_template__url__service.cc +++ b/www/chromium/files/patch-components_search__engines_template__url__service.cc @@ -1,11 +1,11 @@ ---- components/search_engines/template_url_service.cc.orig 2024-04-19 13:02:56 UTC +--- components/search_engines/template_url_service.cc.orig 2025-07-02 06:08:04 UTC +++ components/search_engines/template_url_service.cc -@@ -2930,7 +2930,7 @@ bool TemplateURLService::MatchesDefaultSearchProvider( - std::unique_ptr<EnterpriseSiteSearchManager> - TemplateURLService::GetEnterpriseSiteSearchManager(PrefService* prefs) { +@@ -3561,7 +3561,7 @@ bool TemplateURLService::MatchesDefaultSearchProvider( + std::unique_ptr<EnterpriseSearchManager> + TemplateURLService::GetEnterpriseSearchManager(PrefService* prefs) { #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - return base::FeatureList::IsEnabled(omnibox::kSiteSearchSettingsPolicy) - ? std::make_unique<EnterpriseSiteSearchManager>( - prefs, base::BindRepeating( + return std::make_unique<EnterpriseSearchManager>( + prefs, base::BindRepeating(&TemplateURLService::EnterpriseSearchChanged, + base::Unretained(this))); diff --git a/www/chromium/files/patch-components_security__interstitials_content_utils.cc b/www/chromium/files/patch-components_security__interstitials_content_utils.cc index 61e641d41b0c..06f894eb0497 100644 --- a/www/chromium/files/patch-components_security__interstitials_content_utils.cc +++ b/www/chromium/files/patch-components_security__interstitials_content_utils.cc @@ -1,11 +1,11 @@ ---- components/security_interstitials/content/utils.cc.orig 2023-01-11 09:17:16 UTC +--- components/security_interstitials/content/utils.cc.orig 2025-02-19 07:43:18 UTC +++ components/security_interstitials/content/utils.cc -@@ -38,7 +38,7 @@ void LaunchDateAndTimeSettings() { +@@ -37,7 +37,7 @@ void LaunchDateAndTimeSettings() { #if BUILDFLAG(IS_ANDROID) JNIEnv* env = base::android::AttachCurrentThread(); Java_DateAndTimeSettingsHelper_openDateAndTimeSettings(env); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) struct ClockCommand { const char* const pathname; const char* const argument; diff --git a/www/chromium/files/patch-components_segmentation__platform_embedder_default__model_cross__device__user__segment.cc b/www/chromium/files/patch-components_segmentation__platform_embedder_default__model_cross__device__user__segment.cc index 6475ff057add..22c7a886bc4c 100644 --- a/www/chromium/files/patch-components_segmentation__platform_embedder_default__model_cross__device__user__segment.cc +++ b/www/chromium/files/patch-components_segmentation__platform_embedder_default__model_cross__device__user__segment.cc @@ -1,6 +1,6 @@ ---- components/segmentation_platform/embedder/default_model/cross_device_user_segment.cc.orig 2023-11-03 10:09:45 UTC +--- components/segmentation_platform/embedder/default_model/cross_device_user_segment.cc.orig 2025-02-19 07:43:18 UTC +++ components/segmentation_platform/embedder/default_model/cross_device_user_segment.cc -@@ -148,7 +148,7 @@ void CrossDeviceUserSegment::ExecuteModelWithInput( +@@ -147,7 +147,7 @@ void CrossDeviceUserSegment::ExecuteModelWithInput( // Check for current device type and subtract it from the device count // calculation. #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ diff --git a/www/chromium/files/patch-components_services_on__device__translation_sandbox__hook.cc b/www/chromium/files/patch-components_services_on__device__translation_sandbox__hook.cc new file mode 100644 index 000000000000..3abf4d20fa2a --- /dev/null +++ b/www/chromium/files/patch-components_services_on__device__translation_sandbox__hook.cc @@ -0,0 +1,43 @@ +--- components/services/on_device_translation/sandbox_hook.cc.orig 2024-11-14 07:57:23 UTC ++++ components/services/on_device_translation/sandbox_hook.cc +@@ -7,12 +7,15 @@ + #include "components/services/on_device_translation/translate_kit_client.h" + #include "sandbox/linux/syscall_broker/broker_command.h" + ++#if !BUILDFLAG(IS_BSD) + using sandbox::syscall_broker::BrokerFilePermission; + using sandbox::syscall_broker::MakeBrokerCommandSet; ++#endif + + namespace on_device_translation { + namespace { + ++#if !BUILDFLAG(IS_BSD) + // Gets the file permissions required by the TranslateKit + std::vector<BrokerFilePermission> GetOnDeviceTranslationFilePermissions() { + std::vector<BrokerFilePermission> permissions{ +@@ -21,6 +24,7 @@ std::vector<BrokerFilePermission> GetOnDeviceTranslati + }; + return permissions; + } ++#endif + + } // namespace + +@@ -29,6 +33,7 @@ bool OnDeviceTranslationSandboxHook( + // Call `TranslateKitClient::Get()` to load libtranslatekit.so + TranslateKitClient::Get(); + ++#if !BUILDFLAG(IS_BSD) + auto* instance = sandbox::policy::SandboxLinux::GetInstance(); + instance->StartBrokerProcess(MakeBrokerCommandSet({ + sandbox::syscall_broker::COMMAND_OPEN, +@@ -36,7 +41,7 @@ bool OnDeviceTranslationSandboxHook( + GetOnDeviceTranslationFilePermissions(), + options); + instance->EngageNamespaceSandboxIfPossible(); +- ++#endif + return true; + } + diff --git a/www/chromium/files/patch-components_services_on__device__translation_sandbox__hook.h b/www/chromium/files/patch-components_services_on__device__translation_sandbox__hook.h new file mode 100644 index 000000000000..d27468a99063 --- /dev/null +++ b/www/chromium/files/patch-components_services_on__device__translation_sandbox__hook.h @@ -0,0 +1,16 @@ +--- components/services/on_device_translation/sandbox_hook.h.orig 2024-11-14 07:57:23 UTC ++++ components/services/on_device_translation/sandbox_hook.h +@@ -5,7 +5,13 @@ + #ifndef COMPONENTS_SERVICES_ON_DEVICE_TRANSLATION_SANDBOX_HOOK_H_ + #define COMPONENTS_SERVICES_ON_DEVICE_TRANSLATION_SANDBOX_HOOK_H_ + ++#include "build/build_config.h" ++ ++#if BUILDFLAG(IS_BSD) ++#include "sandbox/policy/sandbox.h" ++#else + #include "sandbox/policy/linux/sandbox_linux.h" ++#endif + + namespace on_device_translation { + diff --git a/www/chromium/files/patch-components_signin_public_base_signin__switches.cc b/www/chromium/files/patch-components_signin_public_base_signin__switches.cc index f62411cb27e8..6b4ba47a31b6 100644 --- a/www/chromium/files/patch-components_signin_public_base_signin__switches.cc +++ b/www/chromium/files/patch-components_signin_public_base_signin__switches.cc @@ -1,20 +1,11 @@ ---- components/signin/public/base/signin_switches.cc.orig 2024-04-19 13:02:56 UTC +--- components/signin/public/base/signin_switches.cc.orig 2025-07-02 06:08:04 UTC +++ components/signin/public/base/signin_switches.cc -@@ -132,7 +132,7 @@ bool IsExplicitBrowserSigninUIOnDesktopEnabled( - } - - #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) - BASE_FEATURE(kMinorModeRestrictionsForHistorySyncOptIn, - "MinorModeRestrictionsForHistorySyncOptIn", +@@ -64,7 +64,7 @@ BASE_FEATURE(kFullscreenSignInPromoUseDate, base::FEATURE_DISABLED_BY_DEFAULT); -@@ -141,7 +141,7 @@ constexpr int kMinorModeRestrictionsFetchDeadlineDefau - #if BUILDFLAG(IS_ANDROID) - // Based on Signin.AccountCapabilities.UserVisibleLatency - 400; --#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - // Based on Signin.SyncOptIn.PreSyncConfirmationLatency - 900; - #elif BUILDFLAG(IS_IOS) + #endif + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Enables the History Sync Opt-in on Desktop. + BASE_FEATURE(kEnableHistorySyncOptin, + "EnableHistorySyncOptin", diff --git a/www/chromium/files/patch-components_signin_public_base_signin__switches.h b/www/chromium/files/patch-components_signin_public_base_signin__switches.h index 867df2dec5a5..3438afb6235c 100644 --- a/www/chromium/files/patch-components_signin_public_base_signin__switches.h +++ b/www/chromium/files/patch-components_signin_public_base_signin__switches.h @@ -1,11 +1,11 @@ ---- components/signin/public/base/signin_switches.h.orig 2024-04-19 13:02:56 UTC +--- components/signin/public/base/signin_switches.h.orig 2025-07-02 06:08:04 UTC +++ components/signin/public/base/signin_switches.h -@@ -123,7 +123,7 @@ bool IsExplicitBrowserSigninUIOnDesktopEnabled( +@@ -58,7 +58,7 @@ COMPONENT_EXPORT(SIGNIN_SWITCHES) + BASE_DECLARE_FEATURE(kFullscreenSignInPromoUseDate); + #endif - // Controls the view mode for (history) sync screen. - #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) COMPONENT_EXPORT(SIGNIN_SWITCHES) - BASE_DECLARE_FEATURE(kMinorModeRestrictionsForHistorySyncOptIn); - + BASE_DECLARE_FEATURE(kEnableHistorySyncOptin); + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-components_soda_soda__util.cc b/www/chromium/files/patch-components_soda_soda__util.cc new file mode 100644 index 000000000000..bf98e7eeae7d --- /dev/null +++ b/www/chromium/files/patch-components_soda_soda__util.cc @@ -0,0 +1,29 @@ +--- components/soda/soda_util.cc.orig 2025-05-05 10:57:53 UTC ++++ components/soda/soda_util.cc +@@ -23,7 +23,7 @@ + #include "base/win/windows_version.h" + #endif + +-#if BUILDFLAG(IS_LINUX) && defined(ARCH_CPU_X86_FAMILY) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(ARCH_CPU_X86_FAMILY) + #include "base/cpu.h" + #endif + +@@ -39,7 +39,7 @@ bool IsSupportedChromeOS() { + } + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + bool IsSupportedLinux() { + #if defined(ARCH_CPU_X86_FAMILY) + // Check if the CPU has the required instruction set to run the Speech +@@ -70,7 +70,7 @@ bool IsSupportedWin() { + bool IsOnDeviceSpeechRecognitionSupported() { + #if BUILDFLAG(IS_CHROMEOS) + return IsSupportedChromeOS(); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return IsSupportedLinux(); + #elif BUILDFLAG(IS_WIN) + return IsSupportedWin(); diff --git a/www/chromium/files/patch-components_startup__metric__utils_common_startup__metric__utils.cc b/www/chromium/files/patch-components_startup__metric__utils_common_startup__metric__utils.cc index f23e84b504ff..dc5ff7946665 100644 --- a/www/chromium/files/patch-components_startup__metric__utils_common_startup__metric__utils.cc +++ b/www/chromium/files/patch-components_startup__metric__utils_common_startup__metric__utils.cc @@ -1,9 +1,9 @@ ---- components/startup_metric_utils/common/startup_metric_utils.cc.orig 2024-02-23 21:04:38 UTC +--- components/startup_metric_utils/common/startup_metric_utils.cc.orig 2024-08-26 12:06:38 UTC +++ components/startup_metric_utils/common/startup_metric_utils.cc -@@ -85,7 +85,7 @@ base::TimeTicks CommonStartupMetricRecorder::StartupTi +@@ -94,7 +94,7 @@ base::TimeTicks CommonStartupMetricRecorder::StartupTi // Enabling this logic on OS X causes a significant performance regression. - // TODO(crbug.com/601270): Remove IS_APPLE ifdef once priority changes are - // ignored on Mac main thread. + // TODO(crbug.com/40464036): Remove IS_APPLE ifdef once utility processes + // set their desired main thread priority. -#if !BUILDFLAG(IS_APPLE) +#if !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_BSD) static bool statics_initialized = false; diff --git a/www/chromium/files/patch-components_storage__monitor_BUILD.gn b/www/chromium/files/patch-components_storage__monitor_BUILD.gn index 1f37a78ee276..e4aacc3f46c0 100644 --- a/www/chromium/files/patch-components_storage__monitor_BUILD.gn +++ b/www/chromium/files/patch-components_storage__monitor_BUILD.gn @@ -1,20 +1,20 @@ ---- components/storage_monitor/BUILD.gn.orig 2023-11-03 10:09:45 UTC +--- components/storage_monitor/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ components/storage_monitor/BUILD.gn -@@ -77,7 +77,7 @@ static_library("storage_monitor") { +@@ -73,7 +73,7 @@ component("storage_monitor") { deps += [ "//services/device/public/mojom" ] } - } else if (is_linux || is_chromeos_lacros) { + } else if (is_linux) { - if (use_udev) { + if (use_udev && !is_bsd) { sources += [ "mtab_watcher_linux.cc", "mtab_watcher_linux.h", -@@ -184,7 +184,7 @@ source_set("unit_tests") { +@@ -182,7 +182,7 @@ source_set("unit_tests") { "storage_monitor_chromeos_unittest.cc", ] } -- } else if (is_linux || is_chromeos_lacros) { -+ } else if ((is_linux || is_chromeos_lacros) && !is_bsd) { +- } else if (is_linux) { ++ } else if (is_linux && !is_bsd) { if (use_udev) { sources += [ "storage_monitor_linux_unittest.cc" ] } diff --git a/www/chromium/files/patch-components_storage__monitor_removable__device__constants.h b/www/chromium/files/patch-components_storage__monitor_removable__device__constants.h index 71ac1f80d945..0b6652c591c0 100644 --- a/www/chromium/files/patch-components_storage__monitor_removable__device__constants.h +++ b/www/chromium/files/patch-components_storage__monitor_removable__device__constants.h @@ -1,11 +1,11 @@ ---- components/storage_monitor/removable_device_constants.h.orig 2022-02-28 16:54:41 UTC +--- components/storage_monitor/removable_device_constants.h.orig 2025-05-05 10:57:53 UTC +++ components/storage_monitor/removable_device_constants.h -@@ -14,7 +14,7 @@ namespace storage_monitor { - extern const char kFSUniqueIdPrefix[]; - extern const char kVendorModelSerialPrefix[]; +@@ -15,7 +15,7 @@ namespace storage_monitor { + extern COMPONENT_EXPORT(STORAGE_MONITOR) const char kFSUniqueIdPrefix[]; + extern COMPONENT_EXPORT(STORAGE_MONITOR) const char kVendorModelSerialPrefix[]; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - extern const char kVendorModelVolumeStoragePrefix[]; + extern COMPONENT_EXPORT(STORAGE_MONITOR) const + char kVendorModelVolumeStoragePrefix[]; #endif - diff --git a/www/chromium/files/patch-components_supervised__user_core_browser_list__family__members__service.h b/www/chromium/files/patch-components_supervised__user_core_browser_list__family__members__service.h new file mode 100644 index 000000000000..b0b5b1707528 --- /dev/null +++ b/www/chromium/files/patch-components_supervised__user_core_browser_list__family__members__service.h @@ -0,0 +1,11 @@ +--- components/supervised_user/core/browser/list_family_members_service.h.orig 2025-02-19 07:43:18 UTC ++++ components/supervised_user/core/browser/list_family_members_service.h +@@ -33,7 +33,7 @@ namespace supervised_user { + // If true, this fetcher is active for all users with CanFetchFamilyMemberInfo + // capability. Otherwise, it is only used by supervised users. + constexpr bool FetchListFamilyMembersWithCapability() { +-#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + return true; + #else + return false; diff --git a/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__metrics__service.cc b/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__metrics__service.cc new file mode 100644 index 000000000000..3ed3978a9764 --- /dev/null +++ b/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__metrics__service.cc @@ -0,0 +1,11 @@ +--- components/supervised_user/core/browser/supervised_user_metrics_service.cc.orig 2025-07-02 06:08:04 UTC ++++ components/supervised_user/core/browser/supervised_user_metrics_service.cc +@@ -68,7 +68,7 @@ SupervisedUserMetricsService::SupervisedUserMetricsSer + extensions_metrics_delegate_(std::move(extensions_metrics_delegate)) { + DCHECK(pref_service_); + supervised_user_service_observation_.Observe(&supervised_user_service); +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + CHECK(extensions_metrics_delegate_) + << "Extensions metrics delegate must exist on Win/Linux/Mac"; + #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__preferences.cc b/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__preferences.cc new file mode 100644 index 000000000000..962ba8b9f69d --- /dev/null +++ b/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__preferences.cc @@ -0,0 +1,11 @@ +--- components/supervised_user/core/browser/supervised_user_preferences.cc.orig 2025-07-02 06:08:04 UTC ++++ components/supervised_user/core/browser/supervised_user_preferences.cc +@@ -153,7 +153,7 @@ void RegisterProfilePrefs(PrefRegistrySimple* registry + registry->RegisterBooleanPref(prefs::kChildAccountStatusKnown, false); + registry->RegisterStringPref(prefs::kFamilyLinkUserMemberRole, std::string()); + #if BUILDFLAG(ENABLE_EXTENSIONS) && \ +- (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX)) ++ (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) + registry->RegisterIntegerPref( + prefs::kLocallyParentApprovedExtensionsMigrationState, + static_cast<int>( diff --git a/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__service.cc b/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__service.cc deleted file mode 100644 index 5deae2c26986..000000000000 --- a/www/chromium/files/patch-components_supervised__user_core_browser_supervised__user__service.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/supervised_user/core/browser/supervised_user_service.cc.orig 2024-04-19 13:02:56 UTC -+++ components/supervised_user/core/browser/supervised_user_service.cc -@@ -170,7 +170,7 @@ FirstTimeInterstitialBannerState SupervisedUserService - const FirstTimeInterstitialBannerState original_state) { - FirstTimeInterstitialBannerState target_state = original_state; - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_IOS) -+ BUILDFLAG(IS_IOS) || BUILDFLAG(IS_BSD) - if (original_state != FirstTimeInterstitialBannerState::kSetupComplete && - can_show_first_time_interstitial_banner_) { - target_state = FirstTimeInterstitialBannerState::kNeedToShow; diff --git a/www/chromium/files/patch-components_supervised__user_core_common_features.cc b/www/chromium/files/patch-components_supervised__user_core_common_features.cc index ceaa4133d4b8..409f714ca9b5 100644 --- a/www/chromium/files/patch-components_supervised__user_core_common_features.cc +++ b/www/chromium/files/patch-components_supervised__user_core_common_features.cc @@ -1,20 +1,54 @@ ---- components/supervised_user/core/common/features.cc.orig 2024-04-19 13:02:56 UTC +--- components/supervised_user/core/common/features.cc.orig 2025-05-28 14:55:43 UTC +++ components/supervised_user/core/common/features.cc -@@ -63,7 +63,7 @@ BASE_FEATURE(kEnableSupervisedUserSkipParentApprovalTo - "EnableSupervisedUserSkipParentApprovalToInstallExtensions", - base::FEATURE_DISABLED_BY_DEFAULT); +@@ -37,7 +37,7 @@ BASE_FEATURE(kAllowSubframeLocalWebApprovals, + #endif + + #if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + const int kLocalWebApprovalBottomSheetLoadTimeoutDefaultValueMs = 5000; + + const base::FeatureParam<int> kLocalWebApprovalBottomSheetLoadTimeoutMs{ +@@ -46,7 +46,7 @@ const base::FeatureParam<int> kLocalWebApprovalBottomS + #endif // BUILDFLAG(IS_IOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - BASE_FEATURE(kEnableExtensionsPermissionsForSupervisedUsersOnDesktop, - "EnableExtensionsPermissionsForSupervisedUsersOnDesktop", + BASE_FEATURE(kEnableLocalWebApprovalErrorDialog, + "EnableLocalWebApprovalErrorDialog", + base::FEATURE_ENABLED_BY_DEFAULT); +@@ -89,7 +89,7 @@ bool IsLocalWebApprovalsEnabledForSubframes() { + return base::FeatureList::IsEnabled(kAllowSubframeLocalWebApprovals); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kCustomProfileStringsForSupervisedUsers, + "CustomProfileStringsForSupervisedUsers", + base::FEATURE_ENABLED_BY_DEFAULT); +@@ -101,13 +101,13 @@ BASE_FEATURE(kShowKiteForSupervisedUsers, + + BASE_FEATURE(kForceSafeSearchForUnauthenticatedSupervisedUsers, + "ForceSafeSearchForUnauthenticatedSupervisedUsers", +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT); + #else + base::FEATURE_DISABLED_BY_DEFAULT); + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kEnableSupervisedUserVersionSignOutDialog, + "EnableSupervisedUserVersionSignOutDialog", + base::FEATURE_ENABLED_BY_DEFAULT); +@@ -119,7 +119,7 @@ BASE_FEATURE(kEnableSupervisedUserVersionSignOutDialog + // platform #defines. + BASE_FEATURE(kUncredentialedFilteringFallbackForSupervisedUsers, + "UncredentialedFilteringFallbackForSupervisedUsers", +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT); + #else base::FEATURE_DISABLED_BY_DEFAULT); -@@ -74,7 +74,7 @@ bool IsSupervisedUserSkipParentApprovalToInstallExtens - #if BUILDFLAG(IS_CHROMEOS) - return base::FeatureList::IsEnabled( - kEnableSupervisedUserSkipParentApprovalToInstallExtensions); --#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - bool skipParentApprovalEnabled = base::FeatureList::IsEnabled( - kEnableSupervisedUserSkipParentApprovalToInstallExtensions); - bool permissionExtensionsForSupervisedUsersEnabled = diff --git a/www/chromium/files/patch-components_supervised__user_core_common_features.h b/www/chromium/files/patch-components_supervised__user_core_common_features.h index 4b1713457f73..1319fe53139a 100644 --- a/www/chromium/files/patch-components_supervised__user_core_common_features.h +++ b/www/chromium/files/patch-components_supervised__user_core_common_features.h @@ -1,11 +1,35 @@ ---- components/supervised_user/core/common/features.h.orig 2024-04-19 13:02:56 UTC +--- components/supervised_user/core/common/features.h.orig 2025-05-28 14:55:43 UTC +++ components/supervised_user/core/common/features.h -@@ -23,7 +23,7 @@ BASE_DECLARE_FEATURE(kLocalWebApprovals); - BASE_DECLARE_FEATURE( - kEnableSupervisedUserSkipParentApprovalToInstallExtensions); +@@ -20,12 +20,12 @@ BASE_DECLARE_FEATURE(kLocalWebApprovals); + BASE_DECLARE_FEATURE(kAllowSubframeLocalWebApprovals); + + #if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + extern const base::FeatureParam<int> kLocalWebApprovalBottomSheetLoadTimeoutMs; + #endif // BUILDFLAG(IS_IOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || + // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - BASE_DECLARE_FEATURE(kEnableExtensionsPermissionsForSupervisedUsersOnDesktop); - #endif + // Whether we show an error screen in case of failure of a local web approval. + BASE_DECLARE_FEATURE(kEnableLocalWebApprovalErrorDialog); + #endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) +@@ -37,7 +37,7 @@ BASE_DECLARE_FEATURE(kLocalWebApprovalsWidgetSupportsU + // Whether supervised users see an updated URL filter interstitial. + BASE_DECLARE_FEATURE(kSupervisedUserBlockInterstitialV3); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // Enable different web sign in interception behaviour for supervised users: + // + // 1. Supervised user signs in to existing signed out Profile: show modal +@@ -55,7 +55,7 @@ BASE_DECLARE_FEATURE(kShowKiteForSupervisedUsers); + // unauthenticated (e.g. signed out of the content area) account. + BASE_DECLARE_FEATURE(kForceSafeSearchForUnauthenticatedSupervisedUsers); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + // Uses supervised user strings on the signout dialog. + BASE_DECLARE_FEATURE(kEnableSupervisedUserVersionSignOutDialog); + #endif diff --git a/www/chromium/files/patch-components_supervised__user_core_common_pref__names.h b/www/chromium/files/patch-components_supervised__user_core_common_pref__names.h index 782809dbe592..3d095a8225db 100644 --- a/www/chromium/files/patch-components_supervised__user_core_common_pref__names.h +++ b/www/chromium/files/patch-components_supervised__user_core_common_pref__names.h @@ -1,9 +1,9 @@ ---- components/supervised_user/core/common/pref_names.h.orig 2024-04-19 13:02:56 UTC +--- components/supervised_user/core/common/pref_names.h.orig 2025-05-28 14:55:43 UTC +++ components/supervised_user/core/common/pref_names.h -@@ -131,7 +131,7 @@ inline constexpr char kFirstTimeInterstitialBannerStat - "profile.managed.banner_state"; +@@ -129,7 +129,7 @@ inline constexpr char kDefaultSupervisedUserFilteringB + "profile.managed.default_filtering_behavior"; - #if BUILDFLAG(ENABLE_EXTENSIONS) + #if BUILDFLAG(ENABLE_EXTENSIONS_CORE) -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // An integer pref that stores the current state of the local extension diff --git a/www/chromium/files/patch-components_sync__device__info_local__device__info__util.cc b/www/chromium/files/patch-components_sync__device__info_local__device__info__util.cc index be1ef2dc6f9f..6670a65926dc 100644 --- a/www/chromium/files/patch-components_sync__device__info_local__device__info__util.cc +++ b/www/chromium/files/patch-components_sync__device__info_local__device__info__util.cc @@ -1,6 +1,6 @@ ---- components/sync_device_info/local_device_info_util.cc.orig 2023-09-13 12:11:42 UTC +--- components/sync_device_info/local_device_info_util.cc.orig 2025-02-19 07:43:18 UTC +++ components/sync_device_info/local_device_info_util.cc -@@ -82,7 +82,7 @@ void OnMachineStatisticsLoaded(LocalDeviceNameInfo* na +@@ -84,7 +84,7 @@ void OnMachineStatisticsLoaded(LocalDeviceNameInfo* na sync_pb::SyncEnums::DeviceType GetLocalDeviceType() { #if BUILDFLAG(IS_CHROMEOS) return sync_pb::SyncEnums_DeviceType_TYPE_CROS; @@ -9,10 +9,10 @@ return sync_pb::SyncEnums_DeviceType_TYPE_LINUX; #elif BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) switch (ui::GetDeviceFormFactor()) { -@@ -107,7 +107,7 @@ DeviceInfo::OsType GetLocalDeviceOSType() { +@@ -107,7 +107,7 @@ sync_pb::SyncEnums::DeviceType GetLocalDeviceType() { + DeviceInfo::OsType GetLocalDeviceOSType() { + #if BUILDFLAG(IS_CHROMEOS) return DeviceInfo::OsType::kChromeOsAsh; - #elif BUILDFLAG(IS_CHROMEOS_LACROS) - return DeviceInfo::OsType::kChromeOsLacros; -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return DeviceInfo::OsType::kLinux; diff --git a/www/chromium/files/patch-components_sync__preferences_common__syncable__prefs__database.cc b/www/chromium/files/patch-components_sync__preferences_common__syncable__prefs__database.cc new file mode 100644 index 000000000000..f38eddaf4649 --- /dev/null +++ b/www/chromium/files/patch-components_sync__preferences_common__syncable__prefs__database.cc @@ -0,0 +1,11 @@ +--- components/sync_preferences/common_syncable_prefs_database.cc.orig 2025-05-28 14:55:43 UTC ++++ components/sync_preferences/common_syncable_prefs_database.cc +@@ -339,7 +339,7 @@ constexpr auto kCommonSyncablePrefsAllowlist = + PrefSensitivity::kNone, MergeBehavior::kNone}}, + #endif // BUILDFLAG(IS_ANDROID) + #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + {autofill::prefs::kAutofillBnplEnabled, + {syncable_prefs_ids::kAutofillBnplEnabled, syncer::PREFERENCES, + PrefSensitivity::kNone, MergeBehavior::kNone}}, diff --git a/www/chromium/files/patch-components_sync_base_features.cc b/www/chromium/files/patch-components_sync_base_features.cc deleted file mode 100644 index 59a5a0612642..000000000000 --- a/www/chromium/files/patch-components_sync_base_features.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- components/sync/base/features.cc.orig 2024-04-19 13:02:56 UTC -+++ components/sync/base/features.cc -@@ -126,7 +126,7 @@ BASE_FEATURE(kEnablePreferencesAccountStorage, - BASE_FEATURE(kSyncPollImmediatelyOnEveryStartup, - "SyncPollImmediatelyOnEveryStartup2", - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT diff --git a/www/chromium/files/patch-components_sync_service_sync__prefs.cc b/www/chromium/files/patch-components_sync_service_sync__prefs.cc new file mode 100644 index 000000000000..0a500e15d0be --- /dev/null +++ b/www/chromium/files/patch-components_sync_service_sync__prefs.cc @@ -0,0 +1,11 @@ +--- components/sync/service/sync_prefs.cc.orig 2025-07-02 06:08:04 UTC ++++ components/sync/service/sync_prefs.cc +@@ -776,7 +776,7 @@ bool SyncPrefs::IsTypeSupportedInTransportMode(UserSel + // transport mode everywhere. + return true; + case UserSelectableType::kHistory: +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return base::FeatureList::IsEnabled(kReplaceSyncPromosWithSignInPromos) || + base::FeatureList::IsEnabled(switches::kEnableHistorySyncOptin); + #else diff --git a/www/chromium/files/patch-components_trusted__vault_trusted__vault__connection__impl.cc b/www/chromium/files/patch-components_trusted__vault_trusted__vault__connection__impl.cc new file mode 100644 index 000000000000..b0ababc7a986 --- /dev/null +++ b/www/chromium/files/patch-components_trusted__vault_trusted__vault__connection__impl.cc @@ -0,0 +1,11 @@ +--- components/trusted_vault/trusted_vault_connection_impl.cc.orig 2025-07-02 06:08:04 UTC ++++ components/trusted_vault/trusted_vault_connection_impl.cc +@@ -105,7 +105,7 @@ GetLocalPhysicalDeviceType() { + // currently used or even built on all platforms. + #if BUILDFLAG(IS_CHROMEOS) + return trusted_vault_pb::PhysicalDeviceMetadata::DEVICE_TYPE_CHROMEOS; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return trusted_vault_pb::PhysicalDeviceMetadata::DEVICE_TYPE_LINUX; + #elif BUILDFLAG(IS_ANDROID) + return trusted_vault_pb::PhysicalDeviceMetadata::DEVICE_TYPE_ANDROID; diff --git a/www/chromium/files/patch-components_update__client_update__query__params.cc b/www/chromium/files/patch-components_update__client_update__query__params.cc index 34e21cc73c9a..f8772e7807f2 100644 --- a/www/chromium/files/patch-components_update__client_update__query__params.cc +++ b/www/chromium/files/patch-components_update__client_update__query__params.cc @@ -1,6 +1,6 @@ ---- components/update_client/update_query_params.cc.orig 2023-07-16 15:47:57 UTC +--- components/update_client/update_query_params.cc.orig 2025-02-19 07:43:18 UTC +++ components/update_client/update_query_params.cc -@@ -42,6 +42,8 @@ const char kOs[] = +@@ -39,6 +39,8 @@ const char kOs[] = "fuchsia"; #elif BUILDFLAG(IS_OPENBSD) "openbsd"; diff --git a/www/chromium/files/patch-components_url__formatter_spoof__checks_idn__spoof__checker.cc b/www/chromium/files/patch-components_url__formatter_spoof__checks_idn__spoof__checker.cc index 084b204dae90..910d31e61b21 100644 --- a/www/chromium/files/patch-components_url__formatter_spoof__checks_idn__spoof__checker.cc +++ b/www/chromium/files/patch-components_url__formatter_spoof__checks_idn__spoof__checker.cc @@ -1,6 +1,6 @@ ---- components/url_formatter/spoof_checks/idn_spoof_checker.cc.orig 2024-02-23 21:04:38 UTC +--- components/url_formatter/spoof_checks/idn_spoof_checker.cc.orig 2025-03-05 08:14:56 UTC +++ components/url_formatter/spoof_checks/idn_spoof_checker.cc -@@ -294,7 +294,7 @@ IDNSpoofChecker::IDNSpoofChecker() { +@@ -298,7 +298,7 @@ IDNSpoofChecker::IDNSpoofChecker() { // The ideal fix would be to change the omnibox font used for Thai. In // that case, the Linux-only list should be revisited and potentially // removed. diff --git a/www/chromium/files/patch-components_user__education_views_help__bubble__view.cc b/www/chromium/files/patch-components_user__education_views_help__bubble__view.cc index 2c23881a9d4d..0f4a2f09738d 100644 --- a/www/chromium/files/patch-components_user__education_views_help__bubble__view.cc +++ b/www/chromium/files/patch-components_user__education_views_help__bubble__view.cc @@ -1,11 +1,29 @@ ---- components/user_education/views/help_bubble_view.cc.orig 2024-03-22 08:19:40 UTC +--- components/user_education/views/help_bubble_view.cc.orig 2025-05-05 10:57:53 UTC +++ components/user_education/views/help_bubble_view.cc -@@ -1011,7 +1011,7 @@ gfx::Rect HelpBubbleView::GetAnchorRect() const { +@@ -268,7 +268,7 @@ DEFINE_CLASS_ELEMENT_IDENTIFIER_VALUE(HelpBubbleView, + // TODO(https://crbug.com/382611284): Temporarily handle the case when the + // primary window is minimized by closing the help bubble. Remove this code when + // the issue is solved at the Views framework level. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + class HelpBubbleView::PrimaryWidgetObserver : public views::WidgetObserver { + public: + explicit PrimaryWidgetObserver(HelpBubbleView& help_bubble) +@@ -743,7 +743,7 @@ HelpBubbleView::HelpBubbleView( + event_relay_->Init(this); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + primary_widget_observer_ = std::make_unique<PrimaryWidgetObserver>(*this); + #endif + +@@ -855,7 +855,7 @@ gfx::Rect HelpBubbleView::GetAnchorRect() const { void HelpBubbleView::OnBeforeBubbleWidgetInit(views::Widget::InitParams* params, views::Widget* widget) const { BubbleDialogDelegateView::OnBeforeBubbleWidgetInit(params, widget); -#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || BUILDFLAG(IS_BSD) // Help bubbles anchored to menus may be clipped to their anchors' bounds, // resulting in visual errors, unless they use accelerated rendering. See - // crbug.com/1445770 for details. + // crbug.com/1445770 for details. This also applies to bubbles anchored to diff --git a/www/chromium/files/patch-components_user__education_views_help__bubble__view.h b/www/chromium/files/patch-components_user__education_views_help__bubble__view.h new file mode 100644 index 000000000000..09b011f9c647 --- /dev/null +++ b/www/chromium/files/patch-components_user__education_views_help__bubble__view.h @@ -0,0 +1,11 @@ +--- components/user_education/views/help_bubble_view.h.orig 2025-05-05 10:57:53 UTC ++++ components/user_education/views/help_bubble_view.h +@@ -160,7 +160,7 @@ class HelpBubbleView : public views::BubbleDialogDeleg + // work around this problem by closing the bubble if the widget is minimized. + // When the underlying issue is fixed at the framework level, this can be + // removed. +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + class PrimaryWidgetObserver; + std::unique_ptr<PrimaryWidgetObserver> primary_widget_observer_; + #endif diff --git a/www/chromium/files/patch-components_variations_net_variations__command__line.cc b/www/chromium/files/patch-components_variations_net_variations__command__line.cc new file mode 100644 index 000000000000..3ad7561ceefa --- /dev/null +++ b/www/chromium/files/patch-components_variations_net_variations__command__line.cc @@ -0,0 +1,11 @@ +--- components/variations/net/variations_command_line.cc.orig 2025-05-28 14:55:43 UTC ++++ components/variations/net/variations_command_line.cc +@@ -50,7 +50,7 @@ void ExitWithMessage(const std::string& message) { + namespace variations { + + #if !BUILDFLAG(IS_CHROMEOS) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kFeedbackIncludeVariations, + "FeedbackIncludeVariations", + base::FEATURE_ENABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-components_variations_service_variations__service.cc b/www/chromium/files/patch-components_variations_service_variations__service.cc index ab6858c04cc7..cb59dfff157f 100644 --- a/www/chromium/files/patch-components_variations_service_variations__service.cc +++ b/www/chromium/files/patch-components_variations_service_variations__service.cc @@ -1,6 +1,6 @@ ---- components/variations/service/variations_service.cc.orig 2024-03-22 08:19:40 UTC +--- components/variations/service/variations_service.cc.orig 2025-03-05 08:14:56 UTC +++ components/variations/service/variations_service.cc -@@ -99,7 +99,7 @@ std::string GetPlatformString() { +@@ -100,7 +100,7 @@ std::string GetPlatformString() { return "android"; #elif BUILDFLAG(IS_FUCHSIA) return "fuchsia"; diff --git a/www/chromium/files/patch-components_visited__url__ranking_public_url__visit__util.cc b/www/chromium/files/patch-components_visited__url__ranking_public_url__visit__util.cc new file mode 100644 index 000000000000..c51375640920 --- /dev/null +++ b/www/chromium/files/patch-components_visited__url__ranking_public_url__visit__util.cc @@ -0,0 +1,11 @@ +--- components/visited_url_ranking/public/url_visit_util.cc.orig 2025-05-28 14:55:43 UTC ++++ components/visited_url_ranking/public/url_visit_util.cc +@@ -68,7 +68,7 @@ PlatformType GetPlatformInput() { + return PlatformType::kWindows; + #elif BUILDFLAG(IS_MAC) + return PlatformType::kMac; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return PlatformType::kLinux; + #elif BUILDFLAG(IS_IOS) + return PlatformType::kIos; diff --git a/www/chromium/files/patch-components_viz_host_gpu__host__impl.cc b/www/chromium/files/patch-components_viz_host_gpu__host__impl.cc new file mode 100644 index 000000000000..97eddc1b675d --- /dev/null +++ b/www/chromium/files/patch-components_viz_host_gpu__host__impl.cc @@ -0,0 +1,11 @@ +--- components/viz/host/gpu_host_impl.cc.orig 2025-02-19 07:43:18 UTC ++++ components/viz/host/gpu_host_impl.cc +@@ -135,7 +135,7 @@ GpuHostImpl::GpuHostImpl(Delegate* delegate, + mojom::GpuServiceCreationParams::New(); + #if BUILDFLAG(IS_OZONE) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Linux has an issue when running in single-process mode wherein + // GetPlatformRuntimeProperties() browser-side calls can have a data race with + // in-process GPU service initialization. The call to diff --git a/www/chromium/files/patch-components_viz_host_host__display__client.cc b/www/chromium/files/patch-components_viz_host_host__display__client.cc index 4c63ecd3a9b4..f8955c1b6747 100644 --- a/www/chromium/files/patch-components_viz_host_host__display__client.cc +++ b/www/chromium/files/patch-components_viz_host_host__display__client.cc @@ -1,6 +1,6 @@ ---- components/viz/host/host_display_client.cc.orig 2024-01-30 07:53:34 UTC +--- components/viz/host/host_display_client.cc.orig 2024-05-21 18:07:39 UTC +++ components/viz/host/host_display_client.cc -@@ -64,7 +64,7 @@ void HostDisplayClient::AddChildWindowToBrowser( +@@ -65,7 +65,7 @@ void HostDisplayClient::AddChildWindowToBrowser( } #endif diff --git a/www/chromium/files/patch-components_viz_service_display__embedder_skia__output__surface__impl.cc b/www/chromium/files/patch-components_viz_service_display__embedder_skia__output__surface__impl.cc index fc579ddbbd9f..6533a7ab2ff3 100644 --- a/www/chromium/files/patch-components_viz_service_display__embedder_skia__output__surface__impl.cc +++ b/www/chromium/files/patch-components_viz_service_display__embedder_skia__output__surface__impl.cc @@ -1,9 +1,9 @@ ---- components/viz/service/display_embedder/skia_output_surface_impl.cc.orig 2024-04-25 21:17:54 UTC +--- components/viz/service/display_embedder/skia_output_surface_impl.cc.orig 2025-07-02 06:08:04 UTC +++ components/viz/service/display_embedder/skia_output_surface_impl.cc -@@ -1527,7 +1527,7 @@ GrBackendFormat SkiaOutputSurfaceImpl::GetGrBackendFor - ->GetVulkanPhysicalDevice(), - VK_IMAGE_TILING_OPTIMAL, vk_format, - si_format, yuv_color_space, ycbcr_info); +@@ -1503,7 +1503,7 @@ GrBackendFormat SkiaOutputSurfaceImpl::GetGrBackendFor + ->GetVulkanPhysicalDevice(), + VK_IMAGE_TILING_OPTIMAL, vk_format, + si_format, yuv_color_space, ycbcr_info); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Textures that were allocated _on linux_ with ycbcr info came from diff --git a/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.cc b/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.cc index 3f501b56ec58..b68559961f3b 100644 --- a/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.cc +++ b/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.cc @@ -1,20 +1,20 @@ ---- components/viz/service/display_embedder/software_output_surface.cc.orig 2024-02-23 21:04:38 UTC +--- components/viz/service/display_embedder/software_output_surface.cc.orig 2025-02-19 07:43:18 UTC +++ components/viz/service/display_embedder/software_output_surface.cc -@@ -124,7 +124,7 @@ void SoftwareOutputSurface::SwapBuffersCallback(base:: +@@ -115,7 +115,7 @@ void SoftwareOutputSurface::SwapBuffersCallback(base:: + base::TimeTicks now = base::TimeTicks::Now(); + base::TimeDelta interval_to_next_refresh = now.SnappedToNextTick(refresh_timebase_, refresh_interval_) - now; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) if (needs_swap_size_notifications_) client_->DidSwapWithSize(pixel_size); #endif -@@ -153,7 +153,7 @@ gfx::OverlayTransform SoftwareOutputSurface::GetDispla +@@ -142,7 +142,7 @@ gfx::OverlayTransform SoftwareOutputSurface::GetDispla + return gfx::OVERLAY_TRANSFORM_NONE; + } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void SoftwareOutputSurface::SetNeedsSwapSizeNotifications( bool needs_swap_size_notifications) { needs_swap_size_notifications_ = needs_swap_size_notifications; diff --git a/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.h b/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.h index 3d8759e36eb0..e82b6f040c13 100644 --- a/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.h +++ b/www/chromium/files/patch-components_viz_service_display__embedder_software__output__surface.h @@ -1,20 +1,20 @@ ---- components/viz/service/display_embedder/software_output_surface.h.orig 2023-12-10 06:10:27 UTC +--- components/viz/service/display_embedder/software_output_surface.h.orig 2025-07-02 06:08:04 UTC +++ components/viz/service/display_embedder/software_output_surface.h -@@ -47,7 +47,7 @@ class VIZ_SERVICE_EXPORT SoftwareOutputSurface : publi +@@ -40,7 +40,7 @@ class VIZ_SERVICE_EXPORT SoftwareOutputSurface : publi + UpdateVSyncParametersCallback callback) override; + void SetDisplayTransformHint(gfx::OverlayTransform transform) override {} gfx::OverlayTransform GetDisplayTransform() override; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void SetNeedsSwapSizeNotifications( bool needs_swap_size_notifications) override; #endif -@@ -70,7 +70,7 @@ class VIZ_SERVICE_EXPORT SoftwareOutputSurface : publi +@@ -58,7 +58,7 @@ class VIZ_SERVICE_EXPORT SoftwareOutputSurface : publi + base::TimeTicks refresh_timebase_; + base::TimeDelta refresh_interval_ = BeginFrameArgs::DefaultInterval(); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool needs_swap_size_notifications_ = false; #endif diff --git a/www/chromium/files/patch-components_viz_service_display_skia__renderer.cc b/www/chromium/files/patch-components_viz_service_display_skia__renderer.cc index 3711cc5ce6a2..037b84a2fafb 100644 --- a/www/chromium/files/patch-components_viz_service_display_skia__renderer.cc +++ b/www/chromium/files/patch-components_viz_service_display_skia__renderer.cc @@ -1,6 +1,6 @@ ---- components/viz/service/display/skia_renderer.cc.orig 2024-04-19 13:02:56 UTC +--- components/viz/service/display/skia_renderer.cc.orig 2025-07-02 06:08:04 UTC +++ components/viz/service/display/skia_renderer.cc -@@ -1448,7 +1448,7 @@ void SkiaRenderer::ClearFramebuffer() { +@@ -1380,7 +1380,7 @@ void SkiaRenderer::ClearFramebuffer() { if (current_frame()->current_render_pass->has_transparent_background) { ClearCanvas(SkColors::kTransparent); } else { diff --git a/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.cc b/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.cc index 1a3381f6e758..bd9c7304e002 100644 --- a/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.cc +++ b/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.cc @@ -1,6 +1,6 @@ ---- components/viz/service/frame_sinks/root_compositor_frame_sink_impl.cc.orig 2024-04-19 13:02:56 UTC +--- components/viz/service/frame_sinks/root_compositor_frame_sink_impl.cc.orig 2025-07-02 06:08:04 UTC +++ components/viz/service/frame_sinks/root_compositor_frame_sink_impl.cc -@@ -111,7 +111,7 @@ RootCompositorFrameSinkImpl::Create( +@@ -141,7 +141,7 @@ RootCompositorFrameSinkImpl::Create( output_surface->SetNeedsSwapSizeNotifications( params->send_swap_size_notifications); @@ -9,7 +9,7 @@ // For X11, we need notify client about swap completion after resizing, so the // client can use it for synchronize with X11 WM. output_surface->SetNeedsSwapSizeNotifications(true); -@@ -649,7 +649,7 @@ void RootCompositorFrameSinkImpl::DisplayDidCompleteSw +@@ -930,7 +930,7 @@ void RootCompositorFrameSinkImpl::DisplayDidCompleteSw if (display_client_ && enable_swap_completion_callback_) { display_client_->DidCompleteSwapWithSize(pixel_size); } diff --git a/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.h b/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.h index 68f6c90f56aa..8d96578c7309 100644 --- a/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.h +++ b/www/chromium/files/patch-components_viz_service_frame__sinks_root__compositor__frame__sink__impl.h @@ -1,8 +1,8 @@ ---- components/viz/service/frame_sinks/root_compositor_frame_sink_impl.h.orig 2024-04-19 13:02:56 UTC +--- components/viz/service/frame_sinks/root_compositor_frame_sink_impl.h.orig 2025-05-28 14:55:43 UTC +++ components/viz/service/frame_sinks/root_compositor_frame_sink_impl.h -@@ -209,7 +209,7 @@ class VIZ_SERVICE_EXPORT RootCompositorFrameSinkImpl - // See comments on `EvictionHandler`. - EvictionHandler eviction_handler_; +@@ -234,7 +234,7 @@ class VIZ_SERVICE_EXPORT RootCompositorFrameSinkImpl + base::TimeDelta preferred_frame_interval_ = + FrameRateDecider::UnspecifiedFrameInterval(); -#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE_X11) diff --git a/www/chromium/files/patch-components_viz_service_gl_gpu__service__impl.cc b/www/chromium/files/patch-components_viz_service_gl_gpu__service__impl.cc new file mode 100644 index 000000000000..4fe0ed10104f --- /dev/null +++ b/www/chromium/files/patch-components_viz_service_gl_gpu__service__impl.cc @@ -0,0 +1,20 @@ +--- components/viz/service/gl/gpu_service_impl.cc.orig 2025-07-02 06:08:04 UTC ++++ components/viz/service/gl/gpu_service_impl.cc +@@ -515,7 +515,7 @@ void GpuServiceImpl::InitializeWithHostInternal( + + mojo::Remote<mojom::GpuHost> gpu_host(std::move(pending_gpu_host)); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + gpu_extra_info_.is_gmb_nv12_supported = IsGMBNV12Supported(); + #endif + +@@ -1351,7 +1351,7 @@ bool GpuServiceImpl::OnBeginFrameDerivedImpl(const Beg + return true; + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + bool GpuServiceImpl::IsGMBNV12Supported() { + CHECK(main_runner_->BelongsToCurrentThread()); + auto buffer_format = gfx::BufferFormat::YUV_420_BIPLANAR; diff --git a/www/chromium/files/patch-components_viz_service_gl_gpu__service__impl.h b/www/chromium/files/patch-components_viz_service_gl_gpu__service__impl.h new file mode 100644 index 000000000000..955bd62f4058 --- /dev/null +++ b/www/chromium/files/patch-components_viz_service_gl_gpu__service__impl.h @@ -0,0 +1,11 @@ +--- components/viz/service/gl/gpu_service_impl.h.orig 2025-07-02 06:08:04 UTC ++++ components/viz/service/gl/gpu_service_impl.h +@@ -487,7 +487,7 @@ class VIZ_SERVICE_EXPORT GpuServiceImpl + + void OnBeginFrameOnIO(const BeginFrameArgs& args); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + bool IsGMBNV12Supported(); + #endif + diff --git a/www/chromium/files/patch-components_viz_test_mock__display__client.h b/www/chromium/files/patch-components_viz_test_mock__display__client.h index 5cd831b091b6..0a38967366a8 100644 --- a/www/chromium/files/patch-components_viz_test_mock__display__client.h +++ b/www/chromium/files/patch-components_viz_test_mock__display__client.h @@ -1,9 +1,9 @@ ---- components/viz/test/mock_display_client.h.orig 2024-01-30 07:53:34 UTC +--- components/viz/test/mock_display_client.h.orig 2025-02-19 07:43:18 UTC +++ components/viz/test/mock_display_client.h -@@ -43,7 +43,7 @@ class MockDisplayClient : public mojom::DisplayClient - MOCK_METHOD1(SetWideColorEnabled, void(bool enabled)); +@@ -45,7 +45,7 @@ class MockDisplayClient : public mojom::DisplayClient + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) MOCK_METHOD1(SetPreferredRefreshRate, void(float refresh_rate)); - #endif + #endif // BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE_X11) MOCK_METHOD1(DidCompleteSwapWithNewSize, void(const gfx::Size&)); diff --git a/www/chromium/files/patch-components_webui_flags_flags__state.cc b/www/chromium/files/patch-components_webui_flags_flags__state.cc new file mode 100644 index 000000000000..fe99ec26dbde --- /dev/null +++ b/www/chromium/files/patch-components_webui_flags_flags__state.cc @@ -0,0 +1,11 @@ +--- components/webui/flags/flags_state.cc.orig 2025-07-02 06:08:04 UTC ++++ components/webui/flags/flags_state.cc +@@ -781,7 +781,7 @@ unsigned short FlagsState::GetCurrentPlatform() { + return kOsWin; + #elif BUILDFLAG(IS_CHROMEOS) + return kOsCrOS; +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_OPENBSD) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return kOsLinux; + #elif BUILDFLAG(IS_ANDROID) + return kOsAndroid; diff --git a/www/chromium/files/patch-content_app_BUILD.gn b/www/chromium/files/patch-content_app_BUILD.gn new file mode 100644 index 000000000000..e2919490114d --- /dev/null +++ b/www/chromium/files/patch-content_app_BUILD.gn @@ -0,0 +1,15 @@ +--- content/app/BUILD.gn.orig 2025-05-05 10:57:53 UTC ++++ content/app/BUILD.gn +@@ -90,9 +90,9 @@ source_set("content_main_runner_app") { + "//third_party/tflite:buildflags", + "//tools/v8_context_snapshot:buildflags", + ] +- if (build_tflite_with_xnnpack) { +- deps += [ "//third_party/cpuinfo" ] +- } ++# if (build_tflite_with_xnnpack) { ++# deps += [ "//third_party/cpuinfo" ] ++# } + } + + source_set("app") { diff --git a/www/chromium/files/patch-content_app_content__main.cc b/www/chromium/files/patch-content_app_content__main.cc index db478fe22317..4f637b07a483 100644 --- a/www/chromium/files/patch-content_app_content__main.cc +++ b/www/chromium/files/patch-content_app_content__main.cc @@ -1,11 +1,20 @@ ---- content/app/content_main.cc.orig 2024-02-23 21:04:38 UTC +--- content/app/content_main.cc.orig 2025-07-02 06:08:04 UTC +++ content/app/content_main.cc -@@ -207,7 +207,7 @@ RunContentProcess(ContentMainParams params, - #endif +@@ -233,7 +233,7 @@ NO_STACK_PROTECTOR int RunContentProcess( base::EnableTerminationOnOutOfMemory(); + logging::RegisterAbslAbortHook(); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // The various desktop environments set this environment variable that // allows the dbus client library to connect directly to the bus. When this // variable is not set (test environments like xvfb-run), the dbus client +@@ -332,7 +332,7 @@ NO_STACK_PROTECTOR int RunContentProcess( + #endif + #endif + +-#if (BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX)) && !defined(COMPONENT_BUILD) ++#if (BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX)) && !defined(COMPONENT_BUILD) && defined(notyet) + base::subtle::EnableFDOwnershipEnforcement(true); + #endif + diff --git a/www/chromium/files/patch-content_app_content__main__runner__impl.cc b/www/chromium/files/patch-content_app_content__main__runner__impl.cc index b67c231aaef1..b059dda05cc1 100644 --- a/www/chromium/files/patch-content_app_content__main__runner__impl.cc +++ b/www/chromium/files/patch-content_app_content__main__runner__impl.cc @@ -1,6 +1,6 @@ ---- content/app/content_main_runner_impl.cc.orig 2024-03-22 08:19:40 UTC +--- content/app/content_main_runner_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/app/content_main_runner_impl.cc -@@ -143,13 +143,13 @@ +@@ -148,18 +148,20 @@ #include "content/browser/posix_file_descriptor_info_impl.h" #include "content/public/common/content_descriptors.h" @@ -16,7 +16,14 @@ #include "base/files/file_path_watcher_inotify.h" #include "base/native_library.h" #include "base/rand_util.h" -@@ -187,6 +187,10 @@ + #include "content/public/common/zygote/sandbox_support_linux.h" ++#if !BUILDFLAG(IS_BSD) + #include "sandbox/policy/linux/sandbox_linux.h" ++#endif + #include "third_party/boringssl/src/include/openssl/crypto.h" + #include "third_party/webrtc_overrides/init_webrtc.h" // nogncheck + +@@ -188,6 +190,10 @@ #include "media/base/media_switches.h" #endif @@ -27,7 +34,7 @@ #if BUILDFLAG(IS_ANDROID) #include "base/system/sys_info.h" #include "content/browser/android/battery_metrics.h" -@@ -373,7 +377,7 @@ void InitializeZygoteSandboxForBrowserProcess( +@@ -386,7 +392,7 @@ void InitializeZygoteSandboxForBrowserProcess( } #endif // BUILDFLAG(USE_ZYGOTE) @@ -36,7 +43,7 @@ #if BUILDFLAG(ENABLE_PPAPI) // Loads the (native) libraries but does not initialize them (i.e., does not -@@ -411,7 +415,10 @@ void PreloadLibraryCdms() { +@@ -424,7 +430,10 @@ void PreloadLibraryCdms() { void PreSandboxInit() { // Ensure the /dev/urandom is opened. @@ -47,7 +54,7 @@ // May use sysinfo(), sched_getaffinity(), and open various /sys/ and /proc/ // files. -@@ -423,9 +430,16 @@ void PreSandboxInit() { +@@ -436,9 +445,16 @@ void PreSandboxInit() { // https://boringssl.googlesource.com/boringssl/+/HEAD/SANDBOXING.md CRYPTO_pre_sandbox_init(); @@ -64,7 +71,16 @@ #if BUILDFLAG(ENABLE_PPAPI) // Ensure access to the Pepper plugins before the sandbox is turned on. -@@ -838,11 +852,10 @@ int ContentMainRunnerImpl::Initialize(ContentMainParam +@@ -763,7 +779,7 @@ NO_STACK_PROTECTOR int RunOtherNamedProcessTypeMain( + unregister_thread_closure = base::HangWatcher::RegisterThread( + base::HangWatcher::ThreadType::kMainThread); + bool start_hang_watcher_now; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // On Linux/ChromeOS, the HangWatcher can't start until after the sandbox is + // initialized, because the sandbox can't be started with multiple threads. + // TODO(mpdenton): start the HangWatcher after the sandbox is initialized. +@@ -876,11 +892,10 @@ int ContentMainRunnerImpl::Initialize(ContentMainParam base::GlobalDescriptors::kBaseDescriptor); #endif // !BUILDFLAG(IS_ANDROID) @@ -78,12 +94,14 @@ #endif // !BUILDFLAG(IS_WIN) -@@ -1035,8 +1048,20 @@ int ContentMainRunnerImpl::Initialize(ContentMainParam +@@ -1073,10 +1088,22 @@ int ContentMainRunnerImpl::Initialize(ContentMainParam process_type == switches::kZygoteProcess) { PreSandboxInit(); } +#elif BUILDFLAG(IS_BSD) + PreSandboxInit(); + #elif BUILDFLAG(IS_IOS) && !BUILDFLAG(IS_IOS_TVOS) + ChildProcessEnterSandbox(); #endif +#if BUILDFLAG(IS_BSD) @@ -99,16 +117,7 @@ delegate_->SandboxInitialized(process_type); #if BUILDFLAG(USE_ZYGOTE) -@@ -1104,7 +1129,7 @@ int NO_STACK_PROTECTOR ContentMainRunnerImpl::Run() { - ->ReconfigureAfterFeatureListInit(process_type); - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // If dynamic Mojo Core is being used, ensure that it's loaded very early in - // the child/zygote process, before any sandbox is initialized. The library - // is not fully initialized with IPC support until a ChildProcess is later -@@ -1139,6 +1164,11 @@ int NO_STACK_PROTECTOR ContentMainRunnerImpl::Run() { +@@ -1176,6 +1203,11 @@ NO_STACK_PROTECTOR int ContentMainRunnerImpl::Run() { content_main_params_.reset(); RegisterMainThreadFactories(); diff --git a/www/chromium/files/patch-content_browser_BUILD.gn b/www/chromium/files/patch-content_browser_BUILD.gn index 6eca2da664cc..bbd14b12b2c6 100644 --- a/www/chromium/files/patch-content_browser_BUILD.gn +++ b/www/chromium/files/patch-content_browser_BUILD.gn @@ -1,16 +1,33 @@ ---- content/browser/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- content/browser/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ content/browser/BUILD.gn -@@ -2406,6 +2406,13 @@ source_set("browser") { - deps += [ "//media/mojo/mojom/stable:stable_video_decoder" ] +@@ -2580,6 +2580,14 @@ source_set("browser") { + ] } + if (is_bsd) { ++ sources += [ ++ "file_system_access/file_path_watcher/file_path_watcher_bsd.cc", ++ "file_system_access/file_path_watcher/file_path_watcher_kqueue.cc", ++ "file_system_access/file_path_watcher/file_path_watcher_kqueue.h", ++ ] ++ } ++ + if (is_linux || is_chromeos) { + sources -= + [ "file_system_access/file_path_watcher/file_path_watcher_stub.cc" ] +@@ -2628,6 +2636,15 @@ source_set("browser") { + if (allow_oop_video_decoder) { + sources += [ "media/oop_video_decoder_factory.cc" ] + deps += [ "//media/mojo/mojom" ] ++ } ++ ++ if (is_bsd) { + sources -= [ ++ "file_system_access/file_path_watcher/file_path_watcher_inotify.cc", ++ "file_system_access/file_path_watcher/file_path_watcher_inotify.h", + "sandbox_ipc_linux.cc", + "sandbox_ipc_linux.h", + ] -+ } -+ + } + if (is_chromeos) { - sources += [ - "handwriting/handwriting_recognition_service_impl_cros.cc", diff --git a/www/chromium/files/patch-content_browser_accessibility_browser__accessibility__state__impl.cc b/www/chromium/files/patch-content_browser_accessibility_browser__accessibility__state__impl.cc new file mode 100644 index 000000000000..588100f05d65 --- /dev/null +++ b/www/chromium/files/patch-content_browser_accessibility_browser__accessibility__state__impl.cc @@ -0,0 +1,11 @@ +--- content/browser/accessibility/browser_accessibility_state_impl.cc.orig 2025-07-02 06:08:04 UTC ++++ content/browser/accessibility/browser_accessibility_state_impl.cc +@@ -278,7 +278,7 @@ BrowserAccessibilityStateImpl* BrowserAccessibilitySta + + // On Android, Mac, Windows and Linux there are platform-specific subclasses. + #if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_MAC) && \ +- !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) ++ !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) + // static + std::unique_ptr<BrowserAccessibilityStateImpl> + BrowserAccessibilityStateImpl::Create() { diff --git a/www/chromium/files/patch-content_browser_accessibility_browser__accessibility__state__impl__auralinux.cc b/www/chromium/files/patch-content_browser_accessibility_browser__accessibility__state__impl__auralinux.cc new file mode 100644 index 000000000000..aee5426cbcd1 --- /dev/null +++ b/www/chromium/files/patch-content_browser_accessibility_browser__accessibility__state__impl__auralinux.cc @@ -0,0 +1,33 @@ +--- content/browser/accessibility/browser_accessibility_state_impl_auralinux.cc.orig 2025-07-02 06:08:04 UTC ++++ content/browser/accessibility/browser_accessibility_state_impl_auralinux.cc +@@ -33,7 +33,11 @@ bool CheckCmdlineForOrca(const std::string& cmdline_al + std::string cmdline; + std::stringstream ss(cmdline_all); + while (std::getline(ss, cmdline, '\0')) { ++#if BUILDFLAG(IS_BSD) ++ re2::RE2 orca_regex(R"((^|/)(usr/)?(local/)?bin/orca(\s|$))"); ++#else + re2::RE2 orca_regex(R"((^|/)(usr/)?bin/orca(\s|$))"); ++#endif + if (re2::RE2::PartialMatch(cmdline, orca_regex)) { + return true; // Orca was found + } +@@ -43,6 +47,10 @@ bool CheckCmdlineForOrca(const std::string& cmdline_al + + // Returns true if Orca is active. + bool DiscoverOrca() { ++#if BUILDFLAG(IS_BSD) ++ NOTIMPLEMENTED(); ++ return false; ++#else + // NOTE: this method is run from another thread to reduce jank, since + // there's no guarantee these system calls will return quickly. + std::unique_ptr<DIR, decltype(&CloseDir)> proc_dir(opendir("/proc"), +@@ -80,6 +88,7 @@ bool DiscoverOrca() { + } + + return is_orca_active; ++#endif + } + + } // namespace diff --git a/www/chromium/files/patch-content_browser_audio_audio__service.cc b/www/chromium/files/patch-content_browser_audio_audio__service.cc index 933a4193a464..fd3f992eccd7 100644 --- a/www/chromium/files/patch-content_browser_audio_audio__service.cc +++ b/www/chromium/files/patch-content_browser_audio_audio__service.cc @@ -1,6 +1,6 @@ ---- content/browser/audio/audio_service.cc.orig 2024-02-23 21:04:38 UTC +--- content/browser/audio/audio_service.cc.orig 2025-03-05 08:14:56 UTC +++ content/browser/audio/audio_service.cc -@@ -34,7 +34,7 @@ +@@ -33,7 +33,7 @@ #if BUILDFLAG(ENABLE_PASSTHROUGH_AUDIO_CODECS) #include "ui/display/util/edid_parser.h" @@ -9,7 +9,7 @@ #include "ui/display/display_util.h" #endif // BUILDFLAG(IS_LINUX) -@@ -202,7 +202,7 @@ audio::mojom::AudioService& GetAudioService() { +@@ -201,7 +201,7 @@ audio::mojom::AudioService& GetAudioService() { ->PostTaskAndReplyWithResult( FROM_HERE, base::BindOnce(&ScanEdidBitstreams), base::BindOnce(&LaunchAudioService, std::move(receiver))); diff --git a/www/chromium/files/patch-content_browser_browser__child__process__host__impl.cc b/www/chromium/files/patch-content_browser_browser__child__process__host__impl.cc index fd852fcb7398..0922fcb37da7 100644 --- a/www/chromium/files/patch-content_browser_browser__child__process__host__impl.cc +++ b/www/chromium/files/patch-content_browser_browser__child__process__host__impl.cc @@ -1,14 +1,14 @@ ---- content/browser/browser_child_process_host_impl.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/browser_child_process_host_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/browser_child_process_host_impl.cc -@@ -329,6 +329,7 @@ void BrowserChildProcessHostImpl::LaunchWithoutExtraCo - switches::kMojoCoreLibraryPath, +@@ -326,6 +326,7 @@ void BrowserChildProcessHostImpl::LaunchWithoutExtraCo + switches::kLogBestEffortTasks, switches::kPerfettoDisableInterning, switches::kTraceToConsole, + switches::kDisableUnveil, }; cmd_line->CopySwitchesFrom(browser_command_line, kForwardSwitches); -@@ -644,7 +645,7 @@ void BrowserChildProcessHostImpl::OnProcessLaunched() +@@ -696,7 +697,7 @@ void BrowserChildProcessHostImpl::OnProcessLaunched() ->child_process()); #endif diff --git a/www/chromium/files/patch-content_browser_browser__child__process__host__impl.h b/www/chromium/files/patch-content_browser_browser__child__process__host__impl.h index 01c48bc74f14..f5673dcef553 100644 --- a/www/chromium/files/patch-content_browser_browser__child__process__host__impl.h +++ b/www/chromium/files/patch-content_browser_browser__child__process__host__impl.h @@ -1,6 +1,6 @@ ---- content/browser/browser_child_process_host_impl.h.orig 2024-04-19 13:02:56 UTC +--- content/browser/browser_child_process_host_impl.h.orig 2025-03-05 08:14:56 UTC +++ content/browser/browser_child_process_host_impl.h -@@ -34,7 +34,7 @@ +@@ -36,7 +36,7 @@ #include "base/win/object_watcher.h" #endif @@ -9,7 +9,7 @@ #include "content/browser/child_thread_type_switcher_linux.h" #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -266,7 +266,7 @@ class BrowserChildProcessHostImpl +@@ -287,7 +287,7 @@ class BrowserChildProcessHostImpl std::unique_ptr<tracing::SystemTracingService> system_tracing_service_; #endif diff --git a/www/chromium/files/patch-content_browser_browser__child__process__host__impl__receiver__bindings.cc b/www/chromium/files/patch-content_browser_browser__child__process__host__impl__receiver__bindings.cc index be6079ddca2f..a76c3ff20809 100644 --- a/www/chromium/files/patch-content_browser_browser__child__process__host__impl__receiver__bindings.cc +++ b/www/chromium/files/patch-content_browser_browser__child__process__host__impl__receiver__bindings.cc @@ -1,6 +1,6 @@ ---- content/browser/browser_child_process_host_impl_receiver_bindings.cc.orig 2023-12-10 06:10:27 UTC +--- content/browser/browser_child_process_host_impl_receiver_bindings.cc.orig 2025-03-05 08:14:56 UTC +++ content/browser/browser_child_process_host_impl_receiver_bindings.cc -@@ -62,7 +62,7 @@ void BrowserChildProcessHostImpl::BindHostReceiver( +@@ -64,7 +64,7 @@ void BrowserChildProcessHostImpl::BindHostReceiver( } } diff --git a/www/chromium/files/patch-content_browser_browser__main__loop.cc b/www/chromium/files/patch-content_browser_browser__main__loop.cc index d212da0d13ad..d282cb37b42f 100644 --- a/www/chromium/files/patch-content_browser_browser__main__loop.cc +++ b/www/chromium/files/patch-content_browser_browser__main__loop.cc @@ -1,6 +1,6 @@ ---- content/browser/browser_main_loop.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/browser_main_loop.cc.orig 2025-05-05 10:57:53 UTC +++ content/browser/browser_main_loop.cc -@@ -251,6 +251,12 @@ +@@ -249,6 +249,12 @@ #include "mojo/public/cpp/bindings/lib/test_random_mojo_delays.h" #endif @@ -13,7 +13,7 @@ // One of the linux specific headers defines this as a macro. #ifdef DestroyAll #undef DestroyAll -@@ -556,6 +562,12 @@ int BrowserMainLoop::EarlyInitialization() { +@@ -543,6 +549,12 @@ int BrowserMainLoop::EarlyInitialization() { // by now since a thread to start the ServiceManager has been created // before the browser main loop starts. DCHECK(SandboxHostLinux::GetInstance()->IsInitialized()); @@ -26,8 +26,8 @@ #endif // GLib's spawning of new processes is buggy, so it's important that at this -@@ -593,7 +605,7 @@ int BrowserMainLoop::EarlyInitialization() { - base::PlatformThread::SetCurrentThreadType(base::ThreadType::kCompositing); +@@ -575,7 +587,7 @@ int BrowserMainLoop::EarlyInitialization() { + base::ThreadType::kDisplayCritical); #if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-content_browser_child__process__launcher__helper.h b/www/chromium/files/patch-content_browser_child__process__launcher__helper.h deleted file mode 100644 index 6358752b531b..000000000000 --- a/www/chromium/files/patch-content_browser_child__process__launcher__helper.h +++ /dev/null @@ -1,11 +0,0 @@ ---- content/browser/child_process_launcher_helper.h.orig 2024-04-19 13:02:56 UTC -+++ content/browser/child_process_launcher_helper.h -@@ -293,7 +293,7 @@ class ChildProcessLauncherHelper - std::unique_ptr<SandboxedProcessLauncherDelegate> delegate_; - base::WeakPtr<ChildProcessLauncher> child_process_launcher_; - --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // The priority of the process. The state is stored to avoid changing the - // setting repeatedly. - std::optional<base::Process::Priority> priority_; diff --git a/www/chromium/files/patch-content_browser_child__process__launcher__helper__linux.cc b/www/chromium/files/patch-content_browser_child__process__launcher__helper__linux.cc index eba7cac39400..5d29abddf530 100644 --- a/www/chromium/files/patch-content_browser_child__process__launcher__helper__linux.cc +++ b/www/chromium/files/patch-content_browser_child__process__launcher__helper__linux.cc @@ -1,6 +1,6 @@ ---- content/browser/child_process_launcher_helper_linux.cc.orig 2023-11-03 10:09:45 UTC +--- content/browser/child_process_launcher_helper_linux.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/child_process_launcher_helper_linux.cc -@@ -21,7 +21,9 @@ +@@ -22,7 +22,9 @@ #include "content/public/common/result_codes.h" #include "content/public/common/sandboxed_process_launcher_delegate.h" #include "content/public/common/zygote/sandbox_support_linux.h" @@ -10,7 +10,7 @@ #include "sandbox/policy/linux/sandbox_linux.h" namespace content { -@@ -46,14 +48,20 @@ ChildProcessLauncherHelper::GetFilesToMap() { +@@ -47,14 +49,20 @@ ChildProcessLauncherHelper::GetFilesToMap() { } bool ChildProcessLauncherHelper::IsUsingLaunchOptions() { @@ -31,7 +31,7 @@ // Convert FD mapping to FileHandleMappingVector options->fds_to_remap = files_to_register.GetMappingWithIDAdjustment( base::GlobalDescriptors::kBaseDescriptor); -@@ -65,7 +73,9 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLaunche +@@ -66,7 +74,9 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLaunche options->environment = delegate_->GetEnvironment(); } else { @@ -41,15 +41,15 @@ // Environment variables could be supported in the future, but are not // currently supported when launching with the zygote. DCHECK(delegate_->GetEnvironment().empty()); -@@ -82,6 +92,7 @@ ChildProcessLauncherHelper::LaunchProcessOnLauncherThr +@@ -83,6 +93,7 @@ ChildProcessLauncherHelper::LaunchProcessOnLauncherThr int* launch_result) { *is_synchronous_launch = true; Process process; +#if !BUILDFLAG(IS_BSD) ZygoteCommunication* zygote_handle = GetZygoteForLaunch(); if (zygote_handle) { - // TODO(crbug.com/569191): If chrome supported multiple zygotes they could -@@ -92,7 +103,6 @@ ChildProcessLauncherHelper::LaunchProcessOnLauncherThr + // TODO(crbug.com/40448989): If chrome supported multiple zygotes they could +@@ -93,7 +104,6 @@ ChildProcessLauncherHelper::LaunchProcessOnLauncherThr GetProcessType()); *launch_result = LAUNCH_RESULT_SUCCESS; @@ -57,7 +57,7 @@ if (handle) { // It could be a renderer process or an utility process. int oom_score = content::kMiscOomScore; -@@ -101,15 +111,17 @@ ChildProcessLauncherHelper::LaunchProcessOnLauncherThr +@@ -102,15 +112,17 @@ ChildProcessLauncherHelper::LaunchProcessOnLauncherThr oom_score = content::kLowestRendererOomScore; ZygoteHostImpl::GetInstance()->AdjustRendererOOMScore(handle, oom_score); } @@ -75,8 +75,8 @@ +#endif #if BUILDFLAG(IS_CHROMEOS) - if (GetProcessType() == switches::kRendererProcess) { -@@ -131,10 +143,14 @@ ChildProcessTerminationInfo ChildProcessLauncherHelper + process_id_ = process.process.Pid(); +@@ -134,10 +146,14 @@ ChildProcessTerminationInfo ChildProcessLauncherHelper const ChildProcessLauncherHelper::Process& process, bool known_dead) { ChildProcessTerminationInfo info; @@ -91,7 +91,7 @@ info.status = base::GetKnownDeadTerminationStatus(process.process.Handle(), &info.exit_code); } else { -@@ -160,13 +176,17 @@ void ChildProcessLauncherHelper::ForceNormalProcessTer +@@ -163,13 +179,17 @@ void ChildProcessLauncherHelper::ForceNormalProcessTer DCHECK(CurrentlyOnProcessLauncherTaskRunner()); process.process.Terminate(RESULT_CODE_NORMAL_EXIT, false); // On POSIX, we must additionally reap the child. @@ -109,7 +109,7 @@ } void ChildProcessLauncherHelper::SetProcessPriorityOnLauncherThread( -@@ -179,11 +199,13 @@ void ChildProcessLauncherHelper::SetProcessPriorityOnL +@@ -181,11 +201,13 @@ void ChildProcessLauncherHelper::SetProcessPriorityOnL } } diff --git a/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.cc b/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.cc index 88fa0d2ad071..b1bee9932493 100644 --- a/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.cc +++ b/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.cc @@ -1,4 +1,4 @@ ---- content/browser/child_thread_type_switcher_linux.cc.orig 2023-12-10 06:10:27 UTC +--- content/browser/child_thread_type_switcher_linux.cc.orig 2025-04-04 08:52:13 UTC +++ content/browser/child_thread_type_switcher_linux.cc @@ -20,6 +20,9 @@ void SetThreadTypeOnLauncherThread(base::ProcessId pee base::ThreadType thread_type) { @@ -8,13 +8,22 @@ + NOTIMPLEMENTED(); +#else bool ns_pid_supported = false; - pid_t peer_tid = base::FindThreadID(peer_pid, ns_tid, &ns_pid_supported); - if (peer_tid == -1) { -@@ -37,6 +40,7 @@ void SetThreadTypeOnLauncherThread(base::ProcessId pee - - base::PlatformThread::SetThreadType(peer_pid, peer_tid, thread_type, - base::IsViaIPC(true)); + pid_t peer_tid = + base::FindThreadID(peer_pid, ns_tid.raw(), &ns_pid_supported); +@@ -41,6 +44,7 @@ void SetThreadTypeOnLauncherThread(base::ProcessId pee + base::PlatformThread::SetThreadType(peer_pid, + base::PlatformThreadId(peer_tid), + thread_type, base::IsViaIPC(true)); +#endif } } // namespace +@@ -69,7 +73,7 @@ void ChildThreadTypeSwitcher::SetPid(base::ProcessId c + } + } + +-void ChildThreadTypeSwitcher::SetThreadType(int32_t ns_tid, ++void ChildThreadTypeSwitcher::SetThreadType(uint64_t ns_tid, + base::ThreadType thread_type) { + // This function is only used on platforms with 32-bit thread ids. + static_assert(sizeof(ns_tid) == sizeof(base::PlatformThreadId)); diff --git a/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.h b/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.h new file mode 100644 index 000000000000..1332f8cb0ea0 --- /dev/null +++ b/www/chromium/files/patch-content_browser_child__thread__type__switcher__linux.h @@ -0,0 +1,11 @@ +--- content/browser/child_thread_type_switcher_linux.h.orig 2025-04-04 08:52:13 UTC ++++ content/browser/child_thread_type_switcher_linux.h +@@ -36,7 +36,7 @@ class ChildThreadTypeSwitcher : public mojom::ThreadTy + void SetPid(base::ProcessId child_pid); + + // mojom::ThreadTypeSwitcher: +- void SetThreadType(int32_t ns_tid, base::ThreadType thread_type) override; ++ void SetThreadType(uint64_t ns_tid, base::ThreadType thread_type) override; + + private: + base::ProcessId child_pid_ = base::kNullProcessHandle; diff --git a/www/chromium/files/patch-content_browser_compositor_viz__process__transport__factory.cc b/www/chromium/files/patch-content_browser_compositor_viz__process__transport__factory.cc index 2d1843fe277c..1a42fbd56aa1 100644 --- a/www/chromium/files/patch-content_browser_compositor_viz__process__transport__factory.cc +++ b/www/chromium/files/patch-content_browser_compositor_viz__process__transport__factory.cc @@ -1,6 +1,6 @@ ---- content/browser/compositor/viz_process_transport_factory.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/compositor/viz_process_transport_factory.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/compositor/viz_process_transport_factory.cc -@@ -105,7 +105,7 @@ class HostDisplayClient : public viz::HostDisplayClien +@@ -104,7 +104,7 @@ class HostDisplayClient : public viz::HostDisplayClien HostDisplayClient& operator=(const HostDisplayClient&) = delete; // viz::HostDisplayClient: diff --git a/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.cc b/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.cc index 40151b5c65d2..5897c47eb11c 100644 --- a/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.cc +++ b/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.cc @@ -1,6 +1,6 @@ ---- content/browser/devtools/devtools_frontend_host_impl.cc.orig 2023-11-03 10:09:45 UTC +--- content/browser/devtools/devtools_frontend_host_impl.cc.orig 2025-02-19 07:43:18 UTC +++ content/browser/devtools/devtools_frontend_host_impl.cc -@@ -22,7 +22,7 @@ +@@ -24,7 +24,7 @@ #include "third_party/blink/public/common/associated_interfaces/associated_interface_provider.h" #include "ui/base/webui/resource_path.h" @@ -9,7 +9,7 @@ #include "components/crash/content/browser/error_reporting/javascript_error_report.h" // nogncheck #include "components/crash/content/browser/error_reporting/js_error_report_processor.h" // nogncheck #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -37,7 +37,7 @@ const char kCompatibilityScriptSourceURL[] = +@@ -36,7 +36,7 @@ const char kCompatibilityScriptSourceURL[] = "\n//# " "sourceURL=devtools://devtools/bundled/devtools_compatibility.js"; @@ -18,7 +18,7 @@ // Remove the pieces of the URL we don't want to send back with the error // reports. In particular, do not send query or fragments as those can have // privacy-sensitive information in them. -@@ -107,7 +107,7 @@ DevToolsFrontendHostImpl::DevToolsFrontendHostImpl( +@@ -106,7 +106,7 @@ DevToolsFrontendHostImpl::DevToolsFrontendHostImpl( const HandleMessageCallback& handle_message_callback) : web_contents_(WebContents::FromRenderFrameHost(frame_host)), handle_message_callback_(handle_message_callback) { @@ -27,7 +27,7 @@ Observe(web_contents_); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) mojo::AssociatedRemote<blink::mojom::DevToolsFrontend> frontend; -@@ -132,7 +132,7 @@ void DevToolsFrontendHostImpl::DispatchEmbedderMessage +@@ -131,7 +131,7 @@ void DevToolsFrontendHostImpl::DispatchEmbedderMessage handle_message_callback_.Run(std::move(message)); } diff --git a/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.h b/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.h index d3c8ff7f9c01..c8a223cb39f0 100644 --- a/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.h +++ b/www/chromium/files/patch-content_browser_devtools_devtools__frontend__host__impl.h @@ -1,6 +1,6 @@ ---- content/browser/devtools/devtools_frontend_host_impl.h.orig 2023-11-03 10:09:45 UTC +--- content/browser/devtools/devtools_frontend_host_impl.h.orig 2024-05-21 18:07:39 UTC +++ content/browser/devtools/devtools_frontend_host_impl.h -@@ -33,7 +33,7 @@ class DevToolsFrontendHostImpl : public DevToolsFronte +@@ -34,7 +34,7 @@ class DevToolsFrontendHostImpl : public DevToolsFronte void BadMessageReceived() override; diff --git a/www/chromium/files/patch-content_browser_devtools_protocol_system__info__handler.cc b/www/chromium/files/patch-content_browser_devtools_protocol_system__info__handler.cc index 6ad4ea61d97a..382734ee2a97 100644 --- a/www/chromium/files/patch-content_browser_devtools_protocol_system__info__handler.cc +++ b/www/chromium/files/patch-content_browser_devtools_protocol_system__info__handler.cc @@ -1,6 +1,6 @@ ---- content/browser/devtools/protocol/system_info_handler.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/devtools/protocol/system_info_handler.cc.orig 2025-02-19 07:43:18 UTC +++ content/browser/devtools/protocol/system_info_handler.cc -@@ -50,7 +50,7 @@ std::unique_ptr<SystemInfo::Size> GfxSizeToSystemInfoS +@@ -52,7 +52,7 @@ std::unique_ptr<SystemInfo::Size> GfxSizeToSystemInfoS // 1046598, and 1153667. // Windows builds need more time -- see Issue 873112 and 1004472. // Mac builds need more time - see Issue angleproject:6182. diff --git a/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher.h b/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher.h new file mode 100644 index 000000000000..98612ef4032a --- /dev/null +++ b/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher.h @@ -0,0 +1,11 @@ +--- content/browser/file_system_access/file_path_watcher/file_path_watcher.h.orig 2025-02-19 07:43:18 UTC ++++ content/browser/file_system_access/file_path_watcher/file_path_watcher.h +@@ -126,7 +126,7 @@ class CONTENT_EXPORT FilePathWatcher { + Type type = Type::kNonRecursive; + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ +- BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + // The callback will return the full path to a changed file instead of + // the watched path supplied as |path| when Watch is called. + // So the full path can be different from the watched path when a folder is diff --git a/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher__bsd.cc b/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher__bsd.cc new file mode 100644 index 000000000000..99d0c372c2d5 --- /dev/null +++ b/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher__bsd.cc @@ -0,0 +1,63 @@ +--- content/browser/file_system_access/file_path_watcher/file_path_watcher_bsd.cc.orig 2025-02-19 07:43:18 UTC ++++ content/browser/file_system_access/file_path_watcher/file_path_watcher_bsd.cc +@@ -0,0 +1,60 @@ ++// Copyright 2024 The Chromium Authors ++// Use of this source code is governed by a BSD-style license that can be ++// found in the LICENSE file. ++ ++#include "content/browser/file_system_access/file_path_watcher/file_path_watcher.h" ++ ++#include <memory> ++ ++#include "base/memory/ptr_util.h" ++#include "build/build_config.h" ++#include "content/browser/file_system_access/file_path_watcher/file_path_watcher_kqueue.h" ++ ++namespace content { ++ ++namespace { ++ ++class FilePathWatcherImpl : public FilePathWatcher::PlatformDelegate { ++ public: ++ FilePathWatcherImpl() = default; ++ FilePathWatcherImpl(const FilePathWatcherImpl&) = delete; ++ FilePathWatcherImpl& operator=(const FilePathWatcherImpl&) = delete; ++ ~FilePathWatcherImpl() override = default; ++ ++ bool Watch(const base::FilePath& path, ++ Type type, ++ const FilePathWatcher::Callback& callback) override { ++ DCHECK(!impl_.get()); ++ if (type == Type::kRecursive) { ++ if (!FilePathWatcher::RecursiveWatchAvailable()) { ++ return false; ++ } ++ } else { ++ impl_ = std::make_unique<FilePathWatcherKQueue>(); ++ } ++ DCHECK(impl_.get()); ++ return impl_->Watch(path, type, callback); ++ } ++ ++ void Cancel() override { ++ if (impl_.get()) { ++ impl_->Cancel(); ++ } ++ set_cancelled(); ++ } ++ ++ private: ++ std::unique_ptr<PlatformDelegate> impl_; ++}; ++ ++} // namespace ++ ++FilePathWatcher::FilePathWatcher() ++ : FilePathWatcher(std::make_unique<FilePathWatcherImpl>()) {} ++ ++// static ++size_t FilePathWatcher::GetQuotaLimitImpl() { ++ return std::numeric_limits<size_t>::max(); ++} ++ ++} // namespace content diff --git a/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher__kqueue.h b/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher__kqueue.h new file mode 100644 index 000000000000..1a59af20c1ba --- /dev/null +++ b/www/chromium/files/patch-content_browser_file__system__access_file__path__watcher_file__path__watcher__kqueue.h @@ -0,0 +1,10 @@ +--- content/browser/file_system_access/file_path_watcher/file_path_watcher_kqueue.h.orig 2024-07-30 11:12:21 UTC ++++ content/browser/file_system_access/file_path_watcher/file_path_watcher_kqueue.h +@@ -5,6 +5,7 @@ + #ifndef CONTENT_BROWSER_FILE_SYSTEM_ACCESS_FILE_PATH_WATCHER_FILE_PATH_WATCHER_KQUEUE_H_ + #define CONTENT_BROWSER_FILE_SYSTEM_ACCESS_FILE_PATH_WATCHER_FILE_PATH_WATCHER_KQUEUE_H_ + ++#include <sys/time.h> + #include <sys/event.h> + + #include <memory> diff --git a/www/chromium/files/patch-content_browser_file__system__access_file__system__access__local__path__watcher.cc b/www/chromium/files/patch-content_browser_file__system__access_file__system__access__local__path__watcher.cc index 2ed42a8e3cbe..afe6ba027315 100644 --- a/www/chromium/files/patch-content_browser_file__system__access_file__system__access__local__path__watcher.cc +++ b/www/chromium/files/patch-content_browser_file__system__access_file__system__access__local__path__watcher.cc @@ -1,11 +1,11 @@ ---- content/browser/file_system_access/file_system_access_local_path_watcher.cc.orig 2023-11-03 10:09:45 UTC +--- content/browser/file_system_access/file_system_access_local_path_watcher.cc.orig 2025-01-15 09:18:26 UTC +++ content/browser/file_system_access/file_system_access_local_path_watcher.cc -@@ -63,7 +63,7 @@ void FileSystemAccessLocalPathWatcher::Initialize( - base::FilePathWatcher::WatchOptions watch_options { - .type = scope().IsRecursive() ? base::FilePathWatcher::Type::kRecursive - : base::FilePathWatcher::Type::kNonRecursive, --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Note: `report_modified_path` is also present on Android - // and Fuchsia. Update this switch if support for watching - // the local file system is added on those platforms. +@@ -67,7 +67,7 @@ void FileSystemAccessLocalPathWatcher::Initialize( + .type = scope().IsRecursive() ? FilePathWatcher::Type::kRecursive + : FilePathWatcher::Type::kNonRecursive, + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + // Note: `report_modified_path` is also present on Android + // and Fuchsia. Update this switch if support for watching + // the local file system is added on those platforms. diff --git a/www/chromium/files/patch-content_browser_gpu_compositor__util.cc b/www/chromium/files/patch-content_browser_gpu_compositor__util.cc index d9084c632939..b74c9a0a6e43 100644 --- a/www/chromium/files/patch-content_browser_gpu_compositor__util.cc +++ b/www/chromium/files/patch-content_browser_gpu_compositor__util.cc @@ -1,20 +1,20 @@ ---- content/browser/gpu/compositor_util.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/gpu/compositor_util.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/gpu/compositor_util.cc -@@ -149,7 +149,7 @@ std::vector<GpuFeatureData> GetGpuFeatureData( +@@ -143,7 +143,7 @@ std::vector<GpuFeatureData> GetGpuFeatureData( "video_decode", SafeGetFeatureStatus( gpu_feature_info, gpu::GPU_FEATURE_TYPE_ACCELERATED_VIDEO_DECODE, -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - !base::FeatureList::IsEnabled(media::kVaapiVideoDecodeLinux) || + !base::FeatureList::IsEnabled(media::kAcceleratedVideoDecodeLinux) || #endif // BUILDFLAG(IS_LINUX) command_line.HasSwitch(switches::kDisableAcceleratedVideoDecode)), -@@ -161,7 +161,7 @@ std::vector<GpuFeatureData> GetGpuFeatureData( +@@ -155,7 +155,7 @@ std::vector<GpuFeatureData> GetGpuFeatureData( "video_encode", SafeGetFeatureStatus( gpu_feature_info, gpu::GPU_FEATURE_TYPE_ACCELERATED_VIDEO_ENCODE, -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - !base::FeatureList::IsEnabled(media::kVaapiVideoEncodeLinux)), + !base::FeatureList::IsEnabled(media::kAcceleratedVideoEncodeLinux)), #else command_line.HasSwitch(switches::kDisableAcceleratedVideoEncode)), diff --git a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.cc b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.cc index f7c90c69ea55..f31c238f49f0 100644 --- a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.cc +++ b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.cc @@ -1,6 +1,6 @@ ---- content/browser/gpu/gpu_data_manager_impl.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/gpu/gpu_data_manager_impl.cc.orig 2025-05-05 10:57:53 UTC +++ content/browser/gpu/gpu_data_manager_impl.cc -@@ -394,7 +394,7 @@ void GpuDataManagerImpl::OnDisplayMetricsChanged( +@@ -412,7 +412,7 @@ void GpuDataManagerImpl::OnDisplayMetricsChanged( private_->OnDisplayMetricsChanged(display, changed_metrics); } diff --git a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.h b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.h index a9f6b6851ab3..c23acf32e286 100644 --- a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.h +++ b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl.h @@ -1,11 +1,11 @@ ---- content/browser/gpu/gpu_data_manager_impl.h.orig 2024-04-19 13:02:56 UTC +--- content/browser/gpu/gpu_data_manager_impl.h.orig 2025-07-02 06:08:04 UTC +++ content/browser/gpu/gpu_data_manager_impl.h -@@ -217,7 +217,7 @@ class CONTENT_EXPORT GpuDataManagerImpl : public GpuDa +@@ -225,7 +225,7 @@ class CONTENT_EXPORT GpuDataManagerImpl : public GpuDa void OnDisplayMetricsChanged(const display::Display& display, uint32_t changed_metrics) override; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool IsGpuMemoryBufferNV12Supported(); - void SetGpuMemoryBufferNV12Supported(bool supported); #endif // BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.cc b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.cc index da4369a9a95f..6a3bf2832a78 100644 --- a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.cc +++ b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.cc @@ -1,11 +1,11 @@ ---- content/browser/gpu/gpu_data_manager_impl_private.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/gpu/gpu_data_manager_impl_private.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/gpu/gpu_data_manager_impl_private.cc -@@ -1673,7 +1673,7 @@ void GpuDataManagerImplPrivate::RecordCompositingMode( +@@ -1696,7 +1696,7 @@ void GpuDataManagerImplPrivate::RecordCompositingMode( UMA_HISTOGRAM_ENUMERATION("GPU.CompositingMode", compositing_mode); } -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool GpuDataManagerImplPrivate::IsGpuMemoryBufferNV12Supported() { - return is_gpu_memory_buffer_NV12_supported_; + return gpu_extra_info_.is_gmb_nv12_supported; } diff --git a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.h b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.h index 7e878d710b14..5e6993cbb4bc 100644 --- a/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.h +++ b/www/chromium/files/patch-content_browser_gpu_gpu__data__manager__impl__private.h @@ -1,4 +1,4 @@ ---- content/browser/gpu/gpu_data_manager_impl_private.h.orig 2024-04-19 13:02:56 UTC +--- content/browser/gpu/gpu_data_manager_impl_private.h.orig 2025-07-02 06:08:04 UTC +++ content/browser/gpu/gpu_data_manager_impl_private.h @@ -149,7 +149,7 @@ class CONTENT_EXPORT GpuDataManagerImplPrivate { void OnDisplayMetricsChanged(const display::Display& display, @@ -7,9 +7,9 @@ -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool IsGpuMemoryBufferNV12Supported(); - void SetGpuMemoryBufferNV12Supported(bool supported); #endif // BUILDFLAG(IS_LINUX) -@@ -301,7 +301,7 @@ class CONTENT_EXPORT GpuDataManagerImplPrivate { + +@@ -312,7 +312,7 @@ class CONTENT_EXPORT GpuDataManagerImplPrivate { bool application_is_visible_ = true; bool disable_gpu_compositing_ = false; @@ -17,4 +17,4 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) bool is_gpu_memory_buffer_NV12_supported_ = false; #endif // BUILDFLAG(IS_LINUX) - }; + diff --git a/www/chromium/files/patch-content_browser_gpu_gpu__memory__buffer__manager__singleton.cc b/www/chromium/files/patch-content_browser_gpu_gpu__memory__buffer__manager__singleton.cc deleted file mode 100644 index 02b9cbae7b8f..000000000000 --- a/www/chromium/files/patch-content_browser_gpu_gpu__memory__buffer__manager__singleton.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- content/browser/gpu/gpu_memory_buffer_manager_singleton.cc.orig 2024-02-23 21:04:38 UTC -+++ content/browser/gpu/gpu_memory_buffer_manager_singleton.cc -@@ -54,7 +54,7 @@ scoped_refptr<base::SingleThreadTaskRunner> GetTaskRun - #endif - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - bool IsGpuMemoryBufferNV12Supported() { - static bool is_computed = false; - static bool supported = false; -@@ -117,7 +117,7 @@ void GpuMemoryBufferManagerSingleton::OnGpuExtraInfoUp - SetNativeConfigurations(std::move(configs)); - } - #endif // BUILDFLAG(IS_OZONE_X11) --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Dynamic check whether the NV12 format is supported as it may be - // inconsistent between the system GBM (Generic Buffer Management) and - // chromium miniGBM. diff --git a/www/chromium/files/patch-content_browser_gpu_gpu__process__host.cc b/www/chromium/files/patch-content_browser_gpu_gpu__process__host.cc index f3ec73f9128b..5d31ab2094d2 100644 --- a/www/chromium/files/patch-content_browser_gpu_gpu__process__host.cc +++ b/www/chromium/files/patch-content_browser_gpu_gpu__process__host.cc @@ -1,16 +1,16 @@ ---- content/browser/gpu/gpu_process_host.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/gpu/gpu_process_host.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/gpu/gpu_process_host.cc -@@ -264,6 +264,7 @@ static const char* const kSwitchNames[] = { - switches::kEnableLowEndDeviceMode, +@@ -274,6 +274,7 @@ static const char* const kSwitchNames[] = { switches::kDisableSkiaGraphite, + switches::kDisableSkiaGraphitePrecompilation, switches::kDisableLowEndDeviceMode, + switches::kDisableUnveil, switches::kProfilingAtStart, switches::kProfilingFile, switches::kProfilingFlush, -@@ -290,7 +291,7 @@ static const char* const kSwitchNames[] = { - switches::kDisableExplicitDmaFences, - switches::kOzoneDumpFile, +@@ -302,7 +303,7 @@ static const char* const kSwitchNames[] = { + switches::kEnableNativeGpuMemoryBuffers, + switches::kRenderNodeOverride, #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-content_browser_media_frameless__media__interface__proxy.h b/www/chromium/files/patch-content_browser_media_frameless__media__interface__proxy.h index c3269a9e39de..479feb625a2e 100644 --- a/www/chromium/files/patch-content_browser_media_frameless__media__interface__proxy.h +++ b/www/chromium/files/patch-content_browser_media_frameless__media__interface__proxy.h @@ -1,4 +1,4 @@ ---- content/browser/media/frameless_media_interface_proxy.h.orig 2022-10-24 13:33:33 UTC +--- content/browser/media/frameless_media_interface_proxy.h.orig 2025-05-28 14:55:43 UTC +++ content/browser/media/frameless_media_interface_proxy.h @@ -19,7 +19,7 @@ #include "mojo/public/cpp/bindings/receiver_set.h" @@ -6,15 +6,15 @@ -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "media/mojo/mojom/stable/stable_video_decoder.mojom.h" + #include "media/mojo/mojom/video_decoder.mojom.h" #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -100,7 +100,7 @@ class FramelessMediaInterfaceProxy final +@@ -98,7 +98,7 @@ class FramelessMediaInterfaceProxy final // Connections to the renderer. mojo::ReceiverSet<media::mojom::InterfaceFactory> receivers_; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Connection to the StableVideoDecoderFactory that lives in a utility - // process. This is only used for out-of-process video decoding and only when - // the FramelessMediaInterfaceProxy is created without a RenderProcessHost + // Connection to the InterfaceFactory that lives in a utility process. + // This is only used for out-of-process video decoding and only when the + // FramelessMediaInterfaceProxy is created without a RenderProcessHost diff --git a/www/chromium/files/patch-content_browser_media_media__keys__listener__manager__impl.cc b/www/chromium/files/patch-content_browser_media_media__keys__listener__manager__impl.cc index d3eba0b54393..6e2749f0a835 100644 --- a/www/chromium/files/patch-content_browser_media_media__keys__listener__manager__impl.cc +++ b/www/chromium/files/patch-content_browser_media_media__keys__listener__manager__impl.cc @@ -1,11 +1,11 @@ ---- content/browser/media/media_keys_listener_manager_impl.cc.orig 2024-03-22 08:19:40 UTC +--- content/browser/media/media_keys_listener_manager_impl.cc.orig 2025-02-19 07:43:18 UTC +++ content/browser/media/media_keys_listener_manager_impl.cc -@@ -334,7 +334,7 @@ void MediaKeysListenerManagerImpl::StartListeningForMe +@@ -332,7 +332,7 @@ void MediaKeysListenerManagerImpl::StartListeningForMe + return; } - #if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || \ -- BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) // Create SystemMediaControls with the SingletonHwnd. browser_system_media_controls_ = system_media_controls::SystemMediaControls::Create( diff --git a/www/chromium/files/patch-content_browser_network__service__instance__impl.cc b/www/chromium/files/patch-content_browser_network__service__instance__impl.cc index 352984aa5db6..74bcc08b0254 100644 --- a/www/chromium/files/patch-content_browser_network__service__instance__impl.cc +++ b/www/chromium/files/patch-content_browser_network__service__instance__impl.cc @@ -1,6 +1,6 @@ ---- content/browser/network_service_instance_impl.cc.orig 2024-01-30 07:53:34 UTC +--- content/browser/network_service_instance_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/network_service_instance_impl.cc -@@ -81,7 +81,7 @@ +@@ -85,7 +85,7 @@ #include "content/browser/network/network_service_process_tracker_win.h" #endif @@ -9,7 +9,7 @@ #include "content/browser/system_dns_resolution/system_dns_resolver.h" #include "services/network/public/mojom/system_dns_resolution.mojom-forward.h" #endif -@@ -359,7 +359,7 @@ void CreateInProcessNetworkService( +@@ -335,7 +335,7 @@ void CreateInProcessNetworkService( std::move(receiver))); } @@ -18,7 +18,7 @@ // Runs a self-owned SystemDnsResolverMojoImpl. This is meant to run on a // high-priority thread pool. void RunSystemDnsResolverOnThreadPool( -@@ -428,7 +428,7 @@ network::mojom::NetworkServiceParamsPtr CreateNetworkS +@@ -402,7 +402,7 @@ network::mojom::NetworkServiceParamsPtr CreateNetworkS } #endif // BUILDFLAG(IS_POSIX) diff --git a/www/chromium/files/patch-content_browser_renderer__host_delegated__frame__host.cc b/www/chromium/files/patch-content_browser_renderer__host_delegated__frame__host.cc index d833c8e5f7d5..8acfad0fb7eb 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_delegated__frame__host.cc +++ b/www/chromium/files/patch-content_browser_renderer__host_delegated__frame__host.cc @@ -1,11 +1,11 @@ ---- content/browser/renderer_host/delegated_frame_host.cc.orig 2024-03-22 08:19:40 UTC +--- content/browser/renderer_host/delegated_frame_host.cc.orig 2025-05-05 10:57:53 UTC +++ content/browser/renderer_host/delegated_frame_host.cc -@@ -318,7 +318,7 @@ void DelegatedFrameHost::EmbedSurface( +@@ -333,7 +333,7 @@ void DelegatedFrameHost::EmbedSurface( if (!primary_surface_id || primary_surface_id->local_surface_id() != local_surface_id_) { --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // On Windows and Linux, we would like to produce new content as soon as // possible or the OS will create an additional black gutter. Until we can // block resize on surface synchronization on these platforms, we will not diff --git a/www/chromium/files/patch-content_browser_renderer__host_media_service__video__capture__device__launcher.cc b/www/chromium/files/patch-content_browser_renderer__host_media_service__video__capture__device__launcher.cc index 8d485438562e..967501873d0b 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_media_service__video__capture__device__launcher.cc +++ b/www/chromium/files/patch-content_browser_renderer__host_media_service__video__capture__device__launcher.cc @@ -1,6 +1,6 @@ ---- content/browser/renderer_host/media/service_video_capture_device_launcher.cc.orig 2023-12-10 06:10:27 UTC +--- content/browser/renderer_host/media/service_video_capture_device_launcher.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/renderer_host/media/service_video_capture_device_launcher.cc -@@ -25,7 +25,7 @@ +@@ -29,7 +29,7 @@ #include "media/base/media_switches.h" #endif @@ -9,7 +9,7 @@ #include "content/browser/gpu/gpu_data_manager_impl.h" #endif -@@ -172,7 +172,7 @@ void ServiceVideoCaptureDeviceLauncher::LaunchDeviceAs +@@ -188,7 +188,7 @@ void ServiceVideoCaptureDeviceLauncher::LaunchDeviceAs } #else if (switches::IsVideoCaptureUseGpuMemoryBufferEnabled()) { diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.cc b/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.cc index 93e6ac80fc40..d095f6398b2d 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.cc +++ b/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.cc @@ -1,6 +1,6 @@ ---- content/browser/renderer_host/render_process_host_impl.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/renderer_host/render_process_host_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/renderer_host/render_process_host_impl.cc -@@ -225,7 +225,7 @@ +@@ -222,7 +222,7 @@ #include "third_party/blink/public/mojom/android_font_lookup/android_font_lookup.mojom.h" #endif @@ -9,7 +9,7 @@ #include <sys/resource.h> #include "components/services/font/public/mojom/font_service.mojom.h" // nogncheck -@@ -967,7 +967,7 @@ static constexpr size_t kUnknownPlatformProcessLimit = +@@ -1126,7 +1126,7 @@ static constexpr size_t kUnknownPlatformProcessLimit = // to indicate failure and std::numeric_limits<size_t>::max() to indicate // unlimited. size_t GetPlatformProcessLimit() { @@ -18,34 +18,16 @@ struct rlimit limit; if (getrlimit(RLIMIT_NPROC, &limit) != 0) return kUnknownPlatformProcessLimit; -@@ -1149,7 +1149,7 @@ class RenderProcessHostImpl::IOThreadHostImpl : public - IOThreadHostImpl& operator=(const IOThreadHostImpl& other) = delete; +@@ -1333,7 +1333,7 @@ RenderProcessHostImpl::IOThreadHostImpl::~IOThreadHost - void SetPid(base::ProcessId child_pid) { + void RenderProcessHostImpl::IOThreadHostImpl::SetPid( + base::ProcessId child_pid) { -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - child_thread_type_switcher_.SetPid(child_pid); + child_thread_type_switcher_.SetPid(child_pid); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - } -@@ -1166,7 +1166,7 @@ class RenderProcessHostImpl::IOThreadHostImpl : public - return; - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (auto font_receiver = receiver.As<font_service::mojom::FontService>()) { - ConnectToFontService(std::move(font_receiver)); - return; -@@ -1260,7 +1260,7 @@ class RenderProcessHostImpl::IOThreadHostImpl : public - std::unique_ptr<service_manager::BinderRegistry> binders_; - mojo::Receiver<mojom::ChildProcessHost> receiver_{this}; - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - mojo::Remote<media::mojom::VideoEncodeAcceleratorProviderFactory> - video_encode_accelerator_factory_remote_; - ChildThreadTypeSwitcher child_thread_type_switcher_; -@@ -3353,7 +3353,7 @@ void RenderProcessHostImpl::AppendRendererCommandLine( + } +@@ -3426,7 +3426,7 @@ void RenderProcessHostImpl::AppendRendererCommandLine( base::TimeTicks::UnixEpoch().since_origin().InMicroseconds())); } @@ -54,11 +36,20 @@ // Append `kDisableVideoCaptureUseGpuMemoryBuffer` flag if there is no support // for NV12 GPU memory buffer. if (switches::IsVideoCaptureUseGpuMemoryBufferEnabled() && -@@ -3412,6 +3412,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLin - switches::kDisableSpeechAPI, - switches::kDisableThreadedCompositing, - switches::kDisableTouchDragDrop, -+ switches::kDisableUnveil, - switches::kDisableV8IdleTasks, - switches::kDisableVideoCaptureUseGpuMemoryBuffer, - switches::kDisableWebGLImageChromium, +@@ -3480,6 +3480,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLin + switches::kDisableSkiaRuntimeOpts, + switches::kDisableSpeechAPI, + switches::kDisableThreadedCompositing, ++ switches::kDisableUnveil, + switches::kDisableV8IdleTasks, + switches::kDisableVideoCaptureUseGpuMemoryBuffer, + switches::kDisableWebGLImageChromium, +@@ -5329,7 +5330,7 @@ uint64_t RenderProcessHostImpl::GetPrivateMemoryFootpr + // - Win: https://crbug.com/707022 . + uint64_t total_size = 0; + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ +- BUILDFLAG(IS_FUCHSIA) ++ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + total_size = dump->platform_private_footprint->rss_anon_bytes + + dump->platform_private_footprint->vm_swap_bytes; + #elif BUILDFLAG(IS_APPLE) diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.h b/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.h index b37628f18aaf..131fa6beb0c6 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.h +++ b/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl.h @@ -1,11 +1,29 @@ ---- content/browser/renderer_host/render_process_host_impl.h.orig 2024-03-22 08:19:40 UTC +--- content/browser/renderer_host/render_process_host_impl.h.orig 2025-07-02 06:08:04 UTC +++ content/browser/renderer_host/render_process_host_impl.h -@@ -548,7 +548,7 @@ class CONTENT_EXPORT RenderProcessHostImpl - // Sets this RenderProcessHost to be guest only. For Testing only. - void SetForGuestsOnlyForTesting(); +@@ -101,7 +101,7 @@ + #include "media/fuchsia_media_codec_provider_impl.h" + #endif --#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_BSD) - // Launch the zygote early in the browser startup. - static void EarlyZygoteLaunch(); - #endif // BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_MAC) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "content/browser/child_thread_type_switcher_linux.h" + #include "media/mojo/mojom/video_encode_accelerator.mojom.h" + #endif +@@ -995,7 +995,7 @@ class CONTENT_EXPORT RenderProcessHostImpl + mojo::Remote<media::mojom::VideoEncodeAcceleratorProviderFactory> + video_encode_accelerator_factory_remote_; + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + ChildThreadTypeSwitcher child_thread_type_switcher_; + #endif + }; +@@ -1238,7 +1238,7 @@ class CONTENT_EXPORT RenderProcessHostImpl + // if the request isn't handled on the IO thread. + void OnBindHostReceiver(mojo::GenericPendingReceiver receiver); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Provides /proc/{renderer pid}/status and statm files for the renderer, + // because the files are required to calculate the renderer's private + // footprint on Chromium Linux. Regarding MacOS X and Windows, we have diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl__receiver__bindings.cc b/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl__receiver__bindings.cc new file mode 100644 index 000000000000..2a44264eb401 --- /dev/null +++ b/www/chromium/files/patch-content_browser_renderer__host_render__process__host__impl__receiver__bindings.cc @@ -0,0 +1,29 @@ +--- content/browser/renderer_host/render_process_host_impl_receiver_bindings.cc.orig 2025-07-02 06:08:04 UTC ++++ content/browser/renderer_host/render_process_host_impl_receiver_bindings.cc +@@ -51,7 +51,7 @@ + #include "third_party/blink/public/mojom/android_font_lookup/android_font_lookup.mojom.h" + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "components/services/font/public/mojom/font_service.mojom.h" // nogncheck + #include "content/browser/font_service.h" // nogncheck + #endif +@@ -336,7 +336,7 @@ void RenderProcessHostImpl::IOThreadHostImpl::BindHost + } + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (auto font_receiver = receiver.As<font_service::mojom::FontService>()) { + ConnectToFontService(std::move(font_receiver)); + return; +@@ -364,7 +364,7 @@ void RenderProcessHostImpl::IOThreadHostImpl::BindHost + } + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (auto r = receiver.As<mojom::ThreadTypeSwitcher>()) { + child_thread_type_switcher_.Bind(std::move(r)); + return; diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__view__host__impl.cc b/www/chromium/files/patch-content_browser_renderer__host_render__view__host__impl.cc index a018ade93ce6..a8bb5458fa6e 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_render__view__host__impl.cc +++ b/www/chromium/files/patch-content_browser_renderer__host_render__view__host__impl.cc @@ -1,9 +1,9 @@ ---- content/browser/renderer_host/render_view_host_impl.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/renderer_host/render_view_host_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/browser/renderer_host/render_view_host_impl.cc -@@ -272,7 +272,7 @@ void RenderViewHostImpl::GetPlatformSpecificPrefs( - display::win::ScreenWin::GetSystemMetricsInDIP(SM_CYVSCROLL); +@@ -271,7 +271,7 @@ void RenderViewHostImpl::GetPlatformSpecificPrefs( + display::win::GetScreenWin()->GetSystemMetricsInDIP(SM_CYVSCROLL); prefs->arrow_bitmap_width_horizontal_scroll_bar_in_dips = - display::win::ScreenWin::GetSystemMetricsInDIP(SM_CXHSCROLL); + display::win::GetScreenWin()->GetSystemMetricsInDIP(SM_CXHSCROLL); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.cc b/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.cc index fb935548bb16..1b7d1a082985 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.cc +++ b/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.cc @@ -1,25 +1,25 @@ ---- content/browser/renderer_host/render_widget_host_view_aura.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/renderer_host/render_widget_host_view_aura.cc.orig 2025-05-05 10:57:53 UTC +++ content/browser/renderer_host/render_widget_host_view_aura.cc -@@ -119,7 +119,7 @@ +@@ -121,7 +121,7 @@ #include "ui/gfx/gdi_util.h" - #endif + #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "content/browser/accessibility/browser_accessibility_auralinux.h" + #include "ui/accessibility/platform/browser_accessibility_auralinux.h" #include "ui/base/ime/linux/text_edit_command_auralinux.h" #include "ui/base/ime/text_input_flags.h" -@@ -452,7 +452,7 @@ gfx::NativeViewAccessible RenderWidgetHostViewAura::Ge +@@ -478,7 +478,7 @@ gfx::NativeViewAccessible RenderWidgetHostViewAura::Ge return ToBrowserAccessibilityWin(manager->GetBrowserAccessibilityRoot()) ->GetCOM(); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - BrowserAccessibilityManager* manager = + ui::BrowserAccessibilityManager* manager = host()->GetOrCreateRootBrowserAccessibilityManager(); if (manager && manager->GetBrowserAccessibilityRoot()) -@@ -1705,7 +1705,7 @@ bool RenderWidgetHostViewAura::ShouldDoLearning() { - return host_->delegate() && host_->delegate()->ShouldDoLearning(); +@@ -1882,7 +1882,7 @@ bool RenderWidgetHostViewAura::ShouldDoLearning() { + return host() && host()->delegate() && host()->delegate()->ShouldDoLearning(); } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -27,21 +27,21 @@ bool RenderWidgetHostViewAura::SetCompositionFromExistingText( const gfx::Range& range, const std::vector<ui::ImeTextSpan>& ui_ime_text_spans) { -@@ -2538,7 +2538,7 @@ bool RenderWidgetHostViewAura::NeedsInputGrab() { +@@ -2858,7 +2858,7 @@ bool RenderWidgetHostViewAura::NeedsInputGrab() { } bool RenderWidgetHostViewAura::NeedsMouseCapture() { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return NeedsInputGrab(); #else return false; -@@ -2722,7 +2722,7 @@ void RenderWidgetHostViewAura::ForwardKeyboardEventWit +@@ -3042,7 +3042,7 @@ void RenderWidgetHostViewAura::ForwardKeyboardEventWit if (!target_host) return; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) auto* linux_ui = ui::LinuxUi::instance(); - std::vector<ui::TextEditCommandAuraLinux> commands; - if (!event.skip_if_unhandled && linux_ui && event.os_event && + if (!event.skip_if_unhandled && linux_ui && event.os_event) { + const auto command = linux_ui->GetTextEditCommandForEvent( diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.h b/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.h index ad519c87a011..e56bbd807bda 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.h +++ b/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__aura.h @@ -1,6 +1,6 @@ ---- content/browser/renderer_host/render_widget_host_view_aura.h.orig 2024-04-19 13:02:56 UTC +--- content/browser/renderer_host/render_widget_host_view_aura.h.orig 2025-03-05 08:14:56 UTC +++ content/browser/renderer_host/render_widget_host_view_aura.h -@@ -259,7 +259,7 @@ class CONTENT_EXPORT RenderWidgetHostViewAura +@@ -276,7 +276,7 @@ class CONTENT_EXPORT RenderWidgetHostViewAura ukm::SourceId GetClientSourceForMetrics() const override; bool ShouldDoLearning() override; diff --git a/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__event__handler.cc b/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__event__handler.cc index 0066af0e5bc4..c910ef23142c 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__event__handler.cc +++ b/www/chromium/files/patch-content_browser_renderer__host_render__widget__host__view__event__handler.cc @@ -1,7 +1,7 @@ ---- content/browser/renderer_host/render_widget_host_view_event_handler.cc.orig 2024-01-30 07:53:34 UTC +--- content/browser/renderer_host/render_widget_host_view_event_handler.cc.orig 2024-08-26 12:06:38 UTC +++ content/browser/renderer_host/render_widget_host_view_event_handler.cc -@@ -599,7 +599,7 @@ bool RenderWidgetHostViewEventHandler::CanRendererHand - if (event->type() == ui::ET_MOUSE_EXITED) { +@@ -602,7 +602,7 @@ bool RenderWidgetHostViewEventHandler::CanRendererHand + if (event->type() == ui::EventType::kMouseExited) { if (mouse_locked || selection_popup) return false; -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-content_browser_scheduler_responsiveness_jank__monitor__impl.cc b/www/chromium/files/patch-content_browser_scheduler_responsiveness_jank__monitor__impl.cc index 2c45b03fb15d..3bd2c92c011d 100644 --- a/www/chromium/files/patch-content_browser_scheduler_responsiveness_jank__monitor__impl.cc +++ b/www/chromium/files/patch-content_browser_scheduler_responsiveness_jank__monitor__impl.cc @@ -1,11 +1,11 @@ ---- content/browser/scheduler/responsiveness/jank_monitor_impl.cc.orig 2023-08-17 07:33:31 UTC +--- content/browser/scheduler/responsiveness/jank_monitor_impl.cc.orig 2025-03-05 08:14:56 UTC +++ content/browser/scheduler/responsiveness/jank_monitor_impl.cc -@@ -340,7 +340,7 @@ void JankMonitorImpl::ThreadExecutionState::DidRunTask +@@ -337,7 +337,7 @@ void JankMonitorImpl::ThreadExecutionState::DidRunTask // in context menus, among others). Simply ignore the mismatches for now. // See https://crbug.com/929813 for the details of why the mismatch // happens. --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) && \ - BUILDFLAG(IS_OZONE) +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE) task_execution_metadata_.clear(); #endif + return; diff --git a/www/chromium/files/patch-content_browser_service__host_utility__process__host.cc b/www/chromium/files/patch-content_browser_service__host_utility__process__host.cc new file mode 100644 index 000000000000..dcf5437a0601 --- /dev/null +++ b/www/chromium/files/patch-content_browser_service__host_utility__process__host.cc @@ -0,0 +1,38 @@ +--- content/browser/service_host/utility_process_host.cc.orig 2025-07-02 06:08:04 UTC ++++ content/browser/service_host/utility_process_host.cc +@@ -68,7 +68,7 @@ + #include "content/browser/v8_snapshot_files.h" + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "base/files/file_util.h" + #include "base/files/scoped_file.h" + #include "base/pickle.h" +@@ -96,7 +96,7 @@ namespace content { + + namespace { + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + base::ScopedFD PassNetworkContextParentDirs( + std::vector<base::FilePath> network_context_parent_dirs) { + base::Pickle pickle; +@@ -491,7 +491,7 @@ bool UtilityProcessHost::StartProcess() { + GetV8SnapshotFilesToPreload(*cmd_line)); + #endif // BUILDFLAG(IS_POSIX) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // The network service should have access to the parent directories + // necessary for its usage. + if (options_.sandbox_type_ == sandbox::mojom::Sandbox::kNetwork) { +@@ -509,7 +509,7 @@ bool UtilityProcessHost::StartProcess() { + video_capture::mojom::VideoCaptureService::Name_) { + bool pass_gpu_buffer_flag = + switches::IsVideoCaptureUseGpuMemoryBufferEnabled(); +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Check if NV12 GPU memory buffer supported at the same time. + pass_gpu_buffer_flag = + pass_gpu_buffer_flag && diff --git a/www/chromium/files/patch-content_browser_service__host_utility__process__host__receiver__bindings.cc b/www/chromium/files/patch-content_browser_service__host_utility__process__host__receiver__bindings.cc new file mode 100644 index 000000000000..c436cbec54a6 --- /dev/null +++ b/www/chromium/files/patch-content_browser_service__host_utility__process__host__receiver__bindings.cc @@ -0,0 +1,20 @@ +--- content/browser/service_host/utility_process_host_receiver_bindings.cc.orig 2025-04-04 08:52:13 UTC ++++ content/browser/service_host/utility_process_host_receiver_bindings.cc +@@ -10,7 +10,7 @@ + #include "content/public/common/content_client.h" + #include "media/media_buildflags.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "components/services/font/public/mojom/font_service.mojom.h" // nogncheck + #include "content/browser/font_service.h" // nogncheck + #endif +@@ -24,7 +24,7 @@ namespace content { + + void UtilityProcessHost::BindHostReceiver( + mojo::GenericPendingReceiver receiver) { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (auto font_receiver = receiver.As<font_service::mojom::FontService>()) { + ConnectToFontService(std::move(font_receiver)); + return; diff --git a/www/chromium/files/patch-content_browser_service__host_utility__sandbox__delegate.cc b/www/chromium/files/patch-content_browser_service__host_utility__sandbox__delegate.cc new file mode 100644 index 000000000000..0956ff8d29f0 --- /dev/null +++ b/www/chromium/files/patch-content_browser_service__host_utility__sandbox__delegate.cc @@ -0,0 +1,34 @@ +--- content/browser/service_host/utility_sandbox_delegate.cc.orig 2025-07-02 06:08:04 UTC ++++ content/browser/service_host/utility_sandbox_delegate.cc +@@ -91,14 +91,14 @@ UtilitySandboxedProcessLauncherDelegate:: + #endif // BUILDFLAG(ENABLE_CROS_LIBASSISTANT) + #endif // BUILDFLAG(IS_CHROMEOS) + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + sandbox_type_ == sandbox::mojom::Sandbox::kScreenAI || + sandbox_type_ == sandbox::mojom::Sandbox::kPrintBackend || + #endif +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + sandbox_type_ == sandbox::mojom::Sandbox::kVideoEffects || + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + sandbox_type_ == sandbox::mojom::Sandbox::kOnDeviceTranslation || + #endif + sandbox_type_ == sandbox::mojom::Sandbox::kAudio || +@@ -159,11 +159,11 @@ ZygoteCommunication* UtilitySandboxedProcessLauncherDe + #endif // BUILDFLAG(IS_CHROMEOS) + sandbox_type_ == sandbox::mojom::Sandbox::kAudio || + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + sandbox_type_ == sandbox::mojom::Sandbox::kPrintBackend || + sandbox_type_ == sandbox::mojom::Sandbox::kScreenAI || + #endif +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + sandbox_type_ == sandbox::mojom::Sandbox::kVideoEffects || + sandbox_type_ == sandbox::mojom::Sandbox::kOnDeviceTranslation || + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-content_browser_utility__process__host.cc b/www/chromium/files/patch-content_browser_utility__process__host.cc deleted file mode 100644 index 61d6657762f5..000000000000 --- a/www/chromium/files/patch-content_browser_utility__process__host.cc +++ /dev/null @@ -1,72 +0,0 @@ ---- content/browser/utility_process_host.cc.orig 2024-04-19 13:02:56 UTC -+++ content/browser/utility_process_host.cc -@@ -61,7 +61,7 @@ - #include "content/browser/v8_snapshot_files.h" - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "base/files/file_util.h" - #include "base/files/scoped_file.h" - #include "base/pickle.h" -@@ -75,7 +75,7 @@ - #include "services/network/public/mojom/network_service.mojom.h" - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "base/task/sequenced_task_runner.h" - #include "components/viz/host/gpu_client.h" - #include "media/capture/capture_switches.h" -@@ -86,7 +86,7 @@ namespace content { - - namespace { - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - base::ScopedFD PassNetworkContextParentDirs( - std::vector<base::FilePath> network_context_parent_dirs) { - base::Pickle pickle; -@@ -150,7 +150,7 @@ UtilityProcessHost::UtilityProcessHost(std::unique_ptr - started_(false), - name_(u"utility process"), - file_data_(std::make_unique<ChildProcessLauncherFileData>()), --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - allowed_gpu_(false), - gpu_client_(nullptr, base::OnTaskRunnerDeleter(nullptr)), - #endif -@@ -234,7 +234,7 @@ void UtilityProcessHost::SetPinUser32() { - #endif // BUILDFLAG(IS_WIN) - - void UtilityProcessHost::SetAllowGpuClient() { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - allowed_gpu_ = true; - #endif - } -@@ -434,7 +434,7 @@ bool UtilityProcessHost::StartProcess() { - file_data_->files_to_preload.merge(GetV8SnapshotFilesToPreload()); - #endif // BUILDFLAG(IS_POSIX) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // The network service should have access to the parent directories - // necessary for its usage. - if (sandbox_type_ == sandbox::mojom::Sandbox::kNetwork) { -@@ -445,13 +445,13 @@ bool UtilityProcessHost::StartProcess() { - } - #endif // BUILDFLAG(IS_LINUX) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - // Pass `kVideoCaptureUseGpuMemoryBuffer` flag to video capture service only - // when the video capture use GPU memory buffer enabled. - if (metrics_name_ == video_capture::mojom::VideoCaptureService::Name_) { - bool pass_gpu_buffer_flag = - switches::IsVideoCaptureUseGpuMemoryBufferEnabled(); --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Check if NV12 GPU memory buffer supported at the same time. - pass_gpu_buffer_flag = - pass_gpu_buffer_flag && diff --git a/www/chromium/files/patch-content_browser_utility__process__host.h b/www/chromium/files/patch-content_browser_utility__process__host.h deleted file mode 100644 index 5563360ffdb5..000000000000 --- a/www/chromium/files/patch-content_browser_utility__process__host.h +++ /dev/null @@ -1,20 +0,0 @@ ---- content/browser/utility_process_host.h.orig 2024-04-19 13:02:56 UTC -+++ content/browser/utility_process_host.h -@@ -39,7 +39,7 @@ namespace base { - class Thread; - } // namespace base - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - namespace viz { - class GpuClient; - } // namespace viz -@@ -228,7 +228,7 @@ class CONTENT_EXPORT UtilityProcessHost - std::vector<RunServiceDeprecatedCallback> pending_run_service_callbacks_; - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - bool allowed_gpu_; - std::unique_ptr<viz::GpuClient, base::OnTaskRunnerDeleter> gpu_client_; - #endif diff --git a/www/chromium/files/patch-content_browser_utility__process__host__receiver__bindings.cc b/www/chromium/files/patch-content_browser_utility__process__host__receiver__bindings.cc deleted file mode 100644 index 01d070d67677..000000000000 --- a/www/chromium/files/patch-content_browser_utility__process__host__receiver__bindings.cc +++ /dev/null @@ -1,33 +0,0 @@ ---- content/browser/utility_process_host_receiver_bindings.cc.orig 2024-04-19 13:02:56 UTC -+++ content/browser/utility_process_host_receiver_bindings.cc -@@ -10,12 +10,12 @@ - #include "content/public/browser/content_browser_client.h" - #include "content/public/common/content_client.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "components/services/font/public/mojom/font_service.mojom.h" // nogncheck - #include "content/browser/font_service.h" // nogncheck - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "components/viz/host/gpu_client.h" - #include "content/public/browser/gpu_client.h" - #endif -@@ -24,13 +24,13 @@ namespace content { - - void UtilityProcessHost::BindHostReceiver( - mojo::GenericPendingReceiver receiver) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (auto font_receiver = receiver.As<font_service::mojom::FontService>()) { - ConnectToFontService(std::move(font_receiver)); - return; - } - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - if (allowed_gpu_) { - // TODO(crbug.com/328099369) Remove once all clients get this directly. - if (auto gpu_receiver = receiver.As<viz::mojom::Gpu>()) { diff --git a/www/chromium/files/patch-content_browser_utility__sandbox__delegate.cc b/www/chromium/files/patch-content_browser_utility__sandbox__delegate.cc deleted file mode 100644 index a5906276e719..000000000000 --- a/www/chromium/files/patch-content_browser_utility__sandbox__delegate.cc +++ /dev/null @@ -1,28 +0,0 @@ ---- content/browser/utility_sandbox_delegate.cc.orig 2024-01-30 07:53:34 UTC -+++ content/browser/utility_sandbox_delegate.cc -@@ -67,10 +67,10 @@ UtilitySandboxedProcessLauncherDelegate:: - #if BUILDFLAG(IS_FUCHSIA) - sandbox_type_ == sandbox::mojom::Sandbox::kVideoCapture || - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - sandbox_type_ == sandbox::mojom::Sandbox::kHardwareVideoDecoding || - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - sandbox_type_ == sandbox::mojom::Sandbox::kHardwareVideoEncoding || - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - #if BUILDFLAG(IS_CHROMEOS_ASH) -@@ -126,10 +126,10 @@ ZygoteCommunication* UtilitySandboxedProcessLauncherDe - // process upon startup. - if (sandbox_type_ == sandbox::mojom::Sandbox::kNetwork || - sandbox_type_ == sandbox::mojom::Sandbox::kOnDeviceModelExecution || --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - sandbox_type_ == sandbox::mojom::Sandbox::kHardwareVideoDecoding || - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - sandbox_type_ == sandbox::mojom::Sandbox::kHardwareVideoEncoding || - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - #if BUILDFLAG(IS_CHROMEOS_ASH) diff --git a/www/chromium/files/patch-content_browser_v8__snapshot__files.cc b/www/chromium/files/patch-content_browser_v8__snapshot__files.cc index e686f76f3ff1..3c2290a9ecae 100644 --- a/www/chromium/files/patch-content_browser_v8__snapshot__files.cc +++ b/www/chromium/files/patch-content_browser_v8__snapshot__files.cc @@ -1,9 +1,9 @@ ---- content/browser/v8_snapshot_files.cc.orig 2023-03-09 06:31:50 UTC +--- content/browser/v8_snapshot_files.cc.orig 2025-05-05 10:57:53 UTC +++ content/browser/v8_snapshot_files.cc -@@ -13,7 +13,7 @@ namespace content { - std::map<std::string, absl::variant<base::FilePath, base::ScopedFD>> - GetV8SnapshotFilesToPreload() { - std::map<std::string, absl::variant<base::FilePath, base::ScopedFD>> files; +@@ -19,7 +19,7 @@ namespace content { + std::map<std::string, std::variant<base::FilePath, base::ScopedFD>> + GetV8SnapshotFilesToPreload(base::CommandLine& process_command_line) { + std::map<std::string, std::variant<base::FilePath, base::ScopedFD>> files; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #if BUILDFLAG(USE_V8_CONTEXT_SNAPSHOT) diff --git a/www/chromium/files/patch-content_browser_renderer__host_input_input__device__change__observer.cc b/www/chromium/files/patch-content_browser_web__contents_slow__web__preference__cache.cc index 00e9275d7d0d..926156827508 100644 --- a/www/chromium/files/patch-content_browser_renderer__host_input_input__device__change__observer.cc +++ b/www/chromium/files/patch-content_browser_web__contents_slow__web__preference__cache.cc @@ -1,6 +1,6 @@ ---- content/browser/renderer_host/input/input_device_change_observer.cc.orig 2022-02-28 16:54:41 UTC -+++ content/browser/renderer_host/input/input_device_change_observer.cc -@@ -9,7 +9,7 @@ +--- content/browser/web_contents/slow_web_preference_cache.cc.orig 2025-02-19 07:43:18 UTC ++++ content/browser/web_contents/slow_web_preference_cache.cc +@@ -17,7 +17,7 @@ #if BUILDFLAG(IS_WIN) #include "ui/events/devices/input_device_observer_win.h" @@ -8,9 +8,9 @@ +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "ui/events/devices/device_data_manager.h" #elif BUILDFLAG(IS_ANDROID) - #include "ui/events/devices/input_device_observer_android.h" -@@ -21,7 +21,7 @@ InputDeviceChangeObserver::InputDeviceChangeObserver(R - render_view_host_impl_ = rvhi; + #include "ui/base/device_form_factor.h" +@@ -57,7 +57,7 @@ SlowWebPreferenceCache::SlowWebPreferenceCache() { + #if BUILDFLAG(IS_WIN) ui::InputDeviceObserverWin::GetInstance()->AddObserver(this); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -18,8 +18,8 @@ ui::DeviceDataManager::GetInstance()->AddObserver(this); #elif BUILDFLAG(IS_ANDROID) ui::InputDeviceObserverAndroid::GetInstance()->AddObserver(this); -@@ -31,7 +31,7 @@ InputDeviceChangeObserver::InputDeviceChangeObserver(R - InputDeviceChangeObserver::~InputDeviceChangeObserver() { +@@ -69,7 +69,7 @@ SlowWebPreferenceCache::SlowWebPreferenceCache() { + SlowWebPreferenceCache::~SlowWebPreferenceCache() { #if BUILDFLAG(IS_WIN) ui::InputDeviceObserverWin::GetInstance()->RemoveObserver(this); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura.cc b/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura.cc index d2b6094e510b..e5fd544f24da 100644 --- a/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura.cc +++ b/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura.cc @@ -1,6 +1,6 @@ ---- content/browser/web_contents/web_contents_view_aura.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/web_contents/web_contents_view_aura.cc.orig 2025-03-05 08:14:56 UTC +++ content/browser/web_contents/web_contents_view_aura.cc -@@ -174,7 +174,7 @@ class WebDragSourceAura : public content::WebContentsO +@@ -173,7 +173,7 @@ class WebDragSourceAura : public content::WebContentsO raw_ptr<aura::Window> window_; }; @@ -18,7 +18,7 @@ // We set the file contents before the URL because the URL also sets file // contents (to a .URL shortcut). We want to prefer file content data over // a shortcut so we add it first. -@@ -1330,7 +1330,7 @@ void WebContentsViewAura::OnMouseEvent(ui::MouseEvent* +@@ -1327,7 +1327,7 @@ void WebContentsViewAura::OnMouseEvent(ui::MouseEvent* // Linux window managers like to handle raise-on-click themselves. If we // raise-on-click manually, this may override user settings that prevent // focus-stealing. diff --git a/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura__unittest.cc b/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura__unittest.cc new file mode 100644 index 000000000000..a1d4cae882f8 --- /dev/null +++ b/www/chromium/files/patch-content_browser_web__contents_web__contents__view__aura__unittest.cc @@ -0,0 +1,74 @@ +--- content/browser/web_contents/web_contents_view_aura_unittest.cc.orig 2025-04-04 08:52:13 UTC ++++ content/browser/web_contents/web_contents_view_aura_unittest.cc +@@ -40,7 +40,7 @@ + #include "ui/base/dragdrop/os_exchange_data_provider_win.h" + #endif + +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE_X11) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE_X11) + #include "ui/base/x/selection_utils.h" + #include "ui/base/x/x11_os_exchange_data_provider.h" + #include "ui/gfx/x/atom_cache.h" +@@ -96,7 +96,7 @@ class TestDragDropClient : public aura::client::DragDr + drag_drop_data_ = std::move(data); + return DragOperation::kCopy; + } +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void UpdateDragImage(const gfx::ImageSkia& image, + const gfx::Vector2d& offset) override {} + #endif +@@ -231,7 +231,7 @@ TEST_F(WebContentsViewAuraTest, WebContentsDestroyedDu + ui::EF_LEFT_MOUSE_BUTTON, 0); + ui::EventHandler* event_handler = GetView(); + event_handler->OnMouseEvent(&mouse_event); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // The web-content is not activated during mouse-press on Linux. + // See comment in WebContentsViewAura::OnMouseEvent() for more details. + EXPECT_NE(web_contents(), nullptr); +@@ -297,7 +297,7 @@ TEST_F(WebContentsViewAuraTest, MAYBE_DragDropFiles) { + view->OnDragEntered(event); + ASSERT_NE(nullptr, view->current_drag_data_); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // By design, Linux implementations return an empty string if file data + // is also present. + EXPECT_TRUE(!view->current_drag_data_->text || +@@ -337,7 +337,7 @@ TEST_F(WebContentsViewAuraTest, MAYBE_DragDropFiles) { + + CheckDropData(view); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // By design, Linux implementations returns an empty string if file data + // is also present. + EXPECT_TRUE(!drop_complete_data_->drop_data.text || +@@ -395,7 +395,7 @@ TEST_F(WebContentsViewAuraTest, MAYBE_DragDropFilesOri + view->OnDragEntered(event); + ASSERT_NE(nullptr, view->current_drag_data_); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // By design, Linux implementations return an empty string if file data + // is also present. + EXPECT_TRUE(!view->current_drag_data_->text || +@@ -427,7 +427,7 @@ TEST_F(WebContentsViewAuraTest, MAYBE_DragDropFilesOri + + CheckDropData(view); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // By design, Linux implementations returns an empty string if file data is + // also present. + EXPECT_TRUE(!drop_complete_data_->drop_data.text || +@@ -458,7 +458,7 @@ TEST_F(WebContentsViewAuraTest, MAYBE_DragDropImageFro + + auto data = std::make_unique<ui::OSExchangeData>(); + +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE_X11) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE_X11) + // FileContents drag-drop in X relies on XDragDropClient::InitDrag() setting + // window property 'XdndDirectSave0' to filename. Since XDragDropClient is not + // created in this unittest, we will set this property manually to allow diff --git a/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.cc b/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.cc index f9ecfc4d4301..f934127d06ba 100644 --- a/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.cc +++ b/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.cc @@ -1,38 +1,11 @@ ---- content/browser/webui/web_ui_main_frame_observer.cc.orig 2023-05-31 08:12:17 UTC +--- content/browser/webui/web_ui_main_frame_observer.cc.orig 2025-02-19 07:43:18 UTC +++ content/browser/webui/web_ui_main_frame_observer.cc -@@ -13,7 +13,7 @@ - #include "content/public/browser/navigation_handle.h" - #include "content/public/browser/web_ui_controller.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "base/feature_list.h" - #include "base/functional/callback_helpers.h" - #include "base/logging.h" -@@ -31,7 +31,7 @@ namespace content { - - namespace { - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Remove the pieces of the URL we don't want to send back with the error - // reports. In particular, do not send query or fragments as those can have - // privacy-sensitive information in them. -@@ -55,7 +55,7 @@ WebUIMainFrameObserver::WebUIMainFrameObserver(WebUIIm - - WebUIMainFrameObserver::~WebUIMainFrameObserver() = default; - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - void WebUIMainFrameObserver::OnDidAddMessageToConsole( - RenderFrameHost* source_frame, - blink::mojom::ConsoleMessageLevel log_level, -@@ -167,7 +167,7 @@ void WebUIMainFrameObserver::ReadyToCommitNavigation( - - // TODO(crbug.com/1129544) This is currently disabled due to Windows DLL - // thunking issues. Fix & re-enable. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - MaybeEnableWebUIJavaScriptErrorReporting(navigation_handle); - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - } +@@ -47,7 +47,7 @@ std::string RedactURL(const GURL& url) { + bool IsWebUIJavaScriptErrorReportingSupported() { + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) + return false; +-#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return true; + #else + return base::FeatureList::IsEnabled(features::kWebUIJSErrorReportingExtended); diff --git a/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.h b/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.h deleted file mode 100644 index 20f198f06ca5..000000000000 --- a/www/chromium/files/patch-content_browser_webui_web__ui__main__frame__observer.h +++ /dev/null @@ -1,20 +0,0 @@ ---- content/browser/webui/web_ui_main_frame_observer.h.orig 2022-07-22 17:30:31 UTC -+++ content/browser/webui/web_ui_main_frame_observer.h -@@ -44,7 +44,7 @@ class CONTENT_EXPORT WebUIMainFrameObserver : public W - - // TODO(crbug.com/1129544) This is currently disabled due to Windows DLL - // thunking issues. Fix & re-enable. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // On official Google builds, capture and report JavaScript error messages on - // WebUI surfaces back to Google. This allows us to fix JavaScript errors and - // exceptions. -@@ -60,7 +60,7 @@ class CONTENT_EXPORT WebUIMainFrameObserver : public W - void ReadyToCommitNavigation(NavigationHandle* navigation_handle) override; - - private: --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - void MaybeEnableWebUIJavaScriptErrorReporting( - NavigationHandle* navigation_handle); - diff --git a/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.cc b/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.cc index 12922a8aeae2..6775c09486bd 100644 --- a/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.cc +++ b/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.cc @@ -1,7 +1,7 @@ ---- content/browser/zygote_host/zygote_host_impl_linux.cc.orig 2024-04-19 13:02:56 UTC +--- content/browser/zygote_host/zygote_host_impl_linux.cc.orig 2025-03-05 08:14:56 UTC +++ content/browser/zygote_host/zygote_host_impl_linux.cc -@@ -18,8 +18,10 @@ - #include "build/chromeos_buildflags.h" +@@ -23,8 +23,10 @@ + #include "build/build_config.h" #include "content/common/zygote/zygote_commands_linux.h" #include "content/common/zygote/zygote_communication_linux.h" +#if !BUILDFLAG(IS_BSD) @@ -11,7 +11,7 @@ #include "sandbox/linux/services/credentials.h" #include "sandbox/linux/services/namespace_sandbox.h" #include "sandbox/linux/suid/client/setuid_sandbox_host.h" -@@ -37,6 +39,7 @@ namespace content { +@@ -42,6 +44,7 @@ namespace content { namespace { @@ -19,7 +19,7 @@ // Receive a fixed message on fd and return the sender's PID. // Returns true if the message received matches the expected message. bool ReceiveFixedMessage(int fd, -@@ -58,6 +61,7 @@ bool ReceiveFixedMessage(int fd, +@@ -64,6 +67,7 @@ bool ReceiveFixedMessage(int fd, return false; return true; } @@ -27,7 +27,7 @@ } // namespace -@@ -67,9 +71,13 @@ ZygoteHost* ZygoteHost::GetInstance() { +@@ -73,9 +77,13 @@ ZygoteHost* ZygoteHost::GetInstance() { } ZygoteHostImpl::ZygoteHostImpl() @@ -41,7 +41,7 @@ sandbox_binary_(), zygote_pids_lock_(), zygote_pids_() {} -@@ -82,6 +90,7 @@ ZygoteHostImpl* ZygoteHostImpl::GetInstance() { +@@ -88,6 +96,7 @@ ZygoteHostImpl* ZygoteHostImpl::GetInstance() { } void ZygoteHostImpl::Init(const base::CommandLine& command_line) { @@ -49,7 +49,7 @@ if (command_line.HasSwitch(sandbox::policy::switches::kNoSandbox)) { return; } -@@ -132,6 +141,7 @@ void ZygoteHostImpl::Init(const base::CommandLine& com +@@ -142,6 +151,7 @@ void ZygoteHostImpl::Init(const base::CommandLine& com "you can try using --" << sandbox::policy::switches::kNoSandbox << "."; } @@ -57,7 +57,7 @@ } void ZygoteHostImpl::AddZygotePid(pid_t pid) { -@@ -156,6 +166,7 @@ pid_t ZygoteHostImpl::LaunchZygote( +@@ -166,6 +176,7 @@ pid_t ZygoteHostImpl::LaunchZygote( base::CommandLine* cmd_line, base::ScopedFD* control_fd, base::FileHandleMappingVector additional_remapped_fds) { @@ -65,7 +65,7 @@ int fds[2]; CHECK_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET | SOCK_CLOEXEC, 0, fds)); CHECK(base::UnixDomainSocket::EnableReceiveProcessId(fds[0])); -@@ -224,9 +235,12 @@ pid_t ZygoteHostImpl::LaunchZygote( +@@ -234,9 +245,12 @@ pid_t ZygoteHostImpl::LaunchZygote( AddZygotePid(pid); return pid; diff --git a/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.h b/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.h index 2750bfc84521..beaab3f8c35e 100644 --- a/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.h +++ b/www/chromium/files/patch-content_browser_zygote__host_zygote__host__impl__linux.h @@ -1,6 +1,6 @@ ---- content/browser/zygote_host/zygote_host_impl_linux.h.orig 2023-02-08 09:03:45 UTC +--- content/browser/zygote_host/zygote_host_impl_linux.h.orig 2025-02-19 07:43:18 UTC +++ content/browser/zygote_host/zygote_host_impl_linux.h -@@ -47,12 +47,14 @@ class CONTENT_EXPORT ZygoteHostImpl : public ZygoteHos +@@ -46,12 +46,14 @@ class CONTENT_EXPORT ZygoteHostImpl : public ZygoteHos base::ScopedFD* control_fd, base::FileHandleMappingVector additional_remapped_fds); @@ -15,7 +15,7 @@ bool HasZygote() { return !zygote_pids_.empty(); } -@@ -67,9 +69,11 @@ class CONTENT_EXPORT ZygoteHostImpl : public ZygoteHos +@@ -66,9 +68,11 @@ class CONTENT_EXPORT ZygoteHostImpl : public ZygoteHos int renderer_sandbox_status_; diff --git a/www/chromium/files/patch-content_child_BUILD.gn b/www/chromium/files/patch-content_child_BUILD.gn index 0d85489d1809..67475a951683 100644 --- a/www/chromium/files/patch-content_child_BUILD.gn +++ b/www/chromium/files/patch-content_child_BUILD.gn @@ -1,6 +1,6 @@ ---- content/child/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- content/child/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ content/child/BUILD.gn -@@ -131,6 +131,13 @@ target(link_target_type, "child") { +@@ -135,6 +135,13 @@ target(link_target_type, "child") { ] } @@ -13,4 +13,4 @@ + if (is_win) { sources += [ - "dwrite_font_proxy/dwrite_font_proxy_init_impl_win.cc", + "child_process_sandbox_support_impl_win.cc", diff --git a/www/chromium/files/patch-content_child_child__process.cc b/www/chromium/files/patch-content_child_child__process.cc index 2f0bbf2bcac0..8f32ac959520 100644 --- a/www/chromium/files/patch-content_child_child__process.cc +++ b/www/chromium/files/patch-content_child_child__process.cc @@ -1,11 +1,20 @@ ---- content/child/child_process.cc.orig 2023-11-03 10:09:45 UTC +--- content/child/child_process.cc.orig 2025-04-04 08:52:13 UTC +++ content/child/child_process.cc -@@ -66,7 +66,7 @@ ChildProcess::ChildProcess(base::ThreadType io_thread_ - thread_pool_init_params) - : resetter_(&child_process, this, nullptr), - io_thread_(std::make_unique<ChildIOThread>()) { +@@ -31,7 +31,7 @@ + #include "content/common/android/cpu_time_metrics.h" + #endif + -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const base::CommandLine& command_line = - *base::CommandLine::ForCurrentProcess(); - const bool is_embedded_in_browser_process = + #include "content/child/sandboxed_process_thread_type_handler.h" + #endif + +@@ -177,7 +177,7 @@ void ChildProcess::set_main_thread(ChildThreadImpl* th + main_thread_.reset(thread); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + void ChildProcess::SetIOThreadType(base::ThreadType thread_type) { + if (!io_thread_) { + return; diff --git a/www/chromium/files/patch-content_child_child__process.h b/www/chromium/files/patch-content_child_child__process.h new file mode 100644 index 000000000000..8b7c855a26a3 --- /dev/null +++ b/www/chromium/files/patch-content_child_child__process.h @@ -0,0 +1,11 @@ +--- content/child/child_process.h.orig 2024-07-30 11:12:21 UTC ++++ content/child/child_process.h +@@ -79,7 +79,7 @@ class CONTENT_EXPORT ChildProcess { + return io_thread_runner_.get(); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // Changes the thread type of the child process IO thread. + void SetIOThreadType(base::ThreadType thread_type); + #endif diff --git a/www/chromium/files/patch-content_common_BUILD.gn b/www/chromium/files/patch-content_common_BUILD.gn index 1d04f98784ee..f81cb7852507 100644 --- a/www/chromium/files/patch-content_common_BUILD.gn +++ b/www/chromium/files/patch-content_common_BUILD.gn @@ -1,6 +1,6 @@ ---- content/common/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- content/common/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ content/common/BUILD.gn -@@ -444,19 +444,28 @@ source_set("common") { +@@ -382,19 +382,28 @@ source_set("common") { } if (is_linux || is_chromeos) { diff --git a/www/chromium/files/patch-content_common_features.cc b/www/chromium/files/patch-content_common_features.cc index a4b0ea019803..9ec523b4f515 100644 --- a/www/chromium/files/patch-content_common_features.cc +++ b/www/chromium/files/patch-content_common_features.cc @@ -1,6 +1,6 @@ ---- content/common/features.cc.orig 2024-04-19 13:02:56 UTC +--- content/common/features.cc.orig 2025-07-02 06:08:04 UTC +++ content/common/features.cc -@@ -169,7 +169,7 @@ BASE_FEATURE(kEnableBackForwardCacheForOngoingSubframe +@@ -170,7 +170,7 @@ BASE_FEATURE(kEmbeddingRequiresOptIn, base::FEATURE_DISABLED_BY_DEFAULT); // Enables error reporting for JS errors inside DevTools frontend host @@ -9,12 +9,3 @@ BASE_FEATURE(kEnableDevToolsJsErrorReporting, "EnableDevToolsJsErrorReporting", base::FEATURE_DISABLED_BY_DEFAULT); -@@ -272,7 +272,7 @@ BASE_FEATURE(kGroupNIKByJoiningOrigin, - // process and having browser process handle adjusting thread properties (nice - // value, c-group, latency sensitivity...) for children which have sandbox - // restrictions. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - BASE_FEATURE(kHandleChildThreadTypeChangesInBrowser, - "HandleChildThreadTypeChangesInBrowser", - base::FEATURE_ENABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-content_common_features.h b/www/chromium/files/patch-content_common_features.h index 9b74dafa9b2e..4f17dd3bce7f 100644 --- a/www/chromium/files/patch-content_common_features.h +++ b/www/chromium/files/patch-content_common_features.h @@ -1,20 +1,11 @@ ---- content/common/features.h.orig 2024-04-19 13:02:56 UTC +--- content/common/features.h.orig 2025-07-02 06:08:04 UTC +++ content/common/features.h -@@ -38,7 +38,7 @@ CONTENT_EXPORT BASE_DECLARE_FEATURE(kDocumentPolicyNeg - CONTENT_EXPORT BASE_DECLARE_FEATURE(kEnableBackForwardCacheForScreenReader); - CONTENT_EXPORT BASE_DECLARE_FEATURE( - kEnableBackForwardCacheForOngoingSubframeNavigation); +@@ -60,7 +60,7 @@ CONTENT_EXPORT BASE_DECLARE_FEATURE(kCommittedOriginEn + CONTENT_EXPORT BASE_DECLARE_FEATURE(kCommittedOriginTracking); + CONTENT_EXPORT BASE_DECLARE_FEATURE(kCriticalClientHint); + CONTENT_EXPORT BASE_DECLARE_FEATURE(kDocumentPolicyNegotiation); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) CONTENT_EXPORT BASE_DECLARE_FEATURE(kEnableDevToolsJsErrorReporting); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - CONTENT_EXPORT BASE_DECLARE_FEATURE(kEnsureAllowBindingsIsAlwaysForWebUI); -@@ -63,7 +63,7 @@ CONTENT_EXPORT extern const base::FeatureParam<int> - CONTENT_EXPORT BASE_DECLARE_FEATURE(kGpuInfoCollectionSeparatePrefetch); - #endif - CONTENT_EXPORT BASE_DECLARE_FEATURE(kGroupNIKByJoiningOrigin); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - CONTENT_EXPORT BASE_DECLARE_FEATURE(kHandleChildThreadTypeChangesInBrowser); - #endif - CONTENT_EXPORT BASE_DECLARE_FEATURE(kHighPriorityBeforeUnload); + CONTENT_EXPORT BASE_DECLARE_FEATURE(kEmbeddingRequiresOptIn); diff --git a/www/chromium/files/patch-content_common_font__list__unittest.cc b/www/chromium/files/patch-content_common_font__list__unittest.cc index 2abc9696304c..8ae02d2af573 100644 --- a/www/chromium/files/patch-content_common_font__list__unittest.cc +++ b/www/chromium/files/patch-content_common_font__list__unittest.cc @@ -1,6 +1,6 @@ ---- content/common/font_list_unittest.cc.orig 2023-02-08 09:03:45 UTC +--- content/common/font_list_unittest.cc.orig 2024-05-21 18:07:39 UTC +++ content/common/font_list_unittest.cc -@@ -47,7 +47,7 @@ TEST(FontList, GetFontList) { +@@ -48,7 +48,7 @@ TEST(FontList, GetFontList) { EXPECT_TRUE(HasFontWithName(fonts, "MS Gothic", "MS Gothic")); EXPECT_TRUE(HasFontWithName(fonts, "Segoe UI", "Segoe UI")); EXPECT_TRUE(HasFontWithName(fonts, "Verdana", "Verdana")); diff --git a/www/chromium/files/patch-content_common_mojo__core__library__support.cc b/www/chromium/files/patch-content_common_mojo__core__library__support.cc deleted file mode 100644 index c6003a4713a4..000000000000 --- a/www/chromium/files/patch-content_common_mojo__core__library__support.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- content/common/mojo_core_library_support.cc.orig 2024-02-23 21:04:38 UTC -+++ content/common/mojo_core_library_support.cc -@@ -15,7 +15,7 @@ bool IsMojoCoreSharedLibraryEnabled() { - } - - std::optional<base::FilePath> GetMojoCoreSharedLibraryPath() { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const base::CommandLine& command_line = - *base::CommandLine::ForCurrentProcess(); - if (!command_line.HasSwitch(switches::kMojoCoreLibraryPath)) diff --git a/www/chromium/files/patch-content_common_thread__type__switcher.mojom b/www/chromium/files/patch-content_common_thread__type__switcher.mojom new file mode 100644 index 000000000000..212d7c3d32ce --- /dev/null +++ b/www/chromium/files/patch-content_common_thread__type__switcher.mojom @@ -0,0 +1,10 @@ +--- content/common/thread_type_switcher.mojom.orig 2025-04-04 08:52:13 UTC ++++ content/common/thread_type_switcher.mojom +@@ -10,6 +10,6 @@ import "mojo/public/mojom/base/thread_type.mojom"; + // occur in a child process due to its sandbox, e.g. on Linux and ChromeOS. + interface ThreadTypeSwitcher { + // Asks the browser to change the type of thread. +- SetThreadType(int32 platform_thread_id, ++ SetThreadType(uint64 platform_thread_id, + mojo_base.mojom.ThreadType thread_type); + }; diff --git a/www/chromium/files/patch-content_common_user__agent.cc b/www/chromium/files/patch-content_common_user__agent.cc deleted file mode 100644 index 8b8fa849fd1c..000000000000 --- a/www/chromium/files/patch-content_common_user__agent.cc +++ /dev/null @@ -1,37 +0,0 @@ ---- content/common/user_agent.cc.orig 2023-04-05 11:05:06 UTC -+++ content/common/user_agent.cc -@@ -45,7 +45,7 @@ std::string GetUserAgentPlatform() { - return ""; - #elif BUILDFLAG(IS_MAC) - return "Macintosh; "; --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - return "X11; "; // strange, but that's what Firefox uses - #elif BUILDFLAG(IS_ANDROID) - return "Linux; "; -@@ -71,7 +71,7 @@ std::string GetUnifiedPlatform() { - return "Windows NT 10.0; Win64; x64"; - #elif BUILDFLAG(IS_FUCHSIA) - return "Fuchsia"; --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return "X11; Linux x86_64"; - #elif BUILDFLAG(IS_IOS) - if (ui::GetDeviceFormFactor() == ui::DEVICE_FORM_FACTOR_TABLET) { -@@ -296,6 +296,16 @@ std::string BuildOSCpuInfoFromOSVersionAndCpuType(cons - "Android %s", os_version.c_str() - #elif BUILDFLAG(IS_FUCHSIA) - "Fuchsia" -+#elif BUILDFLAG(IS_BSD) -+#if defined(__x86_64__) -+ "Linux x86_64; %s %s", -+#elif defined(__aarch64__) -+ "Linux aarch64; %s %s", -+#else -+ "Linux i686; %s %s", -+#endif -+ unixinfo.sysname, // e.g. Linux -+ cpu_type.c_str() // e.g. i686 - #elif BUILDFLAG(IS_IOS) - "CPU %s OS %s like Mac OS X", cpu_type.c_str(), - os_version.c_str() diff --git a/www/chromium/files/patch-content_gpu_gpu__child__thread.cc b/www/chromium/files/patch-content_gpu_gpu__child__thread.cc index 078c44304a3a..2b2c00bc447f 100644 --- a/www/chromium/files/patch-content_gpu_gpu__child__thread.cc +++ b/www/chromium/files/patch-content_gpu_gpu__child__thread.cc @@ -1,6 +1,6 @@ ---- content/gpu/gpu_child_thread.cc.orig 2024-04-19 13:02:56 UTC +--- content/gpu/gpu_child_thread.cc.orig 2025-02-19 07:43:18 UTC +++ content/gpu/gpu_child_thread.cc -@@ -58,7 +58,7 @@ +@@ -57,7 +57,7 @@ #include "third_party/skia/include/ports/SkFontConfigInterface.h" #endif @@ -9,7 +9,7 @@ #include "content/child/sandboxed_process_thread_type_handler.h" #endif -@@ -142,7 +142,8 @@ void GpuChildThread::Init(const base::TimeTicks& proce +@@ -147,7 +147,8 @@ void GpuChildThread::Init(const base::TimeTicks& proce viz_main_.gpu_service()->set_start_time(process_start_time); diff --git a/www/chromium/files/patch-content_gpu_gpu__main.cc b/www/chromium/files/patch-content_gpu_gpu__main.cc index 52a1c3350848..90a517be3aab 100644 --- a/www/chromium/files/patch-content_gpu_gpu__main.cc +++ b/www/chromium/files/patch-content_gpu_gpu__main.cc @@ -1,6 +1,6 @@ ---- content/gpu/gpu_main.cc.orig 2024-04-19 13:02:56 UTC +--- content/gpu/gpu_main.cc.orig 2025-07-02 06:08:04 UTC +++ content/gpu/gpu_main.cc -@@ -91,10 +91,14 @@ +@@ -105,10 +105,14 @@ #include "sandbox/win/src/sandbox.h" #endif @@ -16,7 +16,7 @@ #include "sandbox/policy/sandbox_type.h" #endif -@@ -114,7 +118,7 @@ namespace content { +@@ -126,7 +130,7 @@ namespace content { namespace { @@ -25,16 +25,16 @@ bool StartSandboxLinux(gpu::GpuWatchdogThread*, const gpu::GPUInfo*, const gpu::GpuPreferences&); -@@ -179,7 +183,7 @@ class ContentSandboxHelper : public gpu::GpuSandboxHel - bool EnsureSandboxInitialized(gpu::GpuWatchdogThread* watchdog_thread, +@@ -188,7 +192,7 @@ class ContentSandboxHelper : public gpu::GpuSandboxHel const gpu::GPUInfo* gpu_info, const gpu::GpuPreferences& gpu_prefs) override { + GPU_STARTUP_TRACE_EVENT("gpu_main::EnsureSandboxInitialized"); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) return StartSandboxLinux(watchdog_thread, gpu_info, gpu_prefs); #elif BUILDFLAG(IS_WIN) return StartSandboxWindows(sandbox_info_); -@@ -291,7 +295,7 @@ int GpuMain(MainFunctionParams parameters) { +@@ -304,7 +308,7 @@ int GpuMain(MainFunctionParams parameters) { std::make_unique<base::SingleThreadTaskExecutor>( gpu_preferences.message_pump_type); } @@ -43,17 +43,17 @@ #error "Unsupported Linux platform." #elif BUILDFLAG(IS_MAC) // Cross-process CoreAnimation requires a CFRunLoop to function at all, and -@@ -328,7 +332,8 @@ int GpuMain(MainFunctionParams parameters) { - // before it. - InitializeSkia(); +@@ -329,7 +333,8 @@ int GpuMain(MainFunctionParams parameters) { + base::PlatformThread::SetName("CrGpuMain"); + mojo::InterfaceEndpointClient::SetThreadNameSuffixForMetrics("GpuMain"); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +// XXX BSD +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && !BUILDFLAG(IS_BSD) // Thread type delegate of the process should be registered before - // first thread type change in ChildProcess constructor. - // It also needs to be registered before the process has multiple threads, -@@ -436,7 +441,7 @@ int GpuMain(MainFunctionParams parameters) { + // thread type change below for the main thread and for thread pool in + // ChildProcess constructor. +@@ -461,7 +466,7 @@ int GpuMain(MainFunctionParams parameters) { namespace { @@ -62,12 +62,12 @@ bool StartSandboxLinux(gpu::GpuWatchdogThread* watchdog_thread, const gpu::GPUInfo* gpu_info, const gpu::GpuPreferences& gpu_prefs) { -@@ -476,7 +481,7 @@ bool StartSandboxLinux(gpu::GpuWatchdogThread* watchdo +@@ -509,7 +514,7 @@ bool StartSandboxLinux(gpu::GpuWatchdogThread* watchdo sandbox_options.accelerated_video_encode_enabled = !gpu_prefs.disable_accelerated_video_encode; -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Video decoding of many video streams can use thousands of FDs as well as - // Exo clients like Lacros. + // Exo clients. // See https://crbug.com/1417237 diff --git a/www/chromium/files/patch-content_ppapi__plugin_ppapi__blink__platform__impl.h b/www/chromium/files/patch-content_ppapi__plugin_ppapi__blink__platform__impl.h index cd0f7746c10c..5143ca044cb9 100644 --- a/www/chromium/files/patch-content_ppapi__plugin_ppapi__blink__platform__impl.h +++ b/www/chromium/files/patch-content_ppapi__plugin_ppapi__blink__platform__impl.h @@ -1,6 +1,6 @@ ---- content/ppapi_plugin/ppapi_blink_platform_impl.h.orig 2024-02-23 21:04:38 UTC +--- content/ppapi_plugin/ppapi_blink_platform_impl.h.orig 2024-07-30 11:12:21 UTC +++ content/ppapi_plugin/ppapi_blink_platform_impl.h -@@ -34,7 +34,7 @@ class PpapiBlinkPlatformImpl : public BlinkPlatformImp +@@ -36,7 +36,7 @@ class PpapiBlinkPlatformImpl : public BlinkPlatformImp blink::WebString DefaultLocale() override; private: diff --git a/www/chromium/files/patch-content_ppapi__plugin_ppapi__plugin__main.cc b/www/chromium/files/patch-content_ppapi__plugin_ppapi__plugin__main.cc index 3ec8cccf14fd..2d0f03ae81d3 100644 --- a/www/chromium/files/patch-content_ppapi__plugin_ppapi__plugin__main.cc +++ b/www/chromium/files/patch-content_ppapi__plugin_ppapi__plugin__main.cc @@ -1,6 +1,6 @@ ---- content/ppapi_plugin/ppapi_plugin_main.cc.orig 2023-08-17 07:33:31 UTC +--- content/ppapi_plugin/ppapi_plugin_main.cc.orig 2025-03-05 08:14:56 UTC +++ content/ppapi_plugin/ppapi_plugin_main.cc -@@ -54,6 +54,11 @@ +@@ -52,6 +52,11 @@ #include "gin/v8_initializer.h" #endif @@ -12,7 +12,7 @@ #if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_ANDROID) #include <stdlib.h> #endif -@@ -150,7 +155,7 @@ int PpapiPluginMain(MainFunctionParams parameters) { +@@ -139,7 +144,7 @@ int PpapiPluginMain(MainFunctionParams parameters) { gin::V8Initializer::LoadV8Snapshot(); #endif diff --git a/www/chromium/files/patch-content_public_browser_content__browser__client.cc b/www/chromium/files/patch-content_public_browser_content__browser__client.cc index 340ba95a4231..2ed8ac354006 100644 --- a/www/chromium/files/patch-content_public_browser_content__browser__client.cc +++ b/www/chromium/files/patch-content_public_browser_content__browser__client.cc @@ -1,6 +1,6 @@ ---- content/public/browser/content_browser_client.cc.orig 2024-04-19 13:02:56 UTC +--- content/public/browser/content_browser_client.cc.orig 2025-07-02 06:08:04 UTC +++ content/public/browser/content_browser_client.cc -@@ -1283,7 +1283,7 @@ bool ContentBrowserClient::ShouldRunOutOfProcessSystem +@@ -1418,7 +1418,7 @@ bool ContentBrowserClient::ShouldRunOutOfProcessSystem // that can be adequately sandboxed. // Currently Android's network service will not run out of process or sandboxed, // so OutOfProcessSystemDnsResolution is not currently enabled on Android. diff --git a/www/chromium/files/patch-content_public_browser_service__process__host.cc b/www/chromium/files/patch-content_public_browser_service__process__host.cc deleted file mode 100644 index bd77d5fab65c..000000000000 --- a/www/chromium/files/patch-content_public_browser_service__process__host.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- content/public/browser/service_process_host.cc.orig 2024-04-19 13:02:56 UTC -+++ content/public/browser/service_process_host.cc -@@ -76,7 +76,7 @@ ServiceProcessHost::Options& ServiceProcessHost::Optio - - ServiceProcessHost::Options& ServiceProcessHost::Options::WithGpuClient( - base::PassKey<ServiceProcessHostGpuClient> passkey) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - allow_gpu_client = true; - #endif - return *this; diff --git a/www/chromium/files/patch-content_public_browser_zygote__host_zygote__host__linux.h b/www/chromium/files/patch-content_public_browser_zygote__host_zygote__host__linux.h index 38fc251c1674..d8e7875777d7 100644 --- a/www/chromium/files/patch-content_public_browser_zygote__host_zygote__host__linux.h +++ b/www/chromium/files/patch-content_public_browser_zygote__host_zygote__host__linux.h @@ -1,6 +1,6 @@ ---- content/public/browser/zygote_host/zygote_host_linux.h.orig 2023-02-08 09:03:45 UTC +--- content/public/browser/zygote_host/zygote_host_linux.h.orig 2025-02-19 07:43:18 UTC +++ content/public/browser/zygote_host/zygote_host_linux.h -@@ -35,11 +35,13 @@ class ZygoteHost { +@@ -34,11 +34,13 @@ class ZygoteHost { // after the first render has been forked. virtual int GetRendererSandboxStatus() = 0; diff --git a/www/chromium/files/patch-content_public_common_content__features.cc b/www/chromium/files/patch-content_public_common_content__features.cc index ed8436f3e825..2b7639e3f7f8 100644 --- a/www/chromium/files/patch-content_public_common_content__features.cc +++ b/www/chromium/files/patch-content_public_common_content__features.cc @@ -1,33 +1,27 @@ ---- content/public/common/content_features.cc.orig 2024-04-19 13:02:56 UTC +--- content/public/common/content_features.cc.orig 2025-07-02 06:08:04 UTC +++ content/public/common/content_features.cc -@@ -27,7 +27,7 @@ BASE_FEATURE(kAudioServiceOutOfProcess, +@@ -87,7 +87,7 @@ BASE_FEATURE(kAudioServiceLaunchOnStartup, + // Runs the audio service in a separate process. + BASE_FEATURE(kAudioServiceOutOfProcess, "AudioServiceOutOfProcess", - // TODO(crbug.com/1052397): Remove !IS_CHROMEOS_LACROS once lacros starts being - // built with OS_CHROMEOS instead of OS_LINUX. --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS)) - base::FEATURE_ENABLED_BY_DEFAULT - #else -@@ -39,7 +39,7 @@ BASE_FEATURE(kAudioServiceOutOfProcess, - // kAudioServiceOutOfProcess feature is enabled. - BASE_FEATURE(kAudioServiceSandbox, - "AudioServiceSandbox", --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -1199,7 +1199,7 @@ BASE_FEATURE(kWebAssemblyTiering, +@@ -1268,9 +1268,9 @@ BASE_FEATURE(kWebAssemblyTiering, BASE_FEATURE(kWebAssemblyTrapHandler, "WebAssemblyTrapHandler", - #if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_MAC)) && \ -+ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD)) && \ - defined(ARCH_CPU_X86_64)) || \ - (BUILDFLAG(IS_MAC) && defined(ARCH_CPU_ARM64)) + #if ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC)) && \ ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD)) && \ + defined(ARCH_CPU_X86_64)) || \ +- ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC)) && \ ++ ((BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD)) && \ + defined(ARCH_CPU_ARM64)) base::FEATURE_ENABLED_BY_DEFAULT -@@ -1241,7 +1241,11 @@ BASE_FEATURE(kWebUICodeCache, + #else +@@ -1327,7 +1327,11 @@ BASE_FEATURE(kWebUIJSErrorReportingExtended, // Controls whether the WebUSB API is enabled: // https://wicg.github.io/webusb diff --git a/www/chromium/files/patch-content_public_common_content__switches.cc b/www/chromium/files/patch-content_public_common_content__switches.cc index 4b7ee87ee215..41276ee15739 100644 --- a/www/chromium/files/patch-content_public_common_content__switches.cc +++ b/www/chromium/files/patch-content_public_common_content__switches.cc @@ -1,6 +1,6 @@ ---- content/public/common/content_switches.cc.orig 2024-04-19 13:02:56 UTC +--- content/public/common/content_switches.cc.orig 2025-05-28 14:55:43 UTC +++ content/public/common/content_switches.cc -@@ -366,6 +366,8 @@ const char kEnableIsolatedWebAppsInRenderer[] = +@@ -345,6 +345,8 @@ const char kEnableIsolatedWebAppsInRenderer[] = // builds. const char kEnableLogging[] = "enable-logging"; @@ -9,12 +9,12 @@ // Enables the type, downlinkMax attributes of the NetInfo API. Also, enables // triggering of change attribute of the NetInfo API when there is a change in // the connection type. -@@ -1007,7 +1009,7 @@ const char kPreventResizingContentsForTesting[] = +@@ -952,7 +954,7 @@ const char kPreventResizingContentsForTesting[] = + "prevent-resizing-contents-for-testing"; + #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Allows sending text-to-speech requests to speech-dispatcher, a common // Linux speech service. Because it's buggy, the user must explicitly // enable it so that visiting a random webpage can't cause instability. diff --git a/www/chromium/files/patch-content_public_common_content__switches.h b/www/chromium/files/patch-content_public_common_content__switches.h index 80f69c9c4fad..b70d16bb9102 100644 --- a/www/chromium/files/patch-content_public_common_content__switches.h +++ b/www/chromium/files/patch-content_public_common_content__switches.h @@ -1,6 +1,6 @@ ---- content/public/common/content_switches.h.orig 2024-04-19 13:02:56 UTC +--- content/public/common/content_switches.h.orig 2025-05-28 14:55:43 UTC +++ content/public/common/content_switches.h -@@ -113,6 +113,7 @@ CONTENT_EXPORT extern const char kEnableGpuMemoryBuffe +@@ -108,6 +108,7 @@ CONTENT_EXPORT extern const char kEnableGpuMemoryBuffe CONTENT_EXPORT extern const char kEnableIsolatedWebAppsInRenderer[]; CONTENT_EXPORT extern const char kEnableLCDText[]; CONTENT_EXPORT extern const char kEnableLogging[]; @@ -8,12 +8,12 @@ CONTENT_EXPORT extern const char kEnableNetworkInformationDownlinkMax[]; CONTENT_EXPORT extern const char kEnableCanvas2DLayers[]; CONTENT_EXPORT extern const char kEnablePluginPlaceholderTesting[]; -@@ -268,7 +269,7 @@ CONTENT_EXPORT extern const char kPreventResizingConte +@@ -259,7 +260,7 @@ CONTENT_EXPORT extern const char kRendererWaitForJavaD + CONTENT_EXPORT extern const char kPreventResizingContentsForTesting[]; + #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) CONTENT_EXPORT extern const char kEnableSpeechDispatcher[]; - CONTENT_EXPORT extern const char kLLVMProfileFile[]; #endif + diff --git a/www/chromium/files/patch-content_renderer_render__thread__impl.cc b/www/chromium/files/patch-content_renderer_render__thread__impl.cc index f55d22b10731..5c2470edebc0 100644 --- a/www/chromium/files/patch-content_renderer_render__thread__impl.cc +++ b/www/chromium/files/patch-content_renderer_render__thread__impl.cc @@ -1,6 +1,6 @@ ---- content/renderer/render_thread_impl.cc.orig 2024-04-19 13:02:56 UTC +--- content/renderer/render_thread_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/renderer/render_thread_impl.cc -@@ -203,6 +203,8 @@ +@@ -204,6 +204,8 @@ #if BUILDFLAG(IS_APPLE) #include <malloc/malloc.h> @@ -9,25 +9,25 @@ #else #include <malloc.h> #endif -@@ -996,7 +998,7 @@ media::GpuVideoAcceleratorFactories* RenderThreadImpl: +@@ -1066,7 +1068,7 @@ media::GpuVideoAcceleratorFactories* RenderThreadImpl: kGpuStreamIdMedia, kGpuStreamPriorityMedia); const bool enable_video_decode_accelerator = -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FeatureList::IsEnabled(media::kVaapiVideoDecodeLinux) && + base::FeatureList::IsEnabled(media::kAcceleratedVideoDecodeLinux) && #endif // BUILDFLAG(IS_LINUX) !cmd_line->HasSwitch(switches::kDisableAcceleratedVideoDecode) && -@@ -1005,7 +1007,7 @@ media::GpuVideoAcceleratorFactories* RenderThreadImpl: +@@ -1075,7 +1077,7 @@ media::GpuVideoAcceleratorFactories* RenderThreadImpl: gpu::kGpuFeatureStatusEnabled); const bool enable_video_encode_accelerator = -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FeatureList::IsEnabled(media::kVaapiVideoEncodeLinux) && + base::FeatureList::IsEnabled(media::kAcceleratedVideoEncodeLinux) && #else !cmd_line->HasSwitch(switches::kDisableAcceleratedVideoEncode) && -@@ -1769,7 +1771,7 @@ std::unique_ptr<CodecFactory> RenderThreadImpl::Create +@@ -1850,7 +1852,7 @@ RenderThreadImpl::CreateMediaMojoCodecFactory( bool enable_video_encode_accelerator) { mojo::PendingRemote<media::mojom::VideoEncodeAcceleratorProvider> vea_provider; diff --git a/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.cc b/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.cc index 9b30b60d6a92..1ebc4e9e1eba 100644 --- a/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.cc +++ b/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.cc @@ -1,6 +1,6 @@ ---- content/renderer/renderer_blink_platform_impl.cc.orig 2024-04-12 16:47:14 UTC +--- content/renderer/renderer_blink_platform_impl.cc.orig 2025-07-02 06:08:04 UTC +++ content/renderer/renderer_blink_platform_impl.cc -@@ -115,7 +115,7 @@ +@@ -123,7 +123,7 @@ #if BUILDFLAG(IS_MAC) #include "content/child/child_process_sandbox_support_impl_mac.h" @@ -9,7 +9,7 @@ #include "content/child/child_process_sandbox_support_impl_linux.h" #include "content/child/sandboxed_process_thread_type_handler.h" #endif -@@ -185,13 +185,13 @@ RendererBlinkPlatformImpl::RendererBlinkPlatformImpl( +@@ -191,13 +191,13 @@ RendererBlinkPlatformImpl::RendererBlinkPlatformImpl( is_locked_to_site_(false), main_thread_scheduler_(main_thread_scheduler), next_frame_sink_id_(uint32_t{std::numeric_limits<int32_t>::max()} + 1) { @@ -25,21 +25,21 @@ mojo::PendingRemote<font_service::mojom::FontService> font_service; RenderThreadImpl::current()->BindHostReceiver( font_service.InitWithNewPipeAndPassReceiver()); -@@ -200,7 +200,7 @@ RendererBlinkPlatformImpl::RendererBlinkPlatformImpl( - #endif +@@ -222,7 +222,7 @@ RendererBlinkPlatformImpl::RendererBlinkPlatformImpl( } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) if (sandboxEnabled()) { #if BUILDFLAG(IS_MAC) sandbox_support_ = std::make_unique<WebSandboxSupportMac>(); -@@ -261,7 +261,7 @@ void RendererBlinkPlatformImpl::SetThreadType(base::Pl - #endif +@@ -295,7 +295,7 @@ RendererBlinkPlatformImpl::GetWebUIBundledCodeCacheRes blink::WebSandboxSupport* RendererBlinkPlatformImpl::GetSandboxSupport() { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) return sandbox_support_.get(); #else // These platforms do not require sandbox support. diff --git a/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.h b/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.h index a96e1594ad1d..a075eb8670bd 100644 --- a/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.h +++ b/www/chromium/files/patch-content_renderer_renderer__blink__platform__impl.h @@ -1,11 +1,11 @@ ---- content/renderer/renderer_blink_platform_impl.h.orig 2024-04-12 16:47:14 UTC +--- content/renderer/renderer_blink_platform_impl.h.orig 2025-05-28 14:55:43 UTC +++ content/renderer/renderer_blink_platform_impl.h -@@ -246,7 +246,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : publi - void Collect3DContextInformation(blink::Platform::GraphicsInfo* gl_info, +@@ -266,7 +266,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : publi const gpu::GPUInfo& gpu_info) const; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) std::unique_ptr<blink::WebSandboxSupport> sandbox_support_; #endif diff --git a/www/chromium/files/patch-content_shell_BUILD.gn b/www/chromium/files/patch-content_shell_BUILD.gn index db00816f6199..05cda5599dae 100644 --- a/www/chromium/files/patch-content_shell_BUILD.gn +++ b/www/chromium/files/patch-content_shell_BUILD.gn @@ -1,6 +1,6 @@ ---- content/shell/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- content/shell/BUILD.gn.orig 2025-05-28 14:55:43 UTC +++ content/shell/BUILD.gn -@@ -1064,7 +1064,7 @@ group("content_shell_crash_test") { +@@ -1111,7 +1111,7 @@ group("content_shell_crash_test") { if (is_win) { data_deps += [ "//build/win:copy_cdb_to_output" ] } diff --git a/www/chromium/files/patch-content_shell_app_shell__main__delegate.cc b/www/chromium/files/patch-content_shell_app_shell__main__delegate.cc index 18fb4b97fea5..46de71dd125c 100644 --- a/www/chromium/files/patch-content_shell_app_shell__main__delegate.cc +++ b/www/chromium/files/patch-content_shell_app_shell__main__delegate.cc @@ -1,6 +1,6 @@ ---- content/shell/app/shell_main_delegate.cc.orig 2024-04-19 13:02:56 UTC +--- content/shell/app/shell_main_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ content/shell/app/shell_main_delegate.cc -@@ -283,7 +283,7 @@ void ShellMainDelegate::PreSandboxStartup() { +@@ -270,7 +270,7 @@ void ShellMainDelegate::PreSandboxStartup() { // Reporting for sub-processes will be initialized in ZygoteForked. if (process_type != switches::kZygoteProcess) { crash_reporter::InitializeCrashpad(process_type.empty(), process_type); diff --git a/www/chromium/files/patch-content_shell_browser_shell__browser__main__parts.cc b/www/chromium/files/patch-content_shell_browser_shell__browser__main__parts.cc index 09347fba6f2c..8201adc90d41 100644 --- a/www/chromium/files/patch-content_shell_browser_shell__browser__main__parts.cc +++ b/www/chromium/files/patch-content_shell_browser_shell__browser__main__parts.cc @@ -1,33 +1,33 @@ ---- content/shell/browser/shell_browser_main_parts.cc.orig 2023-10-11 18:22:24 UTC +--- content/shell/browser/shell_browser_main_parts.cc.orig 2025-04-04 08:52:13 UTC +++ content/shell/browser/shell_browser_main_parts.cc -@@ -51,7 +51,7 @@ +@@ -50,7 +50,7 @@ #include "net/base/network_change_notifier.h" #endif --#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +-#if BUILDFLAG(IS_LINUX) && defined(USE_AURA) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(USE_AURA) #include "ui/base/ime/init/input_method_initializer.h" #endif -@@ -68,7 +68,7 @@ - #include "chromeos/lacros/dbus/lacros_dbus_thread_manager.h" +@@ -61,7 +61,7 @@ + #include "device/bluetooth/floss/floss_features.h" #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "device/bluetooth/dbus/dbus_bluez_manager_wrapper_linux.h" #include "ui/linux/linux_ui.h" // nogncheck #include "ui/linux/linux_ui_factory.h" // nogncheck - #endif -@@ -139,7 +139,7 @@ void ShellBrowserMainParts::PostCreateMainMessageLoop( +@@ -128,7 +128,7 @@ void ShellBrowserMainParts::PostCreateMainMessageLoop( } int ShellBrowserMainParts::PreEarlyInitialization() { --#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +-#if BUILDFLAG(IS_LINUX) && defined(USE_AURA) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(USE_AURA) ui::InitializeInputMethodForTesting(); - #endif - #if BUILDFLAG(IS_ANDROID) -@@ -168,7 +168,7 @@ void ShellBrowserMainParts::ToolkitInitialized() { + #elif BUILDFLAG(IS_ANDROID) + net::NetworkChangeNotifier::SetFactory( +@@ -156,7 +156,7 @@ void ShellBrowserMainParts::ToolkitInitialized() { if (switches::IsRunWebTestsSwitchPresent()) return; @@ -36,7 +36,7 @@ ui::LinuxUi::SetInstance(ui::GetDefaultLinuxUi()); #endif } -@@ -215,7 +215,7 @@ void ShellBrowserMainParts::PostMainMessageLoopRun() { +@@ -203,7 +203,7 @@ void ShellBrowserMainParts::PostMainMessageLoopRun() { ShellDevToolsManagerDelegate::StopHttpHandler(); browser_context_.reset(); off_the_record_browser_context_.reset(); diff --git a/www/chromium/files/patch-content_shell_browser_shell__paths.cc b/www/chromium/files/patch-content_shell_browser_shell__paths.cc deleted file mode 100644 index c00a1c66a5a2..000000000000 --- a/www/chromium/files/patch-content_shell_browser_shell__paths.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- content/shell/browser/shell_paths.cc.orig 2022-02-28 16:54:41 UTC -+++ content/shell/browser/shell_paths.cc -@@ -13,7 +13,7 @@ - - #if BUILDFLAG(IS_FUCHSIA) - #include "base/fuchsia/file_utils.h" --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "base/nix/xdg_util.h" - #endif - -@@ -25,7 +25,7 @@ bool GetDefaultUserDataDirectory(base::FilePath* resul - #if BUILDFLAG(IS_WIN) - CHECK(base::PathService::Get(base::DIR_LOCAL_APP_DATA, result)); - *result = result->Append(std::wstring(L"content_shell")); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - std::unique_ptr<base::Environment> env(base::Environment::Create()); - base::FilePath config_dir(base::nix::GetXDGDirectory( - env.get(), base::nix::kXdgConfigHomeEnvVar, base::nix::kDotConfigDir)); diff --git a/www/chromium/files/patch-content_shell_browser_shell__platform__delegate__views.cc b/www/chromium/files/patch-content_shell_browser_shell__platform__delegate__views.cc new file mode 100644 index 000000000000..4547857015b5 --- /dev/null +++ b/www/chromium/files/patch-content_shell_browser_shell__platform__delegate__views.cc @@ -0,0 +1,11 @@ +--- content/shell/browser/shell_platform_delegate_views.cc.orig 2025-05-05 10:57:53 UTC ++++ content/shell/browser/shell_platform_delegate_views.cc +@@ -373,7 +373,7 @@ void ShellPlatformDelegate::CreatePlatformWindow( + views::Widget::InitParams::NATIVE_WIDGET_OWNS_WIDGET); + params.bounds = gfx::Rect(initial_size); + params.delegate = delegate.release(); +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + params.wm_class_class = "chromium-content_shell"; + params.wm_class_name = params.wm_class_class; + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-content_renderer_render__process__impl.cc b/www/chromium/files/patch-content_shell_renderer_shell__content__renderer__client.cc index 454c21c5e641..26421ce2a6fc 100644 --- a/www/chromium/files/patch-content_renderer_render__process__impl.cc +++ b/www/chromium/files/patch-content_shell_renderer_shell__content__renderer__client.cc @@ -1,11 +1,11 @@ ---- content/renderer/render_process_impl.cc.orig 2024-01-30 07:53:34 UTC -+++ content/renderer/render_process_impl.cc -@@ -44,7 +44,7 @@ - #include "third_party/blink/public/web/web_frame.h" - #include "v8/include/v8-initialization.h" +--- content/shell/renderer/shell_content_renderer_client.cc.orig 2025-02-19 07:43:18 UTC ++++ content/shell/renderer/shell_content_renderer_client.cc +@@ -55,7 +55,7 @@ + #include "media/base/media_switches.h" + #endif -#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && \ (defined(ARCH_CPU_X86_64) || defined(ARCH_CPU_ARM64)) #define ENABLE_WEB_ASSEMBLY_TRAP_HANDLER_LINUX - #endif + #include "base/debug/stack_trace.h" diff --git a/www/chromium/files/patch-content_shell_utility_shell__content__utility__client.cc b/www/chromium/files/patch-content_shell_utility_shell__content__utility__client.cc index ded3fdb2150c..8d59de4f66eb 100644 --- a/www/chromium/files/patch-content_shell_utility_shell__content__utility__client.cc +++ b/www/chromium/files/patch-content_shell_utility_shell__content__utility__client.cc @@ -1,6 +1,6 @@ ---- content/shell/utility/shell_content_utility_client.cc.orig 2023-03-09 06:31:50 UTC +--- content/shell/utility/shell_content_utility_client.cc.orig 2025-03-05 08:14:56 UTC +++ content/shell/utility/shell_content_utility_client.cc -@@ -38,7 +38,7 @@ +@@ -43,7 +43,7 @@ #include "sandbox/policy/sandbox.h" #include "services/test/echo/echo_service.h" @@ -9,7 +9,7 @@ #include "content/test/sandbox_status_service.h" #endif -@@ -187,7 +187,7 @@ void ShellContentUtilityClient::ExposeInterfacesToBrow +@@ -192,7 +192,7 @@ void ShellContentUtilityClient::ExposeInterfacesToBrow binders->Add<mojom::PowerMonitorTest>( base::BindRepeating(&PowerMonitorTestImpl::MakeSelfOwnedReceiver), base::SingleThreadTaskRunner::GetCurrentDefault()); diff --git a/www/chromium/files/patch-content_utility_services.cc b/www/chromium/files/patch-content_utility_services.cc index 398dec910413..2f938f3a09db 100644 --- a/www/chromium/files/patch-content_utility_services.cc +++ b/www/chromium/files/patch-content_utility_services.cc @@ -1,40 +1,15 @@ ---- content/utility/services.cc.orig 2024-04-19 13:02:56 UTC +--- content/utility/services.cc.orig 2025-07-02 06:08:04 UTC +++ content/utility/services.cc -@@ -74,7 +74,7 @@ +@@ -73,7 +73,7 @@ extern sandbox::TargetServices* g_utility_target_services; #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "media/mojo/services/mojo_video_encode_accelerator_provider_factory.h" #include "sandbox/linux/services/libc_interceptor.h" #include "sandbox/policy/mojom/sandbox.mojom.h" -@@ -97,7 +97,7 @@ extern sandbox::TargetServices* g_utility_target_servi - #endif // BUILDFLAG(IS_CHROMEOS_ASH) && (BUILDFLAG(USE_VAAPI) || - // BUILDFLAG(USE_V4L2_CODEC)) - --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD)) && \ - (BUILDFLAG(USE_VAAPI) || BUILDFLAG(USE_V4L2_CODEC)) - #include "content/common/features.h" - #include "media/mojo/services/stable_video_decoder_factory_process_service.h" // nogncheck -@@ -115,13 +115,13 @@ extern sandbox::TargetServices* g_utility_target_servi - #endif // BUILDFLAG(ENABLE_ACCESSIBILITY_SERVICE) - - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || \ -- BUILDFLAG(ENABLE_VIDEO_EFFECTS) -+ BUILDFLAG(ENABLE_VIDEO_EFFECTS) || BUILDFLAG(IS_BSD) - #include "services/viz/public/cpp/gpu/gpu.h" - #include "services/viz/public/mojom/gpu.mojom.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || - // BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(ENABLE_VIDEO_EFFECTS) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "media/capture/capture_switches.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || - // BUILDFLAG(IS_CHROMEOS_ASH) -@@ -239,7 +239,7 @@ auto RunAudio(mojo::PendingReceiver<audio::mojom::Audi + #include "sandbox/policy/sandbox_type.h" +@@ -233,7 +233,7 @@ auto RunAudio(mojo::PendingReceiver<audio::mojom::Audi << "task_policy_set TASK_QOS_POLICY"; #endif @@ -43,57 +18,3 @@ auto* command_line = base::CommandLine::ForCurrentProcess(); if (sandbox::policy::SandboxTypeFromCommandLine(*command_line) == sandbox::mojom::Sandbox::kNoSandbox) { -@@ -328,7 +328,7 @@ auto RunVideoCapture( - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - auto service = std::make_unique<UtilityThreadVideoCaptureServiceImpl>( - std::move(receiver), base::SingleThreadTaskRunner::GetCurrentDefault()); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #if BUILDFLAG(IS_CHROMEOS_ASH) - { - #else -@@ -407,7 +407,7 @@ auto RunOOPArcVideoAcceleratorFactoryService( - #endif // BUILDFLAG(IS_CHROMEOS_ASH) && (BUILDFLAG(USE_VAAPI) || - // BUILDFLAG(USE_V4L2_CODEC)) - --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD)) && \ - (BUILDFLAG(USE_VAAPI) || BUILDFLAG(USE_V4L2_CODEC)) - auto RunStableVideoDecoderFactoryProcessService( - mojo::PendingReceiver< -@@ -418,7 +418,7 @@ auto RunStableVideoDecoderFactoryProcessService( - #endif // (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && - // (BUILDFLAG(USE_VAAPI) || BUILDFLAG(USE_V4L2_CODEC)) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - auto RunVideoEncodeAcceleratorProviderFactory( - mojo::PendingReceiver<media::mojom::VideoEncodeAcceleratorProviderFactory> - receiver) { -@@ -441,7 +441,7 @@ void RegisterIOThreadServices(mojo::ServiceFactory& se - // loop of type IO that can get notified when pipes have data. - services.Add(RunNetworkService); - --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD)) && \ - (BUILDFLAG(USE_VAAPI) || BUILDFLAG(USE_V4L2_CODEC)) - if (base::FeatureList::IsEnabled( - features::kRunStableVideoDecoderFactoryProcessServiceOnIOThread)) { -@@ -493,7 +493,7 @@ void RegisterMainThreadServices(mojo::ServiceFactory& - #endif // BUILDFLAG(IS_CHROMEOS_ASH) && (BUILDFLAG(USE_VAAPI) || - // BUILDFLAG(USE_V4L2_CODEC)) - --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD)) && \ - (BUILDFLAG(USE_VAAPI) || BUILDFLAG(USE_V4L2_CODEC)) - if (!base::FeatureList::IsEnabled( - features::kRunStableVideoDecoderFactoryProcessServiceOnIOThread)) { -@@ -502,7 +502,7 @@ void RegisterMainThreadServices(mojo::ServiceFactory& - #endif // (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)) && - // (BUILDFLAG(USE_VAAPI) || BUILDFLAG(USE_V4L2_CODEC)) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - services.Add(RunVideoEncodeAcceleratorProviderFactory); - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - diff --git a/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.cc b/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.cc index 87b7212eae57..56a2020d394b 100644 --- a/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.cc +++ b/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.cc @@ -1,4 +1,4 @@ ---- content/utility/utility_blink_platform_with_sandbox_support_impl.cc.orig 2023-05-31 08:12:17 UTC +--- content/utility/utility_blink_platform_with_sandbox_support_impl.cc.orig 2025-03-05 08:14:56 UTC +++ content/utility/utility_blink_platform_with_sandbox_support_impl.cc @@ -9,7 +9,7 @@ @@ -7,9 +7,9 @@ -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "content/child/child_process_sandbox_support_impl_linux.h" - #endif - -@@ -17,7 +17,7 @@ namespace content { + #elif BUILDFLAG(IS_WIN) + #include "content/child/child_process_sandbox_support_impl_win.h" +@@ -19,7 +19,7 @@ namespace content { UtilityBlinkPlatformWithSandboxSupportImpl:: UtilityBlinkPlatformWithSandboxSupportImpl() { @@ -18,12 +18,12 @@ mojo::PendingRemote<font_service::mojom::FontService> font_service; UtilityThread::Get()->BindHostReceiver( font_service.InitWithNewPipeAndPassReceiver()); -@@ -35,7 +35,7 @@ UtilityBlinkPlatformWithSandboxSupportImpl:: - +@@ -40,7 +40,7 @@ UtilityBlinkPlatformWithSandboxSupportImpl:: blink::WebSandboxSupport* UtilityBlinkPlatformWithSandboxSupportImpl::GetSandboxSupport() { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) return sandbox_support_.get(); #else return nullptr; diff --git a/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.h b/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.h index fbf629fa8aa6..34259cf2bd22 100644 --- a/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.h +++ b/www/chromium/files/patch-content_utility_utility__blink__platform__with__sandbox__support__impl.h @@ -1,11 +1,11 @@ ---- content/utility/utility_blink_platform_with_sandbox_support_impl.h.orig 2023-05-31 08:12:17 UTC +--- content/utility/utility_blink_platform_with_sandbox_support_impl.h.orig 2025-03-05 08:14:56 UTC +++ content/utility/utility_blink_platform_with_sandbox_support_impl.h -@@ -33,7 +33,7 @@ class UtilityBlinkPlatformWithSandboxSupportImpl : pub - blink::WebSandboxSupport* GetSandboxSupport() override; +@@ -34,7 +34,7 @@ class UtilityBlinkPlatformWithSandboxSupportImpl : pub private: --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) std::unique_ptr<blink::WebSandboxSupport> sandbox_support_; #endif }; diff --git a/www/chromium/files/patch-content_utility_utility__main.cc b/www/chromium/files/patch-content_utility_utility__main.cc index 0ad7aa73724d..f8b3e99ab9e0 100644 --- a/www/chromium/files/patch-content_utility_utility__main.cc +++ b/www/chromium/files/patch-content_utility_utility__main.cc @@ -1,8 +1,8 @@ ---- content/utility/utility_main.cc.orig 2024-04-19 13:02:56 UTC +--- content/utility/utility_main.cc.orig 2025-07-02 06:08:04 UTC +++ content/utility/utility_main.cc -@@ -37,17 +37,21 @@ - #include "third_party/icu/source/common/unicode/unistr.h" - #include "third_party/icu/source/i18n/unicode/timezone.h" +@@ -37,15 +37,19 @@ + #include "services/tracing/public/cpp/trace_startup.h" + #include "services/video_effects/public/cpp/buildflags.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) @@ -10,46 +10,41 @@ #include "base/files/file_util.h" #include "base/pickle.h" #include "content/child/sandboxed_process_thread_type_handler.h" -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ++#if !BUILDFLAG(IS_BSD) #include "content/common/gpu_pre_sandbox_hook_linux.h" +#endif #include "content/public/common/content_descriptor_keys.h" #include "content/utility/speech/speech_recognition_sandbox_hook_linux.h" - #include "gpu/config/gpu_info_collector.h" - #include "media/gpu/sandbox/hardware_video_encoding_sandbox_hook_linux.h" +#if !BUILDFLAG(IS_BSD) #include "sandbox/policy/linux/sandbox_linux.h" +#endif #include "services/audio/audio_sandbox_hook_linux.h" #include "services/network/network_sandbox_hook_linux.h" - // gn check is not smart enough to realize that this include only applies to -@@ -59,10 +63,15 @@ - #endif - #endif + #include "services/screen_ai/buildflags/buildflags.h" +@@ -70,7 +74,12 @@ --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "media/gpu/sandbox/hardware_video_decoding_sandbox_hook_linux.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +-#if BUILDFLAG(ENABLE_VIDEO_EFFECTS) && BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_BSD) +#include "sandbox/policy/sandbox.h" +#include "content/common/gpu_pre_sandbox_hook_bsd.h" +#endif + - #if BUILDFLAG(IS_CHROMEOS_ASH) - #include "chromeos/ash/components/assistant/buildflags.h" - #include "chromeos/ash/services/ime/ime_sandbox_hook.h" -@@ -74,7 +83,7 @@ - #endif // BUILDFLAG(IS_CHROMEOS_ASH) ++#if BUILDFLAG(ENABLE_VIDEO_EFFECTS) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) + #include "services/video_effects/video_effects_sandbox_hook_linux.h" // nogncheck + #endif // BUILDFLAG(IS_LINUX) - #if (BUILDFLAG(ENABLE_SCREEN_AI_SERVICE) && \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS))) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD))) - #include "services/screen_ai/public/cpp/utilities.h" // nogncheck - #include "services/screen_ai/sandbox/screen_ai_sandbox_hook_linux.h" // nogncheck - #endif -@@ -101,7 +110,7 @@ namespace content { +@@ -105,7 +114,7 @@ + sandbox::TargetServices* g_utility_target_services = nullptr; + #endif // BUILDFLAG(IS_WIN) + +-#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION) && BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) + #include "components/services/on_device_translation/sandbox_hook.h" + #endif // BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION) && BUILDFLAG(IS_LINUX) + +@@ -113,7 +122,7 @@ namespace content { namespace { @@ -58,38 +53,18 @@ std::vector<std::string> GetNetworkContextsParentDirectories() { base::MemoryMappedFile::Region region; base::ScopedFD read_pipe_fd = base::FileDescriptorStore::GetInstance().TakeFD( -@@ -127,9 +136,10 @@ std::vector<std::string> GetNetworkContextsParentDirec - return dirs; - } - -+#if !BUILDFLAG(IS_BSD) - bool ShouldUseAmdGpuPolicy(sandbox::mojom::Sandbox sandbox_type) { - const bool obtain_gpu_info = --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - sandbox_type == sandbox::mojom::Sandbox::kHardwareVideoDecoding || - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) - sandbox_type == sandbox::mojom::Sandbox::kHardwareVideoEncoding; -@@ -144,6 +154,7 @@ bool ShouldUseAmdGpuPolicy(sandbox::mojom::Sandbox san - - return false; - } -+#endif - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - - #if BUILDFLAG(IS_WIN) -@@ -252,7 +263,8 @@ int UtilityMain(MainFunctionParams parameters) { - } +@@ -252,7 +261,8 @@ int UtilityMain(MainFunctionParams parameters) { + CHECK(on_device_model::OnDeviceModelService::PreSandboxInit()); } -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +// XXX BSD +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && !BUILDFLAG(IS_BSD) - // Thread type delegate of the process should be registered before - // first thread type change in ChildProcess constructor. - // It also needs to be registered before the process has multiple threads, -@@ -263,7 +275,7 @@ int UtilityMain(MainFunctionParams parameters) { - } + // Thread type delegate of the process should be registered before first + // thread type change in ChildProcess constructor. It also needs to be + // registered before the process has multiple threads, which may race with +@@ -260,7 +270,7 @@ int UtilityMain(MainFunctionParams parameters) { + SandboxedProcessThreadTypeHandler::Create(); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -97,16 +72,25 @@ // Initializes the sandbox before any threads are created. // TODO(jorgelo): move this after GTK initialization when we enable a strict // Seccomp-BPF policy. -@@ -301,7 +313,7 @@ int UtilityMain(MainFunctionParams parameters) { - screen_ai::GetBinaryPathSwitch())); +@@ -292,7 +302,7 @@ int UtilityMain(MainFunctionParams parameters) { + pre_sandbox_hook = + base::BindOnce(&speech::SpeechRecognitionPreSandboxHook); break; +-#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION) && BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(ENABLE_ON_DEVICE_TRANSLATION) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) + case sandbox::mojom::Sandbox::kOnDeviceTranslation: + pre_sandbox_hook = base::BindOnce( + &on_device_translation::OnDeviceTranslationSandboxHook); +@@ -308,7 +318,7 @@ int UtilityMain(MainFunctionParams parameters) { + #else + NOTREACHED(); #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - case sandbox::mojom::Sandbox::kHardwareVideoDecoding: +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + case sandbox::mojom::Sandbox::kVideoEffects: + #if BUILDFLAG(ENABLE_VIDEO_EFFECTS) pre_sandbox_hook = - base::BindOnce(&media::HardwareVideoDecodingPreSandboxHook); -@@ -328,6 +340,7 @@ int UtilityMain(MainFunctionParams parameters) { +@@ -343,6 +353,7 @@ int UtilityMain(MainFunctionParams parameters) { default: break; } @@ -114,7 +98,7 @@ if (!sandbox::policy::IsUnsandboxedSandboxType(sandbox_type) && (parameters.zygote_child || !pre_sandbox_hook.is_null())) { sandbox_options.use_amd_specific_policies = -@@ -335,6 +348,11 @@ int UtilityMain(MainFunctionParams parameters) { +@@ -350,6 +361,11 @@ int UtilityMain(MainFunctionParams parameters) { sandbox::policy::Sandbox::Initialize( sandbox_type, std::move(pre_sandbox_hook), sandbox_options); } diff --git a/www/chromium/files/patch-content_utility_utility__thread__impl.cc b/www/chromium/files/patch-content_utility_utility__thread__impl.cc index 508558300978..9c22d11a1a59 100644 --- a/www/chromium/files/patch-content_utility_utility__thread__impl.cc +++ b/www/chromium/files/patch-content_utility_utility__thread__impl.cc @@ -1,6 +1,6 @@ ---- content/utility/utility_thread_impl.cc.orig 2024-02-23 21:04:38 UTC +--- content/utility/utility_thread_impl.cc.orig 2024-05-21 18:07:39 UTC +++ content/utility/utility_thread_impl.cc -@@ -32,7 +32,7 @@ +@@ -31,7 +31,7 @@ #include "mojo/public/cpp/bindings/pending_receiver.h" #include "mojo/public/cpp/bindings/service_factory.h" @@ -9,7 +9,7 @@ #include "content/child/sandboxed_process_thread_type_handler.h" #endif -@@ -252,7 +252,8 @@ void UtilityThreadImpl::Init() { +@@ -251,7 +251,8 @@ void UtilityThreadImpl::Init() { GetContentClient()->utility()->UtilityThreadStarted(); diff --git a/www/chromium/files/patch-content_zygote_zygote__linux.cc b/www/chromium/files/patch-content_zygote_zygote__linux.cc index 6c2be1d7240c..4cb3060a4e99 100644 --- a/www/chromium/files/patch-content_zygote_zygote__linux.cc +++ b/www/chromium/files/patch-content_zygote_zygote__linux.cc @@ -1,4 +1,4 @@ ---- content/zygote/zygote_linux.cc.orig 2024-03-22 08:19:40 UTC +--- content/zygote/zygote_linux.cc.orig 2025-05-05 10:57:53 UTC +++ content/zygote/zygote_linux.cc @@ -1,6 +1,7 @@ // Copyright 2012 The Chromium Authors @@ -8,7 +8,7 @@ #include "content/zygote/zygote_linux.h" -@@ -717,3 +718,4 @@ void Zygote::HandleReinitializeLoggingRequest(base::Pi +@@ -705,3 +706,4 @@ void Zygote::HandleReinitializeLoggingRequest(base::Pi } } // namespace content diff --git a/www/chromium/files/patch-device_gamepad_BUILD.gn b/www/chromium/files/patch-device_gamepad_BUILD.gn index 6047f69d8591..f63b0c75fed7 100644 --- a/www/chromium/files/patch-device_gamepad_BUILD.gn +++ b/www/chromium/files/patch-device_gamepad_BUILD.gn @@ -1,6 +1,6 @@ ---- device/gamepad/BUILD.gn.orig 2023-11-03 10:09:45 UTC +--- device/gamepad/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ device/gamepad/BUILD.gn -@@ -99,7 +99,7 @@ component("gamepad") { +@@ -98,7 +98,7 @@ component("gamepad") { "hid_writer_linux.cc", "hid_writer_linux.h", ] diff --git a/www/chromium/files/patch-device_gamepad_gamepad__provider.cc b/www/chromium/files/patch-device_gamepad_gamepad__provider.cc index 9cef1ce3c477..8730f7e560f7 100644 --- a/www/chromium/files/patch-device_gamepad_gamepad__provider.cc +++ b/www/chromium/files/patch-device_gamepad_gamepad__provider.cc @@ -1,6 +1,6 @@ ---- device/gamepad/gamepad_provider.cc.orig 2023-03-09 06:31:50 UTC +--- device/gamepad/gamepad_provider.cc.orig 2025-07-02 06:08:04 UTC +++ device/gamepad/gamepad_provider.cc -@@ -219,7 +219,7 @@ void GamepadProvider::Initialize(std::unique_ptr<Gamep +@@ -155,7 +155,7 @@ void GamepadProvider::Initialize(std::unique_ptr<Gamep if (!polling_thread_) polling_thread_ = std::make_unique<base::Thread>("Gamepad polling thread"); diff --git a/www/chromium/files/patch-extensions_browser_api_api__browser__context__keyed__service__factories.cc b/www/chromium/files/patch-extensions_browser_api_api__browser__context__keyed__service__factories.cc index f1aa3cddf900..588baacf87fa 100644 --- a/www/chromium/files/patch-extensions_browser_api_api__browser__context__keyed__service__factories.cc +++ b/www/chromium/files/patch-extensions_browser_api_api__browser__context__keyed__service__factories.cc @@ -1,11 +1,11 @@ ---- extensions/browser/api/api_browser_context_keyed_service_factories.cc.orig 2024-03-22 08:19:40 UTC +--- extensions/browser/api/api_browser_context_keyed_service_factories.cc.orig 2025-07-02 06:08:04 UTC +++ extensions/browser/api/api_browser_context_keyed_service_factories.cc -@@ -102,7 +102,7 @@ void EnsureApiBrowserContextKeyedServiceFactoriesBuilt +@@ -121,7 +121,7 @@ void EnsureApiBrowserContextKeyedServiceFactoriesBuilt + MediaPerceptionAPIManager::GetFactoryInstance(); #endif - MessageService::GetFactoryInstance(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || \ - BUILDFLAG(IS_MAC) + BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) NetworkingPrivateEventRouterFactory::GetInstance(); #endif - OffscreenDocumentManager::GetFactory(); + PrinterProviderAPIFactory::GetInstance(); diff --git a/www/chromium/files/patch-extensions_browser_api_management_management__api.cc b/www/chromium/files/patch-extensions_browser_api_management_management__api.cc index 84f048583d83..a40fd8b05e00 100644 --- a/www/chromium/files/patch-extensions_browser_api_management_management__api.cc +++ b/www/chromium/files/patch-extensions_browser_api_management_management__api.cc @@ -1,11 +1,11 @@ ---- extensions/browser/api/management/management_api.cc.orig 2024-03-22 08:19:40 UTC +--- extensions/browser/api/management/management_api.cc.orig 2025-05-28 14:55:43 UTC +++ extensions/browser/api/management/management_api.cc -@@ -280,7 +280,7 @@ bool PlatformSupportsApprovalFlowForExtensions() { - #if BUILDFLAG(IS_CHROMEOS) - // ChromeOS devices have this feature already shipped. +@@ -284,7 +284,7 @@ void AddExtensionInfo(const Extension* source_extensio + + bool PlatformSupportsApprovalFlowForExtensions() { + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) return true; --#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - return base::FeatureList::IsEnabled( - supervised_user::kEnableExtensionsPermissionsForSupervisedUsersOnDesktop); #else + return false; diff --git a/www/chromium/files/patch-extensions_browser_api_messaging_message__service.cc b/www/chromium/files/patch-extensions_browser_api_messaging_message__service.cc index 72ae18751e3c..779ec03bb8a8 100644 --- a/www/chromium/files/patch-extensions_browser_api_messaging_message__service.cc +++ b/www/chromium/files/patch-extensions_browser_api_messaging_message__service.cc @@ -1,6 +1,6 @@ ---- extensions/browser/api/messaging/message_service.cc.orig 2024-03-22 08:19:40 UTC +--- extensions/browser/api/messaging/message_service.cc.orig 2025-05-05 10:57:53 UTC +++ extensions/browser/api/messaging/message_service.cc -@@ -71,7 +71,7 @@ namespace { +@@ -81,7 +81,7 @@ namespace { const char kReceivingEndDoesntExistError[] = "Could not establish connection. Receiving end does not exist."; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ @@ -9,7 +9,7 @@ const char kMissingPermissionError[] = "Access to native messaging requires nativeMessaging permission."; const char kProhibitedByPoliciesError[] = -@@ -541,7 +541,7 @@ void MessageService::OpenChannelToNativeAppImpl( +@@ -673,7 +673,7 @@ void MessageService::OpenChannelToNativeAppImpl( return; #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-extensions_browser_api_networking__private_networking__private__delegate__factory.cc b/www/chromium/files/patch-extensions_browser_api_networking__private_networking__private__delegate__factory.cc index f8459b174feb..995e19630873 100644 --- a/www/chromium/files/patch-extensions_browser_api_networking__private_networking__private__delegate__factory.cc +++ b/www/chromium/files/patch-extensions_browser_api_networking__private_networking__private__delegate__factory.cc @@ -1,20 +1,29 @@ ---- extensions/browser/api/networking_private/networking_private_delegate_factory.cc.orig 2023-10-11 18:22:24 UTC +--- extensions/browser/api/networking_private/networking_private_delegate_factory.cc.orig 2025-01-15 09:18:26 UTC +++ extensions/browser/api/networking_private/networking_private_delegate_factory.cc -@@ -14,7 +14,7 @@ +@@ -12,7 +12,7 @@ + + #if BUILDFLAG(IS_CHROMEOS) #include "extensions/browser/api/networking_private/networking_private_chromeos.h" - #elif BUILDFLAG(IS_CHROMEOS_LACROS) - #include "extensions/browser/api/networking_private/networking_private_lacros.h" -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "extensions/browser/api/networking_private/networking_private_linux.h" #elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) #include "components/wifi/wifi_service.h" -@@ -67,7 +67,7 @@ NetworkingPrivateDelegateFactory::BuildServiceInstance +@@ -63,7 +63,7 @@ NetworkingPrivateDelegateFactory::BuildServiceInstance + std::unique_ptr<NetworkingPrivateDelegate> delegate; + #if BUILDFLAG(IS_CHROMEOS) delegate = std::make_unique<NetworkingPrivateChromeOS>(browser_context); - #elif BUILDFLAG(IS_CHROMEOS_LACROS) - delegate = std::make_unique<NetworkingPrivateLacros>(browser_context); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) delegate = std::make_unique<NetworkingPrivateLinux>(); #elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) std::unique_ptr<wifi::WiFiService> wifi_service(wifi::WiFiService::Create()); +@@ -74,7 +74,7 @@ NetworkingPrivateDelegateFactory::BuildServiceInstance + #endif + + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ +- BUILDFLAG(IS_MAC) ++ BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + if (ui_factory_) { + delegate->set_ui_delegate(ui_factory_->CreateDelegate()); + } diff --git a/www/chromium/files/patch-extensions_common_api___permission__features.json b/www/chromium/files/patch-extensions_common_api___permission__features.json index bfa6bbeb35e9..421772f84bb9 100644 --- a/www/chromium/files/patch-extensions_common_api___permission__features.json +++ b/www/chromium/files/patch-extensions_common_api___permission__features.json @@ -1,15 +1,15 @@ ---- extensions/common/api/_permission_features.json.orig 2023-12-10 06:10:27 UTC +--- extensions/common/api/_permission_features.json.orig 2025-04-04 08:52:13 UTC +++ extensions/common/api/_permission_features.json -@@ -138,7 +138,7 @@ +@@ -134,7 +134,7 @@ { "channel": "stable", "extension_types": ["platform_app"], -- "platforms": ["chromeos", "lacros", "win", "mac", "linux"], -+ "platforms": ["chromeos", "lacros", "win", "mac", "linux", "openbsd", "freebsd"], +- "platforms": ["chromeos", "win", "mac", "linux"], ++ "platforms": ["chromeos", "win", "mac", "linux", "openbsd", "freebsd"], "allowlist": [ "1C93BD3CF875F4A73C0B2A163BB8FBDA8B8B3D80", // http://crbug.com/387169 "A3BC37E2148AC4E99BE4B16AF9D42DD1E592BBBE", // http://crbug.com/387169 -@@ -432,7 +432,7 @@ +@@ -419,7 +419,7 @@ }, { "channel": "stable", "extension_types": ["extension", "legacy_packaged_app", "platform_app"], @@ -18,12 +18,12 @@ "allowlist": [ "0DE0F05680A4A056BCEC864ED8DDA84296F82B40", // http://crbug.com/434651 "1C93BD3CF875F4A73C0B2A163BB8FBDA8B8B3D80", // http://crbug.com/293683 -@@ -476,7 +476,7 @@ +@@ -463,7 +463,7 @@ "networkingPrivate": { "channel": "stable", "extension_types": ["extension", "legacy_packaged_app", "platform_app"], -- "platforms": ["chromeos", "lacros", "mac", "win", "linux", "fuchsia"], -+ "platforms": ["chromeos", "lacros", "mac", "win", "linux", "fuchsia", "openbsd", "freebsd"], +- "platforms": ["chromeos", "mac", "win", "linux", "fuchsia"], ++ "platforms": ["chromeos", "mac", "win", "linux", "fuchsia", "openbsd", "freebsd"], "allowlist": [ // DO NOT ADD ANY MORE ENTRIES HERE. // networkingPrivate is being migrated to networking.onc. diff --git a/www/chromium/files/patch-extensions_common_command.cc b/www/chromium/files/patch-extensions_common_command.cc index 56b79dc1654b..e2c1af7ef1e2 100644 --- a/www/chromium/files/patch-extensions_common_command.cc +++ b/www/chromium/files/patch-extensions_common_command.cc @@ -1,11 +1,11 @@ ---- extensions/common/command.cc.orig 2024-02-23 21:04:38 UTC +--- extensions/common/command.cc.orig 2025-03-05 08:14:56 UTC +++ extensions/common/command.cc -@@ -283,7 +283,7 @@ std::string Command::CommandPlatform() { - return values::kKeybindingPlatformMac; +@@ -116,7 +116,7 @@ std::string Command::CommandPlatform() { + return ui::kKeybindingPlatformMac; #elif BUILDFLAG(IS_CHROMEOS) - return values::kKeybindingPlatformChromeOs; + return ui::kKeybindingPlatformChromeOs; -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return values::kKeybindingPlatformLinux; + return ui::kKeybindingPlatformLinux; #elif BUILDFLAG(IS_FUCHSIA) - // TODO(crbug.com/1312215): Change this once we decide what string should be + // TODO(crbug.com/40220501): Change this once we decide what string should be diff --git a/www/chromium/files/patch-extensions_common_features_feature.cc b/www/chromium/files/patch-extensions_common_features_feature.cc index c4438ab9628a..6a3bc4866c1a 100644 --- a/www/chromium/files/patch-extensions_common_features_feature.cc +++ b/www/chromium/files/patch-extensions_common_features_feature.cc @@ -1,6 +1,6 @@ ---- extensions/common/features/feature.cc.orig 2023-09-13 12:11:42 UTC +--- extensions/common/features/feature.cc.orig 2025-01-15 09:18:26 UTC +++ extensions/common/features/feature.cc -@@ -34,6 +34,8 @@ Feature::Platform Feature::GetCurrentPlatform() { +@@ -29,6 +29,8 @@ Feature::Platform Feature::GetCurrentPlatform() { return WIN_PLATFORM; #elif BUILDFLAG(IS_FUCHSIA) return FUCHSIA_PLATFORM; diff --git a/www/chromium/files/patch-extensions_renderer_bindings_api__binding__util.cc b/www/chromium/files/patch-extensions_renderer_bindings_api__binding__util.cc index 80e3d05fea23..57203e00e6f6 100644 --- a/www/chromium/files/patch-extensions_renderer_bindings_api__binding__util.cc +++ b/www/chromium/files/patch-extensions_renderer_bindings_api__binding__util.cc @@ -1,8 +1,8 @@ ---- extensions/renderer/bindings/api_binding_util.cc.orig 2022-02-28 16:54:41 UTC +--- extensions/renderer/bindings/api_binding_util.cc.orig 2025-03-05 08:14:56 UTC +++ extensions/renderer/bindings/api_binding_util.cc -@@ -132,7 +132,7 @@ std::string GetPlatformString() { - return "lacros"; - #elif BUILDFLAG(IS_CHROMEOS_ASH) && !BUILDFLAG(IS_CHROMEOS_LACROS) +@@ -129,7 +129,7 @@ void InvalidateContext(v8::Local<v8::Context> context) + std::string GetPlatformString() { + #if BUILDFLAG(IS_CHROMEOS) return "chromeos"; -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-extensions_shell_app_shell__main__delegate.cc b/www/chromium/files/patch-extensions_shell_app_shell__main__delegate.cc index 488b0f4b222d..e3c204b6ebad 100644 --- a/www/chromium/files/patch-extensions_shell_app_shell__main__delegate.cc +++ b/www/chromium/files/patch-extensions_shell_app_shell__main__delegate.cc @@ -1,6 +1,6 @@ ---- extensions/shell/app/shell_main_delegate.cc.orig 2024-04-19 13:02:56 UTC +--- extensions/shell/app/shell_main_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ extensions/shell/app/shell_main_delegate.cc -@@ -43,7 +43,7 @@ +@@ -41,7 +41,7 @@ #if BUILDFLAG(IS_WIN) #include "base/base_paths_win.h" #include "base/process/process_info.h" @@ -9,7 +9,7 @@ #include "base/nix/xdg_util.h" #elif BUILDFLAG(IS_MAC) #include "base/base_paths_mac.h" -@@ -63,7 +63,7 @@ base::FilePath GetDataPath() { +@@ -61,7 +61,7 @@ base::FilePath GetDataPath() { } base::FilePath data_dir; diff --git a/www/chromium/files/patch-extensions_shell_browser_api_runtime_shell__runtime__api__delegate.cc b/www/chromium/files/patch-extensions_shell_browser_api_runtime_shell__runtime__api__delegate.cc index bc82da76db4d..1f6d6122d608 100644 --- a/www/chromium/files/patch-extensions_shell_browser_api_runtime_shell__runtime__api__delegate.cc +++ b/www/chromium/files/patch-extensions_shell_browser_api_runtime_shell__runtime__api__delegate.cc @@ -1,11 +1,11 @@ ---- extensions/shell/browser/api/runtime/shell_runtime_api_delegate.cc.orig 2023-05-31 08:12:17 UTC +--- extensions/shell/browser/api/runtime/shell_runtime_api_delegate.cc.orig 2025-01-15 09:18:26 UTC +++ extensions/shell/browser/api/runtime/shell_runtime_api_delegate.cc -@@ -44,7 +44,7 @@ void ShellRuntimeAPIDelegate::OpenURL(const GURL& unin +@@ -45,7 +45,7 @@ void ShellRuntimeAPIDelegate::OpenURL(const GURL& unin bool ShellRuntimeAPIDelegate::GetPlatformInfo(PlatformInfo* info) { - #if BUILDFLAG(IS_CHROMEOS_ASH) + #if BUILDFLAG(IS_CHROMEOS) info->os = api::runtime::PlatformOs::kCros; --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) info->os = api::runtime::PlatformOs::kLinux; #endif return true; diff --git a/www/chromium/files/patch-extensions_shell_browser_shell__browser__main__parts.cc b/www/chromium/files/patch-extensions_shell_browser_shell__browser__main__parts.cc index 77da3a83720f..915cb2641531 100644 --- a/www/chromium/files/patch-extensions_shell_browser_shell__browser__main__parts.cc +++ b/www/chromium/files/patch-extensions_shell_browser_shell__browser__main__parts.cc @@ -1,11 +1,11 @@ ---- extensions/shell/browser/shell_browser_main_parts.cc.orig 2022-09-24 10:57:32 UTC +--- extensions/shell/browser/shell_browser_main_parts.cc.orig 2025-01-15 09:18:26 UTC +++ extensions/shell/browser/shell_browser_main_parts.cc -@@ -150,7 +150,7 @@ void ShellBrowserMainParts::PostCreateMainMessageLoop( +@@ -137,7 +137,7 @@ void ShellBrowserMainParts::PostCreateMainMessageLoop( switches::kAppShellAllowRoaming)) { network_controller_->SetCellularAllowRoaming(true); } --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // app_shell doesn't need GTK, so the fake input method context can work. // See crbug.com/381852 and revision fb69f142. // TODO(michaelpg): Verify this works for target environments. diff --git a/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.cc b/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.cc index 6d35272bfa2a..9c4daad7680e 100644 --- a/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.cc +++ b/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.cc @@ -1,11 +1,20 @@ ---- extensions/shell/browser/shell_extensions_api_client.cc.orig 2022-02-28 16:54:41 UTC +--- extensions/shell/browser/shell_extensions_api_client.cc.orig 2025-05-28 14:55:43 UTC +++ extensions/shell/browser/shell_extensions_api_client.cc -@@ -58,7 +58,7 @@ ShellExtensionsAPIClient::CreateDisplayInfoProvider() +@@ -18,7 +18,7 @@ + #include "extensions/shell/browser/shell_extension_web_contents_observer.h" + #include "extensions/shell/browser/shell_virtual_keyboard_delegate.h" - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "extensions/shell/browser/api/file_system/shell_file_system_delegate.h" + #endif + +@@ -76,7 +76,7 @@ ShellExtensionsAPIClient::CreateDisplayInfoProvider() + return std::make_unique<ShellDisplayInfoProvider>(); + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) FileSystemDelegate* ShellExtensionsAPIClient::GetFileSystemDelegate() { if (!file_system_delegate_) file_system_delegate_ = std::make_unique<ShellFileSystemDelegate>(); diff --git a/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.h b/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.h index 5c420402f722..162a04ef239a 100644 --- a/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.h +++ b/www/chromium/files/patch-extensions_shell_browser_shell__extensions__api__client.h @@ -1,20 +1,19 @@ ---- extensions/shell/browser/shell_extensions_api_client.h.orig 2022-02-28 16:54:41 UTC +--- extensions/shell/browser/shell_extensions_api_client.h.orig 2025-05-28 14:55:43 UTC +++ extensions/shell/browser/shell_extensions_api_client.h -@@ -36,7 +36,7 @@ class ShellExtensionsAPIClient : public ExtensionsAPIC +@@ -42,14 +42,14 @@ class ShellExtensionsAPIClient : public ExtensionsAPIC + content::BrowserContext* browser_context) const override; + std::unique_ptr<DisplayInfoProvider> CreateDisplayInfoProvider() const override; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) FileSystemDelegate* GetFileSystemDelegate() override; #endif MessagingDelegate* GetMessagingDelegate() override; -@@ -45,7 +45,7 @@ class ShellExtensionsAPIClient : public ExtensionsAPIC + FeedbackPrivateDelegate* GetFeedbackPrivateDelegate() override; + private: - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) std::unique_ptr<FileSystemDelegate> file_system_delegate_; #endif std::unique_ptr<MessagingDelegate> messaging_delegate_; diff --git a/www/chromium/files/patch-google__apis_gcm_engine_heartbeat__manager.cc b/www/chromium/files/patch-google__apis_gcm_engine_heartbeat__manager.cc index 20bb48c3309b..47326ab138a6 100644 --- a/www/chromium/files/patch-google__apis_gcm_engine_heartbeat__manager.cc +++ b/www/chromium/files/patch-google__apis_gcm_engine_heartbeat__manager.cc @@ -1,29 +1,29 @@ ---- google_apis/gcm/engine/heartbeat_manager.cc.orig 2023-04-28 17:01:32 UTC +--- google_apis/gcm/engine/heartbeat_manager.cc.orig 2025-04-04 08:52:13 UTC +++ google_apis/gcm/engine/heartbeat_manager.cc -@@ -32,7 +32,7 @@ const int kMinClientHeartbeatIntervalMs = 1000 * 30; +@@ -31,7 +31,7 @@ const int kMinClientHeartbeatIntervalMs = 1000 * 30; // Minimum time spent sleeping before we force a new heartbeat. const int kMinSuspendTimeMs = 1000 * 10; // 10 seconds. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // The period at which to check if the heartbeat time has passed. Used to // protect against platforms where the timer is delayed by the system being // suspended. Only needed on linux because the other OSes provide a standard -@@ -191,7 +191,7 @@ void HeartbeatManager::RestartTimer() { +@@ -190,7 +190,7 @@ void HeartbeatManager::RestartTimer() { base::BindRepeating(&HeartbeatManager::OnHeartbeatTriggered, weak_ptr_factory_.GetWeakPtr())); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Windows, Mac, Android, iOS, and Chrome OS all provide a way to be notified // when the system is suspending or resuming. The only one that does not is // Linux so we need to poll to check for missed heartbeats. -@@ -214,7 +214,7 @@ void HeartbeatManager::CheckForMissedHeartbeat() { +@@ -213,7 +213,7 @@ void HeartbeatManager::CheckForMissedHeartbeat() { return; } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Otherwise check again later. io_task_runner_->PostDelayedTask( FROM_HERE, diff --git a/www/chromium/files/patch-gpu_command__buffer_client_fake__gpu__memory__buffer.cc b/www/chromium/files/patch-gpu_command__buffer_client_fake__gpu__memory__buffer.cc new file mode 100644 index 000000000000..adcb4cf7cc94 --- /dev/null +++ b/www/chromium/files/patch-gpu_command__buffer_client_fake__gpu__memory__buffer.cc @@ -0,0 +1,29 @@ +--- gpu/command_buffer/client/fake_gpu_memory_buffer.cc.orig 2025-07-02 06:08:04 UTC ++++ gpu/command_buffer/client/fake_gpu_memory_buffer.cc +@@ -14,7 +14,7 @@ + #include "media/base/format_utils.h" + #include "media/base/video_frame.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include <fcntl.h> + #include <sys/stat.h> + #include <sys/types.h> +@@ -29,7 +29,7 @@ namespace gpu { + + namespace { + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + base::ScopedFD GetDummyFD() { + base::ScopedFD fd(open("/dev/zero", O_RDWR)); + DCHECK(fd.is_valid()); +@@ -41,7 +41,7 @@ static base::AtomicSequenceNumber buffer_id_generator; + + } // namespace + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + gfx::GpuMemoryBufferHandle CreatePixmapHandleForTesting( + const gfx::Size& size, + gfx::BufferFormat format, diff --git a/www/chromium/files/patch-gpu_command__buffer_client_fake__gpu__memory__buffer.h b/www/chromium/files/patch-gpu_command__buffer_client_fake__gpu__memory__buffer.h new file mode 100644 index 000000000000..aed66a84d9b0 --- /dev/null +++ b/www/chromium/files/patch-gpu_command__buffer_client_fake__gpu__memory__buffer.h @@ -0,0 +1,11 @@ +--- gpu/command_buffer/client/fake_gpu_memory_buffer.h.orig 2025-07-02 06:08:04 UTC ++++ gpu/command_buffer/client/fake_gpu_memory_buffer.h +@@ -12,7 +12,7 @@ + + namespace gpu { + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // This method is used by tests to create a fake pixmap handle instead of + // creating a FakeGpuMemoryBuffer. Once all tests are converted to use it, + // FakeGpuMemoryBuffer will be removed and this file will be renamed diff --git a/www/chromium/files/patch-gpu_command__buffer_common_gpu__memory__buffer__support.cc b/www/chromium/files/patch-gpu_command__buffer_common_gpu__memory__buffer__support.cc deleted file mode 100644 index e74e66f2535d..000000000000 --- a/www/chromium/files/patch-gpu_command__buffer_common_gpu__memory__buffer__support.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- gpu/command_buffer/common/gpu_memory_buffer_support.cc.orig 2024-04-19 13:02:56 UTC -+++ gpu/command_buffer/common/gpu_memory_buffer_support.cc -@@ -182,7 +182,7 @@ uint32_t GetPlatformSpecificTextureTarget() { - #if BUILDFLAG(IS_MAC) - return macos_specific_texture_target; - #elif BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - return GL_TEXTURE_EXTERNAL_OES; - #elif BUILDFLAG(IS_IOS) - return GL_TEXTURE_2D; -@@ -209,7 +209,7 @@ GPU_EXPORT bool NativeBufferNeedsPlatformSpecificTextu - gfx::BufferFormat format, - gfx::BufferPlane plane) { - #if BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ -- BUILDFLAG(IS_WIN) -+ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - // Always use GL_TEXTURE_2D as the target for RGB textures. - // https://crbug.com/916728 - if (format == gfx::BufferFormat::R_8 || format == gfx::BufferFormat::RG_88 || diff --git a/www/chromium/files/patch-gpu_command__buffer_service_dawn__context__provider.cc b/www/chromium/files/patch-gpu_command__buffer_service_dawn__context__provider.cc index 836149752058..7db455f200a2 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_dawn__context__provider.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_dawn__context__provider.cc @@ -1,6 +1,6 @@ ---- gpu/command_buffer/service/dawn_context_provider.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/command_buffer/service/dawn_context_provider.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/dawn_context_provider.cc -@@ -203,7 +203,7 @@ wgpu::BackendType DawnContextProvider::GetDefaultBacke +@@ -396,7 +396,7 @@ wgpu::BackendType DawnContextProvider::GetDefaultBacke return base::FeatureList::IsEnabled(features::kSkiaGraphiteDawnUseD3D12) ? wgpu::BackendType::D3D12 : wgpu::BackendType::D3D11; diff --git a/www/chromium/files/patch-gpu_command__buffer_service_gles2__cmd__decoder.cc b/www/chromium/files/patch-gpu_command__buffer_service_gles2__cmd__decoder.cc index d40c456e19a1..4a062bec01bf 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_gles2__cmd__decoder.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_gles2__cmd__decoder.cc @@ -1,6 +1,6 @@ ---- gpu/command_buffer/service/gles2_cmd_decoder.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/command_buffer/service/gles2_cmd_decoder.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/gles2_cmd_decoder.cc -@@ -2987,7 +2987,7 @@ GLES2Decoder* GLES2Decoder::Create( +@@ -2862,7 +2862,7 @@ GLES2Decoder* GLES2Decoder::Create( } // Allow linux to run fuzzers. diff --git a/www/chromium/files/patch-gpu_command__buffer_service_raster__decoder__unittest__context__lost.cc b/www/chromium/files/patch-gpu_command__buffer_service_raster__decoder__unittest__context__lost.cc new file mode 100644 index 000000000000..afd5b2a0b709 --- /dev/null +++ b/www/chromium/files/patch-gpu_command__buffer_service_raster__decoder__unittest__context__lost.cc @@ -0,0 +1,21 @@ +--- gpu/command_buffer/service/raster_decoder_unittest_context_lost.cc.orig 2025-04-04 08:52:13 UTC ++++ gpu/command_buffer/service/raster_decoder_unittest_context_lost.cc +@@ -15,6 +15,18 @@ using ::testing::Return; + using ::testing::SaveArg; + using ::testing::SetArrayArgument; + ++#ifndef GL_CONTEXT_LOST_KHR ++#define GL_CONTEXT_LOST_KHR 0x0507 ++#endif ++ ++#ifndef GL_GUILTY_CONTEXT_RESET_KHR ++#define GL_GUILTY_CONTEXT_RESET_KHR 0x8253 ++#endif ++ ++#ifndef GL_INNOCENT_CONTEXT_RESET_KHR ++#define GL_INNOCENT_CONTEXT_RESET_KHR 0x8254 ++#endif ++ + namespace gpu { + namespace raster { + diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__context__state.cc b/www/chromium/files/patch-gpu_command__buffer_service_shared__context__state.cc new file mode 100644 index 000000000000..47fb6016055d --- /dev/null +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__context__state.cc @@ -0,0 +1,29 @@ +--- gpu/command_buffer/service/shared_context_state.cc.orig 2025-05-28 14:55:43 UTC ++++ gpu/command_buffer/service/shared_context_state.cc +@@ -64,7 +64,7 @@ + #include "gpu/vulkan/vulkan_implementation.h" + #include "gpu/vulkan/vulkan_util.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "gpu/command_buffer/service/external_semaphore_pool.h" + #endif + +@@ -348,7 +348,7 @@ SharedContextState::SharedContextState( + if (gr_context_type_ == GrContextType::kVulkan) { + if (vk_context_provider_) { + #if BUILDFLAG(ENABLE_VULKAN) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) + external_semaphore_pool_ = std::make_unique<ExternalSemaphorePool>(this); + #endif + use_virtualized_gl_contexts_ = false; +@@ -385,7 +385,7 @@ SharedContextState::~SharedContextState() { + } + + #if BUILDFLAG(ENABLE_VULKAN) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) + external_semaphore_pool_.reset(); + #endif + diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__context__state.h b/www/chromium/files/patch-gpu_command__buffer_service_shared__context__state.h new file mode 100644 index 000000000000..d7f5b4fc5927 --- /dev/null +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__context__state.h @@ -0,0 +1,20 @@ +--- gpu/command_buffer/service/shared_context_state.h.orig 2025-05-28 14:55:43 UTC ++++ gpu/command_buffer/service/shared_context_state.h +@@ -238,7 +238,7 @@ class GPU_GLES2_EXPORT SharedContextState + return &memory_type_tracker_; + } + #if BUILDFLAG(ENABLE_VULKAN) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) + ExternalSemaphorePool* external_semaphore_pool() { + return external_semaphore_pool_.get(); + } +@@ -455,7 +455,7 @@ class GPU_GLES2_EXPORT SharedContextState + bool disable_check_reset_status_throttling_for_test_ = false; + + #if BUILDFLAG(ENABLE_VULKAN) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD)) + std::unique_ptr<ExternalSemaphorePool> external_semaphore_pool_; + #endif + diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_angle__vulkan__image__backing__factory.cc b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_angle__vulkan__image__backing__factory.cc index 373c63d6f2fb..8bdd24b1dd24 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_angle__vulkan__image__backing__factory.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_angle__vulkan__image__backing__factory.cc @@ -1,11 +1,20 @@ ---- gpu/command_buffer/service/shared_image/angle_vulkan_image_backing_factory.cc.orig 2024-02-23 21:04:38 UTC +--- gpu/command_buffer/service/shared_image/angle_vulkan_image_backing_factory.cc.orig 2025-05-05 10:57:53 UTC +++ gpu/command_buffer/service/shared_image/angle_vulkan_image_backing_factory.cc -@@ -21,7 +21,7 @@ namespace { +@@ -20,7 +20,7 @@ namespace { // TODO(penghuang): verify the scanout is the right usage for video playback. // crbug.com/1280798 - constexpr uint32_t kSupportedUsage = + constexpr SharedImageUsageSet kSupportedUsage = -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) SHARED_IMAGE_USAGE_SCANOUT | #endif SHARED_IMAGE_USAGE_GLES2_READ | SHARED_IMAGE_USAGE_GLES2_WRITE | +@@ -121,7 +121,7 @@ bool AngleVulkanImageBackingFactory::IsGMBSupported( + switch (gmb_type) { + case gfx::EMPTY_BUFFER: + return true; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + case gfx::NATIVE_PIXMAP: { + auto* vulkan_implementation = + context_state_->vk_context_provider()->GetVulkanImplementation(); diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing.cc b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing.cc index f722a1c9ab3c..daf8f8db357d 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing.cc @@ -1,6 +1,6 @@ ---- gpu/command_buffer/service/shared_image/external_vk_image_backing.cc.orig 2024-03-22 08:19:40 UTC +--- gpu/command_buffer/service/shared_image/external_vk_image_backing.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/shared_image/external_vk_image_backing.cc -@@ -50,7 +50,7 @@ +@@ -56,7 +56,7 @@ #include "ui/gl/gl_version_info.h" #include "ui/gl/scoped_binders.h" @@ -9,7 +9,7 @@ #include "gpu/command_buffer/service/shared_image/external_vk_image_dawn_representation.h" #if BUILDFLAG(DAWN_ENABLE_BACKEND_OPENGLES) #include "gpu/command_buffer/service/shared_image/dawn_gl_texture_representation.h" -@@ -689,7 +689,7 @@ std::unique_ptr<DawnImageRepresentation> ExternalVkIma +@@ -696,7 +696,7 @@ std::unique_ptr<DawnImageRepresentation> ExternalVkIma wgpu::BackendType backend_type, std::vector<wgpu::TextureFormat> view_formats, scoped_refptr<SharedContextState> context_state) { diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing__factory.cc b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing__factory.cc index e4a7a7a32ac6..9f59e2184d48 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing__factory.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_external__vk__image__backing__factory.cc @@ -1,11 +1,11 @@ ---- gpu/command_buffer/service/shared_image/external_vk_image_backing_factory.cc.orig 2024-03-22 08:19:40 UTC +--- gpu/command_buffer/service/shared_image/external_vk_image_backing_factory.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/shared_image/external_vk_image_backing_factory.cc -@@ -147,7 +147,7 @@ bool IsFormatSupported(viz::SharedImageFormat format, - } // namespace +@@ -140,7 +140,7 @@ bool IsFormatSupported(viz::SharedImageFormat format, - constexpr uint32_t kSupportedUsage = + SharedImageUsageSet SupportedUsage() { + SharedImageUsageSet supported_usage = -#if BUILDFLAG(IS_LINUX) && BUILDFLAG(USE_DAWN) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(USE_DAWN) - SHARED_IMAGE_USAGE_WEBGPU_READ | SHARED_IMAGE_USAGE_WEBGPU_WRITE | - SHARED_IMAGE_USAGE_WEBGPU_SWAP_CHAIN_TEXTURE | - SHARED_IMAGE_USAGE_WEBGPU_STORAGE_TEXTURE | + SHARED_IMAGE_USAGE_WEBGPU_READ | SHARED_IMAGE_USAGE_WEBGPU_WRITE | + SHARED_IMAGE_USAGE_WEBGPU_SWAP_CHAIN_TEXTURE | + SHARED_IMAGE_USAGE_WEBGPU_STORAGE_TEXTURE | diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__factory.cc b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__factory.cc index 7485b7a79566..4f0c643ec56a 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__factory.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__factory.cc @@ -1,6 +1,24 @@ ---- gpu/command_buffer/service/shared_image/shared_image_factory.cc.orig 2024-03-22 08:19:40 UTC +--- gpu/command_buffer/service/shared_image/shared_image_factory.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/shared_image/shared_image_factory.cc -@@ -144,7 +144,7 @@ gfx::GpuMemoryBufferType GetNativeBufferType() { +@@ -48,7 +48,7 @@ + #include "gpu/command_buffer/service/shared_image/angle_vulkan_image_backing_factory.h" + #include "gpu/vulkan/vulkan_device_queue.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + #include "gpu/command_buffer/service/shared_image/external_vk_image_backing_factory.h" + #endif + +@@ -102,7 +102,7 @@ const char* GmbTypeToString(gfx::GpuMemoryBufferType t + case gfx::IO_SURFACE_BUFFER: + return "platform"; + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + case gfx::NATIVE_PIXMAP: + return "platform"; + #endif +@@ -123,7 +123,7 @@ gfx::GpuMemoryBufferType GetNativeBufferType() { return gfx::GpuMemoryBufferType::IO_SURFACE_BUFFER; #elif BUILDFLAG(IS_ANDROID) return gfx::GpuMemoryBufferType::ANDROID_HARDWARE_BUFFER; @@ -9,3 +27,12 @@ return gfx::GpuMemoryBufferType::NATIVE_PIXMAP; #elif BUILDFLAG(IS_WIN) return gfx::GpuMemoryBufferType::DXGI_SHARED_HANDLE; +@@ -294,7 +294,7 @@ SharedImageFactory::SharedImageFactory( + context_state_, workarounds_); + factories_.push_back(std::move(ozone_factory)); + } +-#if BUILDFLAG(ENABLE_VULKAN) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA)) ++#if BUILDFLAG(ENABLE_VULKAN) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD)) + if (gr_context_type_ == GrContextType::kVulkan) { + auto external_vk_image_factory = + std::make_unique<ExternalVkImageBackingFactory>(context_state_); diff --git a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__manager.cc b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__manager.cc index b9b9c1fc9666..3ec9f6f00512 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__manager.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_shared__image_shared__image__manager.cc @@ -1,11 +1,11 @@ ---- gpu/command_buffer/service/shared_image/shared_image_manager.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/command_buffer/service/shared_image/shared_image_manager.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/shared_image/shared_image_manager.cc -@@ -569,7 +569,7 @@ bool SharedImageManager::SupportsScanoutImages() { +@@ -736,7 +736,7 @@ bool SharedImageManager::SupportsScanoutImages() { return true; #elif BUILDFLAG(IS_ANDROID) return base::AndroidHardwareBufferCompat::IsSupportAvailable(); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - return ui::OzonePlatform::GetInstance() - ->GetPlatformRuntimeProperties() - .supports_native_pixmaps; + return supports_overlays_on_ozone_; + #elif BUILDFLAG(IS_WIN) + return gl::DirectCompositionTextureSupported(); diff --git a/www/chromium/files/patch-gpu_command__buffer_service_webgpu__decoder__impl.cc b/www/chromium/files/patch-gpu_command__buffer_service_webgpu__decoder__impl.cc index 008d5db154d3..bd6250e8477f 100644 --- a/www/chromium/files/patch-gpu_command__buffer_service_webgpu__decoder__impl.cc +++ b/www/chromium/files/patch-gpu_command__buffer_service_webgpu__decoder__impl.cc @@ -1,15 +1,15 @@ ---- gpu/command_buffer/service/webgpu_decoder_impl.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/command_buffer/service/webgpu_decoder_impl.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/service/webgpu_decoder_impl.cc -@@ -1255,7 +1255,7 @@ void WebGPUDecoderImpl::RequestAdapterImpl( - force_fallback_adapter = true; - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (!shared_context_state_->GrContextIsVulkan() && - !shared_context_state_->IsGraphiteDawnVulkan() && - use_webgpu_adapter_ != WebGPUAdapterName::kOpenGLES) { -@@ -1922,7 +1922,7 @@ WebGPUDecoderImpl::AssociateMailboxDawn( +@@ -1790,7 +1790,7 @@ wgpu::Adapter WebGPUDecoderImpl::CreatePreferredAdapte + backend_types = {wgpu::BackendType::D3D12}; + #elif BUILDFLAG(IS_APPLE) + backend_types = {wgpu::BackendType::Metal}; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (shared_context_state_->GrContextIsVulkan() || + shared_context_state_->IsGraphiteDawnVulkan()) { + backend_types = {wgpu::BackendType::Vulkan}; +@@ -2032,7 +2032,7 @@ WebGPUDecoderImpl::AssociateMailboxDawn( } #if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_APPLE) && \ diff --git a/www/chromium/files/patch-gpu_command__buffer_tests_gl__gpu__memory__buffer__unittest.cc b/www/chromium/files/patch-gpu_command__buffer_tests_gl__gpu__memory__buffer__unittest.cc index 942f78f4835d..707a5fb6af81 100644 --- a/www/chromium/files/patch-gpu_command__buffer_tests_gl__gpu__memory__buffer__unittest.cc +++ b/www/chromium/files/patch-gpu_command__buffer_tests_gl__gpu__memory__buffer__unittest.cc @@ -1,6 +1,6 @@ ---- gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc.orig 2023-04-28 17:01:32 UTC +--- gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc -@@ -27,7 +27,7 @@ +@@ -29,7 +29,7 @@ #include "ui/gfx/half_float.h" #include "ui/gl/test/gl_test_support.h" @@ -9,7 +9,7 @@ #include "gpu/ipc/common/gpu_memory_buffer_impl_native_pixmap.h" #include "ui/gfx/linux/client_native_pixmap_factory_dmabuf.h" #endif -@@ -70,7 +70,7 @@ class GpuMemoryBufferTest : public testing::TestWithPa +@@ -72,7 +72,7 @@ class GpuMemoryBufferTest : public testing::TestWithPa GLManager gl_; }; diff --git a/www/chromium/files/patch-gpu_config_gpu__control__list.cc b/www/chromium/files/patch-gpu_config_gpu__control__list.cc index 2308ff445660..0627315ce916 100644 --- a/www/chromium/files/patch-gpu_config_gpu__control__list.cc +++ b/www/chromium/files/patch-gpu_config_gpu__control__list.cc @@ -1,15 +1,6 @@ ---- gpu/config/gpu_control_list.cc.orig 2024-01-30 07:53:34 UTC +--- gpu/config/gpu_control_list.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/config/gpu_control_list.cc -@@ -276,7 +276,7 @@ bool GpuControlList::More::GLVersionInfoMismatch( - GpuControlList::GLType GpuControlList::More::GetDefaultGLType() { - #if BUILDFLAG(IS_CHROMEOS) - return kGLTypeGL; --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_OPENBSD) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return kGLTypeGL; - #elif BUILDFLAG(IS_MAC) - return kGLTypeGL; -@@ -811,7 +811,7 @@ GpuControlList::OsType GpuControlList::GetOsType() { +@@ -830,7 +830,7 @@ GpuControlList::OsType GpuControlList::GetOsType() { return kOsAndroid; #elif BUILDFLAG(IS_FUCHSIA) return kOsFuchsia; diff --git a/www/chromium/files/patch-gpu_config_gpu__finch__features.cc b/www/chromium/files/patch-gpu_config_gpu__finch__features.cc index 95dc2b8a22da..087dcd722d21 100644 --- a/www/chromium/files/patch-gpu_config_gpu__finch__features.cc +++ b/www/chromium/files/patch-gpu_config_gpu__finch__features.cc @@ -1,20 +1,12 @@ ---- gpu/config/gpu_finch_features.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/config/gpu_finch_features.cc.orig 2025-04-04 08:52:13 UTC +++ gpu/config/gpu_finch_features.cc -@@ -145,7 +145,7 @@ const base::FeatureParam<std::string> +@@ -155,7 +155,8 @@ BASE_FEATURE(kAllowHardwareBufferUsageFlagsFromVulkanF BASE_FEATURE(kDefaultEnableGpuRasterization, "DefaultEnableGpuRasterization", #if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) -+ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT -@@ -158,7 +158,7 @@ BASE_FEATURE(kCanvasOopRasterization, - "CanvasOopRasterization", - #if BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_IOS) || BUILDFLAG(IS_WIN) || \ - (BUILDFLAG(IS_MAC) && defined(ARCH_CPU_ARM64)) || BUILDFLAG(IS_ANDROID) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || \ ++ BUILDFLAG(IS_BSD) base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT diff --git a/www/chromium/files/patch-gpu_config_gpu__info__collector.cc b/www/chromium/files/patch-gpu_config_gpu__info__collector.cc index e0db757af438..2729cb59e85c 100644 --- a/www/chromium/files/patch-gpu_config_gpu__info__collector.cc +++ b/www/chromium/files/patch-gpu_config_gpu__info__collector.cc @@ -1,4 +1,4 @@ ---- gpu/config/gpu_info_collector.cc.orig 2024-02-23 21:04:38 UTC +--- gpu/config/gpu_info_collector.cc.orig 2025-05-28 14:55:43 UTC +++ gpu/config/gpu_info_collector.cc @@ -364,7 +364,7 @@ void ReportWebGPUAdapterMetrics(dawn::native::Instance void ReportWebGPUSupportMetrics(dawn::native::Instance* instance) { diff --git a/www/chromium/files/patch-gpu_config_gpu__test__config.cc b/www/chromium/files/patch-gpu_config_gpu__test__config.cc index 86cc37845dcf..74f0336194ba 100644 --- a/www/chromium/files/patch-gpu_config_gpu__test__config.cc +++ b/www/chromium/files/patch-gpu_config_gpu__test__config.cc @@ -1,11 +1,11 @@ ---- gpu/config/gpu_test_config.cc.orig 2022-02-28 16:54:41 UTC +--- gpu/config/gpu_test_config.cc.orig 2025-04-04 08:52:13 UTC +++ gpu/config/gpu_test_config.cc -@@ -29,7 +29,7 @@ GPUTestConfig::OS GetCurrentOS() { - #if BUILDFLAG(IS_CHROMEOS_ASH) +@@ -27,7 +27,7 @@ namespace { + GPUTestConfig::OS GetCurrentOS() { + #if BUILDFLAG(IS_CHROMEOS) return GPUTestConfig::kOsChromeOS; - #elif (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || \ -- BUILDFLAG(IS_OPENBSD) -+ BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_OPENBSD) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return GPUTestConfig::kOsLinux; #elif BUILDFLAG(IS_WIN) int32_t major_version = 0; diff --git a/www/chromium/files/patch-gpu_ipc_common_gpu__memory__buffer__support.cc b/www/chromium/files/patch-gpu_ipc_common_gpu__memory__buffer__support.cc index 297d7701bf26..961f45a601d6 100644 --- a/www/chromium/files/patch-gpu_ipc_common_gpu__memory__buffer__support.cc +++ b/www/chromium/files/patch-gpu_ipc_common_gpu__memory__buffer__support.cc @@ -1,4 +1,4 @@ ---- gpu/ipc/common/gpu_memory_buffer_support.cc.orig 2023-08-17 07:33:31 UTC +--- gpu/ipc/common/gpu_memory_buffer_support.cc.orig 2024-10-22 08:31:56 UTC +++ gpu/ipc/common/gpu_memory_buffer_support.cc @@ -26,7 +26,7 @@ #include "ui/ozone/public/ozone_platform.h" @@ -9,7 +9,7 @@ #include "gpu/ipc/common/gpu_memory_buffer_impl_native_pixmap.h" #endif -@@ -56,7 +56,7 @@ GpuMemoryBufferSupport::GetNativeGpuMemoryBufferType() +@@ -55,7 +55,7 @@ GpuMemoryBufferSupport::GetNativeGpuMemoryBufferType() return gfx::IO_SURFACE_BUFFER; #elif BUILDFLAG(IS_ANDROID) return gfx::ANDROID_HARDWARE_BUFFER; diff --git a/www/chromium/files/patch-gpu_ipc_service_gpu__init.cc b/www/chromium/files/patch-gpu_ipc_service_gpu__init.cc index 47df468187e0..17da50b389d7 100644 --- a/www/chromium/files/patch-gpu_ipc_service_gpu__init.cc +++ b/www/chromium/files/patch-gpu_ipc_service_gpu__init.cc @@ -1,6 +1,15 @@ ---- gpu/ipc/service/gpu_init.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/ipc/service/gpu_init.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/ipc/service/gpu_init.cc -@@ -391,7 +391,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL +@@ -156,7 +156,7 @@ void InitializePlatformOverlaySettings(GPUInfo* gpu_in + + #if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CASTOS) + bool CanAccessDeviceFile(const GPUInfo& gpu_info) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (gpu_info.gpu.vendor_id != 0x10de || // NVIDIA + gpu_info.gpu.driver_vendor != "NVIDIA") + return true; +@@ -392,7 +392,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL enable_watchdog = false; #endif @@ -9,7 +18,7 @@ bool gpu_sandbox_start_early = gpu_preferences_.gpu_sandbox_start_early; #else // !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) // For some reasons MacOSX's VideoToolbox might crash when called after -@@ -428,7 +428,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL +@@ -430,7 +430,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL } bool attempted_startsandbox = false; @@ -18,7 +27,7 @@ // On Chrome OS ARM Mali, GPU driver userspace creates threads when // initializing a GL context, so start the sandbox early. // TODO(zmo): Need to collect OS version before this. -@@ -529,7 +529,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL +@@ -527,7 +527,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL gpu_preferences_.gr_context_type = GrContextType::kGL; } @@ -27,7 +36,7 @@ // The ContentSandboxHelper is currently the only one implementation of // GpuSandboxHelper and it has no dependency. Except on Linux where // VaapiWrapper checks the GL implementation to determine which display -@@ -611,7 +611,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL +@@ -585,7 +585,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL command_line, gpu_feature_info_, gpu_preferences_.disable_software_rasterizer, false); if (gl_use_swiftshader_) { @@ -36,16 +45,16 @@ VLOG(1) << "Quit GPU process launch to fallback to SwiftShader cleanly " << "on Linux"; return false; -@@ -767,7 +767,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL - - InitializePlatformOverlaySettings(&gpu_info_, gpu_feature_info_); +@@ -753,7 +753,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL + ->GetSupportedFormatsForGLNativePixmapImport(); + #endif // BUILDFLAG(IS_OZONE) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Driver may create a compatibility profile context when collect graphics // information on Linux platform. Try to collect graphics information // based on core profile context after disabling platform extensions. -@@ -822,7 +822,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL +@@ -805,7 +805,7 @@ bool GpuInit::InitializeAndStartSandbox(base::CommandL } } } @@ -54,7 +63,7 @@ (BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_CHROMEOS_DEVICE)) if (!gl_disabled && !gl_use_swiftshader_ && std::getenv("RUNNING_UNDER_RR")) { // https://rr-project.org/ is a Linux-only record-and-replay debugger that -@@ -989,7 +989,7 @@ void GpuInit::InitializeInProcess(base::CommandLine* c +@@ -1007,7 +1007,7 @@ void GpuInit::InitializeInProcess(base::CommandLine* c } bool gl_disabled = gl::GetGLImplementation() == gl::kGLImplementationDisabled; @@ -63,7 +72,7 @@ (BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_CHROMEOS_DEVICE)) if (!gl_disabled && !gl_use_swiftshader_ && std::getenv("RUNNING_UNDER_RR")) { // https://rr-project.org/ is a Linux-only record-and-replay debugger that -@@ -1049,7 +1049,7 @@ void GpuInit::InitializeInProcess(base::CommandLine* c +@@ -1063,7 +1063,7 @@ void GpuInit::InitializeInProcess(base::CommandLine* c } } diff --git a/www/chromium/files/patch-gpu_ipc_service_gpu__memory__buffer__factory.cc b/www/chromium/files/patch-gpu_ipc_service_gpu__memory__buffer__factory.cc index 417edffe2cf6..e6b775a9e6e8 100644 --- a/www/chromium/files/patch-gpu_ipc_service_gpu__memory__buffer__factory.cc +++ b/www/chromium/files/patch-gpu_ipc_service_gpu__memory__buffer__factory.cc @@ -1,6 +1,6 @@ ---- gpu/ipc/service/gpu_memory_buffer_factory.cc.orig 2023-03-09 06:31:50 UTC +--- gpu/ipc/service/gpu_memory_buffer_factory.cc.orig 2024-10-22 08:31:56 UTC +++ gpu/ipc/service/gpu_memory_buffer_factory.cc -@@ -13,7 +13,7 @@ +@@ -14,7 +14,7 @@ #include "gpu/ipc/service/gpu_memory_buffer_factory_io_surface.h" #endif @@ -9,10 +9,10 @@ #include "gpu/ipc/service/gpu_memory_buffer_factory_native_pixmap.h" #endif -@@ -36,7 +36,7 @@ GpuMemoryBufferFactory::CreateNativeType( - return std::make_unique<GpuMemoryBufferFactoryIOSurface>(); - #elif BUILDFLAG(IS_ANDROID) - return std::make_unique<GpuMemoryBufferFactoryAndroidHardwareBuffer>(); +@@ -71,7 +71,7 @@ GpuMemoryBufferFactory::CreateNativeType( + // to have a factory that vends invalid GMB handles rather than having no + // factory at all. + return std::make_unique<GpuMemoryBufferFactoryStub>(); -#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) return std::make_unique<GpuMemoryBufferFactoryNativePixmap>( diff --git a/www/chromium/files/patch-gpu_vulkan_generate__bindings.py b/www/chromium/files/patch-gpu_vulkan_generate__bindings.py index 0afd30ae79da..ef663bc1e4f1 100644 --- a/www/chromium/files/patch-gpu_vulkan_generate__bindings.py +++ b/www/chromium/files/patch-gpu_vulkan_generate__bindings.py @@ -1,6 +1,6 @@ ---- gpu/vulkan/generate_bindings.py.orig 2023-11-03 10:09:45 UTC +--- gpu/vulkan/generate_bindings.py.orig 2024-06-17 12:56:06 UTC +++ gpu/vulkan/generate_bindings.py -@@ -270,7 +270,7 @@ VULKAN_DEVICE_FUNCTIONS = [ +@@ -271,7 +271,7 @@ VULKAN_DEVICE_FUNCTIONS = [ ] }, { diff --git a/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.cc b/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.cc index b309b71f35b2..13fc6189a26a 100644 --- a/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.cc +++ b/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.cc @@ -1,6 +1,6 @@ ---- gpu/vulkan/vulkan_device_queue.cc.orig 2024-02-23 21:04:38 UTC +--- gpu/vulkan/vulkan_device_queue.cc.orig 2025-05-28 14:55:43 UTC +++ gpu/vulkan/vulkan_device_queue.cc -@@ -121,7 +121,7 @@ bool VulkanDeviceQueue::Initialize( +@@ -145,7 +145,7 @@ bool VulkanDeviceQueue::Initialize( // In dual-CPU cases, we cannot detect the active GPU correctly on Linux, // so don't select GPU device based on the |gpu_info|. @@ -9,7 +9,7 @@ // If gpu_info is provided, the device should match it. if (gpu_info && (device_properties.vendorID != gpu_info->gpu.vendor_id || device_properties.deviceID != gpu_info->gpu.device_id)) { -@@ -264,7 +264,7 @@ bool VulkanDeviceQueue::Initialize( +@@ -292,7 +292,7 @@ bool VulkanDeviceQueue::Initialize( // Android, Fuchsia, Linux, and CrOS (VaapiVideoDecoder) need YCbCr sampler // support. #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.h b/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.h index c50d6fe2c19f..06fd6b7fc146 100644 --- a/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.h +++ b/www/chromium/files/patch-gpu_vulkan_vulkan__device__queue.h @@ -1,7 +1,7 @@ ---- gpu/vulkan/vulkan_device_queue.h.orig 2024-02-23 21:04:38 UTC +--- gpu/vulkan/vulkan_device_queue.h.orig 2025-03-05 08:14:56 UTC +++ gpu/vulkan/vulkan_device_queue.h -@@ -169,7 +169,7 @@ class COMPONENT_EXPORT(VULKAN) VulkanDeviceQueue - bool allow_protected_memory_ = false; +@@ -182,7 +182,7 @@ class COMPONENT_EXPORT(VULKAN) VulkanDeviceQueue + #endif #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || \ - BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.cc b/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.cc index b90a4fa036e9..40147518292f 100644 --- a/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.cc +++ b/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.cc @@ -1,6 +1,6 @@ ---- gpu/vulkan/vulkan_function_pointers.cc.orig 2024-02-23 21:04:38 UTC +--- gpu/vulkan/vulkan_function_pointers.cc.orig 2024-06-17 12:56:06 UTC +++ gpu/vulkan/vulkan_function_pointers.cc -@@ -1289,7 +1289,7 @@ bool VulkanFunctionPointers::BindDeviceFunctionPointer +@@ -1297,7 +1297,7 @@ bool VulkanFunctionPointers::BindDeviceFunctionPointer } } @@ -9,7 +9,7 @@ if (gfx::HasExtension(enabled_extensions, VK_EXT_IMAGE_DRM_FORMAT_MODIFIER_EXTENSION_NAME)) { constexpr char kvkGetImageDrmFormatModifierPropertiesEXT[] = -@@ -1489,7 +1489,7 @@ void VulkanFunctionPointers::ResetForTesting() { +@@ -1498,7 +1498,7 @@ void VulkanFunctionPointers::ResetForTesting() { vkGetSwapchainImagesKHR = nullptr; vkQueuePresentKHR = nullptr; diff --git a/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.h b/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.h index c0a3540fc54e..439114d13b50 100644 --- a/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.h +++ b/www/chromium/files/patch-gpu_vulkan_vulkan__function__pointers.h @@ -1,6 +1,6 @@ ---- gpu/vulkan/vulkan_function_pointers.h.orig 2023-11-03 10:09:45 UTC +--- gpu/vulkan/vulkan_function_pointers.h.orig 2025-05-05 10:57:53 UTC +++ gpu/vulkan/vulkan_function_pointers.h -@@ -321,7 +321,7 @@ struct COMPONENT_EXPORT(VULKAN) VulkanFunctionPointers +@@ -391,7 +391,7 @@ struct COMPONENT_EXPORT(VULKAN) VulkanFunctionPointers VulkanFunction<PFN_vkGetSwapchainImagesKHR> vkGetSwapchainImagesKHR; VulkanFunction<PFN_vkQueuePresentKHR> vkQueuePresentKHR; @@ -9,7 +9,7 @@ VulkanFunction<PFN_vkGetImageDrmFormatModifierPropertiesEXT> vkGetImageDrmFormatModifierPropertiesEXT; #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -1324,7 +1324,7 @@ ALWAYS_INLINE VkResult vkQueuePresentKHR(VkQueue queue +@@ -1405,7 +1405,7 @@ ALWAYS_INLINE VkResult vkQueuePresentKHR(VkQueue queue pPresentInfo); } @@ -18,7 +18,7 @@ ALWAYS_INLINE VkResult vkGetImageDrmFormatModifierPropertiesEXT( VkDevice device, VkImage image, -@@ -1334,4 +1334,4 @@ ALWAYS_INLINE VkResult vkGetImageDrmFormatModifierProp +@@ -1415,4 +1415,4 @@ ALWAYS_INLINE VkResult vkGetImageDrmFormatModifierProp } #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-gpu_vulkan_vulkan__util.cc b/www/chromium/files/patch-gpu_vulkan_vulkan__util.cc index d46d1a1053f2..743631be52a5 100644 --- a/www/chromium/files/patch-gpu_vulkan_vulkan__util.cc +++ b/www/chromium/files/patch-gpu_vulkan_vulkan__util.cc @@ -1,6 +1,6 @@ ---- gpu/vulkan/vulkan_util.cc.orig 2024-04-19 13:02:56 UTC +--- gpu/vulkan/vulkan_util.cc.orig 2025-07-02 06:08:04 UTC +++ gpu/vulkan/vulkan_util.cc -@@ -467,7 +467,7 @@ bool CheckVulkanCompatibilities( +@@ -476,7 +476,7 @@ bool CheckVulkanCompatibilities( } } diff --git a/www/chromium/files/patch-headless_BUILD.gn b/www/chromium/files/patch-headless_BUILD.gn new file mode 100644 index 000000000000..8423aea0c8a9 --- /dev/null +++ b/www/chromium/files/patch-headless_BUILD.gn @@ -0,0 +1,11 @@ +--- headless/BUILD.gn.orig 2025-05-05 10:57:53 UTC ++++ headless/BUILD.gn +@@ -475,7 +475,7 @@ component("headless_non_renderer") { + } + } + +- if (!is_fuchsia) { ++ if (!is_fuchsia && !is_bsd) { + deps += [ + "//components/crash/content/browser", + "//components/crash/core/app", diff --git a/www/chromium/files/patch-headless_lib_browser_headless__browser__main__parts__posix.cc b/www/chromium/files/patch-headless_lib_browser_headless__browser__main__parts__posix.cc index 5ebbe7026f8c..d57fdb339c73 100644 --- a/www/chromium/files/patch-headless_lib_browser_headless__browser__main__parts__posix.cc +++ b/www/chromium/files/patch-headless_lib_browser_headless__browser__main__parts__posix.cc @@ -1,6 +1,6 @@ ---- headless/lib/browser/headless_browser_main_parts_posix.cc.orig 2023-10-11 18:22:24 UTC +--- headless/lib/browser/headless_browser_main_parts_posix.cc.orig 2025-04-04 08:52:13 UTC +++ headless/lib/browser/headless_browser_main_parts_posix.cc -@@ -21,13 +21,13 @@ +@@ -26,13 +26,13 @@ #include "content/public/browser/browser_thread.h" #include "headless/lib/browser/headless_browser_impl.h" @@ -11,12 +11,12 @@ #include "components/os_crypt/sync/os_crypt.h" #include "headless/public/switches.h" --#if defined(USE_DBUS) -+#if defined(USE_DBUS) && !BUILDFLAG(IS_BSD) +-#if BUILDFLAG(USE_DBUS) ++#if BUILDFLAG(USE_DBUS) && !BUILDFLAG(IS_BSD) #include "device/bluetooth/dbus/bluez_dbus_manager.h" #endif -@@ -161,7 +161,7 @@ class BrowserShutdownHandler { +@@ -166,7 +166,7 @@ class BrowserShutdownHandler { } // namespace @@ -25,15 +25,15 @@ constexpr char kProductName[] = "HeadlessChrome"; #endif -@@ -169,9 +169,9 @@ void HeadlessBrowserMainParts::PostCreateMainMessageLo +@@ -174,9 +174,9 @@ void HeadlessBrowserMainParts::PostCreateMainMessageLo BrowserShutdownHandler::Install(base::BindOnce( &HeadlessBrowserImpl::ShutdownWithExitCode, browser_->GetWeakPtr())); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) --#if defined(USE_DBUS) -+#if defined(USE_DBUS) && !BUILDFLAG(IS_BSD) +-#if BUILDFLAG(USE_DBUS) ++#if BUILDFLAG(USE_DBUS) && !BUILDFLAG(IS_BSD) bluez::BluezDBusManager::Initialize(/*system_bus=*/nullptr); #endif diff --git a/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.cc b/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.cc new file mode 100644 index 000000000000..7cd7c023e54b --- /dev/null +++ b/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.cc @@ -0,0 +1,20 @@ +--- headless/lib/browser/headless_content_browser_client.cc.orig 2025-07-02 06:08:04 UTC ++++ headless/lib/browser/headless_content_browser_client.cc +@@ -59,7 +59,7 @@ + #include "content/public/common/content_descriptors.h" + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) + +-#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX)) && defined(HEADLESS_USE_PREFS) ++#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(HEADLESS_USE_PREFS) + #include "components/os_crypt/sync/os_crypt.h" // nogncheck + #include "content/public/browser/network_service_util.h" + #endif +@@ -557,7 +557,7 @@ void HeadlessContentBrowserClient::HandleExplicitlyAll + + void HeadlessContentBrowserClient::SetEncryptionKey( + ::network::mojom::NetworkService* network_service) { +-#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX)) && defined(HEADLESS_USE_PREFS) ++#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(HEADLESS_USE_PREFS) + // The OSCrypt keys are process bound, so if network service is out of + // process, send it the required key if it is available. + if (content::IsOutOfProcessNetworkService() diff --git a/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.h b/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.h index 2cf63da6f2b6..28ad303dd518 100644 --- a/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.h +++ b/www/chromium/files/patch-headless_lib_browser_headless__content__browser__client.h @@ -1,6 +1,6 @@ ---- headless/lib/browser/headless_content_browser_client.h.orig 2023-01-11 09:17:16 UTC +--- headless/lib/browser/headless_content_browser_client.h.orig 2025-07-02 06:08:04 UTC +++ headless/lib/browser/headless_content_browser_client.h -@@ -45,7 +45,7 @@ class HeadlessContentBrowserClient : public content::C +@@ -48,7 +48,7 @@ class HeadlessContentBrowserClient : public content::C CreateDevToolsManagerDelegate() override; content::GeneratedCodeCacheSettings GetGeneratedCodeCacheSettings( content::BrowserContext* context) override; diff --git a/www/chromium/files/patch-headless_lib_browser_headless__request__context__manager.cc b/www/chromium/files/patch-headless_lib_browser_headless__request__context__manager.cc deleted file mode 100644 index dcfc79b50d6d..000000000000 --- a/www/chromium/files/patch-headless_lib_browser_headless__request__context__manager.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- headless/lib/browser/headless_request_context_manager.cc.orig 2024-02-23 21:04:38 UTC -+++ headless/lib/browser/headless_request_context_manager.cc -@@ -64,7 +64,7 @@ void SetCryptKeyOnce(const base::FilePath& user_data_p - return; - done_once = true; - --#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX)) && defined(HEADLESS_USE_PREFS) -+#if (BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(HEADLESS_USE_PREFS) - // The OSCrypt keys are process bound, so if network service is out of - // process, send it the required key if it is available. - if (content::IsOutOfProcessNetworkService() diff --git a/www/chromium/files/patch-headless_lib_browser_headless__web__contents__impl.cc b/www/chromium/files/patch-headless_lib_browser_headless__web__contents__impl.cc index a8c994c106b7..d7c67c85bfc9 100644 --- a/www/chromium/files/patch-headless_lib_browser_headless__web__contents__impl.cc +++ b/www/chromium/files/patch-headless_lib_browser_headless__web__contents__impl.cc @@ -1,11 +1,11 @@ ---- headless/lib/browser/headless_web_contents_impl.cc.orig 2023-05-31 08:12:17 UTC +--- headless/lib/browser/headless_web_contents_impl.cc.orig 2025-04-04 08:52:13 UTC +++ headless/lib/browser/headless_web_contents_impl.cc -@@ -60,7 +60,7 @@ namespace headless { +@@ -70,7 +70,7 @@ BASE_FEATURE(kPrerender2InHeadlessMode, namespace { void UpdatePrefsFromSystemSettings(blink::RendererPreferences* prefs) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) content::UpdateFontRendererPreferencesFromSystemSettings(prefs); #endif diff --git a/www/chromium/files/patch-headless_lib_headless__content__main__delegate.cc b/www/chromium/files/patch-headless_lib_headless__content__main__delegate.cc index a42c701df4bf..9c2363a8a819 100644 --- a/www/chromium/files/patch-headless_lib_headless__content__main__delegate.cc +++ b/www/chromium/files/patch-headless_lib_headless__content__main__delegate.cc @@ -1,6 +1,6 @@ ---- headless/lib/headless_content_main_delegate.cc.orig 2023-12-10 06:10:27 UTC +--- headless/lib/headless_content_main_delegate.cc.orig 2025-05-28 14:55:43 UTC +++ headless/lib/headless_content_main_delegate.cc -@@ -362,7 +362,7 @@ void HeadlessContentMainDelegate::InitCrashReporter( +@@ -406,7 +406,7 @@ void HeadlessContentMainDelegate::InitCrashReporter( if (process_type != ::switches::kZygoteProcess) { g_headless_crash_client.Pointer()->set_crash_dumps_dir( command_line.GetSwitchValuePath(switches::kCrashDumpsDir)); diff --git a/www/chromium/files/patch-ipc_ipc__channel.h b/www/chromium/files/patch-ipc_ipc__channel.h index 67b336ed3660..6e8f63c5006d 100644 --- a/www/chromium/files/patch-ipc_ipc__channel.h +++ b/www/chromium/files/patch-ipc_ipc__channel.h @@ -1,6 +1,6 @@ ---- ipc/ipc_channel.h.orig 2024-01-30 07:53:34 UTC +--- ipc/ipc_channel.h.orig 2024-06-17 12:56:06 UTC +++ ipc/ipc_channel.h -@@ -240,7 +240,7 @@ class COMPONENT_EXPORT(IPC) Channel : public Sender { +@@ -218,7 +218,7 @@ class COMPONENT_EXPORT(IPC) Channel : public Sender { static std::string GenerateUniqueRandomChannelID(); #endif diff --git a/www/chromium/files/patch-ipc_ipc__message__utils.cc b/www/chromium/files/patch-ipc_ipc__message__utils.cc index f8def4a866b3..2dc0167f1c0e 100644 --- a/www/chromium/files/patch-ipc_ipc__message__utils.cc +++ b/www/chromium/files/patch-ipc_ipc__message__utils.cc @@ -1,6 +1,6 @@ ---- ipc/ipc_message_utils.cc.orig 2024-02-23 21:04:38 UTC +--- ipc/ipc_message_utils.cc.orig 2024-11-14 07:57:23 UTC +++ ipc/ipc_message_utils.cc -@@ -394,7 +394,7 @@ void ParamTraits<unsigned int>::Log(const param_type& +@@ -399,7 +399,7 @@ void ParamTraits<unsigned int>::Log(const param_type& } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ diff --git a/www/chromium/files/patch-ipc_ipc__message__utils.h b/www/chromium/files/patch-ipc_ipc__message__utils.h index 0b1c49c55797..4618c63ee766 100644 --- a/www/chromium/files/patch-ipc_ipc__message__utils.h +++ b/www/chromium/files/patch-ipc_ipc__message__utils.h @@ -1,6 +1,6 @@ ---- ipc/ipc_message_utils.h.orig 2022-09-24 10:57:32 UTC +--- ipc/ipc_message_utils.h.orig 2025-05-05 10:57:53 UTC +++ ipc/ipc_message_utils.h -@@ -214,7 +214,7 @@ struct ParamTraits<unsigned int> { +@@ -216,7 +216,7 @@ struct ParamTraits<unsigned int> { // Since we want to support Android 32<>64 bit IPC, as long as we don't have // these traits for 32 bit ARM then that'll catch any errors. #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ diff --git a/www/chromium/files/patch-media_BUILD.gn b/www/chromium/files/patch-media_BUILD.gn index 7265ccead9c3..ae5427149201 100644 --- a/www/chromium/files/patch-media_BUILD.gn +++ b/www/chromium/files/patch-media_BUILD.gn @@ -1,12 +1,12 @@ ---- media/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- media/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ media/BUILD.gn -@@ -96,6 +96,9 @@ config("media_config") { +@@ -105,6 +105,9 @@ config("media_config") { defines += [ "DLOPEN_PULSEAUDIO" ] } } + if (use_sndio) { + defines += [ "USE_SNDIO" ] + } - if (use_cras) { - defines += [ "USE_CRAS" ] - } + } + + # Internal grouping of the configs necessary to support sub-folders having their diff --git a/www/chromium/files/patch-media_audio_BUILD.gn b/www/chromium/files/patch-media_audio_BUILD.gn index 724df812a7e7..4bf583135073 100644 --- a/www/chromium/files/patch-media_audio_BUILD.gn +++ b/www/chromium/files/patch-media_audio_BUILD.gn @@ -1,18 +1,21 @@ ---- media/audio/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- media/audio/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ media/audio/BUILD.gn -@@ -270,9 +270,20 @@ source_set("audio") { +@@ -286,9 +286,23 @@ source_set("audio") { deps += [ "//media/base/android:media_jni_headers" ] } - if (is_linux || is_chromeos) { -+ if ((is_linux || is_chromeos) && !use_sndio) { ++ if ((is_linux || is_chromeos) && !is_bsd) { sources += [ "linux/audio_manager_linux.cc" ] } + ++ if (is_bsd) { ++ sources += [ "sndio/audio_manager_sndio.cc" ] ++ } ++ + if (use_sndio) { + libs += [ "sndio" ] + sources += [ -+ "sndio/audio_manager_sndio.cc", + "sndio/sndio_input.cc", + "sndio/sndio_input.h", + "sndio/sndio_output.cc", diff --git a/www/chromium/files/patch-media_audio_alsa_audio__manager__alsa.cc b/www/chromium/files/patch-media_audio_alsa_audio__manager__alsa.cc index a26dd20d89cf..dda7610a87cf 100644 --- a/www/chromium/files/patch-media_audio_alsa_audio__manager__alsa.cc +++ b/www/chromium/files/patch-media_audio_alsa_audio__manager__alsa.cc @@ -1,26 +1,26 @@ ---- media/audio/alsa/audio_manager_alsa.cc.orig 2022-04-21 18:48:31 UTC +--- media/audio/alsa/audio_manager_alsa.cc.orig 2025-05-28 14:55:43 UTC +++ media/audio/alsa/audio_manager_alsa.cc -@@ -88,7 +88,9 @@ void AudioManagerAlsa::GetAlsaAudioDevices(StreamType +@@ -106,7 +106,9 @@ void AudioManagerAlsa::GetAlsaAudioDevices(StreamType int card = -1; - // Loop through the sound cards to get ALSA device hints. -+#if !BUILDFLAG(IS_BSD) + // Loop through the physical sound cards to get ALSA device hints. ++#if !BUILDFLAG(IS_BSD) while (!wrapper_->CardNext(&card) && card >= 0) { +#endif - void** hints = NULL; + void** hints = nullptr; int error = wrapper_->DeviceNameHint(card, kPcmInterfaceName, &hints); if (!error) { -@@ -100,7 +102,9 @@ void AudioManagerAlsa::GetAlsaAudioDevices(StreamType +@@ -118,7 +120,9 @@ void AudioManagerAlsa::GetAlsaAudioDevices(StreamType DLOG(WARNING) << "GetAlsaAudioDevices: unable to get device hints: " << wrapper_->StrError(error); } -+#if !BUILDFLAG(IS_BSD) ++#if !BUILDFLAG(IS_BSD) } +#endif } void AudioManagerAlsa::GetAlsaDevicesInfo(AudioManagerAlsa::StreamType type, -@@ -183,7 +187,11 @@ bool AudioManagerAlsa::IsAlsaDeviceAvailable( +@@ -202,7 +206,11 @@ bool AudioManagerAlsa::IsAlsaDeviceAvailable( // goes through software conversion if needed (e.g. incompatible // sample rate). // TODO(joi): Should we prefer "hw" instead? @@ -32,7 +32,7 @@ return strncmp(kDeviceTypeDesired, device_name, std::size(kDeviceTypeDesired) - 1) == 0; } -@@ -205,7 +213,9 @@ bool AudioManagerAlsa::HasAnyAlsaAudioDevice( +@@ -254,7 +262,9 @@ bool AudioManagerAlsa::HasAnyAlsaAudioDevice( // Loop through the sound cards. // Don't use snd_device_name_hint(-1,..) since there is an access violation // inside this ALSA API with libasound.so.2.0.0. @@ -41,8 +41,8 @@ +#endif int error = wrapper_->DeviceNameHint(card, kPcmInterfaceName, &hints); if (!error) { - for (void** hint_iter = hints; *hint_iter != NULL; hint_iter++) { -@@ -229,7 +239,9 @@ bool AudioManagerAlsa::HasAnyAlsaAudioDevice( + for (void** hint_iter = hints; *hint_iter != nullptr; hint_iter++) { +@@ -279,7 +289,9 @@ bool AudioManagerAlsa::HasAnyAlsaAudioDevice( DLOG(WARNING) << "HasAnyAudioDevice: unable to get device hints: " << wrapper_->StrError(error); } diff --git a/www/chromium/files/patch-media_audio_audio__input__device.cc b/www/chromium/files/patch-media_audio_audio__input__device.cc index 0e8b9b3c9a98..162f83363e38 100644 --- a/www/chromium/files/patch-media_audio_audio__input__device.cc +++ b/www/chromium/files/patch-media_audio_audio__input__device.cc @@ -1,6 +1,6 @@ ---- media/audio/audio_input_device.cc.orig 2024-04-19 13:02:56 UTC +--- media/audio/audio_input_device.cc.orig 2025-02-19 07:43:18 UTC +++ media/audio/audio_input_device.cc -@@ -264,7 +264,7 @@ void AudioInputDevice::OnStreamCreated( +@@ -275,7 +275,7 @@ void AudioInputDevice::OnStreamCreated( // here. See comments in AliveChecker and PowerObserverHelper for details and // todos. if (detect_dead_stream_ == DeadStreamDetection::kEnabled) { diff --git a/www/chromium/files/patch-media_audio_pulse_pulse__util.cc b/www/chromium/files/patch-media_audio_pulse_pulse__util.cc new file mode 100644 index 000000000000..ccb79f1f1543 --- /dev/null +++ b/www/chromium/files/patch-media_audio_pulse_pulse__util.cc @@ -0,0 +1,14 @@ +--- media/audio/pulse/pulse_util.cc.orig 2024-09-30 07:45:04 UTC ++++ media/audio/pulse/pulse_util.cc +@@ -50,7 +50,11 @@ constexpr char kBrowserDisplayName[] = "chromium-brows + + #if defined(DLOPEN_PULSEAUDIO) + static const base::FilePath::CharType kPulseLib[] = ++#if BUILDFLAG(IS_BSD) ++ FILE_PATH_LITERAL("libpulse.so"); ++#else + FILE_PATH_LITERAL("libpulse.so.0"); ++#endif + #endif + + void DestroyMainloop(pa_threaded_mainloop* mainloop) { diff --git a/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.cc b/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.cc index e4880eb7f7e9..77ef6c87435e 100644 --- a/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.cc +++ b/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.cc @@ -1,6 +1,6 @@ ---- media/audio/sndio/audio_manager_sndio.cc.orig 2022-10-24 13:33:33 UTC +--- media/audio/sndio/audio_manager_sndio.cc.orig 2025-07-02 06:08:04 UTC +++ media/audio/sndio/audio_manager_sndio.cc -@@ -0,0 +1,181 @@ +@@ -0,0 +1,213 @@ +// Copyright (c) 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. @@ -17,18 +17,19 @@ +#include "media/audio/sndio/sndio_input.h" +#include "media/audio/sndio/sndio_output.h" +#endif ++#if defined(USE_PULSEAUDIO) ++#include "media/audio/pulse/audio_manager_pulse.h" ++#include "media/audio/pulse/pulse_util.h" ++#endif ++#if defined(USE_ALSA) ++#include "media/audio/alsa/audio_manager_alsa.h" ++#endif +#include "media/audio/fake_audio_manager.h" +#include "media/base/limits.h" +#include "media/base/media_switches.h" + +namespace media { + -+enum SndioAudioIO { -+ kPulse, -+ kSndio, -+ kAudioIOMax = kSndio -+}; -+ +#if defined(USE_SNDIO) +// Maximum number of output streams that can be open simultaneously. +static const int kMaxOutputStreams = 50; @@ -61,7 +62,7 @@ +} + +#if defined(USE_SNDIO) -+const char* AudioManagerSndio::GetName() { ++const std::string_view AudioManagerSndio::GetName() { + return "SNDIO"; +} +#endif @@ -164,21 +165,52 @@ + std::unique_ptr<AudioThread> audio_thread, + AudioLogFactory* audio_log_factory) { + DLOG(WARNING) << "CreateAudioManager"; ++ ++ auto _ab = kAudioBackendParam.Get(); ++ + // For testing allow audio output to be disabled. + if (base::CommandLine::ForCurrentProcess()->HasSwitch( -+ switches::kDisableAudioOutput)) { ++ switches::kDisableAudioOutput) || ++ !base::FeatureList::IsEnabled(media::kAudioBackend)) { + return std::make_unique<FakeAudioManager>(std::move(audio_thread), + audio_log_factory); + } ++ ++#if defined(USE_PULSEAUDIO) ++ pa_threaded_mainloop* pa_mainloop = nullptr; ++ pa_context* pa_context = nullptr; ++ if (_ab != AudioBackend::kSndio && _ab != AudioBackend::kAlsa && ++ pulse::InitPulse(&pa_mainloop, &pa_context)) { ++ return std::make_unique<AudioManagerPulse>( ++ std::move(audio_thread), audio_log_factory, pa_mainloop, pa_context); ++ } else if (_ab == AudioBackend::kAuto) { ++ LOG(WARNING) << "Falling back to SNDIO for audio output. PulseAudio is not " ++ "available or could not be initialized."; ++ } ++#endif ++ +#if defined(USE_SNDIO) -+ UMA_HISTOGRAM_ENUMERATION("Media.SndioAudioIO", kSndio, kAudioIOMax + 1); -+ return std::make_unique<AudioManagerSndio>(std::move(audio_thread), -+ audio_log_factory); -+#else -+ return std::make_unique<FakeAudioManager>(std::move(audio_thread), -+ audio_log_factory); ++ if (_ab != AudioBackend::kPulseAudio && _ab != AudioBackend::kAlsa) { ++ return std::make_unique<AudioManagerSndio>(std::move(audio_thread), ++ audio_log_factory); ++ } else if (_ab == AudioBackend::kAuto) { ++ LOG(WARNING) << "Falling back to ALSA audio output. SNDIO is not " ++ "available or could not be initialized."; ++ } ++#endif ++ ++#if defined(USE_ALSA) ++ if (_ab != AudioBackend::kPulseAudio && _ab != AudioBackend::kSndio) { ++ return std::make_unique<AudioManagerAlsa>(std::move(audio_thread), ++ audio_log_factory); ++ } else if (_ab == AudioBackend::kAuto) { ++ LOG(WARNING) << "Falling back to fake audio output. ALSA is not " ++ "available or could not be initialized."; ++ } +#endif + ++ return std::make_unique<FakeAudioManager>(std::move(audio_thread), ++ audio_log_factory); +} + +} // namespace media diff --git a/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.h b/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.h index 33428cfc37d1..d3fcce40a8d0 100644 --- a/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.h +++ b/www/chromium/files/patch-media_audio_sndio_audio__manager__sndio.h @@ -1,4 +1,4 @@ ---- media/audio/sndio/audio_manager_sndio.h.orig 2022-02-07 13:39:41 UTC +--- media/audio/sndio/audio_manager_sndio.h.orig 2025-07-02 06:08:04 UTC +++ media/audio/sndio/audio_manager_sndio.h @@ -0,0 +1,66 @@ +// Copyright (c) 2012 The Chromium Authors. All rights reserved. @@ -34,7 +34,7 @@ + void GetAudioOutputDeviceNames(AudioDeviceNames* device_names) override; + AudioParameters GetInputStreamParameters( + const std::string& device_id) override; -+ const char* GetName() override; ++ const std::string_view GetName() override; + + // Implementation of AudioManagerBase. + AudioOutputStream* MakeLinearOutputStream( diff --git a/www/chromium/files/patch-media_base_audio__latency.cc b/www/chromium/files/patch-media_base_audio__latency.cc index c160a5b24f24..8bc6f327581e 100644 --- a/www/chromium/files/patch-media_base_audio__latency.cc +++ b/www/chromium/files/patch-media_base_audio__latency.cc @@ -1,4 +1,4 @@ ---- media/base/audio_latency.cc.orig 2023-04-05 11:05:06 UTC +--- media/base/audio_latency.cc.orig 2025-04-04 08:52:13 UTC +++ media/base/audio_latency.cc @@ -147,7 +147,7 @@ int AudioLatency::GetRtcBufferSize(int sample_rate, in } diff --git a/www/chromium/files/patch-media_base_media__switches.cc b/www/chromium/files/patch-media_base_media__switches.cc index 2bd334016a61..66b77e24fbf9 100644 --- a/www/chromium/files/patch-media_base_media__switches.cc +++ b/www/chromium/files/patch-media_base_media__switches.cc @@ -1,6 +1,6 @@ ---- media/base/media_switches.cc.orig 2024-04-19 13:02:56 UTC +--- media/base/media_switches.cc.orig 2025-07-02 06:08:04 UTC +++ media/base/media_switches.cc -@@ -21,7 +21,7 @@ +@@ -19,7 +19,7 @@ #include "ui/gl/gl_features.h" #include "ui/gl/gl_utils.h" @@ -9,8 +9,8 @@ #include "base/cpu.h" #endif -@@ -363,8 +363,8 @@ BASE_FEATURE(kMacLoopbackAudioForScreenShare, - "MacLoopbackAudioForScreenShare", +@@ -366,8 +366,8 @@ BASE_FEATURE(kUseSCContentSharingPicker, + "UseSCContentSharingPicker", base::FEATURE_DISABLED_BY_DEFAULT); #endif // BUILDFLAG(IS_MAC) - @@ -20,16 +20,36 @@ // Enables system audio mirroring using pulseaudio. BASE_FEATURE(kPulseaudioLoopbackForCast, "PulseaudioLoopbackForCast", -@@ -597,7 +597,7 @@ BASE_FEATURE(kUseWritePixelsYUV, - BASE_FEATURE(kUseMultiPlaneFormatForHardwareVideo, - "UseMultiPlaneFormatForHardwareVideo", - #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FUCHSIA) || \ -- BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+ BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT -@@ -713,7 +713,7 @@ BASE_FEATURE(kFallbackAfterDecodeError, +@@ -377,6 +377,28 @@ BASE_FEATURE(kPulseaudioLoopbackForCast, + BASE_FEATURE(kPulseaudioLoopbackForScreenShare, + "PulseaudioLoopbackForScreenShare", + base::FEATURE_DISABLED_BY_DEFAULT); ++ ++BASE_FEATURE(kAudioBackend, ++ "AudioBackend", ++ base::FEATURE_ENABLED_BY_DEFAULT); ++ ++constexpr base::FeatureParam<AudioBackend>::Option ++ kAudioBackendOptions[] = { ++ {AudioBackend::kAuto, ++ "auto"}, ++ {AudioBackend::kPulseAudio, "pulseaudio"}, ++ {AudioBackend::kSndio, "sndio"}, ++ {AudioBackend::kAlsa, "alsa"}}; ++ ++const base::FeatureParam<AudioBackend> ++ kAudioBackendParam{ ++ &kAudioBackend, "audio-backend", ++#if BUILDFLAG(IS_OPENBSD) ++ AudioBackend::kSndio, ++#elif BUILDFLAG(IS_FREEBSD) ++ AudioBackend::kAuto, ++#endif ++ &kAudioBackendOptions}; + #endif // BUILDFLAG(IS_LINUX) + + // When enabled, MediaCapabilities will check with GPU Video Accelerator +@@ -658,7 +680,7 @@ BASE_FEATURE(kFileDialogsBlockPictureInPicture, // Show toolbar button that opens dialog for controlling media sessions. BASE_FEATURE(kGlobalMediaControls, "GlobalMediaControls", @@ -38,7 +58,7 @@ base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -741,7 +741,7 @@ BASE_FEATURE(kGlobalMediaControlsUpdatedUI, +@@ -681,7 +703,7 @@ BASE_FEATURE(kGlobalMediaControlsUpdatedUI, // If enabled, users can request Media Remoting without fullscreen-in-tab. BASE_FEATURE(kMediaRemotingWithoutFullscreen, "MediaRemotingWithoutFullscreen", @@ -47,53 +67,35 @@ base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -753,7 +753,7 @@ BASE_FEATURE(kMediaRemotingWithoutFullscreen, +@@ -693,7 +715,7 @@ BASE_FEATURE(kMediaRemotingWithoutFullscreen, BASE_FEATURE(kGlobalMediaControlsPictureInPicture, "GlobalMediaControlsPictureInPicture", #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +- BUILDFLAG(IS_CHROMEOS) ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -782,7 +782,7 @@ BASE_FEATURE(kUnifiedAutoplay, +@@ -722,7 +744,7 @@ BASE_FEATURE(kUnifiedAutoplay, "UnifiedAutoplay", base::FEATURE_ENABLED_BY_DEFAULT); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Enable vaapi video decoding on linux. This is already enabled by default on - // chromeos, but needs an experiment on linux. - BASE_FEATURE(kVaapiVideoDecodeLinux, -@@ -873,7 +873,7 @@ BASE_FEATURE(kVaapiVp9SModeHWEncoding, - "VaapiVp9SModeHWEncoding", + // Enable vaapi/v4l2 video decoding on linux. This is already enabled by default + // on chromeos, but needs an experiment on linux. + BASE_FEATURE(kAcceleratedVideoDecodeLinux, +@@ -795,7 +817,7 @@ BASE_FEATURE(kVSyncMjpegDecoding, + "VSyncMjpegDecoding", base::FEATURE_DISABLED_BY_DEFAULT); #endif // defined(ARCH_CPU_X86_FAMILY) && BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Enables the new V4L2 flat video decoder clients instead of V4L2VideoDecoder. - // Owners: frkoenig@chromium.org, mcasas@chromium.org - // Expiry: When flat decoders are supported on all platforms and the legacy -@@ -998,7 +998,7 @@ BASE_FEATURE(kLiveCaptionUseWaitK, - // Live Caption can be used in multiple languages, as opposed to just English. - BASE_FEATURE(kLiveCaptionMultiLanguage, - "LiveCaptionMultiLanguage", --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT -@@ -1033,7 +1033,7 @@ BASE_FEATURE(kLiveCaptionSystemWideOnChromeOS, - // Live Translate translates captions generated by Live Caption. - BASE_FEATURE(kLiveTranslate, - "LiveTranslate", --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT -@@ -1500,7 +1500,7 @@ BASE_FEATURE(kUseGTFOOutOfProcessVideoDecoding, - base::FEATURE_DISABLED_BY_DEFAULT); + // Enable H264 temporal layer encoding with V4L2 HW encoder on ChromeOS. + BASE_FEATURE(kV4L2H264TemporalLayerHWEncoding, + "V4L2H264TemporalLayerHWEncoding", +@@ -1355,7 +1377,7 @@ BASE_FEATURE(kUseOutOfProcessVideoDecoding, + ); #endif // BUILDFLAG(ALLOW_OOP_VIDEO_DECODER) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -101,3 +103,12 @@ // Spawn utility processes to perform hardware encode acceleration instead of // using the GPU process. BASE_FEATURE(kUseOutOfProcessVideoEncoding, +@@ -1437,7 +1459,7 @@ BASE_FEATURE(kRecordWebAudioEngagement, + "RecordWebAudioEngagement", + base::FEATURE_ENABLED_BY_DEFAULT); + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Reduces the number of buffers needed in the output video frame pool to + // populate the Renderer pipeline for hardware accelerated VideoDecoder in + // non-low latency scenarios. diff --git a/www/chromium/files/patch-media_base_media__switches.h b/www/chromium/files/patch-media_base_media__switches.h index e0d750889720..89432227bff0 100644 --- a/www/chromium/files/patch-media_base_media__switches.h +++ b/www/chromium/files/patch-media_base_media__switches.h @@ -1,6 +1,6 @@ ---- media/base/media_switches.h.orig 2024-04-19 13:02:56 UTC +--- media/base/media_switches.h.orig 2025-07-02 06:08:04 UTC +++ media/base/media_switches.h -@@ -315,7 +315,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kPlatformHEVCEncoder +@@ -336,13 +336,25 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kMediaRecorderHEVCSu MEDIA_EXPORT BASE_DECLARE_FEATURE(kPlaybackSpeedButton); MEDIA_EXPORT BASE_DECLARE_FEATURE(kPreloadMediaEngagementData); MEDIA_EXPORT BASE_DECLARE_FEATURE(kPreloadMetadataSuspend); @@ -8,27 +8,46 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) MEDIA_EXPORT BASE_DECLARE_FEATURE(kPulseaudioLoopbackForCast); MEDIA_EXPORT BASE_DECLARE_FEATURE(kPulseaudioLoopbackForScreenShare); ++ ++enum class AudioBackend { ++ kAuto, ++ kPulseAudio, ++ kSndio, ++ kAlsa ++}; ++ ++MEDIA_EXPORT BASE_DECLARE_FEATURE(kAudioBackend); ++MEDIA_EXPORT extern const base::FeatureParam< ++ AudioBackend> ++ kAudioBackendParam; #endif // BUILDFLAG(IS_LINUX) -@@ -333,7 +333,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kUnifiedAutoplay); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kRecordMediaEngagementScores); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kRecordWebAudioEngagement); +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + MEDIA_EXPORT BASE_DECLARE_FEATURE(kReduceHardwareVideoDecoderBuffers); + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + MEDIA_EXPORT BASE_DECLARE_FEATURE(kResumeBackgroundVideo); +@@ -356,7 +368,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kSuspendMutedAudio); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kUnifiedAutoplay); MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseAndroidOverlayForSecureOnly); - MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseDecoderStreamForWebRTC); MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseFakeDeviceForMediaStream); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVideoDecodeLinux); - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVideoDecodeLinuxGL); - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVideoEncodeLinux); -@@ -352,7 +352,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiH264TemporalLa - MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVp8TemporalLayerHWEncoding); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kAcceleratedVideoDecodeLinux); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kAcceleratedVideoDecodeLinuxGL); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kAcceleratedVideoEncodeLinux); +@@ -372,7 +384,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiAV1TemporalLay MEDIA_EXPORT BASE_DECLARE_FEATURE(kVaapiVp9SModeHWEncoding); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kVSyncMjpegDecoding); #endif // defined(ARCH_CPU_X86_FAMILY) && BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - MEDIA_EXPORT BASE_DECLARE_FEATURE(kV4L2FlatVideoDecoder); - MEDIA_EXPORT BASE_DECLARE_FEATURE(kV4L2FlatStatefulVideoDecoder); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kV4L2H264TemporalLayerHWEncoding); #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -@@ -491,7 +491,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseOutOfProcessVide - MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseGTFOOutOfProcessVideoDecoding); + MEDIA_EXPORT BASE_DECLARE_FEATURE(kVideoBlitColorAccuracy); +@@ -493,7 +505,7 @@ MEDIA_EXPORT BASE_DECLARE_FEATURE(kBackgroundListening + MEDIA_EXPORT BASE_DECLARE_FEATURE(kUseOutOfProcessVideoDecoding); #endif // BUILDFLAG(ALLOW_OOP_VIDEO_DECODER) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-media_base_user__input__monitor__unittest.cc b/www/chromium/files/patch-media_base_user__input__monitor__unittest.cc deleted file mode 100644 index 6922ad201945..000000000000 --- a/www/chromium/files/patch-media_base_user__input__monitor__unittest.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- media/base/user_input_monitor_unittest.cc.orig 2023-02-08 09:03:45 UTC -+++ media/base/user_input_monitor_unittest.cc -@@ -13,7 +13,7 @@ - #include "build/build_config.h" - #include "testing/gtest/include/gtest/gtest.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "base/files/file_descriptor_watcher_posix.h" - #endif - -@@ -49,7 +49,7 @@ class UserInputMonitorTest : public testing::Test { - } // namespace - - TEST_F(UserInputMonitorTest, CreatePlatformSpecific) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - base::test::TaskEnvironment task_environment( - base::test::TaskEnvironment::MainThreadType::IO); - #else -@@ -72,7 +72,7 @@ TEST_F(UserInputMonitorTest, CreatePlatformSpecific) { - } - - TEST_F(UserInputMonitorTest, CreatePlatformSpecificWithMapping) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - base::test::TaskEnvironment task_environment( - base::test::TaskEnvironment::MainThreadType::IO); - #else diff --git a/www/chromium/files/patch-media_base_video__frame.cc b/www/chromium/files/patch-media_base_video__frame.cc index fa6bd935a94e..9e081b0035db 100644 --- a/www/chromium/files/patch-media_base_video__frame.cc +++ b/www/chromium/files/patch-media_base_video__frame.cc @@ -1,6 +1,6 @@ ---- media/base/video_frame.cc.orig 2024-04-19 13:02:56 UTC +--- media/base/video_frame.cc.orig 2025-07-02 06:08:04 UTC +++ media/base/video_frame.cc -@@ -80,7 +80,7 @@ std::string VideoFrame::StorageTypeToString( +@@ -92,7 +92,7 @@ std::string VideoFrame::StorageTypeToString( return "OWNED_MEMORY"; case VideoFrame::STORAGE_SHMEM: return "SHMEM"; @@ -9,7 +9,7 @@ case VideoFrame::STORAGE_DMABUFS: return "DMABUFS"; #endif -@@ -95,7 +95,7 @@ std::string VideoFrame::StorageTypeToString( +@@ -106,7 +106,7 @@ std::string VideoFrame::StorageTypeToString( // static bool VideoFrame::IsStorageTypeMappable(VideoFrame::StorageType storage_type) { return @@ -18,25 +18,16 @@ // This is not strictly needed but makes explicit that, at VideoFrame // level, DmaBufs are not mappable from userspace. storage_type != VideoFrame::STORAGE_DMABUFS && -@@ -306,7 +306,7 @@ static std::optional<VideoFrameLayout> GetDefaultLayou - return VideoFrameLayout::CreateWithPlanes(format, coded_size, planes); - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // This class allows us to embed a vector<ScopedFD> into a scoped_refptr, and - // thus to have several VideoFrames share the same set of DMABUF FDs. - class VideoFrame::DmabufHolder -@@ -636,7 +636,7 @@ scoped_refptr<VideoFrame> VideoFrame::WrapExternalGpuM - for (size_t i = 0; i < num_planes; ++i) - planes[i].stride = gpu_memory_buffer->stride(i); +@@ -417,7 +417,7 @@ VideoFrame::CreateFrameForGpuMemoryBufferOrMappableSII + plane_size.width() * VideoFrame::BytesPerElement(*format, plane); + } uint64_t modifier = gfx::NativePixmapHandle::kNoModifier; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (gpu_memory_buffer->GetType() == gfx::NATIVE_PIXMAP) { - const auto gmb_handle = gpu_memory_buffer->CloneHandle(); - if (gmb_handle.is_null() || -@@ -682,7 +682,7 @@ scoped_refptr<VideoFrame> VideoFrame::WrapExternalGpuM + bool is_native_buffer = + gpu_memory_buffer + ? (gpu_memory_buffer->GetType() != gfx::SHARED_MEMORY_BUFFER) +@@ -889,7 +889,7 @@ scoped_refptr<VideoFrame> VideoFrame::WrapExternalGpuM return frame; } @@ -45,30 +36,12 @@ // static scoped_refptr<VideoFrame> VideoFrame::WrapExternalDmabufs( const VideoFrameLayout& layout, -@@ -901,7 +901,7 @@ scoped_refptr<VideoFrame> VideoFrame::WrapVideoFrame( - } - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - DCHECK(frame->dmabuf_fds_); - // If there are any |dmabuf_fds_| plugged in, we should refer them too. - wrapping_frame->dmabuf_fds_ = frame->dmabuf_fds_; -@@ -1345,7 +1345,7 @@ const gpu::MailboxHolder& VideoFrame::mailbox_holder( - : mailbox_holders_[texture_index]; +@@ -1573,7 +1573,7 @@ scoped_refptr<gpu::ClientSharedImage> VideoFrame::shar + return wrapped_frame_ ? wrapped_frame_->shared_image() : shared_image_; } -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) size_t VideoFrame::NumDmabufFds() const { - return dmabuf_fds_->size(); - } -@@ -1462,7 +1462,7 @@ VideoFrame::VideoFrame(const VideoFrameLayout& layout, - storage_type_(storage_type), - visible_rect_(Intersection(visible_rect, gfx::Rect(layout.coded_size()))), - natural_size_(natural_size), --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - dmabuf_fds_(base::MakeRefCounted<DmabufHolder>()), - #endif - timestamp_(timestamp), + if (wrapped_frame_) { + return wrapped_frame_->NumDmabufFds(); diff --git a/www/chromium/files/patch-media_base_video__frame.h b/www/chromium/files/patch-media_base_video__frame.h index ab252656a3ce..7bd2d18baa33 100644 --- a/www/chromium/files/patch-media_base_video__frame.h +++ b/www/chromium/files/patch-media_base_video__frame.h @@ -1,24 +1,24 @@ ---- media/base/video_frame.h.orig 2024-04-19 13:02:56 UTC +--- media/base/video_frame.h.orig 2025-05-28 14:55:43 UTC +++ media/base/video_frame.h -@@ -44,7 +44,7 @@ - #include "base/apple/scoped_cftyperef.h" - #endif // BUILDFLAG(IS_APPLE) +@@ -42,7 +42,7 @@ + #include "ui/gfx/geometry/size.h" + #include "ui/gfx/hdr_metadata.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "base/files/scoped_file.h" #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -110,7 +110,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte +@@ -88,7 +88,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte STORAGE_UNOWNED_MEMORY = 2, // External, non owned data pointers. STORAGE_OWNED_MEMORY = 3, // VideoFrame has allocated its own data buffer. STORAGE_SHMEM = 4, // Backed by read-only shared memory. -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // TODO(mcasas): Consider turning this type into STORAGE_NATIVE - // based on the idea of using this same enum value for both DMA - // buffers on Linux and CVPixelBuffers on Mac (which currently use -@@ -313,7 +313,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte + STORAGE_DMABUFS = 5, // Each plane is stored into a DmaBuf. + #endif + STORAGE_GPU_MEMORY_BUFFER = 6, +@@ -420,7 +420,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte ReleaseMailboxAndGpuMemoryBufferCB mailbox_holder_and_gmb_release_cb, base::TimeDelta timestamp); @@ -27,21 +27,21 @@ // Wraps provided dmabufs // (https://www.kernel.org/doc/html/latest/driver-api/dma-buf.html) with a // VideoFrame. The frame will take ownership of |dmabuf_fds|, and will -@@ -598,7 +598,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte - // mailbox, the caller must wait for the included sync point. - const gpu::MailboxHolder& mailbox_holder(size_t texture_index) const; +@@ -733,7 +733,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte + // wait for the included sync point. + scoped_refptr<gpu::ClientSharedImage> shared_image() const; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // The number of DmaBufs will be equal or less than the number of planes of // the frame. If there are less, this means that the last FD contains the // remaining planes. Should be > 0 for STORAGE_DMABUFS. -@@ -816,7 +816,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte - // GPU memory buffer, if this frame is STORAGE_GPU_MEMORY_BUFFER. - std::unique_ptr<gfx::GpuMemoryBuffer> gpu_memory_buffer_; +@@ -973,7 +973,7 @@ class MEDIA_EXPORT VideoFrame : public base::RefCounte + // GpuMemoryBuffers. Clients will set this flag while creating a VideoFrame. + bool is_mappable_si_enabled_ = false; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - class DmabufHolder; - // Dmabufs for the frame, used when storage is STORAGE_DMABUFS. Size is either + // equal or less than the number of planes of the frame. If it is less, then + // the memory area represented by the last FD contains the remaining planes. diff --git a/www/chromium/files/patch-media_capture_video_create__video__capture__device__factory.cc b/www/chromium/files/patch-media_capture_video_create__video__capture__device__factory.cc index 0b522ccc9cf8..a1152a30f5d6 100644 --- a/www/chromium/files/patch-media_capture_video_create__video__capture__device__factory.cc +++ b/www/chromium/files/patch-media_capture_video_create__video__capture__device__factory.cc @@ -1,20 +1,20 @@ ---- media/capture/video/create_video_capture_device_factory.cc.orig 2023-03-09 06:31:50 UTC +--- media/capture/video/create_video_capture_device_factory.cc.orig 2025-04-04 08:52:13 UTC +++ media/capture/video/create_video_capture_device_factory.cc -@@ -13,7 +13,7 @@ +@@ -12,7 +12,7 @@ #include "media/capture/video/fake_video_capture_device_factory.h" #include "media/capture/video/file_video_capture_device_factory.h" --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "media/capture/video/linux/video_capture_device_factory_linux.h" - #elif BUILDFLAG(IS_CHROMEOS_ASH) + #elif BUILDFLAG(IS_CHROMEOS) #include "media/capture/video/chromeos/public/cros_features.h" -@@ -56,7 +56,7 @@ CreateFakeVideoCaptureDeviceFactory() { +@@ -55,7 +55,7 @@ CreateFakeVideoCaptureDeviceFactory() { std::unique_ptr<VideoCaptureDeviceFactory> CreatePlatformSpecificVideoCaptureDeviceFactory( scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return std::make_unique<VideoCaptureDeviceFactoryLinux>(ui_task_runner); - #elif BUILDFLAG(IS_CHROMEOS_ASH) + #elif BUILDFLAG(IS_CHROMEOS) if (base::SysInfo::IsRunningOnChromeOS()) diff --git a/www/chromium/files/patch-media_capture_video_fake__video__capture__device__factory.cc b/www/chromium/files/patch-media_capture_video_fake__video__capture__device__factory.cc index 3254b3099506..b2672048f5fc 100644 --- a/www/chromium/files/patch-media_capture_video_fake__video__capture__device__factory.cc +++ b/www/chromium/files/patch-media_capture_video_fake__video__capture__device__factory.cc @@ -1,6 +1,6 @@ ---- media/capture/video/fake_video_capture_device_factory.cc.orig 2024-01-30 07:53:34 UTC +--- media/capture/video/fake_video_capture_device_factory.cc.orig 2025-05-28 14:55:43 UTC +++ media/capture/video/fake_video_capture_device_factory.cc -@@ -230,7 +230,7 @@ void FakeVideoCaptureDeviceFactory::GetDevicesInfo( +@@ -228,7 +228,7 @@ void FakeVideoCaptureDeviceFactory::GetDevicesInfo( int entry_index = 0; for (const auto& entry : devices_config_) { VideoCaptureApi api = diff --git a/www/chromium/files/patch-media_capture_video_linux_fake__v4l2__impl.cc b/www/chromium/files/patch-media_capture_video_linux_fake__v4l2__impl.cc index fd1eb48a0fd6..c1df68787774 100644 --- a/www/chromium/files/patch-media_capture_video_linux_fake__v4l2__impl.cc +++ b/www/chromium/files/patch-media_capture_video_linux_fake__v4l2__impl.cc @@ -1,6 +1,6 @@ ---- media/capture/video/linux/fake_v4l2_impl.cc.orig 2024-04-19 13:02:56 UTC +--- media/capture/video/linux/fake_v4l2_impl.cc.orig 2025-03-05 08:14:56 UTC +++ media/capture/video/linux/fake_v4l2_impl.cc -@@ -562,7 +562,7 @@ int FakeV4L2Impl::close(int fd) { +@@ -569,7 +569,7 @@ int FakeV4L2Impl::close(int fd) { return kSuccessReturnValue; } diff --git a/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.cc b/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.cc index 21a637af00b0..4f22e5f73af0 100644 --- a/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.cc +++ b/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.cc @@ -1,6 +1,6 @@ ---- media/capture/video/linux/v4l2_capture_delegate.cc.orig 2024-02-23 21:04:38 UTC +--- media/capture/video/linux/v4l2_capture_delegate.cc.orig 2025-03-05 08:14:56 UTC +++ media/capture/video/linux/v4l2_capture_delegate.cc -@@ -5,8 +5,10 @@ +@@ -10,8 +10,10 @@ #include "media/capture/video/linux/v4l2_capture_delegate.h" #include <fcntl.h> @@ -11,7 +11,7 @@ #include <poll.h> #include <sys/ioctl.h> #include <sys/mman.h> -@@ -27,17 +29,19 @@ +@@ -34,17 +36,19 @@ #include "media/capture/video/blob_utils.h" #include "media/capture/video/linux/video_capture_device_linux.h" @@ -32,7 +32,7 @@ // TODO(aleksandar.stojiljkovic): Wrap this with kernel version check once the // format is introduced to kernel. -@@ -47,6 +51,14 @@ using media::mojom::MeteringMode; +@@ -54,6 +58,14 @@ using media::mojom::MeteringMode; #define V4L2_PIX_FMT_INVZ v4l2_fourcc('I', 'N', 'V', 'Z') #endif @@ -47,7 +47,7 @@ namespace media { namespace { -@@ -264,7 +276,7 @@ bool V4L2CaptureDelegate::IsBlockedControl(int control +@@ -273,7 +285,7 @@ bool V4L2CaptureDelegate::IsBlockedControl(int control // static bool V4L2CaptureDelegate::IsControllableControl( int control_id, @@ -56,7 +56,7 @@ const int special_control_id = GetControllingSpecialControl(control_id); if (!special_control_id) { // The control is not controlled by a special control thus the control is -@@ -320,7 +332,7 @@ V4L2CaptureDelegate::V4L2CaptureDelegate( +@@ -329,7 +341,7 @@ V4L2CaptureDelegate::V4L2CaptureDelegate( is_capturing_(false), timeout_count_(0), rotation_(rotation) { @@ -65,16 +65,16 @@ use_gpu_buffer_ = switches::IsVideoCaptureUseGpuMemoryBufferEnabled(); #endif // BUILDFLAG(IS_LINUX) } -@@ -447,7 +459,7 @@ void V4L2CaptureDelegate::AllocateAndStart( +@@ -456,7 +468,7 @@ void V4L2CaptureDelegate::AllocateAndStart( client_->OnStarted(); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) if (use_gpu_buffer_) { - v4l2_gpu_helper_ = std::make_unique<V4L2CaptureDelegateGpuHelper>( - std::move(gmb_support_test_)); -@@ -797,7 +809,7 @@ void V4L2CaptureDelegate::SetGPUEnvironmentForTesting( + v4l2_gpu_helper_ = std::make_unique<V4L2CaptureDelegateGpuHelper>(); + } +@@ -800,7 +812,7 @@ base::WeakPtr<V4L2CaptureDelegate> V4L2CaptureDelegate V4L2CaptureDelegate::~V4L2CaptureDelegate() = default; @@ -83,7 +83,7 @@ int num_retries = 0; for (; DoIoctl(request, argp) < 0 && num_retries < kMaxIOCtrlRetries; ++num_retries) { -@@ -807,7 +819,7 @@ bool V4L2CaptureDelegate::RunIoctl(int request, void* +@@ -810,7 +822,7 @@ bool V4L2CaptureDelegate::RunIoctl(int request, void* return num_retries != kMaxIOCtrlRetries; } @@ -92,7 +92,7 @@ return HANDLE_EINTR(v4l2_->ioctl(device_fd_.get(), request, argp)); } -@@ -818,6 +830,7 @@ bool V4L2CaptureDelegate::IsControllableControl(int co +@@ -821,6 +833,7 @@ bool V4L2CaptureDelegate::IsControllableControl(int co } void V4L2CaptureDelegate::ReplaceControlEventSubscriptions() { @@ -100,7 +100,7 @@ constexpr uint32_t kControlIds[] = {V4L2_CID_AUTO_EXPOSURE_BIAS, V4L2_CID_AUTO_WHITE_BALANCE, V4L2_CID_BRIGHTNESS, -@@ -845,6 +858,7 @@ void V4L2CaptureDelegate::ReplaceControlEventSubscript +@@ -848,6 +861,7 @@ void V4L2CaptureDelegate::ReplaceControlEventSubscript << ", {type = V4L2_EVENT_CTRL, id = " << control_id << "}"; } } @@ -108,7 +108,7 @@ } mojom::RangePtr V4L2CaptureDelegate::RetrieveUserControlRange(int control_id) { -@@ -1025,7 +1039,11 @@ void V4L2CaptureDelegate::DoCapture() { +@@ -1028,7 +1042,11 @@ void V4L2CaptureDelegate::DoCapture() { pollfd device_pfd = {}; device_pfd.fd = device_fd_.get(); @@ -120,7 +120,7 @@ const int result = HANDLE_EINTR(v4l2_->poll(&device_pfd, 1, kCaptureTimeoutMs)); -@@ -1063,6 +1081,7 @@ void V4L2CaptureDelegate::DoCapture() { +@@ -1066,6 +1084,7 @@ void V4L2CaptureDelegate::DoCapture() { timeout_count_ = 0; } @@ -128,7 +128,7 @@ // Dequeue events if the driver has filled in some. if (device_pfd.revents & POLLPRI) { bool controls_changed = false; -@@ -1097,6 +1116,7 @@ void V4L2CaptureDelegate::DoCapture() { +@@ -1099,6 +1118,7 @@ void V4L2CaptureDelegate::DoCapture() { client_->OnCaptureConfigurationChanged(); } } @@ -136,7 +136,7 @@ // Deenqueue, send and reenqueue a buffer if the driver has filled one in. if (device_pfd.revents & POLLIN) { -@@ -1150,7 +1170,7 @@ void V4L2CaptureDelegate::DoCapture() { +@@ -1152,7 +1172,7 @@ void V4L2CaptureDelegate::DoCapture() { // workable on Linux. // See http://crbug.com/959919. @@ -145,7 +145,7 @@ if (use_gpu_buffer_) { v4l2_gpu_helper_->OnIncomingCapturedData( client_.get(), buffer_tracker->start(), -@@ -1223,7 +1243,7 @@ void V4L2CaptureDelegate::SetErrorState(VideoCaptureEr +@@ -1226,7 +1246,7 @@ void V4L2CaptureDelegate::SetErrorState(VideoCaptureEr client_->OnError(error, from_here, reason); } diff --git a/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.h b/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.h index 180ba5ba6418..1741c21f7a4d 100644 --- a/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.h +++ b/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__delegate.h @@ -1,6 +1,6 @@ ---- media/capture/video/linux/v4l2_capture_delegate.h.orig 2023-10-11 18:22:24 UTC +--- media/capture/video/linux/v4l2_capture_delegate.h.orig 2025-01-15 09:18:26 UTC +++ media/capture/video/linux/v4l2_capture_delegate.h -@@ -35,7 +35,7 @@ class Location; +@@ -34,7 +34,7 @@ class Location; namespace media { @@ -9,16 +9,16 @@ class V4L2CaptureDelegateGpuHelper; #endif // BUILDFLAG(IS_LINUX) -@@ -86,7 +86,7 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { +@@ -85,7 +85,7 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { static bool IsBlockedControl(int control_id); static bool IsControllableControl( int control_id, - const base::RepeatingCallback<int(int, void*)>& do_ioctl); + const base::RepeatingCallback<int(unsigned int, void*)>& do_ioctl); - void SetGPUEnvironmentForTesting( - std::unique_ptr<gpu::GpuMemoryBufferSupport> gmb_support); -@@ -100,10 +100,10 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { + private: + friend class V4L2CaptureDelegateTest; +@@ -96,10 +96,10 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { // device file descriptor or (re)starting streaming, can fail but works after // retrying (https://crbug.com/670262). Returns false if the |request| ioctl // fails too many times. @@ -31,7 +31,7 @@ // Check whether the control is controllable (and not changed automatically). bool IsControllableControl(int control_id); -@@ -133,7 +133,7 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { +@@ -129,7 +129,7 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { const base::Location& from_here, const std::string& reason); @@ -40,7 +40,7 @@ // Systems which describe a "color space" usually map that to one or more of // {primary, matrix, transfer, range}. BuildColorSpaceFromv4l2() will use the // matched value as first priority. Otherwise, if there is no best matching -@@ -167,7 +167,7 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { +@@ -163,7 +163,7 @@ class CAPTURE_EXPORT V4L2CaptureDelegate final { // Clockwise rotation in degrees. This value should be 0, 90, 180, or 270. int rotation_; diff --git a/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__device.h b/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__device.h index cbba776523a9..5158a7d01c39 100644 --- a/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__device.h +++ b/www/chromium/files/patch-media_capture_video_linux_v4l2__capture__device.h @@ -1,7 +1,7 @@ ---- media/capture/video/linux/v4l2_capture_device.h.orig 2022-02-07 13:39:41 UTC +--- media/capture/video/linux/v4l2_capture_device.h.orig 2025-05-05 10:57:53 UTC +++ media/capture/video/linux/v4l2_capture_device.h -@@ -21,7 +21,7 @@ class CAPTURE_EXPORT V4L2CaptureDevice - public: +@@ -23,7 +23,7 @@ class CAPTURE_EXPORT V4L2CaptureDevice + virtual int open(const char* device_name, int flags) = 0; virtual int close(int fd) = 0; - virtual int ioctl(int fd, int request, void* argp) = 0; diff --git a/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__v4l2.cc b/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__v4l2.cc index 8ea1a7515106..3c15c6bb7846 100644 --- a/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__v4l2.cc +++ b/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__v4l2.cc @@ -1,6 +1,6 @@ ---- media/capture/video/linux/video_capture_device_factory_v4l2.cc.orig 2024-04-19 13:02:56 UTC +--- media/capture/video/linux/video_capture_device_factory_v4l2.cc.orig 2025-03-05 08:14:56 UTC +++ media/capture/video/linux/video_capture_device_factory_v4l2.cc -@@ -38,6 +38,7 @@ bool CompareCaptureDevices(const VideoCaptureDeviceInf +@@ -43,6 +43,7 @@ bool CompareCaptureDevices(const VideoCaptureDeviceInf return a.descriptor < b.descriptor; } @@ -8,7 +8,7 @@ // USB VID and PID are both 4 bytes long. const size_t kVidPidSize = 4; const size_t kMaxInterfaceNameSize = 256; -@@ -70,11 +71,15 @@ std::string ExtractFileNameFromDeviceId(const std::str +@@ -75,11 +76,24 @@ std::string ExtractFileNameFromDeviceId(const std::str DCHECK(base::StartsWith(device_id, kDevDir, base::CompareCase::SENSITIVE)); return device_id.substr(strlen(kDevDir), device_id.length()); } @@ -19,12 +19,21 @@ public: void GetDeviceIds(std::vector<std::string>* target_container) override { +#if BUILDFLAG(IS_OPENBSD) -+ target_container->emplace_back("/dev/video"); ++ char device[12]; ++ int fd; ++ /* unveil(2) limits access to /dev/, try /dev/video[0-7] */ ++ for (int n = 0; n < 8; n++) { ++ snprintf(device, sizeof(device), "/dev/video%d", n); ++ if ((fd = open(device, O_RDONLY)) != -1) { ++ close(fd); ++ target_container->emplace_back(device); ++ } ++ } +#else const base::FilePath path("/dev/"); base::FileEnumerator enumerator(path, false, base::FileEnumerator::FILES, "video*"); -@@ -82,9 +87,13 @@ class DevVideoFilePathsDeviceProvider +@@ -87,9 +101,13 @@ class DevVideoFilePathsDeviceProvider const base::FileEnumerator::FileInfo info = enumerator.GetInfo(); target_container->emplace_back(path.value() + info.GetName().value()); } @@ -38,7 +47,7 @@ const std::string file_name = ExtractFileNameFromDeviceId(device_id); std::string usb_id; const std::string vid_path = -@@ -101,9 +110,13 @@ class DevVideoFilePathsDeviceProvider +@@ -106,9 +124,13 @@ class DevVideoFilePathsDeviceProvider } return usb_id; @@ -52,7 +61,7 @@ const std::string file_name = ExtractFileNameFromDeviceId(device_id); const std::string interface_path = base::StringPrintf(kInterfacePathTemplate, file_name.c_str()); -@@ -114,6 +127,7 @@ class DevVideoFilePathsDeviceProvider +@@ -119,6 +141,7 @@ class DevVideoFilePathsDeviceProvider return std::string(); } return display_name; @@ -60,7 +69,7 @@ } }; -@@ -219,7 +233,7 @@ void VideoCaptureDeviceFactoryV4L2::GetDevicesInfo( +@@ -224,7 +247,7 @@ void VideoCaptureDeviceFactoryV4L2::GetDevicesInfo( std::move(callback).Run(std::move(devices_info)); } diff --git a/www/chromium/files/patch-media_capture_video_video__capture__buffer__tracker__factory__impl.cc b/www/chromium/files/patch-media_capture_video_video__capture__buffer__tracker__factory__impl.cc index 2d5b9a94cab7..e9f2cde8adb2 100644 --- a/www/chromium/files/patch-media_capture_video_video__capture__buffer__tracker__factory__impl.cc +++ b/www/chromium/files/patch-media_capture_video_video__capture__buffer__tracker__factory__impl.cc @@ -1,6 +1,6 @@ ---- media/capture/video/video_capture_buffer_tracker_factory_impl.cc.orig 2023-12-10 06:10:27 UTC +--- media/capture/video/video_capture_buffer_tracker_factory_impl.cc.orig 2025-04-04 08:52:13 UTC +++ media/capture/video/video_capture_buffer_tracker_factory_impl.cc -@@ -14,7 +14,7 @@ +@@ -13,7 +13,7 @@ #include "media/capture/video/chromeos/gpu_memory_buffer_tracker_cros.h" #elif BUILDFLAG(IS_APPLE) #include "media/capture/video/apple/gpu_memory_buffer_tracker_apple.h" @@ -9,7 +9,7 @@ #include "media/capture/video/linux/v4l2_gpu_memory_buffer_tracker.h" #elif BUILDFLAG(IS_WIN) #include "media/capture/video/win/gpu_memory_buffer_tracker_win.h" -@@ -42,7 +42,7 @@ VideoCaptureBufferTrackerFactoryImpl::CreateTracker( +@@ -41,7 +41,7 @@ VideoCaptureBufferTrackerFactoryImpl::CreateTracker( return std::make_unique<GpuMemoryBufferTrackerCros>(); #elif BUILDFLAG(IS_APPLE) return std::make_unique<GpuMemoryBufferTrackerApple>(); diff --git a/www/chromium/files/patch-media_capture_video_video__capture__device__client.cc b/www/chromium/files/patch-media_capture_video_video__capture__device__client.cc index 173e8463271a..8b1a2362dcb9 100644 --- a/www/chromium/files/patch-media_capture_video_video__capture__device__client.cc +++ b/www/chromium/files/patch-media_capture_video_video__capture__device__client.cc @@ -1,6 +1,6 @@ ---- media/capture/video/video_capture_device_client.cc.orig 2024-04-19 13:02:56 UTC +--- media/capture/video/video_capture_device_client.cc.orig 2025-04-04 08:52:13 UTC +++ media/capture/video/video_capture_device_client.cc -@@ -151,7 +151,7 @@ FourccAndFlip GetFourccAndFlipFromPixelFormat( +@@ -172,7 +172,7 @@ FourccAndFlip GetFourccAndFlipFromPixelFormat( CHECK(!is_width_odd && !is_height_odd); return {libyuv::FOURCC_UYVY}; case media::PIXEL_FORMAT_RGB24: diff --git a/www/chromium/files/patch-media_cdm_cdm__paths__unittest.cc b/www/chromium/files/patch-media_cdm_cdm__paths__unittest.cc index e225b2ebe8c7..5aa40b2baa34 100644 --- a/www/chromium/files/patch-media_cdm_cdm__paths__unittest.cc +++ b/www/chromium/files/patch-media_cdm_cdm__paths__unittest.cc @@ -1,6 +1,6 @@ ---- media/cdm/cdm_paths_unittest.cc.orig 2022-10-24 13:33:33 UTC +--- media/cdm/cdm_paths_unittest.cc.orig 2025-04-04 08:52:13 UTC +++ media/cdm/cdm_paths_unittest.cc -@@ -27,7 +27,7 @@ const char kComponentPlatform[] = +@@ -26,7 +26,7 @@ const char kComponentPlatform[] = "win"; #elif BUILDFLAG(IS_CHROMEOS) "cros"; diff --git a/www/chromium/files/patch-media_cdm_library__cdm_cdm__paths.gni b/www/chromium/files/patch-media_cdm_library__cdm_cdm__paths.gni index 320326272b15..2db78dd32fe5 100644 --- a/www/chromium/files/patch-media_cdm_library__cdm_cdm__paths.gni +++ b/www/chromium/files/patch-media_cdm_library__cdm_cdm__paths.gni @@ -1,6 +1,6 @@ ---- media/cdm/library_cdm/cdm_paths.gni.orig 2023-10-11 18:22:24 UTC +--- media/cdm/library_cdm/cdm_paths.gni.orig 2025-04-04 08:52:13 UTC +++ media/cdm/library_cdm/cdm_paths.gni -@@ -15,7 +15,7 @@ assert(enable_library_cdms) +@@ -14,7 +14,7 @@ assert(enable_library_cdms) # Explicitly define what we use to avoid confusion. if (is_chromeos) { component_os = "cros" diff --git a/www/chromium/files/patch-third__party_ffmpeg_chromium_scripts_build__ffmpeg.py b/www/chromium/files/patch-media_ffmpeg_scripts_build__ffmpeg.py index 472bb9478d6b..9b83eed1f968 100644 --- a/www/chromium/files/patch-third__party_ffmpeg_chromium_scripts_build__ffmpeg.py +++ b/www/chromium/files/patch-media_ffmpeg_scripts_build__ffmpeg.py @@ -1,6 +1,6 @@ ---- third_party/ffmpeg/chromium/scripts/build_ffmpeg.py.orig 2024-04-19 13:02:56 UTC -+++ third_party/ffmpeg/chromium/scripts/build_ffmpeg.py -@@ -32,7 +32,7 @@ NDK_ROOT_DIR = os.path.abspath( +--- media/ffmpeg/scripts/build_ffmpeg.py.orig 2025-07-02 06:08:04 UTC ++++ media/ffmpeg/scripts/build_ffmpeg.py +@@ -33,7 +33,7 @@ NDK_ROOT_DIR = os.path.abspath( SUCCESS_TOKEN = 'THIS_BUILD_WORKED' sys.path.append(os.path.join(CHROMIUM_ROOT_DIR, 'build')) @@ -27,7 +27,7 @@ return 'lib%s.so.%s' % (dso_name, dso_version) elif target_os == 'mac': return 'lib%s.%s.dylib' % (dso_name, dso_version) -@@ -474,7 +476,7 @@ def BuildFFmpeg(target_os, target_arch, host_os, host_ +@@ -473,7 +475,7 @@ def BuildFFmpeg(target_os, target_arch, host_os, host_ # removing <sys/sysctl.h> soon, so this is needed to silence a deprecation # #warning which will be converted to an error via -Werror. # There is also no prctl.h @@ -36,7 +36,7 @@ pre_make_rewrites += [ (r'(#define HAVE_SYSCTL [01])', r'#define HAVE_SYSCTL 0 /* \1 -- forced to 0 for Fuchsia */'), -@@ -597,7 +599,7 @@ def main(argv): +@@ -596,7 +598,7 @@ def main(argv): configure_args = args[2:] if target_os not in ('android', 'linux', 'linux-noasm', 'mac', 'win', @@ -64,12 +64,3 @@ # See crbug.com/1467681. These could be removed eventually '--disable-dotprod', '--disable-i8mm', -@@ -1031,7 +1030,7 @@ def ConfigureAndBuild(target_arch, target_os, host_os, - 'Chrome', configure_flags['Common'] + - configure_flags['ChromeAndroid'] + configure_args) - -- if target_os in ['linux', 'linux-noasm']: -+ if target_os in ['linux', 'linux-noasm', 'openbsd', 'freebsd']: - # ChromeOS enables MPEG4 which requires error resilience :( - chrome_os_flags = (configure_flags['Common'] + - configure_flags['Chrome'] + diff --git a/www/chromium/files/patch-third__party_ffmpeg_chromium_scripts_robo__lib_config.py b/www/chromium/files/patch-media_ffmpeg_scripts_robo__lib_config.py index c677afba1eec..6613dd75776c 100644 --- a/www/chromium/files/patch-third__party_ffmpeg_chromium_scripts_robo__lib_config.py +++ b/www/chromium/files/patch-media_ffmpeg_scripts_robo__lib_config.py @@ -1,25 +1,26 @@ ---- third_party/ffmpeg/chromium/scripts/robo_lib/config.py.orig 2024-04-19 13:02:56 UTC -+++ third_party/ffmpeg/chromium/scripts/robo_lib/config.py -@@ -51,18 +51,12 @@ class RoboConfiguration: +--- media/ffmpeg/scripts/robo_lib/config.py.orig 2025-02-19 07:43:18 UTC ++++ media/ffmpeg/scripts/robo_lib/config.py +@@ -56,19 +56,13 @@ class RoboConfiguration: self._llvm_path = os.path.join(self.chrome_src(), "third_party", "llvm-build", "Release+Asserts", "bin") - self.EnsurePathContainsLLVM() - self.EnsureNoMakeInfo() self.EnsureFFmpegHome() - self.EnsureASANConfig() + self.EnsureGNConfig() - self.ComputeBranchName() + if not quiet: shell.log(f"Using chrome src: {self.chrome_src()}") shell.log(f"Using script dir: {self._script_directory}") - shell.log(f"Using ffmpeg home:{self.ffmpeg_home()}") + shell.log(f"Using ffmpeg home: {self.ffmpeg_home()}") - shell.log(f"On branch: {self.branch_name()}") - if self.sushi_branch_name(): - shell.log(f"On sushi branch: {self.sushi_branch_name()}") # Filename that we'll ask generate_gn.py to write git commands to. - # TODO: Should this use script_directory, or stay with ffmpeg? As long as -@@ -155,9 +149,9 @@ class RoboConfiguration: + # TODO: Should this use script_directory, or stay with ffmpeg? As long +@@ -187,9 +181,9 @@ class RoboConfiguration: if re.match(r"i.86", platform.machine()): self._host_architecture = "ia32" @@ -31,7 +32,7 @@ self._host_architecture = "arm64" elif platform.machine() == "mips32": self._host_architecture = "mipsel" -@@ -192,6 +186,10 @@ class RoboConfiguration: +@@ -224,6 +218,10 @@ class RoboConfiguration: elif platform.system() == "Windows" or "CYGWIN_NT" in platform.system( ): self._host_operating_system = "win" @@ -42,7 +43,7 @@ else: raise ValueError(f"Unsupported platform: {platform.system()}") -@@ -200,8 +198,8 @@ class RoboConfiguration: +@@ -232,8 +230,8 @@ class RoboConfiguration: wd = os.getcwd() # Walk up the tree until we find src/AUTHORS while wd != "/": diff --git a/www/chromium/files/patch-media_gpu_buffer__validation.cc b/www/chromium/files/patch-media_gpu_buffer__validation.cc deleted file mode 100644 index e88c78e3363e..000000000000 --- a/www/chromium/files/patch-media_gpu_buffer__validation.cc +++ /dev/null @@ -1,46 +0,0 @@ ---- media/gpu/buffer_validation.cc.orig 2024-02-23 21:04:38 UTC -+++ media/gpu/buffer_validation.cc -@@ -16,7 +16,7 @@ - #include "ui/gfx/geometry/size.h" - #include "ui/gfx/gpu_memory_buffer.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include <drm_fourcc.h> - #include <sys/types.h> - #include <unistd.h> -@@ -29,7 +29,7 @@ - namespace media { - - namespace { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #ifndef I915_FORMAT_MOD_4_TILED_MTL_MC_CCS - // TODO(b/271455200): Remove this definition once drm_fourcc.h contains it. - /* -@@ -55,7 +55,7 @@ bool IsIntelMediaCompressedModifier(uint64_t modifier) - } // namespace - - bool GetFileSize(const int fd, size_t* size) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (fd < 0) { - VLOG(1) << "Invalid file descriptor"; - return false; -@@ -109,14 +109,14 @@ bool VerifyGpuMemoryBufferHandle( - VLOG(1) << "Unsupported: " << pixel_format; - return false; - } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const uint64_t modifier = gmb_handle.native_pixmap_handle.modifier; - const bool is_intel_media_compressed_buffer = - IsIntelMediaCompressedModifier(modifier); - const bool is_intel_media_compression_enabled = - #if BUILDFLAG(IS_CHROMEOS) - base::FeatureList::IsEnabled(features::kEnableIntelMediaCompression); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - false; - #endif - diff --git a/www/chromium/files/patch-media_gpu_chromeos_gl__image__processor__backend.cc b/www/chromium/files/patch-media_gpu_chromeos_gl__image__processor__backend.cc new file mode 100644 index 000000000000..6a42aab37898 --- /dev/null +++ b/www/chromium/files/patch-media_gpu_chromeos_gl__image__processor__backend.cc @@ -0,0 +1,13 @@ +--- media/gpu/chromeos/gl_image_processor_backend.cc.orig 2024-06-18 16:34:35 UTC ++++ media/gpu/chromeos/gl_image_processor_backend.cc +@@ -28,6 +28,10 @@ + #include "ui/ozone/public/ozone_platform.h" + #include "ui/ozone/public/surface_factory_ozone.h" + ++#ifndef GL_CONTEXT_LOST_KHR ++#define GL_CONTEXT_LOST_KHR 0x0507 ++#endif ++ + namespace media { + + namespace { diff --git a/www/chromium/files/patch-media_gpu_chromeos_libyuv__image__processor__backend.cc b/www/chromium/files/patch-media_gpu_chromeos_libyuv__image__processor__backend.cc index 83704b86179c..798caf94eb76 100644 --- a/www/chromium/files/patch-media_gpu_chromeos_libyuv__image__processor__backend.cc +++ b/www/chromium/files/patch-media_gpu_chromeos_libyuv__image__processor__backend.cc @@ -1,6 +1,6 @@ ---- media/gpu/chromeos/libyuv_image_processor_backend.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/chromeos/libyuv_image_processor_backend.cc.orig 2024-11-14 07:57:23 UTC +++ media/gpu/chromeos/libyuv_image_processor_backend.cc -@@ -48,7 +48,7 @@ static constexpr struct { +@@ -53,7 +53,7 @@ static constexpr struct { #define CONV(in, out, trans, result) \ {Fourcc::in, Fourcc::out, Transform::trans, SupportResult::result} // Conversion. @@ -9,16 +9,16 @@ CONV(NV12, AR24, kConversion, Supported), #endif CONV(NV12, NV12, kConversion, Supported), -@@ -436,7 +436,7 @@ int LibYUVImageProcessorBackend::DoConversion(const Fr - fr->GetWritableVisibleData(VideoFrame::kUVPlane)), \ - fr->stride(VideoFrame::kUVPlane) +@@ -412,7 +412,7 @@ int LibYUVImageProcessorBackend::DoConversion(const Fr + fr->GetWritableVisibleData(VideoFrame::Plane::kUV)), \ + fr->stride(VideoFrame::Plane::kUV) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #define ARGB_DATA(fr) \ - fr->GetWritableVisibleData(VideoFrame::kARGBPlane), \ - fr->stride(VideoFrame::kARGBPlane) -@@ -597,7 +597,7 @@ int LibYUVImageProcessorBackend::DoConversion(const Fr + #define ARGB_DATA(fr) \ + fr->GetWritableVisibleData(VideoFrame::Plane::kARGB), \ + fr->stride(VideoFrame::Plane::kARGB) +@@ -574,7 +574,7 @@ int LibYUVImageProcessorBackend::DoConversion(const Fr } } diff --git a/www/chromium/files/patch-media_gpu_chromeos_mailbox__video__frame__converter.cc b/www/chromium/files/patch-media_gpu_chromeos_mailbox__video__frame__converter.cc index 6b1ec820db47..c103c07306e8 100644 --- a/www/chromium/files/patch-media_gpu_chromeos_mailbox__video__frame__converter.cc +++ b/www/chromium/files/patch-media_gpu_chromeos_mailbox__video__frame__converter.cc @@ -1,8 +1,8 @@ ---- media/gpu/chromeos/mailbox_video_frame_converter.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/chromeos/mailbox_video_frame_converter.cc.orig 2025-05-05 10:57:53 UTC +++ media/gpu/chromeos/mailbox_video_frame_converter.cc -@@ -63,7 +63,7 @@ viz::SharedImageFormat GetSharedImageFormat(gfx::Buffe +@@ -68,7 +68,7 @@ viz::SharedImageFormat GetSharedImageFormat(gfx::Buffe << static_cast<int>(buffer_format); - NOTREACHED_NORETURN(); + NOTREACHED(); } -#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-media_gpu_chromeos_native__pixmap__frame__resource.cc b/www/chromium/files/patch-media_gpu_chromeos_native__pixmap__frame__resource.cc deleted file mode 100644 index 9147c398e1fa..000000000000 --- a/www/chromium/files/patch-media_gpu_chromeos_native__pixmap__frame__resource.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- media/gpu/chromeos/native_pixmap_frame_resource.cc.orig 2024-04-19 13:02:56 UTC -+++ media/gpu/chromeos/native_pixmap_frame_resource.cc -@@ -166,7 +166,7 @@ scoped_refptr<NativePixmapFrameResource> NativePixmapF - const bool is_intel_media_compression_enabled = - #if BUILDFLAG(IS_CHROMEOS) - base::FeatureList::IsEnabled(features::kEnableIntelMediaCompression); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - false; - #endif - CHECK(!is_intel_media_compressed_buffer || diff --git a/www/chromium/files/patch-media_gpu_chromeos_platform__video__frame__utils.cc b/www/chromium/files/patch-media_gpu_chromeos_platform__video__frame__utils.cc index c40bd7660a06..c8ada7c79f9d 100644 --- a/www/chromium/files/patch-media_gpu_chromeos_platform__video__frame__utils.cc +++ b/www/chromium/files/patch-media_gpu_chromeos_platform__video__frame__utils.cc @@ -1,6 +1,6 @@ ---- media/gpu/chromeos/platform_video_frame_utils.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/chromeos/platform_video_frame_utils.cc.orig 2025-07-02 06:08:04 UTC +++ media/gpu/chromeos/platform_video_frame_utils.cc -@@ -68,7 +68,7 @@ static std::unique_ptr<ui::GbmDevice> CreateGbmDevice( +@@ -69,7 +69,7 @@ static std::unique_ptr<ui::GbmDevice> CreateGbmDevice( const base::FilePath dev_path(FILE_PATH_LITERAL( base::StrCat({drm_node_file_prefix, base::NumberToString(i)}))); @@ -9,21 +9,12 @@ const bool is_render_node = base::Contains(drm_node_file_prefix, "render"); // TODO(b/313513760): don't guard base::File::FLAG_WRITE behind -@@ -196,7 +196,7 @@ class GbmDeviceWrapper { - const bool is_intel_media_compression_enabled = - #if BUILDFLAG(IS_CHROMEOS) - base::FeatureList::IsEnabled(features::kEnableIntelMediaCompression); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - false; - #endif - if (is_intel_media_compression_enabled) { -@@ -347,7 +347,7 @@ scoped_refptr<VideoFrame> CreateVideoFrameFromGpuMemor - const bool is_intel_media_compression_enabled = - #if BUILDFLAG(IS_CHROMEOS) - base::FeatureList::IsEnabled(features::kEnableIntelMediaCompression); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - false; - #endif +@@ -190,7 +190,7 @@ class GbmDeviceWrapper { + const base::FilePath dev_path( + base::CommandLine::ForCurrentProcess()->GetSwitchValuePath( + switches::kRenderNodeOverride)); +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(USE_V4L2_CODEC) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(USE_V4L2_CODEC) + const bool is_render_node = base::Contains(dev_path.value(), "render"); + // TODO(b/313513760): don't guard base::File::FLAG_WRITE behind diff --git a/www/chromium/files/patch-media_gpu_chromeos_video__decoder__pipeline.cc b/www/chromium/files/patch-media_gpu_chromeos_video__decoder__pipeline.cc index 91e6d983819e..31b99f7f4211 100644 --- a/www/chromium/files/patch-media_gpu_chromeos_video__decoder__pipeline.cc +++ b/www/chromium/files/patch-media_gpu_chromeos_video__decoder__pipeline.cc @@ -1,6 +1,6 @@ ---- media/gpu/chromeos/video_decoder_pipeline.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/chromeos/video_decoder_pipeline.cc.orig 2025-05-28 14:55:43 UTC +++ media/gpu/chromeos/video_decoder_pipeline.cc -@@ -1038,7 +1038,7 @@ VideoDecoderPipeline::PickDecoderOutputFormat( +@@ -1128,7 +1128,7 @@ VideoDecoderPipeline::PickDecoderOutputFormat( } #endif @@ -9,21 +9,21 @@ // Linux should always use a custom allocator (to allocate buffers using // libva) and a PlatformVideoFramePool. CHECK(allocator.has_value()); -@@ -1048,7 +1048,7 @@ VideoDecoderPipeline::PickDecoderOutputFormat( - // to create NativePixmap-backed frames. +@@ -1137,7 +1137,7 @@ VideoDecoderPipeline::PickDecoderOutputFormat( + // VideoFrame::StorageType of VideoFrame::STORAGE_DMABUFS. main_frame_pool_->AsPlatformVideoFramePool()->SetCustomFrameAllocator( - *allocator, VideoFrame::STORAGE_GPU_MEMORY_BUFFER); + *allocator, VideoFrame::STORAGE_DMABUFS); -#elif BUILDFLAG(IS_LINUX) && BUILDFLAG(USE_V4L2_CODEC) +#elif (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(USE_V4L2_CODEC) // Linux w/ V4L2 should not use a custom allocator // Only tested with video_decode_accelerator_tests // TODO(wenst@) Test with full Chromium Browser -@@ -1206,7 +1206,7 @@ VideoDecoderPipeline::PickDecoderOutputFormat( +@@ -1311,7 +1311,7 @@ VideoDecoderPipeline::PickDecoderOutputFormat( << " VideoFrames"; auxiliary_frame_pool_->set_parent_task_runner(decoder_task_runner_); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // TODO(nhebert): Change the storage type argument when |allocator| switches - // to create NativePixmap-backed frames. + // The custom allocator creates frames backed by NativePixmap, which uses a + // VideoFrame::StorageType of VideoFrame::STORAGE_DMABUFS. auxiliary_frame_pool_->AsPlatformVideoFramePool()->SetCustomFrameAllocator( diff --git a/www/chromium/files/patch-media_gpu_gpu__video__decode__accelerator__factory.cc b/www/chromium/files/patch-media_gpu_gpu__video__decode__accelerator__factory.cc new file mode 100644 index 000000000000..8d7b9f6651ef --- /dev/null +++ b/www/chromium/files/patch-media_gpu_gpu__video__decode__accelerator__factory.cc @@ -0,0 +1,20 @@ +--- media/gpu/gpu_video_decode_accelerator_factory.cc.orig 2025-05-05 10:57:53 UTC ++++ media/gpu/gpu_video_decode_accelerator_factory.cc +@@ -13,7 +13,7 @@ + #include "media/gpu/media_gpu_export.h" + #include "media/media_buildflags.h" + +-#if BUILDFLAG(USE_V4L2_CODEC) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) ++#if BUILDFLAG(USE_V4L2_CODEC) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) + #include "media/gpu/v4l2/legacy/v4l2_video_decode_accelerator.h" + #include "media/gpu/v4l2/v4l2_device.h" + #endif +@@ -29,7 +29,7 @@ GpuVideoDecodeAcceleratorFactory::CreateVDA( + if (gpu_preferences.disable_accelerated_video_decode) + return nullptr; + +-#if BUILDFLAG(USE_V4L2_CODEC) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) ++#if BUILDFLAG(USE_V4L2_CODEC) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) + + std::unique_ptr<VideoDecodeAccelerator> vda; + vda.reset(new V4L2VideoDecodeAccelerator(base::MakeRefCounted<V4L2Device>())); diff --git a/www/chromium/files/patch-media_gpu_gpu__video__encode__accelerator__factory.cc b/www/chromium/files/patch-media_gpu_gpu__video__encode__accelerator__factory.cc index e9d24ec7ecfc..5401fc494c18 100644 --- a/www/chromium/files/patch-media_gpu_gpu__video__encode__accelerator__factory.cc +++ b/www/chromium/files/patch-media_gpu_gpu__video__encode__accelerator__factory.cc @@ -1,11 +1,20 @@ ---- media/gpu/gpu_video_encode_accelerator_factory.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/gpu_video_encode_accelerator_factory.cc.orig 2025-05-05 10:57:53 UTC +++ media/gpu/gpu_video_encode_accelerator_factory.cc -@@ -118,7 +118,7 @@ std::vector<VEAFactoryFunction> GetVEAFactoryFunctions - return vea_factory_functions; +@@ -160,7 +160,7 @@ std::vector<VEAFactoryFunction> GetVEAFactoryFunctions + } #if BUILDFLAG(USE_VAAPI) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (base::FeatureList::IsEnabled(kVaapiVideoEncodeLinux)) - vea_factory_functions.push_back(base::BindRepeating(&CreateVaapiVEA)); - #else + if (base::FeatureList::IsEnabled(kAcceleratedVideoEncodeLinux)) { + vea_factory_functions->push_back(base::BindRepeating(&CreateVaapiVEA)); + } +@@ -168,7 +168,7 @@ std::vector<VEAFactoryFunction> GetVEAFactoryFunctions + vea_factory_functions->push_back(base::BindRepeating(&CreateVaapiVEA)); + #endif + #elif BUILDFLAG(USE_V4L2_CODEC) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled(kAcceleratedVideoEncodeLinux)) { + vea_factory_functions->push_back(base::BindRepeating(&CreateV4L2VEA)); + } diff --git a/www/chromium/files/patch-media_gpu_sandbox_hardware__video__decoding__sandbox__hook__linux.cc b/www/chromium/files/patch-media_gpu_sandbox_hardware__video__decoding__sandbox__hook__linux.cc index 754952b561c7..da140f6eb91d 100644 --- a/www/chromium/files/patch-media_gpu_sandbox_hardware__video__decoding__sandbox__hook__linux.cc +++ b/www/chromium/files/patch-media_gpu_sandbox_hardware__video__decoding__sandbox__hook__linux.cc @@ -1,6 +1,6 @@ ---- media/gpu/sandbox/hardware_video_decoding_sandbox_hook_linux.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/sandbox/hardware_video_decoding_sandbox_hook_linux.cc.orig 2025-04-04 08:52:13 UTC +++ media/gpu/sandbox/hardware_video_decoding_sandbox_hook_linux.cc -@@ -16,7 +16,9 @@ +@@ -17,7 +17,9 @@ #include "media/gpu/vaapi/vaapi_wrapper.h" #endif @@ -10,7 +10,7 @@ // TODO(b/195769334): the hardware video decoding sandbox is really only useful // when building with VA-API or V4L2 (otherwise, we're not really doing hardware -@@ -32,6 +34,7 @@ using sandbox::syscall_broker::BrokerFilePermission; +@@ -33,6 +35,7 @@ using sandbox::syscall_broker::BrokerFilePermission; namespace media { namespace { @@ -18,15 +18,15 @@ void AllowAccessToRenderNodes(std::vector<BrokerFilePermission>& permissions, bool include_sys_dev_char, bool read_write) { -@@ -182,6 +185,7 @@ bool HardwareVideoDecodingPreSandboxHookForV4L2( - NOTREACHED_NORETURN(); +@@ -189,6 +192,7 @@ bool HardwareVideoDecodingPreSandboxHookForV4L2( + NOTREACHED(); #endif // BUILDFLAG(USE_V4L2_CODEC) } +#endif } // namespace -@@ -197,6 +201,7 @@ bool HardwareVideoDecodingPreSandboxHookForV4L2( +@@ -204,6 +208,7 @@ bool HardwareVideoDecodingPreSandboxHookForV4L2( // (at least). bool HardwareVideoDecodingPreSandboxHook( sandbox::policy::SandboxLinux::Options options) { @@ -34,7 +34,7 @@ using HardwareVideoDecodingProcessPolicy = sandbox::policy::HardwareVideoDecodingProcessPolicy; using PolicyType = -@@ -242,6 +247,7 @@ bool HardwareVideoDecodingPreSandboxHook( +@@ -249,6 +254,7 @@ bool HardwareVideoDecodingPreSandboxHook( // |permissions| is empty? sandbox::policy::SandboxLinux::GetInstance()->StartBrokerProcess( command_set, permissions, options); diff --git a/www/chromium/files/patch-media_gpu_sandbox_hardware__video__encoding__sandbox__hook__linux.cc b/www/chromium/files/patch-media_gpu_sandbox_hardware__video__encoding__sandbox__hook__linux.cc index e59de2f27ed8..cb2676ffbbaa 100644 --- a/www/chromium/files/patch-media_gpu_sandbox_hardware__video__encoding__sandbox__hook__linux.cc +++ b/www/chromium/files/patch-media_gpu_sandbox_hardware__video__encoding__sandbox__hook__linux.cc @@ -1,4 +1,4 @@ ---- media/gpu/sandbox/hardware_video_encoding_sandbox_hook_linux.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/sandbox/hardware_video_encoding_sandbox_hook_linux.cc.orig 2024-10-22 08:31:56 UTC +++ media/gpu/sandbox/hardware_video_encoding_sandbox_hook_linux.cc @@ -18,12 +18,15 @@ #include "media/gpu/v4l2/v4l2_device.h" @@ -16,9 +16,9 @@ sandbox::syscall_broker::BrokerCommandSet command_set; std::vector<BrokerFilePermission> permissions; -@@ -120,6 +123,7 @@ bool HardwareVideoEncodingPreSandboxHook( - return false; - } +@@ -131,6 +134,7 @@ bool HardwareVideoEncodingPreSandboxHook( + dlopen("libvulkan.so.1", kDlopenFlags); + dlopen("libvulkan_radeon.so", kDlopenFlags); } +#endif #endif diff --git a/www/chromium/files/patch-media_gpu_test_raw__video.cc b/www/chromium/files/patch-media_gpu_test_raw__video.cc new file mode 100644 index 000000000000..314137ad1cc5 --- /dev/null +++ b/www/chromium/files/patch-media_gpu_test_raw__video.cc @@ -0,0 +1,11 @@ +--- media/gpu/test/raw_video.cc.orig 2025-05-28 14:55:43 UTC ++++ media/gpu/test/raw_video.cc +@@ -63,7 +63,7 @@ std::unique_ptr<base::MemoryMappedFile> CreateMemoryMa + base::File::FLAG_READ | base::File::FLAG_WRITE + // On Windows FLAG_CREATE_ALWAYS will require FLAG_WRITE, and FLAG_APPEND + // must not be specified. +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + | base::File::FLAG_APPEND + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + ), diff --git a/www/chromium/files/patch-media_gpu_test_video__frame__file__writer.cc b/www/chromium/files/patch-media_gpu_test_video__frame__file__writer.cc new file mode 100644 index 000000000000..52116d440741 --- /dev/null +++ b/www/chromium/files/patch-media_gpu_test_video__frame__file__writer.cc @@ -0,0 +1,11 @@ +--- media/gpu/test/video_frame_file_writer.cc.orig 2025-04-04 08:52:13 UTC ++++ media/gpu/test/video_frame_file_writer.cc +@@ -25,7 +25,7 @@ + #include "testing/gtest/include/gtest/gtest.h" + #include "ui/gfx/codec/png_codec.h" + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include <sys/mman.h> + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-media_gpu_test_video__frame__helpers.cc b/www/chromium/files/patch-media_gpu_test_video__frame__helpers.cc new file mode 100644 index 000000000000..e3db9463ac40 --- /dev/null +++ b/www/chromium/files/patch-media_gpu_test_video__frame__helpers.cc @@ -0,0 +1,11 @@ +--- media/gpu/test/video_frame_helpers.cc.orig 2025-04-04 08:52:13 UTC ++++ media/gpu/test/video_frame_helpers.cc +@@ -23,7 +23,7 @@ + #include "ui/gfx/buffer_format_util.h" + #include "ui/gfx/gpu_memory_buffer.h" + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include <sys/mman.h> + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-media_gpu_test_video__frame__validator.cc b/www/chromium/files/patch-media_gpu_test_video__frame__validator.cc new file mode 100644 index 000000000000..2519ad940ad2 --- /dev/null +++ b/www/chromium/files/patch-media_gpu_test_video__frame__validator.cc @@ -0,0 +1,11 @@ +--- media/gpu/test/video_frame_validator.cc.orig 2025-04-04 08:52:13 UTC ++++ media/gpu/test/video_frame_validator.cc +@@ -34,7 +34,7 @@ + #include "testing/gtest/include/gtest/gtest.h" + #include "ui/gfx/gpu_memory_buffer.h" + +-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include <sys/mman.h> + #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-media_gpu_vaapi_vaapi__video__decoder.cc b/www/chromium/files/patch-media_gpu_vaapi_vaapi__video__decoder.cc index 88c151005ad8..f7683b9c0f11 100644 --- a/www/chromium/files/patch-media_gpu_vaapi_vaapi__video__decoder.cc +++ b/www/chromium/files/patch-media_gpu_vaapi_vaapi__video__decoder.cc @@ -1,6 +1,6 @@ ---- media/gpu/vaapi/vaapi_video_decoder.cc.orig 2024-04-19 13:02:56 UTC +--- media/gpu/vaapi/vaapi_video_decoder.cc.orig 2025-07-02 06:08:04 UTC +++ media/gpu/vaapi/vaapi_video_decoder.cc -@@ -780,7 +780,7 @@ void VaapiVideoDecoder::ApplyResolutionChangeWithScree +@@ -786,7 +786,7 @@ void VaapiVideoDecoder::ApplyResolutionChangeWithScree const gfx::Size decoder_natural_size = aspect_ratio_.GetNaturalSize(decoder_visible_rect); diff --git a/www/chromium/files/patch-media_gpu_vaapi_vaapi__wrapper.cc b/www/chromium/files/patch-media_gpu_vaapi_vaapi__wrapper.cc index 0a290ec4307d..b5d79736df4f 100644 --- a/www/chromium/files/patch-media_gpu_vaapi_vaapi__wrapper.cc +++ b/www/chromium/files/patch-media_gpu_vaapi_vaapi__wrapper.cc @@ -1,6 +1,6 @@ ---- media/gpu/vaapi/vaapi_wrapper.cc.orig 2024-03-22 08:19:40 UTC +--- media/gpu/vaapi/vaapi_wrapper.cc.orig 2025-05-28 14:55:43 UTC +++ media/gpu/vaapi/vaapi_wrapper.cc -@@ -67,7 +67,7 @@ +@@ -82,7 +82,7 @@ using media_gpu_vaapi::kModuleVa_prot; #endif diff --git a/www/chromium/files/patch-media_media__options.gni b/www/chromium/files/patch-media_media__options.gni index b80cdd2c9011..88d69961b266 100644 --- a/www/chromium/files/patch-media_media__options.gni +++ b/www/chromium/files/patch-media_media__options.gni @@ -1,6 +1,6 @@ ---- media/media_options.gni.orig 2024-02-23 21:04:38 UTC +--- media/media_options.gni.orig 2025-07-02 06:08:04 UTC +++ media/media_options.gni -@@ -190,12 +190,15 @@ declare_args() { +@@ -200,12 +200,15 @@ declare_args() { # Enables runtime selection of ALSA library for audio. use_alsa = false @@ -17,14 +17,3 @@ (!is_castos || (target_cpu == "x86" || target_cpu == "x64") || is_cast_audio_only)) { use_alsa = true -@@ -211,6 +214,10 @@ declare_args() { - if (!use_cras && !is_castos && !is_asan && !is_tsan) { - use_pulseaudio = true - } -+ } -+ if (is_openbsd) { -+ use_sndio = true -+ use_pulseaudio = false - } - } - diff --git a/www/chromium/files/patch-media_mojo_mojom_BUILD.gn b/www/chromium/files/patch-media_mojo_mojom_BUILD.gn new file mode 100644 index 000000000000..7832da7c8076 --- /dev/null +++ b/www/chromium/files/patch-media_mojo_mojom_BUILD.gn @@ -0,0 +1,11 @@ +--- media/mojo/mojom/BUILD.gn.orig 2025-07-02 06:08:04 UTC ++++ media/mojo/mojom/BUILD.gn +@@ -975,7 +975,7 @@ source_set("test_support") { + sources = [] + deps = [] + +- if (is_linux || is_chromeos) { ++ if (!is_bsd && (is_linux || is_chromeos)) { + sources += [ + "buffer_handle_test_util.cc", + "buffer_handle_test_util.h", diff --git a/www/chromium/files/patch-media_mojo_mojom_stable_stable__video__decoder__types__mojom__traits.cc b/www/chromium/files/patch-media_mojo_mojom_stable_stable__video__decoder__types__mojom__traits.cc deleted file mode 100644 index fac46f5a5393..000000000000 --- a/www/chromium/files/patch-media_mojo_mojom_stable_stable__video__decoder__types__mojom__traits.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- media/mojo/mojom/stable/stable_video_decoder_types_mojom_traits.cc.orig 2023-10-11 18:22:24 UTC -+++ media/mojo/mojom/stable/stable_video_decoder_types_mojom_traits.cc -@@ -837,7 +837,7 @@ const gfx::GpuMemoryBufferId& StructTraits< - return input.id; - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // static - gfx::NativePixmapHandle StructTraits< - media::stable::mojom::NativeGpuMemoryBufferHandleDataView, -@@ -858,7 +858,7 @@ bool StructTraits<media::stable::mojom::NativeGpuMemor - - output->type = gfx::NATIVE_PIXMAP; - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (!data.ReadPlatformHandle(&output->native_pixmap_handle)) - return false; - return true; diff --git a/www/chromium/files/patch-media_mojo_mojom_stable_stable__video__decoder__types__mojom__traits.h b/www/chromium/files/patch-media_mojo_mojom_stable_stable__video__decoder__types__mojom__traits.h deleted file mode 100644 index d38bcbe04b9b..000000000000 --- a/www/chromium/files/patch-media_mojo_mojom_stable_stable__video__decoder__types__mojom__traits.h +++ /dev/null @@ -1,11 +0,0 @@ ---- media/mojo/mojom/stable/stable_video_decoder_types_mojom_traits.h.orig 2023-10-11 18:22:24 UTC -+++ media/mojo/mojom/stable/stable_video_decoder_types_mojom_traits.h -@@ -693,7 +693,7 @@ struct StructTraits<media::stable::mojom::NativeGpuMem - static const gfx::GpuMemoryBufferId& id( - const gfx::GpuMemoryBufferHandle& input); - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - static gfx::NativePixmapHandle platform_handle( - gfx::GpuMemoryBufferHandle& input); - #else diff --git a/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.cc b/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.cc index abaff21f1ca3..b9a839065e96 100644 --- a/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.cc +++ b/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.cc @@ -1,4 +1,4 @@ ---- media/mojo/mojom/video_frame_mojom_traits.cc.orig 2022-10-24 13:33:33 UTC +--- media/mojo/mojom/video_frame_mojom_traits.cc.orig 2025-07-02 06:08:04 UTC +++ media/mojo/mojom/video_frame_mojom_traits.cc @@ -22,7 +22,7 @@ #include "ui/gfx/mojom/color_space_mojom_traits.h" @@ -7,5 +7,32 @@ -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "base/posix/eintr_wrapper.h" + #include "media/gpu/buffer_validation.h" #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +@@ -159,7 +159,7 @@ media::mojom::VideoFrameDataPtr MakeVideoFrameData( + media::mojom::OpaqueVideoFrameData::New()); + } +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + if (input->storage_type() == media::VideoFrame::STORAGE_DMABUFS) { + // Duplicates the DMA buffer FDs to a new vector since this cannot take + // ownership of the FDs in |input| due to constness. +@@ -190,7 +190,7 @@ media::mojom::VideoFrameDataPtr MakeVideoFrameData( + + } // namespace + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // static + bool StructTraits< + media::mojom::ColorPlaneLayoutDataView, +@@ -429,7 +429,7 @@ bool StructTraits<media::mojom::VideoFrameDataView, + frame = media::VideoFrame::WrapTrackingToken( + format, *metadata.tracking_token, coded_size, visible_rect, + natural_size, timestamp); +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + } else if (data.is_dmabuf_data()) { + media::mojom::DmabufVideoFrameDataDataView dmabuf_data; + data.GetDmabufDataDataView(&dmabuf_data); diff --git a/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.h b/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.h new file mode 100644 index 000000000000..d4e92c246aac --- /dev/null +++ b/www/chromium/files/patch-media_mojo_mojom_video__frame__mojom__traits.h @@ -0,0 +1,11 @@ +--- media/mojo/mojom/video_frame_mojom_traits.h.orig 2025-05-05 10:57:53 UTC ++++ media/mojo/mojom/video_frame_mojom_traits.h +@@ -21,7 +21,7 @@ + + namespace mojo { + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + template <> + struct StructTraits<media::mojom::ColorPlaneLayoutDataView, + media::ColorPlaneLayout> { diff --git a/www/chromium/files/patch-media_video_fake__gpu__memory__buffer.cc b/www/chromium/files/patch-media_video_fake__gpu__memory__buffer.cc deleted file mode 100644 index 6db9406f8c32..000000000000 --- a/www/chromium/files/patch-media_video_fake__gpu__memory__buffer.cc +++ /dev/null @@ -1,38 +0,0 @@ ---- media/video/fake_gpu_memory_buffer.cc.orig 2024-04-19 13:02:56 UTC -+++ media/video/fake_gpu_memory_buffer.cc -@@ -9,7 +9,7 @@ - #include "media/base/format_utils.h" - #include "media/base/video_frame.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include <fcntl.h> - #include <sys/stat.h> - #include <sys/types.h> -@@ -52,7 +52,7 @@ class FakeGpuMemoryBufferImpl : public gpu::GpuMemoryB - - } // namespace - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - base::ScopedFD GetDummyFD() { - base::ScopedFD fd(open("/dev/zero", O_RDWR)); - DCHECK(fd.is_valid()); -@@ -82,7 +82,7 @@ FakeGpuMemoryBuffer::FakeGpuMemoryBuffer(const gfx::Si - static base::AtomicSequenceNumber buffer_id_generator; - handle_.id = gfx::GpuMemoryBufferId(buffer_id_generator.GetNext()); - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - for (size_t i = 0; i < VideoFrame::NumPlanes(video_pixel_format_); i++) { - const gfx::Size plane_size_in_bytes = - VideoFrame::PlaneSize(video_pixel_format_, i, size_); -@@ -144,7 +144,7 @@ gfx::GpuMemoryBufferHandle FakeGpuMemoryBuffer::CloneH - gfx::GpuMemoryBufferHandle handle; - handle.type = gfx::NATIVE_PIXMAP; - handle.id = handle_.id; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - handle.native_pixmap_handle = - gfx::CloneHandleForIPC(handle_.native_pixmap_handle); - #endif diff --git a/www/chromium/files/patch-media_video_gpu__memory__buffer__video__frame__pool.cc b/www/chromium/files/patch-media_video_gpu__memory__buffer__video__frame__pool.cc index c70de90e2c46..fadb11d7be0a 100644 --- a/www/chromium/files/patch-media_video_gpu__memory__buffer__video__frame__pool.cc +++ b/www/chromium/files/patch-media_video_gpu__memory__buffer__video__frame__pool.cc @@ -1,29 +1,29 @@ ---- media/video/gpu_memory_buffer_video_frame_pool.cc.orig 2024-04-19 13:02:56 UTC +--- media/video/gpu_memory_buffer_video_frame_pool.cc.orig 2025-07-02 06:08:04 UTC +++ media/video/gpu_memory_buffer_video_frame_pool.cc -@@ -803,7 +803,7 @@ void GpuMemoryBufferVideoFramePool::PoolImpl::CreateHa +@@ -647,7 +647,7 @@ void GpuMemoryBufferVideoFramePool::PoolImpl::CreateHa } - bool is_software_backed_video_frame = !video_frame->HasTextures(); + bool is_software_backed_video_frame = !video_frame->HasSharedImage(); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) is_software_backed_video_frame &= !video_frame->HasDmaBufs(); #endif -@@ -1285,7 +1285,7 @@ scoped_refptr<VideoFrame> GpuMemoryBufferVideoFramePoo - } +@@ -1054,7 +1054,7 @@ scoped_refptr<VideoFrame> GpuMemoryBufferVideoFramePoo + media::IOSurfaceIsWebGPUCompatible(handle.io_surface.get()); #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - is_webgpu_compatible = (gpu_memory_buffer != nullptr); - if (is_webgpu_compatible) { - is_webgpu_compatible &= -@@ -1306,7 +1306,7 @@ scoped_refptr<VideoFrame> GpuMemoryBufferVideoFramePoo - gpu::SHARED_IMAGE_USAGE_DISPLAY_READ | - gpu::SHARED_IMAGE_USAGE_SCANOUT; + is_webgpu_compatible = + handle.type == gfx::NATIVE_PIXMAP && + handle.native_pixmap_handle().supports_zero_copy_webgpu_import; +@@ -1226,7 +1226,7 @@ GpuMemoryBufferVideoFramePool::PoolImpl::GetOrCreateFr + si_usage |= gpu::SHARED_IMAGE_USAGE_SCANOUT; + } --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/1241537): Always add the flag once the - // OzoneImageBacking is by default turned on. - if (base::CommandLine::ForCurrentProcess()->HasSwitch( +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // TODO(crbug.com/40194712): Always add the flag once the + // OzoneImageBacking is by default turned on. + if (base::CommandLine::ForCurrentProcess()->HasSwitch( diff --git a/www/chromium/files/patch-media_video_video__encode__accelerator__adapter.cc b/www/chromium/files/patch-media_video_video__encode__accelerator__adapter.cc index 391655c3ac5c..b5e49e7fa857 100644 --- a/www/chromium/files/patch-media_video_video__encode__accelerator__adapter.cc +++ b/www/chromium/files/patch-media_video_video__encode__accelerator__adapter.cc @@ -1,20 +1,11 @@ ---- media/video/video_encode_accelerator_adapter.cc.orig 2024-04-19 13:02:56 UTC +--- media/video/video_encode_accelerator_adapter.cc.orig 2025-05-05 10:57:53 UTC +++ media/video/video_encode_accelerator_adapter.cc -@@ -157,7 +157,7 @@ VideoEncodeAccelerator::Config SetUpVeaConfig( - if (is_rgb) - config.input_format = PIXEL_FORMAT_I420; - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (format != PIXEL_FORMAT_I420 || - !VideoFrame::IsStorageTypeMappable(storage_type)) { - // ChromeOS/Linux hardware video encoders supports I420 on-memory -@@ -482,7 +482,7 @@ void VideoEncodeAcceleratorAdapter::InitializeInternal - SetUpVeaConfig(profile_, options_, format, first_frame->storage_type(), - supported_rc_modes_, required_encoder_type_); +@@ -468,7 +468,7 @@ void VideoEncodeAcceleratorAdapter::InitializeOnAccele + auto format = PIXEL_FORMAT_I420; + auto storage_type = VideoEncodeAccelerator::Config::StorageType::kShmem; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Linux/ChromeOS require a special configuration to use dmabuf storage. - // We need to keep sending frames the same way the first frame was sent. - // Other platforms will happily mix GpuMemoryBuffer storage with regular + // We need to keep sending frames with the same storage type. + // Other platforms will happily mix GpuMemoryBuffer storage with shared-mem diff --git a/www/chromium/files/patch-media_video_video__encode__accelerator__adapter__test.cc b/www/chromium/files/patch-media_video_video__encode__accelerator__adapter__test.cc index de70bfd36b2b..95e36aa82aae 100644 --- a/www/chromium/files/patch-media_video_video__encode__accelerator__adapter__test.cc +++ b/www/chromium/files/patch-media_video_video__encode__accelerator__adapter__test.cc @@ -1,11 +1,38 @@ ---- media/video/video_encode_accelerator_adapter_test.cc.orig 2023-08-17 07:33:31 UTC +--- media/video/video_encode_accelerator_adapter_test.cc.orig 2025-03-05 08:14:56 UTC +++ media/video/video_encode_accelerator_adapter_test.cc -@@ -459,7 +459,7 @@ TEST_P(VideoEncodeAcceleratorAdapterTest, TwoFramesRes +@@ -260,7 +260,7 @@ TEST_F(VideoEncodeAcceleratorAdapterTest, InitializeAf + }); + + VideoPixelFormat expected_input_format = PIXEL_FORMAT_I420; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + expected_input_format = PIXEL_FORMAT_NV12; + #endif + vea()->SetEncodingCallback(base::BindLambdaForTesting( +@@ -369,7 +369,7 @@ TEST_F(VideoEncodeAcceleratorAdapterTest, FlushDuringI + }); + + VideoPixelFormat expected_input_format = PIXEL_FORMAT_I420; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + expected_input_format = PIXEL_FORMAT_NV12; + #endif + +@@ -467,7 +467,7 @@ TEST_P(VideoEncodeAcceleratorAdapterTest, TwoFramesRes CreateGreenFrame(large_size, pixel_format, base::Milliseconds(2)); VideoPixelFormat expected_input_format = PIXEL_FORMAT_I420; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - if (pixel_format != PIXEL_FORMAT_I420 || !small_frame->IsMappable()) expected_input_format = PIXEL_FORMAT_NV12; #endif + const gfx::ColorSpace expected_color_space = +@@ -674,7 +674,7 @@ TEST_F(VideoEncodeAcceleratorAdapterTest, + }); + + VideoPixelFormat expected_input_format = PIXEL_FORMAT_I420; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + expected_input_format = PIXEL_FORMAT_NV12; + #endif + vea()->SetEncodingCallback(base::BindLambdaForTesting( diff --git a/www/chromium/files/patch-media_webrtc_audio__processor.cc b/www/chromium/files/patch-media_webrtc_audio__processor.cc index b24aa3a9e894..cf52d6b63a2f 100644 --- a/www/chromium/files/patch-media_webrtc_audio__processor.cc +++ b/www/chromium/files/patch-media_webrtc_audio__processor.cc @@ -1,11 +1,11 @@ ---- media/webrtc/audio_processor.cc.orig 2024-03-22 08:19:40 UTC +--- media/webrtc/audio_processor.cc.orig 2025-07-02 06:08:04 UTC +++ media/webrtc/audio_processor.cc -@@ -513,7 +513,7 @@ std::optional<double> AudioProcessor::ProcessData( +@@ -507,7 +507,7 @@ std::optional<double> AudioProcessor::ProcessData( + // controller. #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) DCHECK_LE(volume, 1.0); - #elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || \ -- BUILDFLAG(IS_OPENBSD) -+ BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_OPENBSD) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // We have a special situation on Linux where the microphone volume can be // "higher than maximum". The input volume slider in the sound preference // allows the user to set a scaling that is higher than 100%. It means that diff --git a/www/chromium/files/patch-media_webrtc_helpers.cc b/www/chromium/files/patch-media_webrtc_helpers.cc index 22caff51258e..83c31ec58eca 100644 --- a/www/chromium/files/patch-media_webrtc_helpers.cc +++ b/www/chromium/files/patch-media_webrtc_helpers.cc @@ -1,6 +1,6 @@ ---- media/webrtc/helpers.cc.orig 2024-04-19 13:02:56 UTC +--- media/webrtc/helpers.cc.orig 2025-05-28 14:55:43 UTC +++ media/webrtc/helpers.cc -@@ -41,14 +41,14 @@ void ConfigAutomaticGainControl(const AudioProcessingS +@@ -46,14 +46,14 @@ void ConfigAutomaticGainControl(const AudioProcessingS return; } @@ -15,5 +15,5 @@ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) // Use AGC2 digital and input volume controller. - // TODO(crbug.com/1375239): Remove `kWebRtcAllowInputVolumeAdjustment` safely. - if (kInputVolumeAdjustmentOverrideAllowed && + // TODO(crbug.com/40872787): Remove `kWebRtcAllowInputVolumeAdjustment` safely + // and set `input_volume_controller.enabled` true. diff --git a/www/chromium/files/patch-media_webrtc_helpers__unittests.cc b/www/chromium/files/patch-media_webrtc_helpers__unittests.cc index 993c77c653cc..cc67a9e7177e 100644 --- a/www/chromium/files/patch-media_webrtc_helpers__unittests.cc +++ b/www/chromium/files/patch-media_webrtc_helpers__unittests.cc @@ -1,6 +1,6 @@ ---- media/webrtc/helpers_unittests.cc.orig 2024-04-19 13:02:56 UTC +--- media/webrtc/helpers_unittests.cc.orig 2025-02-19 07:43:18 UTC +++ media/webrtc/helpers_unittests.cc -@@ -40,7 +40,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, CheckDefau +@@ -39,7 +39,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, CheckDefau EXPECT_TRUE(config.echo_canceller.enabled); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ @@ -9,7 +9,7 @@ EXPECT_FALSE(config.gain_controller1.enabled); EXPECT_TRUE(config.gain_controller2.enabled); #elif BUILDFLAG(IS_CASTOS) || BUILDFLAG(IS_CAST_ANDROID) -@@ -73,7 +73,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, +@@ -66,7 +66,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, } #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ @@ -18,7 +18,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, InputVolumeAdjustmentEnabledWithAgc2) { ::base::test::ScopedFeatureList feature_list; -@@ -89,7 +89,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, +@@ -82,7 +82,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) @@ -27,7 +27,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, CanDisableInputVolumeAdjustmentWithAgc2) { ::base::test::ScopedFeatureList feature_list; -@@ -106,7 +106,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, +@@ -99,7 +99,7 @@ TEST(CreateWebRtcAudioProcessingModuleTest, #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-mojo_core_BUILD.gn b/www/chromium/files/patch-mojo_core_BUILD.gn index 3e7431c76856..acb8f8d8386f 100644 --- a/www/chromium/files/patch-mojo_core_BUILD.gn +++ b/www/chromium/files/patch-mojo_core_BUILD.gn @@ -1,11 +1,11 @@ ---- mojo/core/BUILD.gn.orig 2023-04-28 17:01:32 UTC +--- mojo/core/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ mojo/core/BUILD.gn -@@ -166,7 +166,7 @@ template("core_impl_source_set") { - ] - } +@@ -164,7 +164,7 @@ source_set("impl_for_embedder") { + ] + } -- if ((is_linux || is_chromeos || is_android) && !is_nacl) { -+ if ((is_linux || is_chromeos || is_android) && !is_nacl && !is_bsd) { - sources += [ - "channel_linux.cc", - "channel_linux.h", +- if ((is_linux || is_chromeos || is_android) && !is_nacl) { ++ if ((is_linux || is_chromeos || is_android) && !is_nacl && !is_bsd) { + sources += [ + "channel_linux.cc", + "channel_linux.h", diff --git a/www/chromium/files/patch-mojo_core_channel.cc b/www/chromium/files/patch-mojo_core_channel.cc index 03dbd6760ae5..72713d708d9c 100644 --- a/www/chromium/files/patch-mojo_core_channel.cc +++ b/www/chromium/files/patch-mojo_core_channel.cc @@ -1,8 +1,8 @@ ---- mojo/core/channel.cc.orig 2023-03-09 06:31:50 UTC +--- mojo/core/channel.cc.orig 2025-07-02 06:08:04 UTC +++ mojo/core/channel.cc -@@ -75,7 +75,11 @@ const size_t kMaxUnusedReadBufferCapacity = 4096; - // Fuchsia: The zx_channel_write() API supports up to 64 handles. - const size_t kMaxAttachedHandles = 64; +@@ -85,7 +85,11 @@ const size_t kMaxAttachedHandles = 64; + const size_t kMaxAttachedHandles = 253; + #endif // BUILDFLAG(IS_FUCHSIA) +#if defined(__i386__) && defined(OS_FREEBSD) +const size_t kChannelMessageAlignment = 4; diff --git a/www/chromium/files/patch-mojo_public_c_system_thunks.cc b/www/chromium/files/patch-mojo_public_c_system_thunks.cc deleted file mode 100644 index fc8468610cda..000000000000 --- a/www/chromium/files/patch-mojo_public_c_system_thunks.cc +++ /dev/null @@ -1,38 +0,0 @@ ---- mojo/public/c/system/thunks.cc.orig 2024-03-22 08:19:40 UTC -+++ mojo/public/c/system/thunks.cc -@@ -25,7 +25,7 @@ - #include "mojo/public/c/system/message_pipe.h" - - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - #include "base/environment.h" - #include "base/files/file_path.h" - #include "base/scoped_native_library.h" -@@ -72,7 +72,7 @@ class CoreLibraryInitializer { - - MojoResult LoadLibrary(base::FilePath library_path) { - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - if (library_ && library_->is_valid()) - return MOJO_RESULT_OK; - -@@ -86,7 +86,7 @@ class CoreLibraryInitializer { - - if (library_path.empty()) { - // Default to looking for the library in the current working directory. --#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const base::FilePath::CharType kDefaultLibraryPathValue[] = - FILE_PATH_LITERAL("./libmojo_core.so"); - #elif BUILDFLAG(IS_FUCHSIA) -@@ -142,7 +142,7 @@ class CoreLibraryInitializer { - - private: - #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || \ -- BUILDFLAG(IS_FUCHSIA) -+ BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - std::optional<base::ScopedNativeLibrary> library_; - #endif - }; diff --git a/www/chromium/files/patch-mojo_public_tools_bindings_mojom.gni b/www/chromium/files/patch-mojo_public_tools_bindings_mojom.gni index 9cc86c147119..69e69e009bda 100644 --- a/www/chromium/files/patch-mojo_public_tools_bindings_mojom.gni +++ b/www/chromium/files/patch-mojo_public_tools_bindings_mojom.gni @@ -1,6 +1,6 @@ ---- mojo/public/tools/bindings/mojom.gni.orig 2024-04-19 13:02:56 UTC +--- mojo/public/tools/bindings/mojom.gni.orig 2025-05-05 10:57:53 UTC +++ mojo/public/tools/bindings/mojom.gni -@@ -748,6 +748,16 @@ template("mojom") { +@@ -774,6 +774,16 @@ template("mojom") { enabled_features += [ "is_apple" ] } @@ -14,6 +14,6 @@ + enabled_features += [ "is_bsd" ] + } + - action(parser_target_name) { - allow_remote = true - + action_outputs = [] + foreach(base_path, output_file_base_paths) { + filename = get_path_info(base_path, "file") diff --git a/www/chromium/files/patch-net_BUILD.gn b/www/chromium/files/patch-net_BUILD.gn index 3cd4eadbb07e..ebbac67e5afb 100644 --- a/www/chromium/files/patch-net_BUILD.gn +++ b/www/chromium/files/patch-net_BUILD.gn @@ -1,6 +1,6 @@ ---- net/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- net/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ net/BUILD.gn -@@ -123,7 +123,7 @@ net_configs = [ +@@ -126,7 +126,7 @@ net_configs = [ "//build/config/compiler:wexit_time_destructors", ] @@ -9,7 +9,7 @@ net_configs += [ "//build/config/linux:libresolv" ] } -@@ -1188,6 +1188,19 @@ component("net") { +@@ -1341,6 +1341,19 @@ component("net") { ] } @@ -29,7 +29,7 @@ if (is_mac) { sources += [ "base/network_notification_thread_mac.cc", -@@ -1344,7 +1357,7 @@ component("net") { +@@ -1504,7 +1517,7 @@ component("net") { } # Use getifaddrs() on POSIX platforms, except Linux. @@ -38,7 +38,24 @@ sources += [ "base/network_interfaces_getifaddrs.cc", "base/network_interfaces_getifaddrs.h", -@@ -2821,7 +2834,7 @@ test("net_unittests") { +@@ -2211,7 +2224,7 @@ static_library("test_support") { + ] + } + +- if (is_linux || is_chromeos || is_android) { ++ if (!is_bsd && (is_linux || is_chromeos || is_android)) { + sources += [ + "base/address_tracker_linux_test_util.cc", + "base/address_tracker_linux_test_util.h", +@@ -3038,14 +3051,14 @@ target(_test_target_type, "net_unittests") { + ] + } + +- if (is_linux) { ++ if (is_linux && !is_bsd) { + sources += [ + "base/network_change_notifier_linux_unittest.cc", + "proxy_resolution/proxy_config_service_linux_unittest.cc", ] } @@ -47,7 +64,7 @@ sources += [ "base/address_tracker_linux_unittest.cc", "base/network_interfaces_linux_unittest.cc", -@@ -2909,6 +2922,10 @@ test("net_unittests") { +@@ -3143,6 +3156,10 @@ target(_test_target_type, "net_unittests") { ] } @@ -56,9 +73,9 @@ + } + if (enable_websockets) { - deps += [ "//net/server:tests" ] - } -@@ -2969,7 +2986,7 @@ test("net_unittests") { + sources += [ + "server/http_connection_unittest.cc", +@@ -3208,7 +3225,7 @@ target(_test_target_type, "net_unittests") { ] } @@ -67,7 +84,7 @@ sources += [ "tools/quic/quic_simple_server_test.cc" ] } -@@ -3105,7 +3122,7 @@ test("net_unittests") { +@@ -3346,7 +3363,7 @@ target(_test_target_type, "net_unittests") { } # Use getifaddrs() on POSIX platforms, except Linux. diff --git a/www/chromium/files/patch-net_base_features.cc b/www/chromium/files/patch-net_base_features.cc index 90ddda075e94..46045ee1946b 100644 --- a/www/chromium/files/patch-net_base_features.cc +++ b/www/chromium/files/patch-net_base_features.cc @@ -1,6 +1,6 @@ ---- net/base/features.cc.orig 2024-04-19 13:02:56 UTC +--- net/base/features.cc.orig 2025-07-02 06:08:04 UTC +++ net/base/features.cc -@@ -26,7 +26,7 @@ BASE_FEATURE(kCapReferrerToOriginOnCrossOrigin, +@@ -31,7 +31,7 @@ BASE_FEATURE(kCapReferrerToOriginOnCrossOrigin, BASE_FEATURE(kAsyncDns, "AsyncDns", #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_ANDROID) || \ @@ -9,16 +9,3 @@ base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT -@@ -504,7 +504,12 @@ BASE_FEATURE(kSpdyHeadersToHttpResponseUseBuilder, - "SpdyHeadersToHttpResponseUseBuilder", - base::FEATURE_DISABLED_BY_DEFAULT); - -+#if BUILDFLAG(IS_OPENBSD) -+// No IP_RECVTOS support - BASE_FEATURE(kReceiveEcn, "ReceiveEcn", base::FEATURE_DISABLED_BY_DEFAULT); -+#else -+BASE_FEATURE(kReceiveEcn, "ReceiveEcn", base::FEATURE_DISABLED_BY_DEFAULT); -+#endif - - // TODO(crbug.com/634470): Remove this feature flag in January 2024 if the new - // limit sticks. diff --git a/www/chromium/files/patch-net_base_mock__network__change__notifier.cc b/www/chromium/files/patch-net_base_mock__network__change__notifier.cc deleted file mode 100644 index f1a396f34293..000000000000 --- a/www/chromium/files/patch-net_base_mock__network__change__notifier.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- net/base/mock_network_change_notifier.cc.orig 2023-08-17 07:33:31 UTC -+++ net/base/mock_network_change_notifier.cc -@@ -103,7 +103,7 @@ MockNetworkChangeNotifier::GetCurrentConnectionCost() - return connection_cost_; - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - AddressMapOwnerLinux* MockNetworkChangeNotifier::GetAddressMapOwnerInternal() { - return address_map_owner_; - } diff --git a/www/chromium/files/patch-net_base_mock__network__change__notifier.h b/www/chromium/files/patch-net_base_mock__network__change__notifier.h deleted file mode 100644 index eb1fb1dd1646..000000000000 --- a/www/chromium/files/patch-net_base_mock__network__change__notifier.h +++ /dev/null @@ -1,20 +0,0 @@ ---- net/base/mock_network_change_notifier.h.orig 2023-08-17 07:33:31 UTC -+++ net/base/mock_network_change_notifier.h -@@ -84,7 +84,7 @@ class MockNetworkChangeNotifier : public NetworkChange - // use_default_connection_cost_implementation is set to true. - ConnectionCost GetCurrentConnectionCost() override; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void SetAddressMapOwnerLinux(AddressMapOwnerLinux* address_map_owner) { - address_map_owner_ = address_map_owner; - } -@@ -104,7 +104,7 @@ class MockNetworkChangeNotifier : public NetworkChange - bool use_default_connection_cost_implementation_ = false; - NetworkChangeNotifier::NetworkList connected_networks_; - std::unique_ptr<SystemDnsConfigChangeNotifier> dns_config_notifier_; --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - raw_ptr<AddressMapOwnerLinux> address_map_owner_ = nullptr; - #endif - }; diff --git a/www/chromium/files/patch-net_base_network__change__notifier.cc b/www/chromium/files/patch-net_base_network__change__notifier.cc index 562dfc71ba47..18486cf55fc8 100644 --- a/www/chromium/files/patch-net_base_network__change__notifier.cc +++ b/www/chromium/files/patch-net_base_network__change__notifier.cc @@ -1,6 +1,6 @@ ---- net/base/network_change_notifier.cc.orig 2024-02-23 21:04:38 UTC +--- net/base/network_change_notifier.cc.orig 2025-05-28 14:55:43 UTC +++ net/base/network_change_notifier.cc -@@ -37,7 +37,7 @@ +@@ -38,7 +38,7 @@ #include "net/base/network_change_notifier_linux.h" #elif BUILDFLAG(IS_APPLE) #include "net/base/network_change_notifier_apple.h" @@ -9,7 +9,7 @@ #include "net/base/network_change_notifier_passive.h" #elif BUILDFLAG(IS_FUCHSIA) #include "net/base/network_change_notifier_fuchsia.h" -@@ -329,6 +329,9 @@ std::unique_ptr<NetworkChangeNotifier> NetworkChangeNo +@@ -325,6 +325,9 @@ std::unique_ptr<NetworkChangeNotifier> NetworkChangeNo #elif BUILDFLAG(IS_FUCHSIA) return std::make_unique<NetworkChangeNotifierFuchsia>( /*require_wlan=*/false); diff --git a/www/chromium/files/patch-net_base_network__change__notifier__passive.cc b/www/chromium/files/patch-net_base_network__change__notifier__passive.cc index 8f22c6025c65..e1649f276863 100644 --- a/www/chromium/files/patch-net_base_network__change__notifier__passive.cc +++ b/www/chromium/files/patch-net_base_network__change__notifier__passive.cc @@ -1,4 +1,4 @@ ---- net/base/network_change_notifier_passive.cc.orig 2023-05-31 08:12:17 UTC +--- net/base/network_change_notifier_passive.cc.orig 2025-05-28 14:55:43 UTC +++ net/base/network_change_notifier_passive.cc @@ -107,7 +107,7 @@ NetworkChangeNotifierPassive::GetAddressMapOwnerIntern NetworkChangeNotifier::NetworkChangeCalculatorParams diff --git a/www/chromium/files/patch-net_base_sockaddr__util__posix.cc b/www/chromium/files/patch-net_base_sockaddr__util__posix.cc index 825c0490c3f1..c0361e0e294a 100644 --- a/www/chromium/files/patch-net_base_sockaddr__util__posix.cc +++ b/www/chromium/files/patch-net_base_sockaddr__util__posix.cc @@ -1,6 +1,6 @@ ---- net/base/sockaddr_util_posix.cc.orig 2022-07-22 17:30:31 UTC +--- net/base/sockaddr_util_posix.cc.orig 2025-07-02 06:08:04 UTC +++ net/base/sockaddr_util_posix.cc -@@ -41,7 +41,8 @@ bool FillUnixAddress(const std::string& socket_path, +@@ -60,7 +60,8 @@ bool FillUnixAddress(const std::string& socket_path, return true; } diff --git a/www/chromium/files/patch-net_base_sockaddr__util__posix__unittest.cc b/www/chromium/files/patch-net_base_sockaddr__util__posix__unittest.cc index 50ed6dc7f90d..7014693faa3a 100644 --- a/www/chromium/files/patch-net_base_sockaddr__util__posix__unittest.cc +++ b/www/chromium/files/patch-net_base_sockaddr__util__posix__unittest.cc @@ -1,6 +1,6 @@ ---- net/base/sockaddr_util_posix_unittest.cc.orig 2022-06-17 14:20:10 UTC +--- net/base/sockaddr_util_posix_unittest.cc.orig 2024-07-30 11:12:21 UTC +++ net/base/sockaddr_util_posix_unittest.cc -@@ -83,7 +83,8 @@ TEST(FillUnixAddressTest, AbstractLinuxAddress) { +@@ -88,7 +88,8 @@ TEST(FillUnixAddressTest, AbstractLinuxAddress) { size_t path_max = MaxPathLength(&storage); std::string path(path_max, '0'); diff --git a/www/chromium/files/patch-net_cert_cert__verify__proc.h b/www/chromium/files/patch-net_cert_cert__verify__proc.h deleted file mode 100644 index 2dadc50d4ab0..000000000000 --- a/www/chromium/files/patch-net_cert_cert__verify__proc.h +++ /dev/null @@ -1,11 +0,0 @@ ---- net/cert/cert_verify_proc.h.orig 2024-04-19 13:02:56 UTC -+++ net/cert/cert_verify_proc.h -@@ -174,7 +174,7 @@ class NET_EXPORT CertVerifyProc - kMaxValue = kChainLengthOne - }; - --#if !(BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || \ -+#if !(BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(CHROME_ROOT_STORE_ONLY)) - // Creates and returns a CertVerifyProc that uses the system verifier. - // |cert_net_fetcher| may not be used, depending on the implementation. diff --git a/www/chromium/files/patch-net_disk__cache_backend__experiment.h b/www/chromium/files/patch-net_disk__cache_backend__experiment.h new file mode 100644 index 000000000000..b286abed6dda --- /dev/null +++ b/www/chromium/files/patch-net_disk__cache_backend__experiment.h @@ -0,0 +1,11 @@ +--- net/disk_cache/backend_experiment.h.orig 2024-11-14 07:57:23 UTC ++++ net/disk_cache/backend_experiment.h +@@ -14,7 +14,7 @@ namespace disk_cache { + // default. + constexpr bool IsSimpleBackendEnabledByDefaultPlatform() { + return BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || +- BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC); ++ BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD); + } + + // True if assigned to any of disk cache backend experiment groups. diff --git a/www/chromium/files/patch-net_disk__cache_simple_simple__file__tracker.cc b/www/chromium/files/patch-net_disk__cache_simple_simple__file__tracker.cc index ea6580b0cab2..234485f163a9 100644 --- a/www/chromium/files/patch-net_disk__cache_simple_simple__file__tracker.cc +++ b/www/chromium/files/patch-net_disk__cache_simple_simple__file__tracker.cc @@ -1,7 +1,7 @@ ---- net/disk_cache/simple/simple_file_tracker.cc.orig 2022-06-17 14:20:10 UTC +--- net/disk_cache/simple/simple_file_tracker.cc.orig 2025-07-02 06:08:04 UTC +++ net/disk_cache/simple/simple_file_tracker.cc -@@ -29,7 +29,17 @@ void RecordFileDescripterLimiterOp(FileDescriptorLimit - } // namespace +@@ -36,7 +36,17 @@ bool SimpleFileTracker::TrackedFiles::InLRUList() cons + } SimpleFileTracker::SimpleFileTracker(int file_limit) +#if defined(OS_OPENBSD) diff --git a/www/chromium/files/patch-net_dns_BUILD.gn b/www/chromium/files/patch-net_dns_BUILD.gn index 8c130b336675..50be0c53f7f4 100644 --- a/www/chromium/files/patch-net_dns_BUILD.gn +++ b/www/chromium/files/patch-net_dns_BUILD.gn @@ -1,6 +1,6 @@ ---- net/dns/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- net/dns/BUILD.gn.orig 2025-02-19 07:43:18 UTC +++ net/dns/BUILD.gn -@@ -136,7 +136,7 @@ source_set("dns") { +@@ -140,7 +140,7 @@ source_set("dns") { "dns_config_service_android.cc", "dns_config_service_android.h", ] @@ -9,7 +9,7 @@ sources += [ "dns_config_service_linux.cc", "dns_config_service_linux.h", -@@ -177,6 +177,7 @@ source_set("dns") { +@@ -181,6 +181,7 @@ source_set("dns") { ":host_resolver_manager", ":mdns_client", "//net:net_public_deps", @@ -17,7 +17,7 @@ ] allow_circular_includes_from = [ -@@ -444,9 +445,9 @@ source_set("tests") { +@@ -450,9 +451,9 @@ source_set("tests") { if (is_android) { sources += [ "dns_config_service_android_unittest.cc" ] diff --git a/www/chromium/files/patch-net_dns_address__info.cc b/www/chromium/files/patch-net_dns_address__info.cc index b783821589e4..af69bca18aed 100644 --- a/www/chromium/files/patch-net_dns_address__info.cc +++ b/www/chromium/files/patch-net_dns_address__info.cc @@ -1,6 +1,6 @@ ---- net/dns/address_info.cc.orig 2024-02-23 21:04:38 UTC +--- net/dns/address_info.cc.orig 2024-07-30 11:12:21 UTC +++ net/dns/address_info.cc -@@ -78,8 +78,12 @@ AddressInfo::AddressInfoAndResult AddressInfo::Get( +@@ -83,8 +83,12 @@ AddressInfo::AddressInfoAndResult AddressInfo::Get( // error. // http://crbug.com/134142 err = ERR_NAME_NOT_RESOLVED; diff --git a/www/chromium/files/patch-net_dns_address__sorter__posix.cc b/www/chromium/files/patch-net_dns_address__sorter__posix.cc index ae7045b502f9..974c87f29130 100644 --- a/www/chromium/files/patch-net_dns_address__sorter__posix.cc +++ b/www/chromium/files/patch-net_dns_address__sorter__posix.cc @@ -1,6 +1,6 @@ ---- net/dns/address_sorter_posix.cc.orig 2024-04-19 13:02:56 UTC +--- net/dns/address_sorter_posix.cc.orig 2024-07-30 11:12:21 UTC +++ net/dns/address_sorter_posix.cc -@@ -27,6 +27,7 @@ +@@ -32,6 +32,7 @@ #include "net/dns/netinet_in_var_ios.h" #else #include <netinet/in_var.h> diff --git a/www/chromium/files/patch-net_dns_dns__config__service__posix.cc b/www/chromium/files/patch-net_dns_dns__config__service__posix.cc index a1cd09892744..cc2598368fc2 100644 --- a/www/chromium/files/patch-net_dns_dns__config__service__posix.cc +++ b/www/chromium/files/patch-net_dns_dns__config__service__posix.cc @@ -1,6 +1,6 @@ ---- net/dns/dns_config_service_posix.cc.orig 2022-08-31 12:19:35 UTC +--- net/dns/dns_config_service_posix.cc.orig 2024-07-30 11:12:21 UTC +++ net/dns/dns_config_service_posix.cc -@@ -34,6 +34,11 @@ +@@ -39,6 +39,11 @@ #include "net/dns/dns_config_watcher_mac.h" #endif @@ -12,7 +12,7 @@ namespace net { namespace internal { -@@ -130,6 +135,11 @@ class DnsConfigServicePosix::Watcher : public DnsConfi +@@ -135,6 +140,11 @@ class DnsConfigServicePosix::Watcher : public DnsConfi bool Watch() override { CheckOnCorrectSequence(); diff --git a/www/chromium/files/patch-net_dns_host__resolver__proc.cc b/www/chromium/files/patch-net_dns_host__resolver__proc.cc index 3e1336aaa4eb..fbe648f9b413 100644 --- a/www/chromium/files/patch-net_dns_host__resolver__proc.cc +++ b/www/chromium/files/patch-net_dns_host__resolver__proc.cc @@ -1,6 +1,6 @@ ---- net/dns/host_resolver_proc.cc.orig 2022-11-30 08:12:58 UTC +--- net/dns/host_resolver_proc.cc.orig 2025-05-28 14:55:43 UTC +++ net/dns/host_resolver_proc.cc -@@ -15,10 +15,6 @@ +@@ -16,10 +16,6 @@ #include "net/base/net_errors.h" #include "net/dns/host_resolver_system_task.h" diff --git a/www/chromium/files/patch-net_dns_public_BUILD.gn b/www/chromium/files/patch-net_dns_public_BUILD.gn index 332fdcd5863f..d0099497585b 100644 --- a/www/chromium/files/patch-net_dns_public_BUILD.gn +++ b/www/chromium/files/patch-net_dns_public_BUILD.gn @@ -1,6 +1,6 @@ ---- net/dns/public/BUILD.gn.orig 2023-11-03 10:09:45 UTC +--- net/dns/public/BUILD.gn.orig 2024-05-21 18:07:39 UTC +++ net/dns/public/BUILD.gn -@@ -77,7 +77,7 @@ source_set("tests") { +@@ -78,7 +78,7 @@ source_set("tests") { "doh_provider_entry_unittest.cc", ] diff --git a/www/chromium/files/patch-net_http_http__auth__gssapi__posix.cc b/www/chromium/files/patch-net_http_http__auth__gssapi__posix.cc index 3978e7db98e0..cfdeaa5e181a 100644 --- a/www/chromium/files/patch-net_http_http__auth__gssapi__posix.cc +++ b/www/chromium/files/patch-net_http_http__auth__gssapi__posix.cc @@ -1,14 +1,13 @@ ---- net/http/http_auth_gssapi_posix.cc.orig 2023-04-28 17:01:32 UTC +--- net/http/http_auth_gssapi_posix.cc.orig 2025-05-05 10:57:53 UTC +++ net/http/http_auth_gssapi_posix.cc -@@ -370,8 +370,9 @@ base::NativeLibrary GSSAPISharedLibrary::LoadSharedLib - static const char* const kDefaultLibraryNames[] = { +@@ -366,7 +366,9 @@ base::NativeLibrary GSSAPISharedLibrary::LoadSharedLib + } else { #if BUILDFLAG(IS_APPLE) - "/System/Library/Frameworks/GSS.framework/GSS" + library_names.emplace_back("/System/Library/Frameworks/GSS.framework/GSS"); -#elif BUILDFLAG(IS_OPENBSD) -- "libgssapi.so" // Heimdal - OpenBSD +#elif BUILDFLAG(IS_BSD) -+ "libgssapi_krb5.so.2", // MIT Kerberos - FreeBSD -+ "libgssapi.so" // Heimdal - OpenBSD, FreeBSD ++ // MIT Kerberos - FreeBSD ++ library_names.emplace_back("libgssapi_krb5.so.2"); + // Heimdal - OpenBSD + library_names.emplace_back("libgssapi.so"); #else - "libgssapi_krb5.so.2", // MIT Kerberos - FC, Suse10, Debian - "libgssapi.so.4", // Heimdal - Suse10, MDK diff --git a/www/chromium/files/patch-net_http_http__auth__handler__negotiate.cc b/www/chromium/files/patch-net_http_http__auth__handler__negotiate.cc index 225ab8115d3d..75f5237f219a 100644 --- a/www/chromium/files/patch-net_http_http__auth__handler__negotiate.cc +++ b/www/chromium/files/patch-net_http_http__auth__handler__negotiate.cc @@ -1,6 +1,6 @@ ---- net/http/http_auth_handler_negotiate.cc.orig 2024-03-22 08:19:40 UTC +--- net/http/http_auth_handler_negotiate.cc.orig 2025-04-04 08:52:13 UTC +++ net/http/http_auth_handler_negotiate.cc -@@ -120,7 +120,7 @@ int HttpAuthHandlerNegotiate::Factory::CreateAuthHandl +@@ -119,7 +119,7 @@ int HttpAuthHandlerNegotiate::Factory::CreateAuthHandl #elif BUILDFLAG(IS_POSIX) if (is_unsupported_) return ERR_UNSUPPORTED_AUTH_SCHEME; diff --git a/www/chromium/files/patch-net_http_http__auth__preferences.cc b/www/chromium/files/patch-net_http_http__auth__preferences.cc index 8a288a931897..446ef7cb39bc 100644 --- a/www/chromium/files/patch-net_http_http__auth__preferences.cc +++ b/www/chromium/files/patch-net_http_http__auth__preferences.cc @@ -1,6 +1,6 @@ ---- net/http/http_auth_preferences.cc.orig 2023-10-11 18:22:24 UTC +--- net/http/http_auth_preferences.cc.orig 2025-04-04 08:52:13 UTC +++ net/http/http_auth_preferences.cc -@@ -39,7 +39,7 @@ std::string HttpAuthPreferences::AuthAndroidNegotiateA +@@ -38,7 +38,7 @@ std::string HttpAuthPreferences::AuthAndroidNegotiateA } #endif // BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-net_http_http__auth__preferences.h b/www/chromium/files/patch-net_http_http__auth__preferences.h index 41432aecd8fd..8f582f94234e 100644 --- a/www/chromium/files/patch-net_http_http__auth__preferences.h +++ b/www/chromium/files/patch-net_http_http__auth__preferences.h @@ -1,6 +1,6 @@ ---- net/http/http_auth_preferences.h.orig 2023-10-11 18:22:24 UTC +--- net/http/http_auth_preferences.h.orig 2025-04-04 08:52:13 UTC +++ net/http/http_auth_preferences.h -@@ -50,7 +50,7 @@ class NET_EXPORT HttpAuthPreferences { +@@ -49,7 +49,7 @@ class NET_EXPORT HttpAuthPreferences { #if BUILDFLAG(IS_ANDROID) virtual std::string AuthAndroidNegotiateAccountType() const; #endif @@ -9,7 +9,7 @@ virtual bool AllowGssapiLibraryLoad() const; #endif // BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) virtual bool CanUseDefaultCredentials( -@@ -86,7 +86,7 @@ class NET_EXPORT HttpAuthPreferences { +@@ -85,7 +85,7 @@ class NET_EXPORT HttpAuthPreferences { } #endif // BUILDFLAG(IS_POSIX) || BUILDFLAG(IS_FUCHSIA) @@ -18,7 +18,7 @@ void set_allow_gssapi_library_load(bool allow_gssapi_library_load) { allow_gssapi_library_load_ = allow_gssapi_library_load; } -@@ -137,7 +137,7 @@ class NET_EXPORT HttpAuthPreferences { +@@ -136,7 +136,7 @@ class NET_EXPORT HttpAuthPreferences { std::string auth_android_negotiate_account_type_; #endif // BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-net_http_http__network__session.cc b/www/chromium/files/patch-net_http_http__network__session.cc index e0b333127ec7..375b498b33eb 100644 --- a/www/chromium/files/patch-net_http_http__network__session.cc +++ b/www/chromium/files/patch-net_http_http__network__session.cc @@ -1,6 +1,6 @@ ---- net/http/http_network_session.cc.orig 2023-01-11 09:17:16 UTC +--- net/http/http_network_session.cc.orig 2025-07-02 06:08:04 UTC +++ net/http/http_network_session.cc -@@ -19,7 +19,9 @@ +@@ -21,7 +21,9 @@ #include "build/build_config.h" #include "net/base/features.h" #include "net/dns/host_resolver.h" @@ -9,4 +9,4 @@ +#endif #include "net/http/http_response_body_drainer.h" #include "net/http/http_stream_factory.h" - #include "net/http/url_security_manager.h" + #include "net/http/http_stream_pool.h" diff --git a/www/chromium/files/patch-net_proxy__resolution_proxy__config__service__linux.cc b/www/chromium/files/patch-net_proxy__resolution_proxy__config__service__linux.cc index 16707212dda0..74b7e19e12d7 100644 --- a/www/chromium/files/patch-net_proxy__resolution_proxy__config__service__linux.cc +++ b/www/chromium/files/patch-net_proxy__resolution_proxy__config__service__linux.cc @@ -1,6 +1,6 @@ ---- net/proxy_resolution/proxy_config_service_linux.cc.orig 2024-02-23 21:04:38 UTC +--- net/proxy_resolution/proxy_config_service_linux.cc.orig 2025-05-28 14:55:43 UTC +++ net/proxy_resolution/proxy_config_service_linux.cc -@@ -6,7 +6,9 @@ +@@ -11,7 +11,9 @@ #include <errno.h> #include <limits.h> @@ -10,15 +10,15 @@ #include <unistd.h> #include <map> -@@ -505,6 +507,7 @@ bool SettingGetterImplGSettings::CheckVersion( +@@ -502,6 +504,7 @@ bool SettingGetterImplGSettings::CheckVersion() { } #endif // defined(USE_GIO) +#if !BUILDFLAG(IS_BSD) // Converts |value| from a decimal string to an int. If there was a failure // parsing, returns |default_value|. - int StringToIntOrDefault(base::StringPiece value, int default_value) { -@@ -1033,6 +1036,7 @@ class SettingGetterImplKDE : public ProxyConfigService + int StringToIntOrDefault(std::string_view value, int default_value) { +@@ -1039,6 +1042,7 @@ class SettingGetterImplKDE : public ProxyConfigService // events on. scoped_refptr<base::SequencedTaskRunner> file_task_runner_; }; @@ -26,7 +26,7 @@ } // namespace -@@ -1251,9 +1255,11 @@ ProxyConfigServiceLinux::Delegate::Delegate( +@@ -1258,9 +1262,11 @@ ProxyConfigServiceLinux::Delegate::Delegate( case base::nix::DESKTOP_ENVIRONMENT_KDE4: case base::nix::DESKTOP_ENVIRONMENT_KDE5: case base::nix::DESKTOP_ENVIRONMENT_KDE6: diff --git a/www/chromium/files/patch-net_quic_quic__network__transaction__unittest.cc b/www/chromium/files/patch-net_quic_quic__network__transaction__unittest.cc new file mode 100644 index 000000000000..7406ec73158a --- /dev/null +++ b/www/chromium/files/patch-net_quic_quic__network__transaction__unittest.cc @@ -0,0 +1,28 @@ +--- net/quic/quic_network_transaction_unittest.cc.orig 2025-04-04 08:52:13 UTC ++++ net/quic/quic_network_transaction_unittest.cc +@@ -5202,10 +5202,10 @@ TEST_P(QuicNetworkTransactionTest, RstStreamBeforeHead + + TEST_P(QuicNetworkTransactionTest, BrokenAlternateProtocol) { + // Alternate-protocol job +- std::unique_ptr<quic::QuicEncryptedPacket> close( ++ std::unique_ptr<quic::QuicEncryptedPacket> test_close( + ConstructServerConnectionClosePacket(1)); + MockRead quic_reads[] = { +- MockRead(ASYNC, close->data(), close->length()), ++ MockRead(ASYNC, test_close->data(), test_close->length()), + MockRead(ASYNC, ERR_IO_PENDING), // No more data to read + MockRead(ASYNC, OK), // EOF + }; +@@ -5248,10 +5248,10 @@ TEST_P(QuicNetworkTransactionTest, + http_server_properties_ = std::make_unique<HttpServerProperties>(); + + // Alternate-protocol job +- std::unique_ptr<quic::QuicEncryptedPacket> close( ++ std::unique_ptr<quic::QuicEncryptedPacket> test_close( + ConstructServerConnectionClosePacket(1)); + MockRead quic_reads[] = { +- MockRead(ASYNC, close->data(), close->length()), ++ MockRead(ASYNC, test_close->data(), test_close->length()), + MockRead(ASYNC, ERR_IO_PENDING), // No more data to read + MockRead(ASYNC, OK), // EOF + }; diff --git a/www/chromium/files/patch-net_socket_socket__posix.cc b/www/chromium/files/patch-net_socket_socket__posix.cc deleted file mode 100644 index 665305fd5623..000000000000 --- a/www/chromium/files/patch-net_socket_socket__posix.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- net/socket/socket_posix.cc.orig 2022-07-22 17:30:31 UTC -+++ net/socket/socket_posix.cc -@@ -516,7 +516,7 @@ void SocketPosix::ReadCompleted() { - } - - int SocketPosix::DoWrite(IOBuffer* buf, int buf_len) { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - // Disable SIGPIPE for this write. Although Chromium globally disables - // SIGPIPE, the net stack may be used in other consumers which do not do - // this. MSG_NOSIGNAL is a Linux-only API. On OS X, this is a setsockopt on diff --git a/www/chromium/files/patch-net_socket_socks5__client__socket.cc b/www/chromium/files/patch-net_socket_socks5__client__socket.cc index d80844cdf1be..17d21c5820b1 100644 --- a/www/chromium/files/patch-net_socket_socks5__client__socket.cc +++ b/www/chromium/files/patch-net_socket_socks5__client__socket.cc @@ -1,6 +1,6 @@ ---- net/socket/socks5_client_socket.cc.orig 2022-04-21 18:48:31 UTC +--- net/socket/socks5_client_socket.cc.orig 2025-04-04 08:52:13 UTC +++ net/socket/socks5_client_socket.cc -@@ -19,6 +19,9 @@ +@@ -23,6 +23,9 @@ #include "net/log/net_log_event_type.h" #include "net/traffic_annotation/network_traffic_annotation.h" diff --git a/www/chromium/files/patch-net_socket_tcp__socket__posix.cc b/www/chromium/files/patch-net_socket_tcp__socket__posix.cc index ed7253f313a8..4dd02e208e0e 100644 --- a/www/chromium/files/patch-net_socket_tcp__socket__posix.cc +++ b/www/chromium/files/patch-net_socket_tcp__socket__posix.cc @@ -1,6 +1,6 @@ ---- net/socket/tcp_socket_posix.cc.orig 2023-05-31 08:12:17 UTC +--- net/socket/tcp_socket_posix.cc.orig 2025-05-28 14:55:43 UTC +++ net/socket/tcp_socket_posix.cc -@@ -98,6 +98,17 @@ bool SetTCPKeepAlive(int fd, bool enable, int delay) { +@@ -99,6 +99,17 @@ bool SetTCPKeepAlive(int fd, bool enable, int delay) { PLOG(ERROR) << "Failed to set TCP_KEEPALIVE on fd: " << fd; return false; } diff --git a/www/chromium/files/patch-net_socket_udp__socket__posix.cc b/www/chromium/files/patch-net_socket_udp__socket__posix.cc index ecbd99d249da..6012903b284f 100644 --- a/www/chromium/files/patch-net_socket_udp__socket__posix.cc +++ b/www/chromium/files/patch-net_socket_udp__socket__posix.cc @@ -1,7 +1,7 @@ ---- net/socket/udp_socket_posix.cc.orig 2024-03-22 08:19:40 UTC +--- net/socket/udp_socket_posix.cc.orig 2025-07-02 06:08:04 UTC +++ net/socket/udp_socket_posix.cc -@@ -592,12 +592,17 @@ int UDPSocketPosix::SetRecvTos() { - } +@@ -524,12 +524,17 @@ int UDPSocketPosix::SetRecvTos() { + #endif // BUILDFLAG(IS_APPLE) } +#ifdef IP_RECVTOS @@ -19,7 +19,7 @@ if (confirm) { sendto_flags_ |= MSG_CONFIRM; } else { -@@ -618,7 +623,7 @@ int UDPSocketPosix::SetBroadcast(bool broadcast) { +@@ -550,7 +555,7 @@ int UDPSocketPosix::SetBroadcast(bool broadcast) { DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); int value = broadcast ? 1 : 0; int rv; @@ -28,8 +28,8 @@ // SO_REUSEPORT on OSX permits multiple processes to each receive // UDP multicast or broadcast datagrams destined for the bound // port. -@@ -959,7 +964,7 @@ int UDPSocketPosix::DoBind(const IPEndPoint& address) - #if BUILDFLAG(IS_CHROMEOS_ASH) +@@ -894,7 +899,7 @@ int UDPSocketPosix::DoBind(const IPEndPoint& address) + #if BUILDFLAG(IS_CHROMEOS) if (last_error == EINVAL) return ERR_ADDRESS_IN_USE; -#elif BUILDFLAG(IS_APPLE) diff --git a/www/chromium/files/patch-net_socket_udp__socket__unittest.cc b/www/chromium/files/patch-net_socket_udp__socket__unittest.cc index 7614d0189516..d5060d2e4ca8 100644 --- a/www/chromium/files/patch-net_socket_udp__socket__unittest.cc +++ b/www/chromium/files/patch-net_socket_udp__socket__unittest.cc @@ -1,6 +1,6 @@ ---- net/socket/udp_socket_unittest.cc.orig 2024-04-19 13:02:56 UTC +--- net/socket/udp_socket_unittest.cc.orig 2025-07-02 06:08:04 UTC +++ net/socket/udp_socket_unittest.cc -@@ -358,7 +358,7 @@ TEST_F(UDPSocketTest, PartialRecv) { +@@ -397,7 +397,7 @@ TEST_F(UDPSocketTest, PartialRecv) { EXPECT_EQ(second_packet, received); } @@ -9,39 +9,39 @@ // - MacOS: requires root permissions on OSX 10.7+. // - Android: devices attached to testbots don't have default network, so // broadcasting to 255.255.255.255 returns error -109 (Address not reachable). -@@ -669,7 +669,7 @@ TEST_F(UDPSocketTest, ClientSetDoNotFragment) { +@@ -708,7 +708,7 @@ TEST_F(UDPSocketTest, ClientSetDoNotFragment) { EXPECT_THAT(rv, IsOk()); rv = client.SetDoNotFragment(); -#if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/945590): IP_MTU_DISCOVER is not implemented on Fuchsia. + // TODO(crbug.com/42050633): IP_MTU_DISCOVER is not implemented on Fuchsia. EXPECT_THAT(rv, IsError(ERR_NOT_IMPLEMENTED)); - #elif BUILDFLAG(IS_MAC) -@@ -697,7 +697,7 @@ TEST_F(UDPSocketTest, ServerSetDoNotFragment) { + #else +@@ -730,7 +730,7 @@ TEST_F(UDPSocketTest, ServerSetDoNotFragment) { EXPECT_THAT(rv, IsOk()); rv = server.SetDoNotFragment(); -#if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/945590): IP_MTU_DISCOVER is not implemented on Fuchsia. + // TODO(crbug.com/42050633): IP_MTU_DISCOVER is not implemented on Fuchsia. EXPECT_THAT(rv, IsError(ERR_NOT_IMPLEMENTED)); - #elif BUILDFLAG(IS_MAC) -@@ -762,7 +762,7 @@ TEST_F(UDPSocketTest, JoinMulticastGroup) { + #else +@@ -796,7 +796,7 @@ TEST_F(UDPSocketTest, JoinMulticastGroup) { - // TODO(https://crbug.com/947115): failing on device on iOS 12.2. - // TODO(https://crbug.com/1227554): flaky on Mac 11. + // TODO(crbug.com/40620614): failing on device on iOS 12.2. + // TODO(crbug.com/40189274): flaky on Mac 11. -#if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_IOS) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) #define MAYBE_SharedMulticastAddress DISABLED_SharedMulticastAddress #else #define MAYBE_SharedMulticastAddress SharedMulticastAddress -@@ -816,7 +816,7 @@ TEST_F(UDPSocketTest, MAYBE_SharedMulticastAddress) { +@@ -850,7 +850,7 @@ TEST_F(UDPSocketTest, MAYBE_SharedMulticastAddress) { NetLogSource()); ASSERT_THAT(client_socket.Connect(send_address), IsOk()); --#if !BUILDFLAG(IS_CHROMEOS_ASH) -+#if !BUILDFLAG(IS_CHROMEOS_ASH) && !BUILDFLAG(IS_BSD) +-#if !BUILDFLAG(IS_CHROMEOS) ++#if !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) // Send a message via the multicast group. That message is expected be be // received by both receving sockets. // diff --git a/www/chromium/files/patch-net_third__party_quiche_BUILD.gn b/www/chromium/files/patch-net_third__party_quiche_BUILD.gn index 29e8797828ff..544648c6bf39 100644 --- a/www/chromium/files/patch-net_third__party_quiche_BUILD.gn +++ b/www/chromium/files/patch-net_third__party_quiche_BUILD.gn @@ -1,6 +1,6 @@ ---- net/third_party/quiche/BUILD.gn.orig 2023-11-03 10:09:45 UTC +--- net/third_party/quiche/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ net/third_party/quiche/BUILD.gn -@@ -29,7 +29,7 @@ import("//net/third_party/quiche/src/build/source_list +@@ -28,7 +28,7 @@ import("//net/third_party/quiche/src/build/source_list import("//testing/libfuzzer/fuzzer_test.gni") import("//third_party/protobuf/proto_library.gni") diff --git a/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__comparision__tool.cc b/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__comparision__tool.cc deleted file mode 100644 index 224843fbcab0..000000000000 --- a/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__comparision__tool.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- net/tools/cert_verify_tool/cert_verify_comparision_tool.cc.orig 2024-02-23 21:04:38 UTC -+++ net/tools/cert_verify_tool/cert_verify_comparision_tool.cc -@@ -35,7 +35,7 @@ - #include "net/url_request/url_request_context_builder.h" - #include "net/url_request/url_request_context_getter.h" - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #include "net/proxy_resolution/proxy_config.h" - #include "net/proxy_resolution/proxy_config_service_fixed.h" - #endif -@@ -55,7 +55,7 @@ void SetUpOnNetworkThread( - base::WaitableEvent* initialization_complete_event) { - net::URLRequestContextBuilder url_request_context_builder; - url_request_context_builder.set_user_agent(GetUserAgent()); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // On Linux, use a fixed ProxyConfigService, since the default one - // depends on glib. - // -@@ -123,7 +123,7 @@ class CertVerifyImpl { - std::unique_ptr<CertVerifyImpl> CreateCertVerifyImplFromName( - base::StringPiece impl_name, - scoped_refptr<net::CertNetFetcher> cert_net_fetcher) { --#if !(BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || \ -+#if !(BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(CHROME_ROOT_STORE_ONLY)) - if (impl_name == "platform") { - return std::make_unique<CertVerifyImpl>( diff --git a/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__tool.cc b/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__tool.cc index 7f00b3572d31..93cb0681e111 100644 --- a/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__tool.cc +++ b/www/chromium/files/patch-net_tools_cert__verify__tool_cert__verify__tool.cc @@ -1,6 +1,6 @@ ---- net/tools/cert_verify_tool/cert_verify_tool.cc.orig 2024-04-19 13:02:56 UTC +--- net/tools/cert_verify_tool/cert_verify_tool.cc.orig 2025-05-28 14:55:43 UTC +++ net/tools/cert_verify_tool/cert_verify_tool.cc -@@ -33,7 +33,7 @@ +@@ -35,7 +35,7 @@ #include "third_party/boringssl/src/pki/trust_store.h" #include "third_party/boringssl/src/pki/trust_store_collection.h" @@ -9,7 +9,7 @@ #include "net/proxy_resolution/proxy_config.h" #include "net/proxy_resolution/proxy_config_service_fixed.h" #endif -@@ -65,7 +65,7 @@ void SetUpOnNetworkThread( +@@ -67,7 +67,7 @@ void SetUpOnNetworkThread( base::WaitableEvent* initialization_complete_event) { net::URLRequestContextBuilder url_request_context_builder; url_request_context_builder.set_user_agent(GetUserAgent()); @@ -18,12 +18,3 @@ // On Linux, use a fixed ProxyConfigService, since the default one // depends on glib. // -@@ -571,7 +571,7 @@ int main(int argc, char** argv) { - std::string impls_str = command_line.GetSwitchValueASCII("impls"); - if (impls_str.empty()) { - // Default value. --#if !(BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || \ -+#if !(BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) || \ - BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(CHROME_ROOT_STORE_ONLY)) - impls_str = "platform,"; - #endif diff --git a/www/chromium/files/patch-net_tools_net__watcher_net__watcher.cc b/www/chromium/files/patch-net_tools_net__watcher_net__watcher.cc index 9f5c72dbbece..c4213618f0bb 100644 --- a/www/chromium/files/patch-net_tools_net__watcher_net__watcher.cc +++ b/www/chromium/files/patch-net_tools_net__watcher_net__watcher.cc @@ -1,6 +1,6 @@ ---- net/tools/net_watcher/net_watcher.cc.orig 2023-02-08 09:03:45 UTC +--- net/tools/net_watcher/net_watcher.cc.orig 2025-04-04 08:52:13 UTC +++ net/tools/net_watcher/net_watcher.cc -@@ -32,7 +32,7 @@ +@@ -31,7 +31,7 @@ #include "net/proxy_resolution/proxy_config_service.h" #include "net/proxy_resolution/proxy_config_with_annotation.h" @@ -9,16 +9,25 @@ #include "net/base/network_change_notifier_linux.h" #endif -@@ -44,7 +44,7 @@ namespace { +@@ -41,7 +41,7 @@ + + namespace { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Flag to specifies which network interfaces to ignore. Interfaces should // follow as a comma seperated list. const char kIgnoreNetifFlag[] = "ignore-netif"; -@@ -163,7 +163,7 @@ int main(int argc, char* argv[]) { +@@ -143,7 +143,7 @@ class NetWatcher : + } // namespace + + int main(int argc, char* argv[]) { +-#if BUILDFLAG(IS_APPLE) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::apple::ScopedNSAutoreleasePool pool; + #endif + base::AtExitManager exit_manager; +@@ -160,7 +160,7 @@ int main(int argc, char* argv[]) { NetWatcher net_watcher; diff --git a/www/chromium/files/patch-net_traffic__annotation_network__traffic__annotation.h b/www/chromium/files/patch-net_traffic__annotation_network__traffic__annotation.h index 71e4b623311b..e57db9a0b9de 100644 --- a/www/chromium/files/patch-net_traffic__annotation_network__traffic__annotation.h +++ b/www/chromium/files/patch-net_traffic__annotation_network__traffic__annotation.h @@ -1,6 +1,6 @@ ---- net/traffic_annotation/network_traffic_annotation.h.orig 2022-09-24 10:57:32 UTC +--- net/traffic_annotation/network_traffic_annotation.h.orig 2025-04-04 08:52:13 UTC +++ net/traffic_annotation/network_traffic_annotation.h -@@ -373,7 +373,7 @@ struct MutablePartialNetworkTrafficAnnotationTag { +@@ -374,7 +374,7 @@ struct MutablePartialNetworkTrafficAnnotationTag { } // namespace net // Placeholder for unannotated usages. @@ -9,12 +9,12 @@ #define TRAFFIC_ANNOTATION_WITHOUT_PROTO(ANNOTATION_ID) \ net::DefineNetworkTrafficAnnotation(ANNOTATION_ID, "No proto yet.") #endif -@@ -387,7 +387,7 @@ struct MutablePartialNetworkTrafficAnnotationTag { - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. - #if !BUILDFLAG(IS_WIN) && \ -- !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +@@ -385,7 +385,7 @@ struct MutablePartialNetworkTrafficAnnotationTag { + // + // On Linux and Windows, use MISSING_TRAFFIC_ANNOTATION or + // TRAFFIC_ANNOTATION_FOR_TESTS. +-#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) #define NO_TRAFFIC_ANNOTATION_YET \ net::DefineNetworkTrafficAnnotation("undefined", "Nothing here yet.") diff --git a/www/chromium/files/patch-net_url__request_url__request__context.cc b/www/chromium/files/patch-net_url__request_url__request__context.cc index 9853b35853b9..8b766328ce81 100644 --- a/www/chromium/files/patch-net_url__request_url__request__context.cc +++ b/www/chromium/files/patch-net_url__request_url__request__context.cc @@ -1,11 +1,11 @@ ---- net/url_request/url_request_context.cc.orig 2024-02-23 21:04:38 UTC +--- net/url_request/url_request_context.cc.orig 2025-04-04 08:52:13 UTC +++ net/url_request/url_request_context.cc -@@ -117,7 +117,7 @@ const HttpNetworkSessionContext* URLRequestContext::Ge - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. - #if !BUILDFLAG(IS_WIN) && \ -- !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +@@ -119,7 +119,7 @@ const HttpNetworkSessionContext* URLRequestContext::Ge + return &network_session->context(); + } + +-#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) std::unique_ptr<URLRequest> URLRequestContext::CreateRequest( const GURL& url, RequestPriority priority, diff --git a/www/chromium/files/patch-net_url__request_url__request__context.h b/www/chromium/files/patch-net_url__request_url__request__context.h index 6766a5c94a17..f5ba7d8a8aff 100644 --- a/www/chromium/files/patch-net_url__request_url__request__context.h +++ b/www/chromium/files/patch-net_url__request_url__request__context.h @@ -1,11 +1,11 @@ ---- net/url_request/url_request_context.h.orig 2024-02-23 21:04:38 UTC +--- net/url_request/url_request_context.h.orig 2025-04-04 08:52:13 UTC +++ net/url_request/url_request_context.h -@@ -85,7 +85,7 @@ class NET_EXPORT URLRequestContext final { - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. - #if !BUILDFLAG(IS_WIN) && \ -- !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +@@ -86,7 +86,7 @@ class NET_EXPORT URLRequestContext final { + // session. + const HttpNetworkSessionContext* GetNetworkSessionContext() const; + +-#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) ++#if !BUILDFLAG(IS_WIN) && !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) // This function should not be used in Chromium, please use the version with // NetworkTrafficAnnotationTag in the future. // diff --git a/www/chromium/files/patch-net_url__request_url__request__context__builder.cc b/www/chromium/files/patch-net_url__request_url__request__context__builder.cc index 6ecf24c32358..6de33a948c95 100644 --- a/www/chromium/files/patch-net_url__request_url__request__context__builder.cc +++ b/www/chromium/files/patch-net_url__request_url__request__context__builder.cc @@ -1,6 +1,6 @@ ---- net/url_request/url_request_context_builder.cc.orig 2024-03-22 08:19:40 UTC +--- net/url_request/url_request_context_builder.cc.orig 2025-05-28 14:55:43 UTC +++ net/url_request/url_request_context_builder.cc -@@ -428,7 +428,7 @@ std::unique_ptr<URLRequestContext> URLRequestContextBu +@@ -444,7 +444,7 @@ std::unique_ptr<URLRequestContext> URLRequestContextBu } if (!proxy_resolution_service_) { diff --git a/www/chromium/files/patch-net_websockets_websocket__basic__stream__adapters__test.cc b/www/chromium/files/patch-net_websockets_websocket__basic__stream__adapters__test.cc new file mode 100644 index 000000000000..8f679f5a81e5 --- /dev/null +++ b/www/chromium/files/patch-net_websockets_websocket__basic__stream__adapters__test.cc @@ -0,0 +1,15 @@ +--- net/websockets/websocket_basic_stream_adapters_test.cc.orig 2025-04-04 08:52:13 UTC ++++ net/websockets/websocket_basic_stream_adapters_test.cc +@@ -1098,10 +1098,10 @@ TEST_F(WebSocketSpdyStreamAdapterTest, + OnCloseOkShouldBeTranslatedToConnectionClose) { + spdy::SpdySerializedFrame response_headers( + spdy_util_.ConstructSpdyResponseHeaders(1, ResponseHeaders(), false)); +- spdy::SpdySerializedFrame close( ++ spdy::SpdySerializedFrame test_close( + spdy_util_.ConstructSpdyRstStream(1, spdy::ERROR_CODE_NO_ERROR)); + MockRead reads[] = {CreateMockRead(response_headers, 1), +- CreateMockRead(close, 2), MockRead(ASYNC, 0, 3)}; ++ CreateMockRead(test_close, 2), MockRead(ASYNC, 0, 3)}; + spdy::SpdySerializedFrame request_headers(spdy_util_.ConstructSpdyHeaders( + 1, RequestHeaders(), DEFAULT_PRIORITY, false)); + MockWrite writes[] = {CreateMockWrite(request_headers, 0)}; diff --git a/www/chromium/files/patch-pdf_pdfium_pdfium__engine.cc b/www/chromium/files/patch-pdf_pdfium_pdfium__engine.cc index 561b3965451a..7393e23f0c6e 100644 --- a/www/chromium/files/patch-pdf_pdfium_pdfium__engine.cc +++ b/www/chromium/files/patch-pdf_pdfium_pdfium__engine.cc @@ -1,7 +1,7 @@ ---- pdf/pdfium/pdfium_engine.cc.orig 2024-02-23 21:04:38 UTC +--- pdf/pdfium/pdfium_engine.cc.orig 2025-07-02 06:08:04 UTC +++ pdf/pdfium/pdfium_engine.cc -@@ -85,7 +85,7 @@ - #include "gin/public/cppgc.h" +@@ -113,7 +113,7 @@ + #include "ui/accessibility/ax_features.mojom-features.h" #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -9,7 +9,7 @@ #include "pdf/pdfium/pdfium_font_linux.h" #endif -@@ -525,7 +525,7 @@ void InitializeSDK(bool enable_v8, +@@ -569,7 +569,7 @@ void InitializeSDK(bool enable_v8, FPDF_InitLibraryWithConfig(&config); diff --git a/www/chromium/files/patch-printing_backend_cups__ipp__helper.cc b/www/chromium/files/patch-printing_backend_cups__ipp__helper.cc index 1aaf9a74d6ed..4edbe9b43b0c 100644 --- a/www/chromium/files/patch-printing_backend_cups__ipp__helper.cc +++ b/www/chromium/files/patch-printing_backend_cups__ipp__helper.cc @@ -1,6 +1,6 @@ ---- printing/backend/cups_ipp_helper.cc.orig 2023-09-13 12:11:42 UTC +--- printing/backend/cups_ipp_helper.cc.orig 2025-07-02 06:08:04 UTC +++ printing/backend/cups_ipp_helper.cc -@@ -215,7 +215,7 @@ void ExtractResolutions(const CupsOptionProvider& prin +@@ -202,7 +202,7 @@ void ExtractResolutions(const CupsOptionProvider& prin // Provide a default DPI if no valid DPI is found. #if BUILDFLAG(IS_MAC) constexpr gfx::Size kDefaultMissingDpi(kDefaultMacDpi, kDefaultMacDpi); diff --git a/www/chromium/files/patch-printing_backend_print__backend__cups.cc b/www/chromium/files/patch-printing_backend_print__backend__cups.cc new file mode 100644 index 000000000000..677125631cfa --- /dev/null +++ b/www/chromium/files/patch-printing_backend_print__backend__cups.cc @@ -0,0 +1,29 @@ +--- printing/backend/print_backend_cups.cc.orig 2025-04-04 08:52:13 UTC ++++ printing/backend/print_backend_cups.cc +@@ -29,7 +29,7 @@ + #include "printing/mojom/print.mojom.h" + #include "url/gurl.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + #include "base/feature_list.h" + #include "printing/backend/cups_connection.h" + #include "printing/backend/print_backend_cups_ipp.h" +@@ -59,7 +59,7 @@ int CaptureCupsDestCallback(void* data, unsigned flags + return 1; // Keep going. + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + // This may be removed when Amazon Linux 2 reaches EOL (30 Jun 2025). + bool AreNewerCupsFunctionsAvailable() { + return cupsFindDestDefault && cupsFindDestSupported && cupsUserAgent && +@@ -286,7 +286,7 @@ bool PrintBackendCUPS::IsValidPrinter(const std::strin + #if !BUILDFLAG(IS_CHROMEOS) + scoped_refptr<PrintBackend> PrintBackend::CreateInstanceImpl( + const std::string& locale) { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + if (AreNewerCupsFunctionsAvailable() && + base::FeatureList::IsEnabled(features::kCupsIppPrintingBackend)) { + return base::MakeRefCounted<PrintBackendCupsIpp>(CupsConnection::Create()); diff --git a/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits.cc b/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits.cc index ef00d3008013..38059b76e472 100644 --- a/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits.cc +++ b/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits.cc @@ -1,4 +1,4 @@ ---- printing/mojom/printing_context_mojom_traits.cc.orig 2023-11-03 10:09:45 UTC +--- printing/mojom/printing_context_mojom_traits.cc.orig 2025-05-28 14:55:43 UTC +++ printing/mojom/printing_context_mojom_traits.cc @@ -19,7 +19,7 @@ #include "base/numerics/safe_conversions.h" @@ -9,7 +9,7 @@ #include "mojo/public/mojom/base/values.mojom.h" #endif -@@ -161,7 +161,7 @@ bool StructTraits< +@@ -162,7 +162,7 @@ bool StructTraits< } out->set_pages_per_sheet(data.pages_per_sheet()); @@ -18,7 +18,7 @@ DCHECK(out->advanced_settings().empty()); if (!data.ReadAdvancedSettings(&out->advanced_settings())) return false; -@@ -238,7 +238,7 @@ bool StructTraits< +@@ -239,7 +239,7 @@ bool StructTraits< if (system_print_dialog_data.size() != dictionary_entries) { return false; } diff --git a/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits__unittest.cc b/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits__unittest.cc new file mode 100644 index 000000000000..30b28cd77325 --- /dev/null +++ b/www/chromium/files/patch-printing_mojom_printing__context__mojom__traits__unittest.cc @@ -0,0 +1,65 @@ +--- printing/mojom/printing_context_mojom_traits_unittest.cc.orig 2025-05-28 14:55:43 UTC ++++ printing/mojom/printing_context_mojom_traits_unittest.cc +@@ -79,7 +79,7 @@ base::Value::Dict GenerateSampleSystemPrintDialogData( + data.Set(kMacSystemPrintDialogDataDestinationLocation, "/foo/bar.pdf"); + } + +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + data.Set(kLinuxSystemPrintDialogDataPrinter, "printer-name"); + data.Set(kLinuxSystemPrintDialogDataPrintSettings, "print-settings-foo"); + data.Set(kLinuxSystemPrintDialogDataPageSetup, "page-setup-bar"); +@@ -116,7 +116,7 @@ const PageMargins kPrintSettingsCustomMarginsInMicrons + /*top=*/10583, + /*bottom=*/12347); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + PrintSettings::AdvancedSettings GenerateSampleAdvancedSettings() { + PrintSettings::AdvancedSettings advanced_settings; + advanced_settings.emplace("advanced-setting-A", base::Value("setting-A")); +@@ -209,7 +209,7 @@ PrintSettings GenerateSamplePrintSettingsCommon() { + settings.set_device_name(kPrintSettingsDeviceName); + settings.set_requested_media(kPrintSettingsRequestedMedia); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + PrintSettings::AdvancedSettings& advanced_settings = + settings.advanced_settings(); + for (const auto& item : kPrintSettingsAdvancedSettings) +@@ -547,7 +547,7 @@ TEST(PrintingContextMojomTraitsTest, + + EXPECT_EQ(output.pages_per_sheet(), kPrintSettingsPagesPerSheet1); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + EXPECT_EQ(output.advanced_settings(), kPrintSettingsAdvancedSettings); + #endif + +@@ -600,7 +600,7 @@ TEST(PrintingContextMojomTraitsTest, + kPrintSettingsCustomMarginsInMicrons)); + EXPECT_EQ(output.pages_per_sheet(), kPrintSettingsPagesPerSheet2); + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + EXPECT_EQ(output.advanced_settings(), kPrintSettingsAdvancedSettings); + #endif + +@@ -639,7 +639,7 @@ TEST(PrintingContextMojomTraitsTest, + EXPECT_EQ(output.page_setup_device_units(), kInput.page_setup_device_units()); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + TEST(PrintingContextMojomTraitsTest, + TestSerializeAndDeserializePrintSettingsEmptyAdvancedSettings) { + PrintSettings input = GenerateSamplePrintSettingsDefaultMargins(); +@@ -837,7 +837,7 @@ TEST( + } + #endif // BUILDFLAG(IS_MAC) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + TEST( + PrintingContextMojomTraitsTest, + TestSerializeAndDeserializePrintSettingsSystemPrintDialogPrinterInvalidDataType) { diff --git a/www/chromium/files/patch-printing_print__settings.cc b/www/chromium/files/patch-printing_print__settings.cc index 073188648cf0..5b052328c1bd 100644 --- a/www/chromium/files/patch-printing_print__settings.cc +++ b/www/chromium/files/patch-printing_print__settings.cc @@ -1,6 +1,6 @@ ---- printing/print_settings.cc.orig 2023-10-11 18:22:24 UTC +--- printing/print_settings.cc.orig 2025-05-28 14:55:43 UTC +++ printing/print_settings.cc -@@ -320,7 +320,7 @@ PrintSettings& PrintSettings::operator=(const PrintSet +@@ -319,7 +319,7 @@ PrintSettings& PrintSettings::operator=(const PrintSet #endif is_modifiable_ = settings.is_modifiable_; pages_per_sheet_ = settings.pages_per_sheet_; @@ -9,25 +9,25 @@ for (const auto& item : settings.advanced_settings_) advanced_settings_.emplace(item.first, item.second.Clone()); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -350,7 +350,7 @@ bool PrintSettings::operator==(const PrintSettings& ot +@@ -349,7 +349,7 @@ bool PrintSettings::operator==(const PrintSettings& ot #endif - is_modifiable_, requested_custom_margins_in_points_, + is_modifiable_, requested_custom_margins_in_microns_, pages_per_sheet_ -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) , advanced_settings_ #endif -@@ -374,7 +374,7 @@ bool PrintSettings::operator==(const PrintSettings& ot +@@ -373,7 +373,7 @@ bool PrintSettings::operator==(const PrintSettings& ot other.is_modifiable_, - other.requested_custom_margins_in_points_, + other.requested_custom_margins_in_microns_, other.pages_per_sheet_ -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) , other.advanced_settings_ #endif -@@ -414,7 +414,7 @@ void PrintSettings::Clear() { +@@ -413,7 +413,7 @@ void PrintSettings::Clear() { #endif is_modifiable_ = true; pages_per_sheet_ = 1; diff --git a/www/chromium/files/patch-printing_print__settings.h b/www/chromium/files/patch-printing_print__settings.h index f584a3f20ad4..532a1c289baf 100644 --- a/www/chromium/files/patch-printing_print__settings.h +++ b/www/chromium/files/patch-printing_print__settings.h @@ -1,4 +1,4 @@ ---- printing/print_settings.h.orig 2023-10-11 18:22:24 UTC +--- printing/print_settings.h.orig 2025-07-02 06:08:04 UTC +++ printing/print_settings.h @@ -25,7 +25,7 @@ #include "base/values.h" @@ -18,7 +18,7 @@ inline constexpr char kLinuxSystemPrintDialogDataPrinter[] = "printer_name"; inline constexpr char kLinuxSystemPrintDialogDataPrintSettings[] = "print_settings"; -@@ -101,7 +101,7 @@ class COMPONENT_EXPORT(PRINTING) PrintSettings { +@@ -101,7 +101,7 @@ class COMPONENT_EXPORT(PRINTING_SETTINGS) PrintSetting std::string vendor_id; }; @@ -27,7 +27,7 @@ using AdvancedSettings = std::map<std::string, base::Value>; #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -276,7 +276,7 @@ class COMPONENT_EXPORT(PRINTING) PrintSettings { +@@ -276,7 +276,7 @@ class COMPONENT_EXPORT(PRINTING_SETTINGS) PrintSetting pages_per_sheet_ = pages_per_sheet; } @@ -36,7 +36,7 @@ AdvancedSettings& advanced_settings() { return advanced_settings_; } const AdvancedSettings& advanced_settings() const { return advanced_settings_; -@@ -429,7 +429,7 @@ class COMPONENT_EXPORT(PRINTING) PrintSettings { +@@ -437,7 +437,7 @@ class COMPONENT_EXPORT(PRINTING_SETTINGS) PrintSetting // Number of pages per sheet. int pages_per_sheet_; diff --git a/www/chromium/files/patch-printing_print__settings__conversion.cc b/www/chromium/files/patch-printing_print__settings__conversion.cc index cd094bec27a5..92e3cdb9976c 100644 --- a/www/chromium/files/patch-printing_print__settings__conversion.cc +++ b/www/chromium/files/patch-printing_print__settings__conversion.cc @@ -1,6 +1,6 @@ ---- printing/print_settings_conversion.cc.orig 2024-04-19 13:02:56 UTC +--- printing/print_settings_conversion.cc.orig 2025-05-28 14:55:43 UTC +++ printing/print_settings_conversion.cc -@@ -285,7 +285,7 @@ std::unique_ptr<PrintSettings> PrintSettingsFromJobSet +@@ -291,7 +291,7 @@ std::unique_ptr<PrintSettings> PrintSettingsFromJobSet settings->set_is_modifiable(is_modifiable.value()); } diff --git a/www/chromium/files/patch-printing_printing__context__linux.cc b/www/chromium/files/patch-printing_printing__context__linux.cc index 98abb1c7e22d..2cf9be972aea 100644 --- a/www/chromium/files/patch-printing_printing__context__linux.cc +++ b/www/chromium/files/patch-printing_printing__context__linux.cc @@ -1,4 +1,4 @@ ---- printing/printing_context_linux.cc.orig 2023-12-10 06:10:27 UTC +--- printing/printing_context_linux.cc.orig 2025-05-28 14:55:43 UTC +++ printing/printing_context_linux.cc @@ -23,7 +23,7 @@ #endif @@ -9,7 +9,7 @@ #include "ui/linux/linux_ui.h" #endif -@@ -68,7 +68,7 @@ mojom::ResultCode PrintingContextLinux::UseDefaultSett +@@ -69,7 +69,7 @@ mojom::ResultCode PrintingContextLinux::UseDefaultSett ResetSettings(); @@ -18,7 +18,7 @@ if (!ui::LinuxUi::instance()) return mojom::ResultCode::kSuccess; -@@ -84,7 +84,7 @@ mojom::ResultCode PrintingContextLinux::UseDefaultSett +@@ -85,7 +85,7 @@ mojom::ResultCode PrintingContextLinux::UseDefaultSett } gfx::Size PrintingContextLinux::GetPdfPaperSizeDeviceUnits() { @@ -27,7 +27,7 @@ if (ui::LinuxUi::instance()) return ui::LinuxUi::instance()->GetPdfPaperSize(this); #endif -@@ -97,7 +97,7 @@ mojom::ResultCode PrintingContextLinux::UpdatePrinterS +@@ -98,7 +98,7 @@ mojom::ResultCode PrintingContextLinux::UpdatePrinterS DCHECK(!printer_settings.show_system_dialog); DCHECK(!in_print_job_); diff --git a/www/chromium/files/patch-printing_printing__features.cc b/www/chromium/files/patch-printing_printing__features.cc new file mode 100644 index 000000000000..82bbeb4661c8 --- /dev/null +++ b/www/chromium/files/patch-printing_printing__features.cc @@ -0,0 +1,26 @@ +--- printing/printing_features.cc.orig 2025-05-05 10:57:53 UTC ++++ printing/printing_features.cc +@@ -26,12 +26,12 @@ BASE_FEATURE(kApiPrintingMarginsAndScale, + base::FEATURE_DISABLED_BY_DEFAULT); + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + // Use the CUPS IPP printing backend instead of the original CUPS backend that + // calls the deprecated PPD API. + BASE_FEATURE(kCupsIppPrintingBackend, + "CupsIppPrintingBackend", +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::FEATURE_DISABLED_BY_DEFAULT + #else + base::FEATURE_ENABLED_BY_DEFAULT +@@ -81,7 +81,7 @@ BASE_FEATURE(kUseXpsForPrintingFromPdf, + // out-of-process. + BASE_FEATURE(kEnableOopPrintDrivers, + "EnableOopPrintDrivers", +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT + #else + base::FEATURE_DISABLED_BY_DEFAULT diff --git a/www/chromium/files/patch-printing_printing__features.h b/www/chromium/files/patch-printing_printing__features.h new file mode 100644 index 000000000000..e4d23f9607ce --- /dev/null +++ b/www/chromium/files/patch-printing_printing__features.h @@ -0,0 +1,11 @@ +--- printing/printing_features.h.orig 2025-05-05 10:57:53 UTC ++++ printing/printing_features.h +@@ -24,7 +24,7 @@ COMPONENT_EXPORT(PRINTING_BASE) + BASE_DECLARE_FEATURE(kApiPrintingMarginsAndScale); + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + COMPONENT_EXPORT(PRINTING_BASE) BASE_DECLARE_FEATURE(kCupsIppPrintingBackend); + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) + diff --git a/www/chromium/files/patch-remoting_base_chromoting__event.cc b/www/chromium/files/patch-remoting_base_chromoting__event.cc index 85d96833a2f5..0226e6c52ce4 100644 --- a/www/chromium/files/patch-remoting_base_chromoting__event.cc +++ b/www/chromium/files/patch-remoting_base_chromoting__event.cc @@ -1,11 +1,11 @@ ---- remoting/base/chromoting_event.cc.orig 2022-11-30 08:12:58 UTC +--- remoting/base/chromoting_event.cc.orig 2025-03-05 08:14:56 UTC +++ remoting/base/chromoting_event.cc -@@ -192,7 +192,7 @@ void ChromotingEvent::AddSystemInfo() { +@@ -191,7 +191,7 @@ void ChromotingEvent::AddSystemInfo() { SetString(kCpuKey, base::SysInfo::OperatingSystemArchitecture()); SetString(kOsVersionKey, base::SysInfo::OperatingSystemVersion()); SetString(kWebAppVersionKey, STRINGIZE(VERSION)); --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) Os os = Os::CHROMOTING_LINUX; - #elif BUILDFLAG(IS_CHROMEOS_ASH) + #elif BUILDFLAG(IS_CHROMEOS) Os os = Os::CHROMOTING_CHROMEOS; diff --git a/www/chromium/files/patch-remoting_base_constants.h b/www/chromium/files/patch-remoting_base_constants.h new file mode 100644 index 000000000000..4b16d520152c --- /dev/null +++ b/www/chromium/files/patch-remoting_base_constants.h @@ -0,0 +1,11 @@ +--- remoting/base/constants.h.orig 2025-05-28 14:55:43 UTC ++++ remoting/base/constants.h +@@ -27,7 +27,7 @@ const int kDefaultDpi = 96; + // The video frame rate. + constexpr int kTargetFrameRate = 30; + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + inline constexpr char kChromeRemoteDesktopSessionEnvVar[] = + "CHROME_REMOTE_DESKTOP_SESSION"; + #endif diff --git a/www/chromium/files/patch-remoting_client_display_sys__opengl.h b/www/chromium/files/patch-remoting_client_display_sys__opengl.h deleted file mode 100644 index 78ba20a4ba8b..000000000000 --- a/www/chromium/files/patch-remoting_client_display_sys__opengl.h +++ /dev/null @@ -1,11 +0,0 @@ ---- remoting/client/display/sys_opengl.h.orig 2022-02-28 16:54:41 UTC -+++ remoting/client/display/sys_opengl.h -@@ -9,7 +9,7 @@ - - #if BUILDFLAG(IS_IOS) - #include <OpenGLES/ES3/gl.h> --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - #define GL_GLEXT_PROTOTYPES - #include <GL/gl.h> - #include <GL/glext.h> diff --git a/www/chromium/files/patch-remoting_codec_webrtc__video__encoder__vpx.cc b/www/chromium/files/patch-remoting_codec_webrtc__video__encoder__vpx.cc index f5d4dab751ac..5e1aadb32e5a 100644 --- a/www/chromium/files/patch-remoting_codec_webrtc__video__encoder__vpx.cc +++ b/www/chromium/files/patch-remoting_codec_webrtc__video__encoder__vpx.cc @@ -1,11 +1,11 @@ ---- remoting/codec/webrtc_video_encoder_vpx.cc.orig 2023-05-31 08:12:17 UTC +--- remoting/codec/webrtc_video_encoder_vpx.cc.orig 2025-03-05 08:14:56 UTC +++ remoting/codec/webrtc_video_encoder_vpx.cc -@@ -88,7 +88,7 @@ void SetVp8CodecParameters(vpx_codec_enc_cfg_t* config +@@ -92,7 +92,7 @@ void SetVp8CodecParameters(vpx_codec_enc_cfg_t* config const webrtc::DesktopSize& size) { SetCommonCodecParameters(config, size); --#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_LACROS) -+#if (BUILDFLAG(IS_BSD) || BUILDFLAG(IS_LINUX)) && !BUILDFLAG(IS_CHROMEOS_LACROS) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // On Linux, using too many threads for VP8 encoding has been linked to high // CPU usage on machines that are under stress. See http://crbug.com/1151148. // 5/3/2022 update: Perf testing has shown that doubling the number of threads diff --git a/www/chromium/files/patch-remoting_host_base_desktop__environment__options.cc b/www/chromium/files/patch-remoting_host_base_desktop__environment__options.cc index 13301e0d6bb1..cd7cc2ce8002 100644 --- a/www/chromium/files/patch-remoting_host_base_desktop__environment__options.cc +++ b/www/chromium/files/patch-remoting_host_base_desktop__environment__options.cc @@ -1,6 +1,6 @@ ---- remoting/host/base/desktop_environment_options.cc.orig 2024-02-23 21:04:38 UTC +--- remoting/host/base/desktop_environment_options.cc.orig 2025-05-05 10:57:53 UTC +++ remoting/host/base/desktop_environment_options.cc -@@ -124,7 +124,7 @@ bool DesktopEnvironmentOptions::capture_video_on_dedic +@@ -109,7 +109,7 @@ bool DesktopEnvironmentOptions::capture_video_on_dedic // TODO(joedow): Determine whether we can migrate additional platforms to // using the DesktopCaptureWrapper instead of the DesktopCaptureProxy. Then // clean up DesktopCapturerProxy::Core::CreateCapturer(). diff --git a/www/chromium/files/patch-remoting_host_base_switches.cc b/www/chromium/files/patch-remoting_host_base_switches.cc index 5bdc44c55b98..ffa9da35bb24 100644 --- a/www/chromium/files/patch-remoting_host_base_switches.cc +++ b/www/chromium/files/patch-remoting_host_base_switches.cc @@ -1,4 +1,4 @@ ---- remoting/host/base/switches.cc.orig 2022-04-21 18:48:31 UTC +--- remoting/host/base/switches.cc.orig 2025-05-28 14:55:43 UTC +++ remoting/host/base/switches.cc @@ -23,13 +23,13 @@ const char kProcessTypeEvaluateCapability[] = "evaluat const char kProcessTypeFileChooser[] = "file_chooser"; @@ -13,6 +13,6 @@ -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - const char kEnableUtempter[] = "enable-utempter"; + const char kEnableWtmpdb[] = "enable-wtmpdb"; #endif diff --git a/www/chromium/files/patch-remoting_host_base_switches.h b/www/chromium/files/patch-remoting_host_base_switches.h index 100a7d5df7ff..450a94abdc2e 100644 --- a/www/chromium/files/patch-remoting_host_base_switches.h +++ b/www/chromium/files/patch-remoting_host_base_switches.h @@ -1,4 +1,4 @@ ---- remoting/host/base/switches.h.orig 2022-04-21 18:48:31 UTC +--- remoting/host/base/switches.h.orig 2025-05-28 14:55:43 UTC +++ remoting/host/base/switches.h @@ -35,13 +35,13 @@ extern const char kProcessTypeRdpDesktopSession[]; extern const char kProcessTypeEvaluateCapability[]; @@ -13,6 +13,6 @@ -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Used to record client sessions to utmp/wtmp. - extern const char kEnableUtempter[]; + // Used to record client sessions to wtmpd. + extern const char kEnableWtmpdb[]; #endif diff --git a/www/chromium/files/patch-remoting_host_basic__desktop__environment.cc b/www/chromium/files/patch-remoting_host_basic__desktop__environment.cc deleted file mode 100644 index aeb2aa8bd1cc..000000000000 --- a/www/chromium/files/patch-remoting_host_basic__desktop__environment.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- remoting/host/basic_desktop_environment.cc.orig 2024-04-19 13:02:56 UTC -+++ remoting/host/basic_desktop_environment.cc -@@ -195,7 +195,7 @@ std::unique_ptr<DesktopCapturer> BasicDesktopEnvironme - scoped_refptr<base::SingleThreadTaskRunner> capture_task_runner; - #if BUILDFLAG(IS_CHROMEOS_ASH) - capture_task_runner = ui_task_runner_; --#elif BUILDFLAG(IS_LINUX) && defined(REMOTING_USE_WAYLAND) -+#elif (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(REMOTING_USE_WAYLAND) - // Each capturer instance should get its own thread so the capturers don't - // compete with each other in multistream mode. - capture_task_runner = base::ThreadPool::CreateSingleThreadTaskRunner( diff --git a/www/chromium/files/patch-remoting_host_chromoting__host.cc b/www/chromium/files/patch-remoting_host_chromoting__host.cc index c0888ea9d898..c25608fb6117 100644 --- a/www/chromium/files/patch-remoting_host_chromoting__host.cc +++ b/www/chromium/files/patch-remoting_host_chromoting__host.cc @@ -1,6 +1,6 @@ ---- remoting/host/chromoting_host.cc.orig 2024-02-23 21:04:38 UTC +--- remoting/host/chromoting_host.cc.orig 2025-07-02 06:08:04 UTC +++ remoting/host/chromoting_host.cc -@@ -129,7 +129,7 @@ void ChromotingHost::Start(const std::string& host_own +@@ -138,7 +138,7 @@ void ChromotingHost::Start(const std::string& host_own &ChromotingHost::OnIncomingSession, base::Unretained(this))); } diff --git a/www/chromium/files/patch-remoting_host_chromoting__host.h b/www/chromium/files/patch-remoting_host_chromoting__host.h index 414fcdd25ef1..0384066d46a6 100644 --- a/www/chromium/files/patch-remoting_host_chromoting__host.h +++ b/www/chromium/files/patch-remoting_host_chromoting__host.h @@ -1,6 +1,6 @@ ---- remoting/host/chromoting_host.h.orig 2023-09-13 12:11:42 UTC +--- remoting/host/chromoting_host.h.orig 2025-05-05 10:57:53 UTC +++ remoting/host/chromoting_host.h -@@ -32,7 +32,7 @@ +@@ -36,7 +36,7 @@ #include "remoting/protocol/session_manager.h" #include "remoting/protocol/transport_context.h" @@ -9,7 +9,7 @@ #include "remoting/host/chromoting_host_services_server.h" #endif -@@ -97,7 +97,7 @@ class ChromotingHost : public ClientSession::EventHand +@@ -112,7 +112,7 @@ class ChromotingHost : public ClientSession::EventHand // This method can only be called once during the lifetime of this object. void Start(const std::string& host_owner); @@ -18,7 +18,7 @@ // Starts running the ChromotingHostServices server and listening for incoming // IPC binding requests. // Currently only Linux runs the ChromotingHostServices server on the host -@@ -206,7 +206,7 @@ class ChromotingHost : public ClientSession::EventHand +@@ -222,7 +222,7 @@ class ChromotingHost : public ClientSession::EventHand // List of host extensions. std::vector<std::unique_ptr<HostExtension>> extensions_; diff --git a/www/chromium/files/patch-remoting_host_chromoting__host__context.cc b/www/chromium/files/patch-remoting_host_chromoting__host__context.cc index 52d08746e061..debfaf62d6ce 100644 --- a/www/chromium/files/patch-remoting_host_chromoting__host__context.cc +++ b/www/chromium/files/patch-remoting_host_chromoting__host__context.cc @@ -1,6 +1,6 @@ ---- remoting/host/chromoting_host_context.cc.orig 2023-08-17 07:33:31 UTC +--- remoting/host/chromoting_host_context.cc.orig 2025-04-04 08:52:13 UTC +++ remoting/host/chromoting_host_context.cc -@@ -294,7 +294,7 @@ std::unique_ptr<ChromotingHostContext> ChromotingHostC +@@ -335,7 +335,7 @@ std::unique_ptr<ChromotingHostContext> ChromotingHostC // on a UI thread. scoped_refptr<AutoThreadTaskRunner> input_task_runner = AutoThread::CreateWithType("ChromotingInputThread", ui_task_runner, diff --git a/www/chromium/files/patch-remoting_host_chromoting__host__services__client.cc b/www/chromium/files/patch-remoting_host_chromoting__host__services__client.cc index b94274aa680a..f7f9101e2e32 100644 --- a/www/chromium/files/patch-remoting_host_chromoting__host__services__client.cc +++ b/www/chromium/files/patch-remoting_host_chromoting__host__services__client.cc @@ -1,15 +1,6 @@ ---- remoting/host/chromoting_host_services_client.cc.orig 2023-09-13 12:11:42 UTC +--- remoting/host/chromoting_host_services_client.cc.orig 2025-05-28 14:55:43 UTC +++ remoting/host/chromoting_host_services_client.cc -@@ -59,7 +59,7 @@ mojo::PendingRemote<mojom::ChromotingHostServices> Con - - } // namespace - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - - // static - constexpr char -@@ -136,7 +136,7 @@ bool ChromotingHostServicesClient::EnsureSessionServic +@@ -134,7 +134,7 @@ bool ChromotingHostServicesClient::EnsureSessionServic if (session_services_remote_.is_bound()) { return true; } diff --git a/www/chromium/files/patch-remoting_host_client__session.cc b/www/chromium/files/patch-remoting_host_client__session.cc index 7bfefc2ff724..39bc7665a847 100644 --- a/www/chromium/files/patch-remoting_host_client__session.cc +++ b/www/chromium/files/patch-remoting_host_client__session.cc @@ -1,7 +1,7 @@ ---- remoting/host/client_session.cc.orig 2024-04-19 13:02:56 UTC +--- remoting/host/client_session.cc.orig 2025-05-05 10:57:53 UTC +++ remoting/host/client_session.cc -@@ -161,7 +161,7 @@ void ClientSession::NotifyClientResolution( - if (desktop_environment_options_.enable_curtaining()) { +@@ -188,7 +188,7 @@ void ClientSession::NotifyClientResolution( + if (effective_policies_.curtain_required.value_or(false)) { dpi_vector.set(resolution.x_dpi(), resolution.y_dpi()); } -#elif BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-remoting_host_crash_crash__file__uploader.cc b/www/chromium/files/patch-remoting_host_crash_crash__file__uploader.cc new file mode 100644 index 000000000000..fcbb2aea270b --- /dev/null +++ b/www/chromium/files/patch-remoting_host_crash_crash__file__uploader.cc @@ -0,0 +1,11 @@ +--- remoting/host/crash/crash_file_uploader.cc.orig 2024-07-30 11:12:21 UTC ++++ remoting/host/crash/crash_file_uploader.cc +@@ -44,7 +44,7 @@ constexpr char kMinidumpFileName[] = "dump"; + + #if BUILDFLAG(IS_WIN) + constexpr char kProductNameValue[] = "Chromoting"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr char kProductNameValue[] = "Chromoting_Linux"; + #elif BUILDFLAG(IS_MAC) + constexpr char kProductNameValue[] = "Chromoting_Mac"; diff --git a/www/chromium/files/patch-remoting_host_desktop__and__cursor__conditional__composer.cc b/www/chromium/files/patch-remoting_host_desktop__and__cursor__conditional__composer.cc deleted file mode 100644 index 068778d8f5dc..000000000000 --- a/www/chromium/files/patch-remoting_host_desktop__and__cursor__conditional__composer.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- remoting/host/desktop_and_cursor_conditional_composer.cc.orig 2023-04-05 11:05:06 UTC -+++ remoting/host/desktop_and_cursor_conditional_composer.cc -@@ -7,7 +7,7 @@ - #include "base/functional/bind.h" - #include "build/build_config.h" - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "remoting/host/linux/wayland_utils.h" - #endif - -@@ -96,7 +96,7 @@ bool DesktopAndCursorConditionalComposer::IsOccluded( - } - - bool DesktopAndCursorConditionalComposer::SupportsFrameCallbacks() { --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return IsRunningWayland(); - #else - return false; diff --git a/www/chromium/files/patch-remoting_host_desktop__capturer__proxy.cc b/www/chromium/files/patch-remoting_host_desktop__capturer__proxy.cc deleted file mode 100644 index 98793b85de1a..000000000000 --- a/www/chromium/files/patch-remoting_host_desktop__capturer__proxy.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- remoting/host/desktop_capturer_proxy.cc.orig 2024-04-19 13:02:56 UTC -+++ remoting/host/desktop_capturer_proxy.cc -@@ -26,7 +26,7 @@ - #include "remoting/host/chromeos/frame_sink_desktop_capturer.h" - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "base/environment.h" - #include "base/nix/xdg_util.h" - #include "remoting/host/linux/wayland_desktop_capturer.h" -@@ -91,7 +91,7 @@ void DesktopCapturerProxy::Core::CreateCapturer( - - #if BUILDFLAG(IS_CHROMEOS_ASH) - capturer_ = std::make_unique<FrameSinkDesktopCapturer>(); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - static base::nix::SessionType session_type = base::nix::SessionType::kUnset; - if (session_type == base::nix::SessionType::kUnset) { - std::unique_ptr<base::Environment> env = base::Environment::Create(); -@@ -298,7 +298,7 @@ void DesktopCapturerProxy::OnMetadata(webrtc::DesktopC - bool DesktopCapturerProxy::SupportsFrameCallbacks() { - DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return IsRunningWayland(); - #else - return false; diff --git a/www/chromium/files/patch-remoting_host_desktop__capturer__wrapper.cc b/www/chromium/files/patch-remoting_host_desktop__capturer__wrapper.cc deleted file mode 100644 index a7b9a34f4d27..000000000000 --- a/www/chromium/files/patch-remoting_host_desktop__capturer__wrapper.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- remoting/host/desktop_capturer_wrapper.cc.orig 2024-04-19 13:02:56 UTC -+++ remoting/host/desktop_capturer_wrapper.cc -@@ -13,7 +13,7 @@ - #include "third_party/webrtc/modules/desktop_capture/desktop_capturer.h" - #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h" - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "remoting/host/linux/wayland_desktop_capturer.h" - #include "remoting/host/linux/wayland_utils.h" - #endif -@@ -33,7 +33,7 @@ void DesktopCapturerWrapper::CreateCapturer( - SourceId id) { - DCHECK(!capturer_); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (IsRunningWayland()) { - capturer_ = std::make_unique<WaylandDesktopCapturer>(options); - } else { -@@ -112,7 +112,7 @@ void DesktopCapturerWrapper::OnCaptureResult( - bool DesktopCapturerWrapper::SupportsFrameCallbacks() { - DCHECK_CALLED_ON_VALID_THREAD(thread_checker_); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return capturer_ && IsRunningWayland(); - #else - return false; diff --git a/www/chromium/files/patch-remoting_host_evaluate__capability.cc b/www/chromium/files/patch-remoting_host_evaluate__capability.cc index 336d7f574080..009a289e8925 100644 --- a/www/chromium/files/patch-remoting_host_evaluate__capability.cc +++ b/www/chromium/files/patch-remoting_host_evaluate__capability.cc @@ -1,6 +1,6 @@ ---- remoting/host/evaluate_capability.cc.orig 2022-02-28 16:54:41 UTC +--- remoting/host/evaluate_capability.cc.orig 2024-06-17 12:56:06 UTC +++ remoting/host/evaluate_capability.cc -@@ -55,7 +55,7 @@ base::FilePath BuildHostBinaryPath() { +@@ -56,7 +56,7 @@ base::FilePath BuildHostBinaryPath() { } #endif diff --git a/www/chromium/files/patch-remoting_host_host__attributes.cc b/www/chromium/files/patch-remoting_host_host__attributes.cc index c38988847578..2212d6af890c 100644 --- a/www/chromium/files/patch-remoting_host_host__attributes.cc +++ b/www/chromium/files/patch-remoting_host_host__attributes.cc @@ -1,6 +1,6 @@ ---- remoting/host/host_attributes.cc.orig 2024-01-30 07:53:34 UTC +--- remoting/host/host_attributes.cc.orig 2025-05-05 10:57:53 UTC +++ remoting/host/host_attributes.cc -@@ -104,7 +104,7 @@ std::string GetHostAttributes() { +@@ -103,7 +103,7 @@ std::string GetHostAttributes() { if (media::InitializeMediaFoundation()) { result.push_back("HWEncoder"); } diff --git a/www/chromium/files/patch-remoting_host_host__details.cc b/www/chromium/files/patch-remoting_host_host__details.cc index 556c96a8d502..99a9be9bde18 100644 --- a/www/chromium/files/patch-remoting_host_host__details.cc +++ b/www/chromium/files/patch-remoting_host_host__details.cc @@ -1,11 +1,29 @@ ---- remoting/host/host_details.cc.orig 2022-02-28 16:54:41 UTC +--- remoting/host/host_details.cc.orig 2025-03-05 08:14:56 UTC +++ remoting/host/host_details.cc -@@ -23,7 +23,7 @@ std::string GetHostOperatingSystemName() { +@@ -7,7 +7,7 @@ + #include "base/system/sys_info.h" + #include "build/build_config.h" + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "base/linux_util.h" + #endif + +@@ -22,7 +22,7 @@ std::string GetHostOperatingSystemName() { return "Mac"; - #elif BUILDFLAG(IS_CHROMEOS_ASH) + #elif BUILDFLAG(IS_CHROMEOS) return "ChromeOS"; --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return "Linux"; #elif BUILDFLAG(IS_ANDROID) return "Android"; +@@ -34,7 +34,7 @@ std::string GetHostOperatingSystemName() { + // Get the host Operating System Version, removing the need to check for OS + // definitions and keeps the format used consistent. + std::string GetHostOperatingSystemVersion() { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + return base::GetLinuxDistro(); + #else + return base::SysInfo::OperatingSystemVersion(); diff --git a/www/chromium/files/patch-remoting_host_host__main.cc b/www/chromium/files/patch-remoting_host_host__main.cc index da41449af3a3..58d7d8acece5 100644 --- a/www/chromium/files/patch-remoting_host_host__main.cc +++ b/www/chromium/files/patch-remoting_host_host__main.cc @@ -1,6 +1,6 @@ ---- remoting/host/host_main.cc.orig 2023-03-09 06:31:50 UTC +--- remoting/host/host_main.cc.orig 2025-07-02 06:08:04 UTC +++ remoting/host/host_main.cc -@@ -50,7 +50,7 @@ int FileChooserMain(); +@@ -57,7 +57,7 @@ int FileChooserMain(); int RdpDesktopSessionMain(); int UrlForwarderConfiguratorMain(); #endif // BUILDFLAG(IS_WIN) @@ -9,7 +9,7 @@ int XSessionChooserMain(); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -63,7 +63,7 @@ const char kUsageMessage[] = +@@ -70,7 +70,7 @@ const char kUsageMessage[] = "\n" "Options:\n" @@ -18,7 +18,7 @@ " --audio-pipe-name=<pipe> - Sets the pipe name to capture audio on " "Linux.\n" #endif // BUILDFLAG(IS_LINUX) -@@ -156,7 +156,7 @@ MainRoutineFn SelectMainRoutine(const std::string& pro +@@ -163,7 +163,7 @@ MainRoutineFn SelectMainRoutine(const std::string& pro } else if (process_type == kProcessTypeUrlForwarderConfigurator) { main_routine = &UrlForwarderConfiguratorMain; #endif // BUILDFLAG(IS_WIN) @@ -27,3 +27,12 @@ } else if (process_type == kProcessTypeXSessionChooser) { main_routine = &XSessionChooserMain; #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +@@ -231,7 +231,7 @@ int HostMain(int argc, char** argv) { + // Note that we enable crash reporting only if the user has opted in to having + // the crash reports uploaded. + if (IsUsageStatsAllowed()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + // TODO: joedow - Enable crash reporting for the RDP process. diff --git a/www/chromium/files/patch-remoting_host_ipc__constants.cc b/www/chromium/files/patch-remoting_host_ipc__constants.cc index 157a0d647307..c36ecb328356 100644 --- a/www/chromium/files/patch-remoting_host_ipc__constants.cc +++ b/www/chromium/files/patch-remoting_host_ipc__constants.cc @@ -1,4 +1,4 @@ ---- remoting/host/ipc_constants.cc.orig 2023-02-08 09:03:45 UTC +--- remoting/host/ipc_constants.cc.orig 2024-11-14 07:57:23 UTC +++ remoting/host/ipc_constants.cc @@ -17,7 +17,7 @@ namespace remoting { @@ -9,7 +9,7 @@ #if !defined(NDEBUG) // Use a different IPC name for debug builds so that we can run the host -@@ -68,7 +68,7 @@ GetChromotingHostServicesServerName() { +@@ -81,7 +81,7 @@ GetChromotingHostServicesServerName() { static const base::NoDestructor<mojo::NamedPlatformChannel::ServerName> server_name( named_mojo_ipc_server::WorkingDirectoryIndependentServerNameFromUTF8( diff --git a/www/chromium/files/patch-remoting_host_it2me_it2me__host.cc b/www/chromium/files/patch-remoting_host_it2me_it2me__host.cc deleted file mode 100644 index fbe62316c189..000000000000 --- a/www/chromium/files/patch-remoting_host_it2me_it2me__host.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- remoting/host/it2me/it2me_host.cc.orig 2024-01-30 07:53:34 UTC -+++ remoting/host/it2me/it2me_host.cc -@@ -52,7 +52,7 @@ - #include "remoting/host/chromeos/features.h" - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "remoting/host/linux/wayland_manager.h" - #include "remoting/host/linux/wayland_utils.h" - #endif // BUILDFLAG(IS_LINUX) -@@ -178,7 +178,7 @@ void It2MeHost::Connect( - - OnPolicyUpdate(std::move(policies)); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (IsRunningWayland()) { - WaylandManager::Get()->Init(host_context_->ui_task_runner()); - } -@@ -338,7 +338,7 @@ void It2MeHost::ConnectOnNetworkThread( - - // Set up the desktop environment options. - DesktopEnvironmentOptions options(DesktopEnvironmentOptions::CreateDefault()); --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (IsRunningWayland()) { - options.desktop_capture_options()->set_prefer_cursor_embedded(true); - } diff --git a/www/chromium/files/patch-remoting_host_it2me_it2me__native__messaging__host__main.cc b/www/chromium/files/patch-remoting_host_it2me_it2me__native__messaging__host__main.cc index 3caee70e7511..a09216de154f 100644 --- a/www/chromium/files/patch-remoting_host_it2me_it2me__native__messaging__host__main.cc +++ b/www/chromium/files/patch-remoting_host_it2me_it2me__native__messaging__host__main.cc @@ -1,6 +1,6 @@ ---- remoting/host/it2me/it2me_native_messaging_host_main.cc.orig 2023-09-13 12:11:42 UTC +--- remoting/host/it2me/it2me_native_messaging_host_main.cc.orig 2025-07-02 06:08:04 UTC +++ remoting/host/it2me/it2me_native_messaging_host_main.cc -@@ -30,7 +30,7 @@ +@@ -29,7 +29,7 @@ #include "remoting/host/resources.h" #include "remoting/host/usage_stats_consent.h" @@ -9,16 +9,34 @@ #if defined(REMOTING_USE_X11) #include <gtk/gtk.h> #include "base/linux_util.h" -@@ -77,7 +77,7 @@ bool CurrentProcessHasUiAccess() { +@@ -43,7 +43,7 @@ + #include "remoting/host/mac/permission_utils.h" + #endif // BUILDFLAG(IS_APPLE) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "remoting/base/crash/crash_reporting_crashpad.h" + #endif // BUILDFLAG(IS_LINUX) + +@@ -79,7 +79,7 @@ bool CurrentProcessHasUiAccess() { // Creates a It2MeNativeMessagingHost instance, attaches it to stdin/stdout and // runs the task executor until It2MeNativeMessagingHost signals shutdown. int It2MeNativeMessagingHostMain(int argc, char** argv) { -#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && defined(REMOTING_USE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && defined(REMOTING_USE_X11) - if (!IsRunningWayland()) { - // Initialize Xlib for multi-threaded use, allowing non-Chromium code to - // use X11 safely (such as the WebRTC capturer, GTK ...) -@@ -125,7 +125,7 @@ int It2MeNativeMessagingHostMain(int argc, char** argv + // Initialize Xlib for multi-threaded use, allowing non-Chromium code to + // use X11 safely (such as the WebRTC capturer, GTK ...) + x11::InitXlib(); +@@ -104,7 +104,7 @@ int It2MeNativeMessagingHostMain(int argc, char** argv + // needs to be initialized first, so that the preference for crash-reporting + // can be looked up in the config file. + if (IsUsageStatsAllowed()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + InitializeBreakpadReporting(); +@@ -129,7 +129,7 @@ int It2MeNativeMessagingHostMain(int argc, char** argv remoting::LoadResources(""); @@ -34,14 +52,14 @@ -#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && defined(REMOTING_USE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && defined(REMOTING_USE_X11) scoped_refptr<AutoThreadTaskRunner> input_task_runner; - if (!IsRunningWayland()) { - // Create an X11EventSource on all UI threads, so the global X11 connection -@@ -284,7 +284,7 @@ int It2MeNativeMessagingHostMain(int argc, char** argv + // Create an X11EventSource on all UI threads, so the global X11 connection + // (x11::Connection::Get()) can dispatch X events. +@@ -281,7 +281,7 @@ int It2MeNativeMessagingHostMain(int argc, char** argv // Run the loop until channel is alive. run_loop.Run(); -#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && defined(REMOTING_USE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && defined(REMOTING_USE_X11) - if (!IsRunningWayland()) { - input_task_runner->PostTask(FROM_HERE, base::BindOnce([]() { - delete ui::X11EventSource::GetInstance(); + input_task_runner->PostTask(FROM_HERE, base::BindOnce([]() { + delete ui::X11EventSource::GetInstance(); + })); diff --git a/www/chromium/files/patch-remoting_host_me2me__desktop__environment.cc b/www/chromium/files/patch-remoting_host_me2me__desktop__environment.cc index ca0aac87c93b..1be89b8b6748 100644 --- a/www/chromium/files/patch-remoting_host_me2me__desktop__environment.cc +++ b/www/chromium/files/patch-remoting_host_me2me__desktop__environment.cc @@ -1,15 +1,15 @@ ---- remoting/host/me2me_desktop_environment.cc.orig 2024-01-30 07:53:34 UTC +--- remoting/host/me2me_desktop_environment.cc.orig 2025-04-04 08:52:13 UTC +++ remoting/host/me2me_desktop_environment.cc -@@ -125,7 +125,7 @@ std::string Me2MeDesktopEnvironment::GetCapabilities() +@@ -112,7 +112,7 @@ std::string Me2MeDesktopEnvironment::GetCapabilities() capabilities += protocol::kRemoteWebAuthnCapability; } -#if BUILDFLAG(IS_LINUX) && defined(REMOTING_USE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && defined(REMOTING_USE_X11) - if (!IsRunningWayland()) { - capabilities += " "; - capabilities += protocol::kMultiStreamCapability; -@@ -164,7 +164,7 @@ Me2MeDesktopEnvironment::Me2MeDesktopEnvironment( + capabilities += " "; + capabilities += protocol::kMultiStreamCapability; + +@@ -150,7 +150,7 @@ Me2MeDesktopEnvironment::Me2MeDesktopEnvironment( // properly under Xvfb. mutable_desktop_capture_options()->set_use_update_notifications(true); @@ -18,16 +18,7 @@ // Setting this option to false means that the capture differ wrapper will not // be used when the X11 capturer is selected. This reduces the X11 capture // time by a few milliseconds per frame and is safe because we can rely on -@@ -173,7 +173,7 @@ Me2MeDesktopEnvironment::Me2MeDesktopEnvironment( - mutable_desktop_capture_options()->set_detect_updated_region(false); - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (IsRunningWayland()) { - mutable_desktop_capture_options()->set_prefer_cursor_embedded(false); - } -@@ -198,7 +198,7 @@ bool Me2MeDesktopEnvironment::InitializeSecurity( +@@ -178,7 +178,7 @@ bool Me2MeDesktopEnvironment::InitializeSecurity( // Otherwise, if the session is shared with the local user start monitoring // the local input and create the in-session UI. diff --git a/www/chromium/files/patch-remoting_host_mojo__caller__security__checker.cc b/www/chromium/files/patch-remoting_host_mojo__caller__security__checker.cc new file mode 100644 index 000000000000..c6ec262e4f71 --- /dev/null +++ b/www/chromium/files/patch-remoting_host_mojo__caller__security__checker.cc @@ -0,0 +1,29 @@ +--- remoting/host/mojo_caller_security_checker.cc.orig 2025-05-28 14:55:43 UTC ++++ remoting/host/mojo_caller_security_checker.cc +@@ -32,7 +32,7 @@ + namespace remoting { + namespace { + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr auto kAllowedCallerProgramNames = + base::MakeFixedFlatSet<base::FilePath::StringViewType>({ + "remote-open-url", +@@ -60,7 +60,7 @@ bool IsTrustedMojoEndpoint( + const named_mojo_ipc_server::ConnectionInfo& caller) { + #if BUILDFLAG(IS_MAC) + return IsProcessTrusted(caller.audit_token, kAllowedIdentifiers); +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + + // TODO: yuweih - see if it's possible to move away from PID-based security + // checks, which might be susceptible of PID reuse attacks. +@@ -84,7 +84,7 @@ bool IsTrustedMojoEndpoint( + base::FilePath::StringType program_name = + caller_process_image_path.BaseName().value(); + if (!kAllowedCallerProgramNames.contains(program_name)) { +-#if BUILDFLAG(IS_LINUX) && !defined(NDEBUG) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !defined(NDEBUG) + // Linux binaries generated in out/Debug are underscore-separated. To make + // debugging easier, we just check the name again with underscores replaced + // with hyphens. diff --git a/www/chromium/files/patch-remoting_host_mouse__cursor__monitor__proxy.cc b/www/chromium/files/patch-remoting_host_mouse__cursor__monitor__proxy.cc deleted file mode 100644 index 7df8f30e6638..000000000000 --- a/www/chromium/files/patch-remoting_host_mouse__cursor__monitor__proxy.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- remoting/host/mouse_cursor_monitor_proxy.cc.orig 2023-03-09 06:31:50 UTC -+++ remoting/host/mouse_cursor_monitor_proxy.cc -@@ -73,7 +73,7 @@ void MouseCursorMonitorProxy::Core::CreateMouseCursorM - - #if BUILDFLAG(IS_CHROMEOS_ASH) - mouse_cursor_monitor_ = std::make_unique<MouseCursorMonitorAura>(); --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (IsRunningWayland()) { - mouse_cursor_monitor_ = webrtc::MouseCursorMonitor::Create(options); - } else { diff --git a/www/chromium/files/patch-remoting_host_policy__watcher.cc b/www/chromium/files/patch-remoting_host_policy__watcher.cc index b336657e2dd6..a28e2243f3fc 100644 --- a/www/chromium/files/patch-remoting_host_policy__watcher.cc +++ b/www/chromium/files/patch-remoting_host_policy__watcher.cc @@ -1,8 +1,8 @@ ---- remoting/host/policy_watcher.cc.orig 2024-03-22 08:19:40 UTC +--- remoting/host/policy_watcher.cc.orig 2025-05-28 14:55:43 UTC +++ remoting/host/policy_watcher.cc -@@ -192,7 +192,7 @@ base::Value::Dict PolicyWatcher::GetDefaultPolicies() - true); +@@ -182,7 +182,7 @@ base::Value::Dict PolicyWatcher::GetDefaultPolicies() result.Set(key::kRemoteAccessHostAllowEnterpriseFileTransfer, false); + result.Set(key::kClassManagementEnabled, "disabled"); #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-remoting_host_remote__open__url_remote__open__url__main.cc b/www/chromium/files/patch-remoting_host_remote__open__url_remote__open__url__main.cc new file mode 100644 index 000000000000..f891d8f486cf --- /dev/null +++ b/www/chromium/files/patch-remoting_host_remote__open__url_remote__open__url__main.cc @@ -0,0 +1,20 @@ +--- remoting/host/remote_open_url/remote_open_url_main.cc.orig 2025-07-02 06:08:04 UTC ++++ remoting/host/remote_open_url/remote_open_url_main.cc +@@ -27,7 +27,7 @@ + #include "remoting/host/usage_stats_consent.h" + #include "ui/base/l10n/l10n_util.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "remoting/base/crash/crash_reporting_crashpad.h" + #endif // BUILDFLAG(IS_LINUX) + +@@ -51,7 +51,7 @@ int RemoteOpenUrlMain(int argc, char** argv) { + + #if defined(REMOTING_ENABLE_CRASH_REPORTING) + if (IsUsageStatsAllowed()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + InitializeBreakpadReporting(); diff --git a/www/chromium/files/patch-remoting_host_remoting__me2me__host.cc b/www/chromium/files/patch-remoting_host_remoting__me2me__host.cc index cffbd690e459..f5bc389e9c67 100644 --- a/www/chromium/files/patch-remoting_host_remoting__me2me__host.cc +++ b/www/chromium/files/patch-remoting_host_remoting__me2me__host.cc @@ -1,6 +1,6 @@ ---- remoting/host/remoting_me2me_host.cc.orig 2024-04-19 13:02:56 UTC +--- remoting/host/remoting_me2me_host.cc.orig 2025-07-02 06:08:04 UTC +++ remoting/host/remoting_me2me_host.cc -@@ -132,7 +132,7 @@ +@@ -139,7 +139,7 @@ #include "remoting/host/mac/permission_utils.h" #endif // BUILDFLAG(IS_APPLE) @@ -8,33 +8,26 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #if defined(REMOTING_USE_X11) #include <gtk/gtk.h> - #endif // defined(REMOTING_USE_X11) -@@ -143,13 +143,13 @@ + +@@ -149,7 +149,7 @@ #endif // defined(REMOTING_USE_X11) #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "base/linux_util.h" - #include "remoting/host/audio_capturer_linux.h" + #include "remoting/host/linux/audio_capturer_linux.h" #include "remoting/host/linux/certificate_watcher.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "remoting/host/host_utmp_logger.h" - #endif - -@@ -162,7 +162,7 @@ - #include "remoting/host/win/session_desktop_environment.h" +@@ -164,7 +164,7 @@ + #include "remoting/host/pairing_registry_delegate_win.h" #endif // BUILDFLAG(IS_WIN) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "remoting/host/linux/wayland_manager.h" - #include "remoting/host/linux/wayland_utils.h" + #include "remoting/base/crash/crash_reporting_crashpad.h" + #include "remoting/host/host_wtmpdb_logger.h" #endif // BUILDFLAG(IS_LINUX) -@@ -192,7 +192,7 @@ const char kApplicationName[] = "chromoting"; +@@ -198,7 +198,7 @@ const char kApplicationName[] = "chromoting"; const char kStdinConfigPath[] = "-"; #endif // !defined(REMOTING_MULTI_PROCESS) @@ -43,25 +36,25 @@ // The command line switch used to pass name of the pipe to capture audio on // linux. const char kAudioPipeSwitchName[] = "audio-pipe-name"; -@@ -401,7 +401,7 @@ class HostProcess : public ConfigWatcher::Delegate, - - std::unique_ptr<ChromotingHostContext> context_; +@@ -447,7 +447,7 @@ class HostProcess : public ConfigWatcher::Delegate, + std::unique_ptr<AgentProcessBrokerClient> agent_process_broker_client_; + #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Watch for certificate changes and kill the host when changes occur std::unique_ptr<CertificateWatcher> cert_watcher_; #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -471,7 +471,7 @@ class HostProcess : public ConfigWatcher::Delegate, +@@ -512,7 +512,7 @@ class HostProcess : public ConfigWatcher::Delegate, + std::unique_ptr<FtlEchoMessageListener> ftl_echo_message_listener_; - std::unique_ptr<HostStatusLogger> host_status_logger_; std::unique_ptr<HostEventLogger> host_event_logger_; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - std::unique_ptr<HostUTMPLogger> host_utmp_logger_; + std::unique_ptr<HostWtmpdbLogger> host_wtmpdb_logger_; #endif std::unique_ptr<HostPowerSaveBlocker> power_save_blocker_; -@@ -783,7 +783,7 @@ void HostProcess::StartOnNetworkThread() { +@@ -839,7 +839,7 @@ void HostProcess::StartOnNetworkThread() { void HostProcess::ShutdownOnNetworkThread() { DCHECK(context_->network_task_runner()->BelongsToCurrentThread()); config_watcher_.reset(); @@ -70,32 +63,25 @@ cert_watcher_.reset(); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) } -@@ -849,7 +849,7 @@ void HostProcess::CreateAuthenticatorFactory() { - DCHECK(third_party_auth_config_.token_url.is_valid()); - DCHECK(third_party_auth_config_.token_validation_url.is_valid()); +@@ -916,7 +916,7 @@ void HostProcess::CreateAuthenticatorFactory() { + context_->create_client_cert_store_callback(), + service_account_email_, oauth_refresh_token_)); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) if (!cert_watcher_) { cert_watcher_ = std::make_unique<CertificateWatcher>( base::BindRepeating(&HostProcess::ShutdownHost, -@@ -974,13 +974,13 @@ void HostProcess::StartOnUiThread() { +@@ -1058,7 +1058,7 @@ void HostProcess::StartOnUiThread() { base::BindRepeating(&HostProcess::OnPolicyUpdate, base::Unretained(this)), base::BindRepeating(&HostProcess::OnPolicyError, base::Unretained(this))); --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (IsRunningWayland()) { - WaylandManager::Get()->Init(context_->ui_task_runner()); - } - #endif // BUILDFLAG(IS_LINUX) - -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // If an audio pipe is specific on the command-line then initialize // AudioCapturerLinux to capture from it. base::FilePath audio_pipe_name = -@@ -1052,7 +1052,7 @@ void HostProcess::ShutdownOnUiThread() { +@@ -1137,7 +1137,7 @@ void HostProcess::ShutdownOnUiThread() { // It is now safe for the HostProcess to be deleted. self_ = nullptr; @@ -104,7 +90,7 @@ // Cause the global AudioPipeReader to be freed, otherwise the audio // thread will remain in-use and prevent the process from exiting. // TODO(wez): DesktopEnvironmentFactory should own the pipe reader. -@@ -1060,7 +1060,7 @@ void HostProcess::ShutdownOnUiThread() { +@@ -1145,7 +1145,7 @@ void HostProcess::ShutdownOnUiThread() { AudioCapturerLinux::InitializePipeReader(nullptr, base::FilePath()); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -113,43 +99,25 @@ context_->input_task_runner()->PostTask( FROM_HERE, base::BindOnce([]() { delete ui::X11EventSource::GetInstance(); })); -@@ -1418,7 +1418,7 @@ bool HostProcess::OnUsernamePolicyUpdate(const base::V - // Returns false: never restart the host after this policy update. - DCHECK(context_->network_task_runner()->BelongsToCurrentThread()); - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) - std::optional<bool> host_username_match_required = - policies.FindBool(policy::key::kRemoteAccessHostMatchUsername); - if (!host_username_match_required.has_value()) { -@@ -1882,7 +1882,7 @@ void HostProcess::StartHost() { - corp_host_status_logger_->StartObserving(*session_manager); - } - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) - desktop_environment_options_.set_enable_remote_webauthn(is_googler_); - #endif +@@ -1928,7 +1928,7 @@ void HostProcess::StartHost() { -@@ -1915,7 +1915,7 @@ void HostProcess::StartHost() { - host_status_logger_ = std::make_unique<HostStatusLogger>( - host_->status_monitor(), log_to_server_.get()); + host_->AddExtension(std::make_unique<TestEchoExtension>()); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) const base::CommandLine* cmd_line = base::CommandLine::ForCurrentProcess(); - if (cmd_line->HasSwitch(kEnableUtempter)) { - host_utmp_logger_ = -@@ -1947,7 +1947,7 @@ void HostProcess::StartHost() { - - host_->Start(host_owner_); + if (cmd_line->HasSwitch(kEnableWtmpdb)) { + host_wtmpdb_logger_ = +@@ -1964,7 +1964,7 @@ void HostProcess::StartHost() { + // addresses. + host_->Start(*host_owner_emails_.begin()); -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // For Windows, ChromotingHostServices connections are handled by the daemon - // process, then the message pipe is forwarded to the network process. + // For Windows and Mac, ChromotingHostServices connections are handled by + // another process, then the message pipe is forwarded to the network process. host_->StartChromotingHostServices(); -@@ -2081,7 +2081,7 @@ int HostProcessMain() { +@@ -2109,7 +2109,7 @@ int HostProcessMain() { HOST_LOG << "Starting host process: version " << STRINGIZE(VERSION); const base::CommandLine* cmd_line = base::CommandLine::ForCurrentProcess(); @@ -158,7 +126,16 @@ #if defined(REMOTING_USE_X11) // Initialize Xlib for multi-threaded use, allowing non-Chromium code to // use X11 safely (such as the WebRTC capturer, GTK ...) -@@ -2130,7 +2130,7 @@ int HostProcessMain() { +@@ -2154,7 +2154,7 @@ int HostProcessMain() { + return kInitializationFailed; + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Log and cleanup the crash database. We do this after a short delay so that + // the crash database has a chance to be updated properly if we just got + // relaunched after a crash. +@@ -2174,7 +2174,7 @@ int HostProcessMain() { std::unique_ptr<net::NetworkChangeNotifier> network_change_notifier( net::NetworkChangeNotifier::CreateIfNeeded()); diff --git a/www/chromium/files/patch-remoting_host_security__key_remote__security__key__main.cc b/www/chromium/files/patch-remoting_host_security__key_remote__security__key__main.cc new file mode 100644 index 000000000000..1722d9754624 --- /dev/null +++ b/www/chromium/files/patch-remoting_host_security__key_remote__security__key__main.cc @@ -0,0 +1,20 @@ +--- remoting/host/security_key/remote_security_key_main.cc.orig 2025-07-02 06:08:04 UTC ++++ remoting/host/security_key/remote_security_key_main.cc +@@ -24,7 +24,7 @@ + #include "remoting/host/security_key/security_key_message_handler.h" + #include "remoting/host/usage_stats_consent.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "remoting/base/crash/crash_reporting_crashpad.h" + #endif // BUILDFLAG(IS_LINUX) + +@@ -96,7 +96,7 @@ int RemoteSecurityKeyMain(int argc, char** argv) { + + #if defined(REMOTING_ENABLE_CRASH_REPORTING) + if (IsUsageStatsAllowed()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + InitializeBreakpadReporting(); diff --git a/www/chromium/files/patch-remoting_host_session__policies__from__dict.cc b/www/chromium/files/patch-remoting_host_session__policies__from__dict.cc new file mode 100644 index 000000000000..37bdc2cbc5a3 --- /dev/null +++ b/www/chromium/files/patch-remoting_host_session__policies__from__dict.cc @@ -0,0 +1,11 @@ +--- remoting/host/session_policies_from_dict.cc.orig 2025-05-05 10:57:53 UTC ++++ remoting/host/session_policies_from_dict.cc +@@ -75,7 +75,7 @@ std::optional<SessionPolicies> SessionPoliciesFromDict + session_policies.curtain_required = + dict.FindBool(policy::key::kRemoteAccessHostRequireCurtain); + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + session_policies.host_username_match_required = + dict.FindBool(policy::key::kRemoteAccessHostMatchUsername); + #endif diff --git a/www/chromium/files/patch-remoting_host_setup_me2me__native__messaging__host__main.cc b/www/chromium/files/patch-remoting_host_setup_me2me__native__messaging__host__main.cc new file mode 100644 index 000000000000..ce5e6c9829d5 --- /dev/null +++ b/www/chromium/files/patch-remoting_host_setup_me2me__native__messaging__host__main.cc @@ -0,0 +1,20 @@ +--- remoting/host/setup/me2me_native_messaging_host_main.cc.orig 2025-07-02 06:08:04 UTC ++++ remoting/host/setup/me2me_native_messaging_host_main.cc +@@ -41,7 +41,7 @@ + #include "base/apple/scoped_nsautorelease_pool.h" + #endif // BUILDFLAG(IS_APPLE) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "remoting/base/crash/crash_reporting_crashpad.h" + #endif // BUILDFLAG(IS_LINUX) + +@@ -99,7 +99,7 @@ int Me2MeNativeMessagingHostMain(int argc, char** argv + // needs to be initialized first, so that the preference for crash-reporting + // can be looked up in the config file. + if (IsUsageStatsAllowed()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + InitializeBreakpadReporting(); diff --git a/www/chromium/files/patch-remoting_host_setup_start__host__main.cc b/www/chromium/files/patch-remoting_host_setup_start__host__main.cc index 88b9949d78c0..2ef68f477eaf 100644 --- a/www/chromium/files/patch-remoting_host_setup_start__host__main.cc +++ b/www/chromium/files/patch-remoting_host_setup_start__host__main.cc @@ -1,15 +1,15 @@ ---- remoting/host/setup/start_host_main.cc.orig 2024-02-23 21:04:38 UTC +--- remoting/host/setup/start_host_main.cc.orig 2025-07-02 06:08:04 UTC +++ remoting/host/setup/start_host_main.cc -@@ -36,7 +36,7 @@ +@@ -44,7 +44,7 @@ #include <unistd.h> #endif // BUILDFLAG(IS_POSIX) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "remoting/base/crash/crash_reporting_crashpad.h" #include "remoting/host/setup/daemon_controller_delegate_linux.h" #include "remoting/host/setup/start_host_as_root.h" - #endif // BUILDFLAG(IS_LINUX) -@@ -252,7 +252,7 @@ bool InitializeCorpMachineParams(HostStarter::Params& +@@ -370,7 +370,7 @@ bool InitializeCloudMachineParams(HostStarter::Params& } // namespace int StartHostMain(int argc, char** argv) { @@ -18,7 +18,7 @@ // Minimize the amount of code that runs as root on Posix systems. if (getuid() == 0) { return remoting::StartHostAsRoot(argc, argv); -@@ -283,7 +283,7 @@ int StartHostMain(int argc, char** argv) { +@@ -395,7 +395,7 @@ int StartHostMain(int argc, char** argv) { mojo::core::Init(); @@ -27,3 +27,12 @@ if (command_line->HasSwitch("no-start")) { // On Linux, registering the host with systemd and starting it is the only // reason start_host requires root. The --no-start options skips that final +@@ -445,7 +445,7 @@ int StartHostMain(int argc, char** argv) { + // We don't have a config file yet so we can't use IsUsageStatsAllowed(), + // instead we can just check the command line parameter. + if (params.enable_crash_reporting) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + InitializeBreakpadReporting(); diff --git a/www/chromium/files/patch-remoting_host_webauthn_desktop__session__type__util.cc b/www/chromium/files/patch-remoting_host_webauthn_desktop__session__type__util.cc new file mode 100644 index 000000000000..f344f53751c9 --- /dev/null +++ b/www/chromium/files/patch-remoting_host_webauthn_desktop__session__type__util.cc @@ -0,0 +1,20 @@ +--- remoting/host/webauthn/desktop_session_type_util.cc.orig 2025-05-28 14:55:43 UTC ++++ remoting/host/webauthn/desktop_session_type_util.cc +@@ -11,7 +11,7 @@ + namespace remoting { + namespace { + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + DesktopSessionType GetDesktopSessionTypeInternal( + std::unique_ptr<base::Environment> environment) { + // Currently on Linux, a desktop session is either remote-only or local-only. +@@ -29,7 +29,7 @@ DesktopSessionType GetDesktopSessionTypeInternal( + } // namespace + + DesktopSessionType GetDesktopSessionType() { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + static const DesktopSessionType desktop_session_type = + GetDesktopSessionTypeInternal(base::Environment::Create()); + return desktop_session_type; diff --git a/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__caller__security__utils.cc b/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__caller__security__utils.cc index b63d09507ae9..b9da889b82e8 100644 --- a/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__caller__security__utils.cc +++ b/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__caller__security__utils.cc @@ -1,6 +1,6 @@ ---- remoting/host/webauthn/remote_webauthn_caller_security_utils.cc.orig 2024-01-30 07:53:34 UTC +--- remoting/host/webauthn/remote_webauthn_caller_security_utils.cc.orig 2025-05-28 14:55:43 UTC +++ remoting/host/webauthn/remote_webauthn_caller_security_utils.cc -@@ -10,7 +10,7 @@ +@@ -14,7 +14,7 @@ #include "base/strings/utf_string_conversions.h" #include "build/build_config.h" @@ -8,8 +8,8 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) #include "base/containers/fixed_flat_set.h" #include "base/files/file_path.h" - #include "base/process/process_handle.h" -@@ -38,7 +38,7 @@ namespace { + #include "remoting/host/base/process_util.h" +@@ -48,7 +48,7 @@ namespace { // No static variables needed for debug builds. @@ -17,8 +17,8 @@ +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) constexpr auto kAllowedCallerPrograms = - base::MakeFixedFlatSet<base::FilePath::StringPieceType>({ -@@ -82,7 +82,7 @@ bool IsLaunchedByTrustedProcess() { + base::MakeFixedFlatSet<base::FilePath::StringViewType>({ +@@ -99,7 +99,7 @@ bool IsLaunchedByTrustedProcess() { #if !defined(NDEBUG) // Just return true on debug builds for the convenience of development. return true; diff --git a/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__extension__notifier.cc b/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__extension__notifier.cc index 3375e977def2..bde200049f1f 100644 --- a/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__extension__notifier.cc +++ b/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__extension__notifier.cc @@ -1,6 +1,6 @@ ---- remoting/host/webauthn/remote_webauthn_extension_notifier.cc.orig 2023-02-08 09:03:45 UTC +--- remoting/host/webauthn/remote_webauthn_extension_notifier.cc.orig 2025-07-02 06:08:04 UTC +++ remoting/host/webauthn/remote_webauthn_extension_notifier.cc -@@ -24,7 +24,7 @@ +@@ -27,7 +27,7 @@ #include "base/task/thread_pool.h" #include "build/build_config.h" @@ -9,7 +9,7 @@ #include "base/environment.h" #include "base/nix/xdg_util.h" #include "base/strings/string_util.h" -@@ -69,14 +69,14 @@ static constexpr char kExtensionWakeupFileContent[] = +@@ -72,14 +72,14 @@ static constexpr char kExtensionWakeupFileContent[] = // Caller should check if the directory exists before writing files to it. A // directory only exists if the corresponding Chrome version is installed. std::vector<base::FilePath> GetRemoteStateChangeDirPaths() { diff --git a/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__main.cc b/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__main.cc new file mode 100644 index 000000000000..df0429a6408a --- /dev/null +++ b/www/chromium/files/patch-remoting_host_webauthn_remote__webauthn__main.cc @@ -0,0 +1,20 @@ +--- remoting/host/webauthn/remote_webauthn_main.cc.orig 2025-07-02 06:08:04 UTC ++++ remoting/host/webauthn/remote_webauthn_main.cc +@@ -27,7 +27,7 @@ + #include "remoting/host/webauthn/remote_webauthn_caller_security_utils.h" + #include "remoting/host/webauthn/remote_webauthn_native_messaging_host.h" + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "remoting/base/crash/crash_reporting_crashpad.h" + #endif // BUILDFLAG(IS_LINUX) + +@@ -50,7 +50,7 @@ int RemoteWebAuthnMain(int argc, char** argv) { + + #if defined(REMOTING_ENABLE_CRASH_REPORTING) + if (IsUsageStatsAllowed()) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + InitializeCrashpadReporting(); + #elif BUILDFLAG(IS_WIN) + InitializeBreakpadReporting(); diff --git a/www/chromium/files/patch-remoting_protocol_webrtc__video__stream.cc b/www/chromium/files/patch-remoting_protocol_webrtc__video__stream.cc index 212884c5469c..66e2af2f59cc 100644 --- a/www/chromium/files/patch-remoting_protocol_webrtc__video__stream.cc +++ b/www/chromium/files/patch-remoting_protocol_webrtc__video__stream.cc @@ -1,11 +1,11 @@ ---- remoting/protocol/webrtc_video_stream.cc.orig 2023-12-10 06:10:27 UTC +--- remoting/protocol/webrtc_video_stream.cc.orig 2025-03-05 08:14:56 UTC +++ remoting/protocol/webrtc_video_stream.cc -@@ -263,7 +263,7 @@ WebrtcVideoStream::WebrtcVideoStream(const std::string - : stream_name_(stream_name), session_options_(session_options) { +@@ -267,7 +267,7 @@ WebrtcVideoStream::WebrtcVideoStream(const SessionOpti + : session_options_(session_options) { // TODO(joedow): Dig into the threading model on other platforms to see if they // can also be updated to run on a dedicated thread. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) core_task_runner_ = base::ThreadPool::CreateSingleThreadTaskRunner( {base::TaskPriority::HIGHEST}, base::SingleThreadTaskRunnerThreadMode::DEDICATED); diff --git a/www/chromium/files/patch-remoting_signaling_ftl__host__device__id__provider.cc b/www/chromium/files/patch-remoting_signaling_ftl__host__device__id__provider.cc new file mode 100644 index 000000000000..a944a9226dbe --- /dev/null +++ b/www/chromium/files/patch-remoting_signaling_ftl__host__device__id__provider.cc @@ -0,0 +1,11 @@ +--- remoting/signaling/ftl_host_device_id_provider.cc.orig 2025-03-05 08:14:56 UTC ++++ remoting/signaling/ftl_host_device_id_provider.cc +@@ -16,7 +16,7 @@ constexpr char kDeviceIdPrefix[] = "crd-win-host-"; + constexpr char kDeviceIdPrefix[] = "crd-mac-host-"; + #elif BUILDFLAG(IS_CHROMEOS) + constexpr char kDeviceIdPrefix[] = "crd-cros-host-"; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr char kDeviceIdPrefix[] = "crd-linux-host-"; + #else + constexpr char kDeviceIdPrefix[] = "crd-unknown-host-"; diff --git a/www/chromium/files/patch-sandbox_linux_BUILD.gn b/www/chromium/files/patch-sandbox_linux_BUILD.gn index 5aa2a9351c39..6b3014a09e85 100644 --- a/www/chromium/files/patch-sandbox_linux_BUILD.gn +++ b/www/chromium/files/patch-sandbox_linux_BUILD.gn @@ -1,4 +1,4 @@ ---- sandbox/linux/BUILD.gn.orig 2023-08-17 07:33:31 UTC +--- sandbox/linux/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ sandbox/linux/BUILD.gn @@ -12,11 +12,11 @@ if (is_android) { } @@ -15,7 +15,7 @@ # On Android, use plain GTest. use_base_test_suite = is_linux || is_chromeos -@@ -379,6 +379,17 @@ component("sandbox_services") { +@@ -369,6 +369,17 @@ component("sandbox_services") { "services/libc_interceptor.h", ] } diff --git a/www/chromium/files/patch-sandbox_linux_services_init__process__reaper.cc b/www/chromium/files/patch-sandbox_linux_services_init__process__reaper.cc index 8ec351166a19..46e9d66c26e0 100644 --- a/www/chromium/files/patch-sandbox_linux_services_init__process__reaper.cc +++ b/www/chromium/files/patch-sandbox_linux_services_init__process__reaper.cc @@ -1,14 +1,14 @@ ---- sandbox/linux/services/init_process_reaper.cc.orig 2022-02-07 13:39:41 UTC +--- sandbox/linux/services/init_process_reaper.cc.orig 2025-03-05 08:14:56 UTC +++ sandbox/linux/services/init_process_reaper.cc -@@ -2,6 +2,7 @@ - // Use of this source code is governed by a BSD-style license that can be - // found in the LICENSE file. +@@ -7,6 +7,7 @@ + #pragma allow_unsafe_libc_calls + #endif +#if 0 #include "sandbox/linux/services/init_process_reaper.h" #include <signal.h> -@@ -100,3 +101,4 @@ bool CreateInitProcessReaper(base::OnceClosure post_fo +@@ -105,3 +106,4 @@ bool CreateInitProcessReaper(base::OnceClosure post_fo } } // namespace sandbox. diff --git a/www/chromium/files/patch-sandbox_linux_services_libc__interceptor.cc b/www/chromium/files/patch-sandbox_linux_services_libc__interceptor.cc index 7e6ee659c7ce..a5c167713139 100644 --- a/www/chromium/files/patch-sandbox_linux_services_libc__interceptor.cc +++ b/www/chromium/files/patch-sandbox_linux_services_libc__interceptor.cc @@ -1,6 +1,6 @@ ---- sandbox/linux/services/libc_interceptor.cc.orig 2023-09-13 12:11:42 UTC +--- sandbox/linux/services/libc_interceptor.cc.orig 2024-08-26 12:06:38 UTC +++ sandbox/linux/services/libc_interceptor.cc -@@ -12,7 +12,9 @@ +@@ -17,7 +17,9 @@ #include <stddef.h> #include <stdint.h> #include <string.h> @@ -10,7 +10,7 @@ #include <sys/socket.h> #include <sys/types.h> #include <time.h> -@@ -167,7 +169,7 @@ bool ReadTimeStruct(base::PickleIterator* iter, +@@ -173,7 +175,7 @@ bool ReadTimeStruct(base::PickleIterator* iter, } else { base::AutoLock lock(g_timezones_lock.Get()); auto ret_pair = g_timezones.Get().insert(timezone); diff --git a/www/chromium/files/patch-sandbox_policy_BUILD.gn b/www/chromium/files/patch-sandbox_policy_BUILD.gn index 08d40d1edcc8..8a0aafacdf7e 100644 --- a/www/chromium/files/patch-sandbox_policy_BUILD.gn +++ b/www/chromium/files/patch-sandbox_policy_BUILD.gn @@ -1,6 +1,6 @@ ---- sandbox/policy/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- sandbox/policy/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ sandbox/policy/BUILD.gn -@@ -49,7 +49,7 @@ component("policy") { +@@ -46,7 +46,7 @@ component("policy") { "//third_party/jni_zero", ] } @@ -9,7 +9,7 @@ sources += [ "linux/bpf_audio_policy_linux.cc", "linux/bpf_audio_policy_linux.h", -@@ -120,6 +120,27 @@ component("policy") { +@@ -115,6 +115,27 @@ component("policy") { "//sandbox/linux:sandbox_services", "//sandbox/linux:seccomp_bpf", "//sandbox/linux:suid_sandbox_client", @@ -36,4 +36,4 @@ + "//ui/gfx/x", ] } - if (is_chromeos_ash) { + if (is_chromeos) { diff --git a/www/chromium/files/patch-sandbox_policy_features.cc b/www/chromium/files/patch-sandbox_policy_features.cc index 41ef415278a9..a5ec08769523 100644 --- a/www/chromium/files/patch-sandbox_policy_features.cc +++ b/www/chromium/files/patch-sandbox_policy_features.cc @@ -1,6 +1,6 @@ ---- sandbox/policy/features.cc.orig 2024-04-19 13:02:56 UTC +--- sandbox/policy/features.cc.orig 2025-04-04 08:52:13 UTC +++ sandbox/policy/features.cc -@@ -20,7 +20,11 @@ namespace sandbox::policy::features { +@@ -19,7 +19,11 @@ namespace sandbox::policy::features { // (Only causes an effect when feature kNetworkServiceInProcess is disabled.) BASE_FEATURE(kNetworkServiceSandbox, "NetworkServiceSandbox", @@ -12,12 +12,3 @@ #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) // Enables a fine-grained seccomp-BPF syscall filter for the network service. -@@ -126,7 +130,7 @@ BASE_FEATURE(kForceSpectreVariant2Mitigation, - base::FEATURE_DISABLED_BY_DEFAULT); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Enabling the kNetworkServiceSandbox feature automatically enables Spectre - // variant 2 mitigations in the network service. This can lead to performance - // regressions, so enabling this feature will turn off the Spectre Variant 2 diff --git a/www/chromium/files/patch-sandbox_policy_features.h b/www/chromium/files/patch-sandbox_policy_features.h deleted file mode 100644 index a78f4fa38587..000000000000 --- a/www/chromium/files/patch-sandbox_policy_features.h +++ /dev/null @@ -1,11 +0,0 @@ ---- sandbox/policy/features.h.orig 2024-04-19 13:02:56 UTC -+++ sandbox/policy/features.h -@@ -43,7 +43,7 @@ SANDBOX_POLICY_EXPORT BASE_DECLARE_FEATURE(kSpectreVar - SANDBOX_POLICY_EXPORT BASE_DECLARE_FEATURE(kForceSpectreVariant2Mitigation); - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - SANDBOX_POLICY_EXPORT BASE_DECLARE_FEATURE( - kForceDisableSpectreVariant2MitigationInNetworkService); - diff --git a/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.cc b/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.cc index 73457e781f1f..28f8771959c2 100644 --- a/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.cc +++ b/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.cc @@ -1,6 +1,6 @@ ---- sandbox/policy/freebsd/sandbox_freebsd.cc.orig 2023-04-28 19:19:55 UTC +--- sandbox/policy/freebsd/sandbox_freebsd.cc.orig 2024-11-14 07:57:23 UTC +++ sandbox/policy/freebsd/sandbox_freebsd.cc -@@ -0,0 +1,245 @@ +@@ -0,0 +1,211 @@ +// Copyright (c) 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. @@ -159,7 +159,7 @@ + return true; + + VLOG(1) << "SandboxLinux::InitializeSandbox: process_type=" -+ << process_type << " sandbox_type=" << GetSandboxTypeInEnglish(sandbox_type); ++ << process_type << " sandbox_type=" << sandbox_type; + + // Only one thread is running, pre-initialize if not already done. + if (!pre_initialized_) @@ -210,39 +210,5 @@ + // !defined(THREAD_SANITIZER) && !defined(LEAK_SANITIZER) +} + -+// static -+std::string SandboxLinux::GetSandboxTypeInEnglish(sandbox::mojom::Sandbox sandbox_type) { -+ switch (sandbox_type) { -+ case sandbox::mojom::Sandbox::kNoSandbox: -+ return "Unsandboxed"; -+ case sandbox::mojom::Sandbox::kRenderer: -+ return "Renderer"; -+ case sandbox::mojom::Sandbox::kUtility: -+ return "Utility"; -+ case sandbox::mojom::Sandbox::kGpu: -+ return "GPU"; -+#if BUILDFLAG(ENABLE_PPAPI) -+ case sandbox::mojom::Sandbox::kPpapi: -+ return "PPAPI"; -+#endif -+ case sandbox::mojom::Sandbox::kNetwork: -+ return "Network"; -+ case sandbox::mojom::Sandbox::kCdm: -+ return "CDM"; -+ case sandbox::mojom::Sandbox::kPrintCompositor: -+ return "Print Compositor"; -+ case sandbox::mojom::Sandbox::kAudio: -+ return "Audio"; -+ case sandbox::mojom::Sandbox::kSpeechRecognition: -+ return "Speech Recognition"; -+ case sandbox::mojom::Sandbox::kService: -+ return "Service"; -+ case sandbox::mojom::Sandbox::kVideoCapture: -+ return "Video Capture"; -+ default: -+ return "Unknown"; -+ } -+} -+ +} // namespace policy +} // namespace sandbox diff --git a/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.h b/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.h index 8a18b8317c14..486c0e08ea8b 100644 --- a/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.h +++ b/www/chromium/files/patch-sandbox_policy_freebsd_sandbox__freebsd.h @@ -1,6 +1,6 @@ ---- sandbox/policy/freebsd/sandbox_freebsd.h.orig 2022-11-30 08:12:58 UTC +--- sandbox/policy/freebsd/sandbox_freebsd.h.orig 2024-11-14 07:57:23 UTC +++ sandbox/policy/freebsd/sandbox_freebsd.h -@@ -0,0 +1,278 @@ +@@ -0,0 +1,276 @@ +// Copyright (c) 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. @@ -169,8 +169,6 @@ + // is called from inside these processes. + int GetStatus(); + -+ static std::string GetSandboxTypeInEnglish(sandbox::mojom::Sandbox sandbox_type); -+ + // Returns true if the current process is single-threaded or if the number + // of threads cannot be determined. + bool IsSingleThreaded() const; diff --git a/www/chromium/files/patch-sandbox_policy_mojom_sandbox.mojom b/www/chromium/files/patch-sandbox_policy_mojom_sandbox.mojom index 48b525912c9f..8b927e59c4d1 100644 --- a/www/chromium/files/patch-sandbox_policy_mojom_sandbox.mojom +++ b/www/chromium/files/patch-sandbox_policy_mojom_sandbox.mojom @@ -1,8 +1,8 @@ ---- sandbox/policy/mojom/sandbox.mojom.orig 2023-12-10 06:10:27 UTC +--- sandbox/policy/mojom/sandbox.mojom.orig 2025-02-19 07:43:18 UTC +++ sandbox/policy/mojom/sandbox.mojom -@@ -77,6 +77,12 @@ enum Sandbox { - [EnableIf=is_fuchsia] - kVideoCapture, +@@ -74,6 +74,12 @@ enum Sandbox { + // Minimally privileged sandbox on Fuchsia. + [EnableIf=is_fuchsia] kVideoCapture, + [EnableIf=is_openbsd] + kVideoCapture, @@ -12,4 +12,4 @@ + // Allows access to file contents and Windows APIs for parsing icons from PE // files. - [EnableIf=is_win] + [EnableIf=is_win] kIconReader, diff --git a/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.cc b/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.cc index 499f85ee6120..421d198975d1 100644 --- a/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.cc +++ b/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.cc @@ -1,6 +1,6 @@ ---- sandbox/policy/openbsd/sandbox_openbsd.cc.orig 2024-03-22 08:19:40 UTC +--- sandbox/policy/openbsd/sandbox_openbsd.cc.orig 2025-07-02 06:08:04 UTC +++ sandbox/policy/openbsd/sandbox_openbsd.cc -@@ -0,0 +1,424 @@ +@@ -0,0 +1,400 @@ +// Copyright (c) 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. @@ -194,6 +194,7 @@ +bool SandboxLinux::SetUnveil(const std::string process_type, sandbox::mojom::Sandbox sandbox_type) { + FILE *fp; + char *s = NULL, *cp = NULL, *home = NULL, **ap, *tokens[MAXTOKENS]; ++ char *xdg_var = NULL; + char path[PATH_MAX]; + const char *ufile; + size_t len = 0, lineno = 0; @@ -203,6 +204,7 @@ + ufile = _UNVEIL_MAIN; + break; + case sandbox::mojom::Sandbox::kGpu: ++ case sandbox::mojom::Sandbox::kOnDeviceModelExecution: + ufile = _UNVEIL_GPU; + break; + case sandbox::mojom::Sandbox::kNetwork: @@ -257,6 +259,13 @@ + strncpy(path, home, sizeof(path) - 1); + path[sizeof(path) - 1] = '\0'; + strncat(path, tokens[0], sizeof(path) - 1 - strlen(path)); ++ } else if (strncmp(tokens[0], "XDG_", 4) == 0) { ++ if ((xdg_var = getenv(tokens[0])) == NULL || *xdg_var == '\0') { ++ LOG(ERROR) << "failed to get " << tokens[0]; ++ continue; ++ } ++ strncpy(path, xdg_var, sizeof(path) - 1); ++ path[sizeof(path) - 1] = '\0'; + } else { + strncpy(path, tokens[0], sizeof(path) - 1); + path[sizeof(path) - 1] = '\0'; @@ -299,7 +308,7 @@ + return true; + + VLOG(1) << "SandboxLinux::InitializeSandbox: process_type=" -+ << process_type << " sandbox_type=" << GetSandboxTypeInEnglish(sandbox_type); ++ << process_type << " sandbox_type=" << sandbox_type; + + // Only one thread is running, pre-initialize if not already done. + if (!pre_initialized_) @@ -331,7 +340,8 @@ + SetPledge("stdio rpath flock prot_exec recvfd sendfd ps", NULL); + break; + case sandbox::mojom::Sandbox::kGpu: -+ SetPledge("stdio drm rpath flock cpath wpath prot_exec recvfd sendfd tmppath", NULL); ++ case sandbox::mojom::Sandbox::kOnDeviceModelExecution: ++ SetPledge("stdio drm inet rpath flock cpath wpath prot_exec recvfd sendfd tmppath unix", NULL); + break; +#if BUILDFLAG(ENABLE_PPAPI) + case sandbox::mojom::Sandbox::kPpapi: @@ -353,7 +363,7 @@ + SetPledge("stdio rpath cpath wpath fattr flock sendfd recvfd prot_exec", NULL); + break; + default: -+ LOG(ERROR) << "non-pledge()'d process: " << GetSandboxTypeInEnglish(sandbox_type); ++ LOG(ERROR) << "non-pledge()'d process: " << sandbox_type; + break; + } + @@ -389,39 +399,5 @@ + // !defined(THREAD_SANITIZER) && !defined(LEAK_SANITIZER) +} + -+// static -+std::string SandboxLinux::GetSandboxTypeInEnglish(sandbox::mojom::Sandbox sandbox_type) { -+ switch (sandbox_type) { -+ case sandbox::mojom::Sandbox::kNoSandbox: -+ return "Unsandboxed"; -+ case sandbox::mojom::Sandbox::kRenderer: -+ return "Renderer"; -+ case sandbox::mojom::Sandbox::kUtility: -+ return "Utility"; -+ case sandbox::mojom::Sandbox::kGpu: -+ return "GPU"; -+#if BUILDFLAG(ENABLE_PPAPI) -+ case sandbox::mojom::Sandbox::kPpapi: -+ return "PPAPI"; -+#endif -+ case sandbox::mojom::Sandbox::kNetwork: -+ return "Network"; -+ case sandbox::mojom::Sandbox::kCdm: -+ return "CDM"; -+ case sandbox::mojom::Sandbox::kPrintCompositor: -+ return "Print Compositor"; -+ case sandbox::mojom::Sandbox::kAudio: -+ return "Audio"; -+ case sandbox::mojom::Sandbox::kSpeechRecognition: -+ return "Speech Recognition"; -+ case sandbox::mojom::Sandbox::kService: -+ return "Service"; -+ case sandbox::mojom::Sandbox::kVideoCapture: -+ return "Video Capture"; -+ default: -+ return "Unknown"; -+ } -+} -+ +} // namespace policy +} // namespace sandbox diff --git a/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.h b/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.h index 88378f8d083c..ac491437c39e 100644 --- a/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.h +++ b/www/chromium/files/patch-sandbox_policy_openbsd_sandbox__openbsd.h @@ -1,6 +1,6 @@ ---- sandbox/policy/openbsd/sandbox_openbsd.h.orig 2022-11-30 08:12:58 UTC +--- sandbox/policy/openbsd/sandbox_openbsd.h.orig 2024-11-14 07:57:23 UTC +++ sandbox/policy/openbsd/sandbox_openbsd.h -@@ -0,0 +1,282 @@ +@@ -0,0 +1,280 @@ +// Copyright (c) 2012 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. @@ -169,8 +169,6 @@ + // is called from inside these processes. + int GetStatus(); + -+ static std::string GetSandboxTypeInEnglish(sandbox::mojom::Sandbox sandbox_type); -+ + // Returns true if the current process is single-threaded or if the number + // of threads cannot be determined. + bool IsSingleThreaded() const; diff --git a/www/chromium/files/patch-sandbox_policy_sandbox__type.cc b/www/chromium/files/patch-sandbox_policy_sandbox__type.cc index 23c5e7819928..89a2a4231d20 100644 --- a/www/chromium/files/patch-sandbox_policy_sandbox__type.cc +++ b/www/chromium/files/patch-sandbox_policy_sandbox__type.cc @@ -1,34 +1,53 @@ ---- sandbox/policy/sandbox_type.cc.orig 2023-12-10 06:10:27 UTC +--- sandbox/policy/sandbox_type.cc.orig 2025-07-02 06:08:04 UTC +++ sandbox/policy/sandbox_type.cc -@@ -38,7 +38,7 @@ bool IsUnsandboxedSandboxType(Sandbox sandbox_type) { +@@ -17,7 +17,7 @@ + #include "chromeos/ash/components/assistant/buildflags.h" + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #include "media/gpu/buildflags.h" // nogncheck #endif - case Sandbox::kAudio: - return false; --#if BUILDFLAG(IS_FUCHSIA) -+#if BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - case Sandbox::kVideoCapture: - return false; + +@@ -42,7 +42,7 @@ constexpr char kPpapiSandbox[] = "ppapi"; #endif -@@ -63,7 +63,7 @@ bool IsUnsandboxedSandboxType(Sandbox sandbox_type) { - case Sandbox::kMirroring: - case Sandbox::kNaClLoader: + + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + constexpr char kPrintBackendSandbox[] = "print_backend"; + constexpr char kScreenAISandbox[] = "screen_ai"; #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - case Sandbox::kHardwareVideoDecoding: - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) - #if BUILDFLAG(IS_CHROMEOS_ASH) -@@ -73,7 +73,7 @@ bool IsUnsandboxedSandboxType(Sandbox sandbox_type) { - case Sandbox::kLibassistant: - #endif // BUILDFLAG(ENABLE_CROS_LIBASSISTANT) - #endif // // BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) | BUILDFLAG(IS_BSD) - case Sandbox::kZygoteIntermediateSandbox: - case Sandbox::kHardwareVideoEncoding: +@@ -60,15 +60,15 @@ constexpr char kWindowsSystemProxyResolverSandbox[] = + constexpr char kMirroringSandbox[] = "mirroring"; + #endif // BUILDFLAG(IS_MAC) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + constexpr char kVideoEffectsSandbox[] = "video_effects"; #endif -@@ -130,7 +130,7 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi + +-#if BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + constexpr char kVideoCaptureSandbox[] = "video_capture"; #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + // USE_LINUX_VIDEO_ACCELERATION implies IS_LINUX || IS_CHROMEOS, so this double + // #if is redundant, however, we cannot include "media/gpu/buildflags.h" on all + // platforms, only one those that need to evaluate the use..., hence this +@@ -88,7 +88,7 @@ constexpr char kLibassistantSandbox[] = "libassistant" + #endif // BUILDFLAG(ENABLE_CROS_LIBASSISTANT) + #endif // BUILDFLAG(IS_CHROMEOS) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + constexpr char kOnDeviceTranslationSandbox[] = "on_device_translation"; + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) + +@@ -150,7 +150,7 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi + case Sandbox::kCdm: case Sandbox::kPrintCompositor: case Sandbox::kAudio: -#if BUILDFLAG(IS_FUCHSIA) @@ -36,30 +55,45 @@ case Sandbox::kVideoCapture: #endif #if BUILDFLAG(IS_WIN) -@@ -141,10 +141,10 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi +@@ -161,7 +161,7 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi case Sandbox::kMediaFoundationCdm: case Sandbox::kWindowsSystemProxyResolver: #endif // BUILDFLAG(IS_WIN) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - case Sandbox::kHardwareVideoDecoding: - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(USE_LINUX_VIDEO_ACCELERATION) + case Sandbox::kHardwareVideoDecoding: case Sandbox::kHardwareVideoEncoding: - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - #if BUILDFLAG(IS_CHROMEOS_ASH) -@@ -172,7 +172,7 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi - case Sandbox::kNaClLoader: - break; +@@ -179,15 +179,15 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi + case Sandbox::kMirroring: #endif // BUILDFLAG(IS_MAC) + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + case Sandbox::kPrintBackend: + case Sandbox::kScreenAI: + #endif + case Sandbox::kSpeechRecognition: +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + case Sandbox::kVideoEffects: + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + case Sandbox::kOnDeviceTranslation: + #endif + DCHECK(command_line->GetSwitchValueASCII(switches::kProcessType) == +@@ -197,7 +197,7 @@ void SetCommandLineFlagsForSandboxType(base::CommandLi + switches::kServiceSandboxType, + StringFromUtilitySandboxType(sandbox_type)); + break; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) case Sandbox::kZygoteIntermediateSandbox: break; #endif -@@ -216,7 +216,7 @@ sandbox::mojom::Sandbox SandboxTypeFromCommandLine( - #endif +@@ -237,7 +237,7 @@ sandbox::mojom::Sandbox SandboxTypeFromCommandLine( + return Sandbox::kUtility; } -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -67,49 +101,84 @@ // Intermediate process gains a sandbox later. if (process_type == switches::kZygoteProcessType) return Sandbox::kZygoteIntermediateSandbox; -@@ -262,7 +262,7 @@ std::string StringFromUtilitySandboxType(Sandbox sandb - return switches::kUtilitySandbox; +@@ -279,7 +279,7 @@ std::string StringFromUtilitySandboxType(Sandbox sandb + return kUtilitySandbox; case Sandbox::kAudio: - return switches::kAudioSandbox; + return kAudioSandbox; -#if BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) case Sandbox::kVideoCapture: - return switches::kVideoCaptureSandbox; + return kVideoCaptureSandbox; + #endif +@@ -290,17 +290,17 @@ std::string StringFromUtilitySandboxType(Sandbox sandb + case Sandbox::kSpeechRecognition: + return kSpeechRecognitionSandbox; + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + case Sandbox::kPrintBackend: + return kPrintBackendSandbox; + case Sandbox::kScreenAI: + return kScreenAISandbox; #endif -@@ -292,11 +292,11 @@ std::string StringFromUtilitySandboxType(Sandbox sandb +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + case Sandbox::kVideoEffects: + return kVideoEffectsSandbox; + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + case Sandbox::kOnDeviceTranslation: + return kOnDeviceTranslationSandbox; + #endif +@@ -320,7 +320,7 @@ std::string StringFromUtilitySandboxType(Sandbox sandb case Sandbox::kMirroring: - return switches::kMirroringSandbox; + return kMirroringSandbox; #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - case Sandbox::kHardwareVideoDecoding: - return switches::kHardwareVideoDecodingSandbox; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - case Sandbox::kHardwareVideoEncoding: - return switches::kHardwareVideoEncodingSandbox; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -@@ -316,7 +316,7 @@ std::string StringFromUtilitySandboxType(Sandbox sandb - #if BUILDFLAG(IS_MAC) - case Sandbox::kNaClLoader: - #endif // BUILDFLAG(IS_MAC) + #if BUILDFLAG(USE_LINUX_VIDEO_ACCELERATION) + case Sandbox::kHardwareVideoDecoding: + return kHardwareVideoDecodingSandbox; +@@ -343,7 +343,7 @@ std::string StringFromUtilitySandboxType(Sandbox sandb + // The following are not utility processes so should not occur. + case Sandbox::kRenderer: + case Sandbox::kGpu: -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) case Sandbox::kZygoteIntermediateSandbox: #endif NOTREACHED(); -@@ -388,11 +388,11 @@ sandbox::mojom::Sandbox UtilitySandboxTypeFromString( - if (sandbox_string == switches::kScreenAISandbox) +@@ -421,7 +421,7 @@ sandbox::mojom::Sandbox UtilitySandboxTypeFromString( + return Sandbox::kSpeechRecognition; + } + #if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC) || \ +- BUILDFLAG(IS_WIN) ++ BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + if (sandbox_string == kPrintBackendSandbox) { + return Sandbox::kPrintBackend; + } +@@ -429,7 +429,7 @@ sandbox::mojom::Sandbox UtilitySandboxTypeFromString( return Sandbox::kScreenAI; + } + #endif +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (sandbox_string == kVideoEffectsSandbox) { + return Sandbox::kVideoEffects; + } +@@ -439,12 +439,12 @@ sandbox::mojom::Sandbox UtilitySandboxTypeFromString( + return Sandbox::kOnDeviceTranslation; + } #endif -#if BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - if (sandbox_string == switches::kVideoCaptureSandbox) + if (sandbox_string == kVideoCaptureSandbox) { return Sandbox::kVideoCapture; + } #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - if (sandbox_string == switches::kHardwareVideoDecodingSandbox) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(USE_LINUX_VIDEO_ACCELERATION) + if (sandbox_string == kHardwareVideoDecodingSandbox) { return Sandbox::kHardwareVideoDecoding; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) diff --git a/www/chromium/files/patch-sandbox_policy_switches.cc b/www/chromium/files/patch-sandbox_policy_switches.cc index e8b567b18b5e..1b42116d2891 100644 --- a/www/chromium/files/patch-sandbox_policy_switches.cc +++ b/www/chromium/files/patch-sandbox_policy_switches.cc @@ -1,19 +1,6 @@ ---- sandbox/policy/switches.cc.orig 2023-12-10 06:10:27 UTC +--- sandbox/policy/switches.cc.orig 2025-04-04 08:52:13 UTC +++ sandbox/policy/switches.cc -@@ -54,10 +54,10 @@ const char kWindowsSystemProxyResolverSandbox[] = "pro - const char kMirroringSandbox[] = "mirroring"; - #endif // BUILDFLAG(IS_MAC) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - const char kHardwareVideoDecodingSandbox[] = "hardware_video_decoding"; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - const char kHardwareVideoEncodingSandbox[] = "hardware_video_encoding"; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - -@@ -96,7 +96,9 @@ const char kGpuSandboxFailuresFatal[] = "gpu-sandbox-f +@@ -37,7 +37,9 @@ const char kGpuSandboxFailuresFatal[] = "gpu-sandbox-f // Meant to be used as a browser-level switch for testing purposes only. const char kNoSandbox[] = "no-sandbox"; diff --git a/www/chromium/files/patch-sandbox_policy_switches.h b/www/chromium/files/patch-sandbox_policy_switches.h index b84e7d2213eb..b19609d509fb 100644 --- a/www/chromium/files/patch-sandbox_policy_switches.h +++ b/www/chromium/files/patch-sandbox_policy_switches.h @@ -1,19 +1,6 @@ ---- sandbox/policy/switches.h.orig 2023-12-10 06:10:27 UTC +--- sandbox/policy/switches.h.orig 2025-02-19 07:43:18 UTC +++ sandbox/policy/switches.h -@@ -57,10 +57,10 @@ SANDBOX_POLICY_EXPORT extern const char kWindowsSystem - SANDBOX_POLICY_EXPORT extern const char kMirroringSandbox[]; - #endif // BUILDFLAG(IS_MAC) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - SANDBOX_POLICY_EXPORT extern const char kHardwareVideoDecodingSandbox[]; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - SANDBOX_POLICY_EXPORT extern const char kHardwareVideoEncodingSandbox[]; - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - -@@ -81,7 +81,8 @@ SANDBOX_POLICY_EXPORT extern const char kDisableSetuid +@@ -23,7 +23,8 @@ SANDBOX_POLICY_EXPORT extern const char kDisableSetuid SANDBOX_POLICY_EXPORT extern const char kGpuSandboxAllowSysVShm[]; SANDBOX_POLICY_EXPORT extern const char kGpuSandboxFailuresFatal[]; SANDBOX_POLICY_EXPORT extern const char kNoSandbox[]; diff --git a/www/chromium/files/patch-services_audio_audio__sandbox__hook__linux.cc b/www/chromium/files/patch-services_audio_audio__sandbox__hook__linux.cc index 33d94315c22d..a9065d56db5c 100644 --- a/www/chromium/files/patch-services_audio_audio__sandbox__hook__linux.cc +++ b/www/chromium/files/patch-services_audio_audio__sandbox__hook__linux.cc @@ -1,6 +1,6 @@ ---- services/audio/audio_sandbox_hook_linux.cc.orig 2024-04-19 13:02:56 UTC +--- services/audio/audio_sandbox_hook_linux.cc.orig 2025-05-28 14:55:43 UTC +++ services/audio/audio_sandbox_hook_linux.cc -@@ -144,6 +144,7 @@ void AddPulseAudioFilePermissions( +@@ -147,6 +147,7 @@ void AddPulseAudioFilePermissions( } #endif @@ -8,7 +8,7 @@ std::vector<BrokerFilePermission> GetAudioFilePermissions() { std::vector<BrokerFilePermission> permissions{ BrokerFilePermission::ReadOnly("/dev/urandom"), -@@ -172,10 +173,12 @@ void LoadAudioLibraries() { +@@ -175,10 +176,12 @@ void LoadAudioLibraries() { } } } @@ -21,8 +21,8 @@ LoadAudioLibraries(); auto* instance = sandbox::policy::SandboxLinux::GetInstance(); instance->StartBrokerProcess(MakeBrokerCommandSet({ -@@ -193,6 +196,7 @@ bool AudioPreSandboxHook(sandbox::policy::SandboxLinux - // TODO(https://crbug.com/850878) enable namespace sandbox. Currently, if +@@ -196,6 +199,7 @@ bool AudioPreSandboxHook(sandbox::policy::SandboxLinux + // TODO(crbug.com/40579955) enable namespace sandbox. Currently, if // enabled, connect() on pulse native socket fails with ENOENT (called from // pa_context_connect). +#endif diff --git a/www/chromium/files/patch-services_device_BUILD.gn b/www/chromium/files/patch-services_device_BUILD.gn index cada3440fcbe..0da3cba064cf 100644 --- a/www/chromium/files/patch-services_device_BUILD.gn +++ b/www/chromium/files/patch-services_device_BUILD.gn @@ -1,11 +1,11 @@ ---- services/device/BUILD.gn.orig 2023-11-03 10:09:45 UTC +--- services/device/BUILD.gn.orig 2025-05-28 14:55:43 UTC +++ services/device/BUILD.gn -@@ -13,7 +13,7 @@ if (is_android) { +@@ -17,7 +17,7 @@ if (is_ios) { } is_serial_enabled_platform = -- is_win || ((is_linux || is_chromeos) && use_udev) || is_mac -+ is_win || ((!is_bsd && is_linux || is_chromeos) && use_udev) || is_mac +- is_win || ((is_linux || is_chromeos) && use_udev) || is_mac || is_android ++ is_win || ((!is_bsd && is_linux || is_chromeos) && use_udev) || is_mac || is_android source_set("lib") { # This should be visible only to embedders of the Device Service, and the diff --git a/www/chromium/files/patch-services_device_geolocation_location__arbitrator.cc b/www/chromium/files/patch-services_device_geolocation_location__arbitrator.cc deleted file mode 100644 index a5ac8d4d488f..000000000000 --- a/www/chromium/files/patch-services_device_geolocation_location__arbitrator.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- services/device/geolocation/location_arbitrator.cc.orig 2024-04-19 13:02:56 UTC -+++ services/device/geolocation/location_arbitrator.cc -@@ -196,7 +196,7 @@ LocationArbitrator::NewNetworkLocationProvider( - - std::unique_ptr<LocationProvider> - LocationArbitrator::NewSystemLocationProvider() { --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - return nullptr; - #else - return device::NewSystemLocationProvider( diff --git a/www/chromium/files/patch-services_device_geolocation_location__provider__manager.cc b/www/chromium/files/patch-services_device_geolocation_location__provider__manager.cc new file mode 100644 index 000000000000..975eac2132a6 --- /dev/null +++ b/www/chromium/files/patch-services_device_geolocation_location__provider__manager.cc @@ -0,0 +1,11 @@ +--- services/device/geolocation/location_provider_manager.cc.orig 2025-05-05 10:57:53 UTC ++++ services/device/geolocation/location_provider_manager.cc +@@ -91,7 +91,7 @@ LocationProviderManager::LocationProviderManager( + #if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_IOS) + // On Android and iOS, default to using the platform location provider. + provider_manager_mode_ = kPlatformOnly; +-#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // On Ash / Lacros / Linux, default to using the network location provider. + provider_manager_mode_ = kNetworkOnly; + #else diff --git a/www/chromium/files/patch-services_device_hid_BUILD.gn b/www/chromium/files/patch-services_device_hid_BUILD.gn index 1015bf9dc39b..1015a93c0ff9 100644 --- a/www/chromium/files/patch-services_device_hid_BUILD.gn +++ b/www/chromium/files/patch-services_device_hid_BUILD.gn @@ -1,6 +1,6 @@ ---- services/device/hid/BUILD.gn.orig 2024-01-30 07:53:34 UTC +--- services/device/hid/BUILD.gn.orig 2025-02-19 07:43:18 UTC +++ services/device/hid/BUILD.gn -@@ -36,7 +36,26 @@ source_set("hid") { +@@ -34,7 +34,26 @@ source_set("hid") { "//services/device/public/mojom", ] diff --git a/www/chromium/files/patch-services_device_hid_hid__connection__fido.cc b/www/chromium/files/patch-services_device_hid_hid__connection__fido.cc index 2eeb889c5484..f665938c7512 100644 --- a/www/chromium/files/patch-services_device_hid_hid__connection__fido.cc +++ b/www/chromium/files/patch-services_device_hid_hid__connection__fido.cc @@ -1,4 +1,4 @@ ---- services/device/hid/hid_connection_fido.cc.orig 2023-03-09 06:31:50 UTC +--- services/device/hid/hid_connection_fido.cc.orig 2024-06-17 12:56:06 UTC +++ services/device/hid/hid_connection_fido.cc @@ -0,0 +1,216 @@ +// Copyright 2014 The Chromium Authors @@ -61,7 +61,7 @@ + base::ScopedBlockingCall scoped_blocking_call( + FROM_HERE, base::BlockingType::MAY_BLOCK); + -+ auto data = buffer->front(); ++ auto data = buffer->data(); + size_t size = buffer->size(); + // if report id is 0, it shouldn't be included + if (data[0] == 0) { @@ -112,7 +112,7 @@ + + auto buffer = + base::MakeRefCounted<base::RefCountedBytes>(report_buffer_size_); -+ uint8_t* data = buffer->front(); ++ uint8_t* data = buffer->as_vector().data(); + size_t length = report_buffer_size_; + if (!has_report_id_) { + // Fido will not prefix the buffer with a report ID if report IDs are not @@ -197,7 +197,7 @@ + DCHECK_GT(device_info()->max_feature_report_size(), 0u); + auto buffer = base::MakeRefCounted<base::RefCountedBytes>( + device_info()->max_feature_report_size() + 1); -+ buffer->data()[0] = report_id; ++ buffer->as_vector().data()[0] = report_id; + + blocking_task_runner_->PostTask( + FROM_HERE, base::BindOnce(&BlockingTaskRunnerHelper::GetFeatureReport, diff --git a/www/chromium/files/patch-services_device_hid_hid__connection__freebsd.cc b/www/chromium/files/patch-services_device_hid_hid__connection__freebsd.cc index b2ca8662c0bc..a1d83847aba6 100644 --- a/www/chromium/files/patch-services_device_hid_hid__connection__freebsd.cc +++ b/www/chromium/files/patch-services_device_hid_hid__connection__freebsd.cc @@ -1,4 +1,4 @@ ---- services/device/hid/hid_connection_freebsd.cc.orig 2023-04-05 11:05:06 UTC +--- services/device/hid/hid_connection_freebsd.cc.orig 2025-01-19 19:00:05 UTC +++ services/device/hid/hid_connection_freebsd.cc @@ -0,0 +1,240 @@ +// Copyright (c) 2014 The Chromium Authors. All rights reserved. @@ -46,7 +46,7 @@ + // Must be called on a thread that has a base::MessageLoopForIO. + void Start() { + DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); -+ base::internal::AssertBlockingAllowed(); ++ base::AssertBlockingAllowed(); + + file_watcher_ = base::FileDescriptorWatcher::WatchReadable( + fd_.get(), base::BindRepeating(&BlockingTaskRunnerHelper::OnFileCanReadWithoutBlocking, @@ -59,7 +59,7 @@ + base::ScopedBlockingCall scoped_blocking_call( + FROM_HERE, base::BlockingType::MAY_BLOCK); + -+ auto data = buffer->front(); ++ auto data = buffer->as_vector().data(); + size_t size = buffer->size(); + // if report id is 0, it shouldn't be included + if (data[0] == 0) { @@ -86,7 +86,7 @@ + FROM_HERE, base::BlockingType::MAY_BLOCK); + struct usb_gen_descriptor ugd; + ugd.ugd_report_type = UHID_FEATURE_REPORT; -+ ugd.ugd_data = buffer->front(); ++ ugd.ugd_data = buffer->as_vector().data(); + ugd.ugd_maxlen = buffer->size(); + int result = HANDLE_EINTR( + ioctl(fd_.get(), USB_GET_REPORT, &ugd)); @@ -109,14 +109,14 @@ + DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); + struct usb_gen_descriptor ugd; + ugd.ugd_report_type = UHID_FEATURE_REPORT; -+ ugd.ugd_data = buffer->front(); ++ ugd.ugd_data = buffer->as_vector().data(); + ugd.ugd_maxlen = buffer->size(); + // FreeBSD does not require report id if it's not used -+ if (buffer->front()[0] == 0) { -+ ugd.ugd_data = buffer->front() + 1; ++ if (buffer->data()[0] == 0) { ++ ugd.ugd_data = buffer->as_vector().data() + 1; + ugd.ugd_maxlen = buffer->size() - 1; + } else { -+ ugd.ugd_data = buffer->front(); ++ ugd.ugd_data = buffer->as_vector().data(); + ugd.ugd_maxlen = buffer->size(); + } + int result = HANDLE_EINTR( @@ -136,7 +136,7 @@ + DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); + + scoped_refptr<base::RefCountedBytes> buffer(new base::RefCountedBytes(report_buffer_size_)); -+ unsigned char* data = buffer->front(); ++ unsigned char* data = buffer->as_vector().data(); + size_t length = report_buffer_size_; + if (!has_report_id_) { + // FreeBSD will not prefix the buffer with a report ID if report IDs are not @@ -220,7 +220,7 @@ + scoped_refptr<base::RefCountedBytes> buffer( + new base::RefCountedBytes(device_info()->max_feature_report_size() + 1)); + if (report_id != 0) -+ buffer->data()[0] = report_id; ++ buffer->as_vector().data()[0] = report_id; + + blocking_task_runner_->PostTask( + FROM_HERE, diff --git a/www/chromium/files/patch-services_device_hid_hid__service__freebsd.cc b/www/chromium/files/patch-services_device_hid_hid__service__freebsd.cc index e6f980102710..59661d7c81ea 100644 --- a/www/chromium/files/patch-services_device_hid_hid__service__freebsd.cc +++ b/www/chromium/files/patch-services_device_hid_hid__service__freebsd.cc @@ -1,4 +1,4 @@ ---- services/device/hid/hid_service_freebsd.cc.orig 2023-04-05 11:05:06 UTC +--- services/device/hid/hid_service_freebsd.cc.orig 2025-01-19 19:00:05 UTC +++ services/device/hid/hid_service_freebsd.cc @@ -0,0 +1,395 @@ +// Copyright 2014 The Chromium Authors. All rights reserved. @@ -106,7 +106,7 @@ + + bool HaveReadWritePermissions(std::string device_id) { + std::string device_node = "/dev/" + device_id; -+ base::internal::AssertBlockingAllowed(); ++ base::AssertBlockingAllowed(); + + base::FilePath device_path(device_node); + base::File device_file; @@ -130,7 +130,7 @@ + + std::vector<uint8_t> report_descriptor; + -+ base::internal::AssertBlockingAllowed(); ++ base::AssertBlockingAllowed(); + + base::FilePath device_path(device_node); + base::File device_file; @@ -196,7 +196,7 @@ + private: + + void CheckPendingPermissionChange() { -+ base::internal::AssertBlockingAllowed(); ++ base::AssertBlockingAllowed(); + std::map<std::string, int>::iterator it; + for (it = permissions_checks_attempts_.begin(); it != permissions_checks_attempts_.end();) { + std::string device_name = it->first; @@ -222,7 +222,7 @@ + } + + void SetupDevdMonitor() { -+ base::internal::AssertBlockingAllowed(); ++ base::AssertBlockingAllowed(); + + int devd_fd = socket(AF_UNIX, SOCK_SEQPACKET, 0); + if (devd_fd < 0) diff --git a/www/chromium/files/patch-services_device_public_cpp_device__features.cc b/www/chromium/files/patch-services_device_public_cpp_device__features.cc new file mode 100644 index 000000000000..625b5a28ce7b --- /dev/null +++ b/www/chromium/files/patch-services_device_public_cpp_device__features.cc @@ -0,0 +1,11 @@ +--- services/device/public/cpp/device_features.cc.orig 2025-05-28 14:55:43 UTC ++++ services/device/public/cpp/device_features.cc +@@ -140,7 +140,7 @@ bool IsOsLevelGeolocationPermissionSupportEnabled() { + + // Controls whether Chrome will try to automatically detach kernel drivers when + // a USB interface is busy. +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kAutomaticUsbDetach, + "AutomaticUsbDetach", + base::FEATURE_DISABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-services_device_public_cpp_device__features.h b/www/chromium/files/patch-services_device_public_cpp_device__features.h new file mode 100644 index 000000000000..905e38fe5337 --- /dev/null +++ b/www/chromium/files/patch-services_device_public_cpp_device__features.h @@ -0,0 +1,11 @@ +--- services/device/public/cpp/device_features.h.orig 2025-04-04 08:52:13 UTC ++++ services/device/public/cpp/device_features.h +@@ -53,7 +53,7 @@ extern const DEVICE_FEATURES_EXPORT + + DEVICE_FEATURES_EXPORT bool IsOsLevelGeolocationPermissionSupportEnabled(); + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + DEVICE_FEATURES_EXPORT BASE_DECLARE_FEATURE(kAutomaticUsbDetach); + #endif // BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) + diff --git a/www/chromium/files/patch-services_device_public_mojom_BUILD.gn b/www/chromium/files/patch-services_device_public_mojom_BUILD.gn index 0ac7ec78f373..d3fcd6156eec 100644 --- a/www/chromium/files/patch-services_device_public_mojom_BUILD.gn +++ b/www/chromium/files/patch-services_device_public_mojom_BUILD.gn @@ -1,6 +1,6 @@ ---- services/device/public/mojom/BUILD.gn.orig 2024-03-22 08:19:40 UTC +--- services/device/public/mojom/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ services/device/public/mojom/BUILD.gn -@@ -96,7 +96,7 @@ mojom("device_service") { +@@ -99,7 +99,7 @@ mojom("device_service") { enable_js_fuzzing = false enabled_features = [] diff --git a/www/chromium/files/patch-services_device_serial_BUILD.gn b/www/chromium/files/patch-services_device_serial_BUILD.gn index a1f5f2465a1e..af1019f78680 100644 --- a/www/chromium/files/patch-services_device_serial_BUILD.gn +++ b/www/chromium/files/patch-services_device_serial_BUILD.gn @@ -1,11 +1,11 @@ ---- services/device/serial/BUILD.gn.orig 2022-11-30 08:12:58 UTC +--- services/device/serial/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ services/device/serial/BUILD.gn -@@ -5,7 +5,7 @@ - import("//build/config/chromeos/ui_mode.gni") +@@ -4,7 +4,7 @@ + import("//build/config/features.gni") --if (is_win || ((is_linux || is_chromeos) && use_udev) || is_mac) { -+if (is_win || ((!is_bsd && is_linux || is_chromeos) && use_udev) || is_mac) { +-if (is_win || ((is_linux || is_chromeos) && use_udev) || is_mac || is_android) { ++if (is_win || ((!is_bsd && is_linux || is_chromeos) && use_udev) || is_mac || is_android) { config("platform_support") { visibility = [ ":serial" ] if (is_win) { diff --git a/www/chromium/files/patch-services_device_serial_serial__device__enumerator.cc b/www/chromium/files/patch-services_device_serial_serial__device__enumerator.cc index 9031e70940e0..5c203817afb9 100644 --- a/www/chromium/files/patch-services_device_serial_serial__device__enumerator.cc +++ b/www/chromium/files/patch-services_device_serial_serial__device__enumerator.cc @@ -1,4 +1,4 @@ ---- services/device/serial/serial_device_enumerator.cc.orig 2023-03-09 06:31:50 UTC +--- services/device/serial/serial_device_enumerator.cc.orig 2025-07-02 06:08:04 UTC +++ services/device/serial/serial_device_enumerator.cc @@ -12,7 +12,7 @@ #include "build/build_config.h" @@ -9,7 +9,7 @@ #include "services/device/serial/serial_device_enumerator_linux.h" #elif BUILDFLAG(IS_MAC) #include "services/device/serial/serial_device_enumerator_mac.h" -@@ -25,7 +25,7 @@ namespace device { +@@ -27,7 +27,7 @@ namespace device { // static std::unique_ptr<SerialDeviceEnumerator> SerialDeviceEnumerator::Create( scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner) { diff --git a/www/chromium/files/patch-services_device_serial_serial__io__handler__posix.cc b/www/chromium/files/patch-services_device_serial_serial__io__handler__posix.cc index 7b908151bdef..c6e3f37fc9c4 100644 --- a/www/chromium/files/patch-services_device_serial_serial__io__handler__posix.cc +++ b/www/chromium/files/patch-services_device_serial_serial__io__handler__posix.cc @@ -1,6 +1,6 @@ ---- services/device/serial/serial_io_handler_posix.cc.orig 2023-03-09 06:31:50 UTC +--- services/device/serial/serial_io_handler_posix.cc.orig 2024-08-26 12:06:38 UTC +++ services/device/serial/serial_io_handler_posix.cc -@@ -68,7 +68,7 @@ bool BitrateToSpeedConstant(int bitrate, speed_t* spee +@@ -73,7 +73,7 @@ bool BitrateToSpeedConstant(int bitrate, speed_t* spee BITRATE_TO_SPEED_CASE(9600) BITRATE_TO_SPEED_CASE(19200) BITRATE_TO_SPEED_CASE(38400) diff --git a/www/chromium/files/patch-services_device_time__zone__monitor_time__zone__monitor__linux.cc b/www/chromium/files/patch-services_device_time__zone__monitor_time__zone__monitor__linux.cc index 69887a89893b..fef990fccb85 100644 --- a/www/chromium/files/patch-services_device_time__zone__monitor_time__zone__monitor__linux.cc +++ b/www/chromium/files/patch-services_device_time__zone__monitor_time__zone__monitor__linux.cc @@ -1,14 +1,15 @@ ---- services/device/time_zone_monitor/time_zone_monitor_linux.cc.orig 2023-09-13 12:11:42 UTC +--- services/device/time_zone_monitor/time_zone_monitor_linux.cc.orig 2025-03-05 08:14:56 UTC +++ services/device/time_zone_monitor/time_zone_monitor_linux.cc -@@ -131,7 +131,11 @@ class TimeZoneMonitorLinuxImpl +@@ -131,9 +131,12 @@ class TimeZoneMonitorLinuxImpl // false positives are harmless, assuming the false positive rate is // reasonable. - const char* const kFilesToWatch[] = { + const auto kFilesToWatch = std::to_array<const char*>({ +#if BUILDFLAG(IS_BSD) -+ "/etc/localtime", + "/etc/localtime", +#else - "/etc/localtime", "/etc/timezone", "/etc/TZ", + "/etc/timezone", + "/etc/TZ", +#endif - }; + }); for (size_t index = 0; index < std::size(kFilesToWatch); ++index) { file_path_watchers_.push_back(std::make_unique<base::FilePathWatcher>()); diff --git a/www/chromium/files/patch-services_device_usb_BUILD.gn b/www/chromium/files/patch-services_device_usb_BUILD.gn index 1e8aab091a64..73d54126ff52 100644 --- a/www/chromium/files/patch-services_device_usb_BUILD.gn +++ b/www/chromium/files/patch-services_device_usb_BUILD.gn @@ -1,33 +1,15 @@ ---- services/device/usb/BUILD.gn.orig 2024-01-30 07:53:34 UTC +--- services/device/usb/BUILD.gn.orig 2025-03-05 08:14:56 UTC +++ services/device/usb/BUILD.gn -@@ -92,15 +92,17 @@ static_library("usb") { +@@ -90,7 +90,7 @@ static_library("usb") { deps += [ "//third_party/re2" ] } - if (is_mac) { -- sources += [ -- "usb_device_handle_mac.cc", -- "usb_device_handle_mac.h", -- "usb_device_mac.cc", -- "usb_device_mac.h", -- "usb_service_mac.cc", -- "usb_service_mac.h", -- ] + if (is_mac || is_openbsd) { -+ if (is_mac) { -+ sources += [ -+ "usb_device_handle_mac.cc", -+ "usb_device_handle_mac.h", -+ "usb_device_mac.cc", -+ "usb_device_mac.h", -+ "usb_service_mac.cc", -+ "usb_service_mac.h", -+ ] -+ } - # These sources and deps are required for libusb. - # TODO(https://crbug.com/1096743) Remove these sources. -@@ -124,6 +126,13 @@ static_library("usb") { + # TODO(crbug.com/40136337) Remove these sources. + sources += [ +@@ -113,6 +113,13 @@ static_library("usb") { deps += [ "//third_party/libusb" ] } @@ -41,7 +23,7 @@ if (is_linux || is_chromeos) { sources += [ "usb_device_linux.cc", -@@ -141,7 +150,7 @@ static_library("usb") { +@@ -134,7 +141,7 @@ static_library("usb") { deps += [ "//device/udev_linux" ] } diff --git a/www/chromium/files/patch-services_device_usb_usb__device__handle__usbfs.cc b/www/chromium/files/patch-services_device_usb_usb__device__handle__usbfs.cc new file mode 100644 index 000000000000..8a1c5f243f27 --- /dev/null +++ b/www/chromium/files/patch-services_device_usb_usb__device__handle__usbfs.cc @@ -0,0 +1,38 @@ +--- services/device/usb/usb_device_handle_usbfs.cc.orig 2025-07-02 06:08:04 UTC ++++ services/device/usb/usb_device_handle_usbfs.cc +@@ -38,7 +38,7 @@ + #include "chromeos/dbus/permission_broker/permission_broker_client.h" + #endif + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "services/device/public/cpp/device_features.h" + #include "services/device/usb/usb_interface_detach_allowlist.h" + #endif // BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) +@@ -270,7 +270,7 @@ bool UsbDeviceHandleUsbfs::BlockingTaskRunnerHelper::R + return true; + } + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + bool UsbDeviceHandleUsbfs::BlockingTaskRunnerHelper::DetachInterface( + int interface_number, + const CombinedInterfaceInfo& interface_info) { +@@ -598,7 +598,7 @@ void UsbDeviceHandleUsbfs::ClaimInterface(int interfac + return; + } + #endif +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled(features::kAutomaticUsbDetach)) { + const mojom::UsbConfigurationInfo* config = + device_->GetActiveConfiguration(); +@@ -944,7 +944,7 @@ void UsbDeviceHandleUsbfs::ReleaseInterfaceComplete(in + return; + } + #endif +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + if (base::FeatureList::IsEnabled(features::kAutomaticUsbDetach)) { + helper_.AsyncCall(&BlockingTaskRunnerHelper::ReattachInterface) + .WithArgs(interface_number) diff --git a/www/chromium/files/patch-services_device_usb_usb__device__handle__usbfs.h b/www/chromium/files/patch-services_device_usb_usb__device__handle__usbfs.h new file mode 100644 index 000000000000..448537157c55 --- /dev/null +++ b/www/chromium/files/patch-services_device_usb_usb__device__handle__usbfs.h @@ -0,0 +1,38 @@ +--- services/device/usb/usb_device_handle_usbfs.h.orig 2025-05-05 10:57:53 UTC ++++ services/device/usb/usb_device_handle_usbfs.h +@@ -19,7 +19,7 @@ + #include "base/threading/sequence_bound.h" + #include "services/device/usb/usb_device_handle.h" + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "base/containers/flat_set.h" + #endif // BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) + +@@ -215,7 +215,7 @@ class UsbDeviceHandleUsbfs::BlockingTaskRunnerHelper { + bool ClearHalt(uint8_t endpoint_address); + void DiscardUrb(Transfer* transfer); + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Detach the interface from a kernel driver before ClaimInterface + virtual bool DetachInterface(int interface_number, + const CombinedInterfaceInfo& interfaceInfo); +@@ -228,7 +228,7 @@ class UsbDeviceHandleUsbfs::BlockingTaskRunnerHelper { + // Called when |fd_| is writable without blocking. + void OnFileCanWriteWithoutBlocking(); + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Called from |DetachInterface|. + std::string GetKernelDriver(int interface_number) const; + #endif // BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) +@@ -240,7 +240,7 @@ class UsbDeviceHandleUsbfs::BlockingTaskRunnerHelper { + std::unique_ptr<base::FileDescriptorWatcher::Controller> watch_controller_; + SEQUENCE_CHECKER(sequence_checker_); + +-#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // All interfaces that have been detached from kernel drivers + base::flat_set<int> detached_interfaces_; + #endif // BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-services_device_usb_usb__service.cc b/www/chromium/files/patch-services_device_usb_usb__service.cc index 3e42afc33502..3bfbcb92200a 100644 --- a/www/chromium/files/patch-services_device_usb_usb__service.cc +++ b/www/chromium/files/patch-services_device_usb_usb__service.cc @@ -1,6 +1,6 @@ ---- services/device/usb/usb_service.cc.orig 2022-11-30 08:12:58 UTC +--- services/device/usb/usb_service.cc.orig 2025-07-02 06:08:04 UTC +++ services/device/usb/usb_service.cc -@@ -22,13 +22,17 @@ +@@ -20,12 +20,16 @@ #if BUILDFLAG(IS_ANDROID) #include "services/device/usb/usb_service_android.h" @@ -9,7 +9,6 @@ #include "services/device/usb/usb_service_linux.h" #elif BUILDFLAG(IS_MAC) #include "services/device/usb/usb_service_impl.h" - #include "services/device/usb/usb_service_mac.h" #elif BUILDFLAG(IS_WIN) #include "services/device/usb/usb_service_win.h" +#elif BUILDFLAG(IS_OPENBSD) @@ -19,7 +18,7 @@ #endif namespace device { -@@ -51,7 +55,7 @@ constexpr base::TaskTraits UsbService::kBlockingTaskTr +@@ -48,11 +52,13 @@ constexpr base::TaskTraits UsbService::kBlockingTaskTr std::unique_ptr<UsbService> UsbService::Create() { #if BUILDFLAG(IS_ANDROID) return base::WrapUnique(new UsbServiceAndroid()); @@ -28,12 +27,9 @@ return base::WrapUnique(new UsbServiceLinux()); #elif BUILDFLAG(IS_WIN) return base::WrapUnique(new UsbServiceWin()); -@@ -60,6 +64,8 @@ std::unique_ptr<UsbService> UsbService::Create() { - return base::WrapUnique(new UsbServiceMac()); - else - return base::WrapUnique(new UsbServiceImpl()); -+#elif BUILDFLAG(IS_BSD) + #elif BUILDFLAG(IS_MAC) + return base::WrapUnique(new UsbServiceImpl()); ++#elif BUILDFLAG(IS_BSD) + return base::WrapUnique(new UsbServiceImpl()); #else return nullptr; - #endif diff --git a/www/chromium/files/patch-services_network_BUILD.gn b/www/chromium/files/patch-services_network_BUILD.gn index b6c1305086f3..10f43d6030c0 100644 --- a/www/chromium/files/patch-services_network_BUILD.gn +++ b/www/chromium/files/patch-services_network_BUILD.gn @@ -1,6 +1,6 @@ ---- services/network/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- services/network/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ services/network/BUILD.gn -@@ -410,7 +410,6 @@ if (is_linux || is_chromeos) { +@@ -417,7 +417,6 @@ if (is_linux || is_chromeos) { ] deps = [ "//base:base", diff --git a/www/chromium/files/patch-services_network_network__context.cc b/www/chromium/files/patch-services_network_network__context.cc index 2fa7170bcc73..6740f701df54 100644 --- a/www/chromium/files/patch-services_network_network__context.cc +++ b/www/chromium/files/patch-services_network_network__context.cc @@ -1,6 +1,6 @@ ---- services/network/network_context.cc.orig 2024-04-19 13:02:56 UTC +--- services/network/network_context.cc.orig 2025-07-02 06:08:04 UTC +++ services/network/network_context.cc -@@ -523,7 +523,7 @@ NetworkContext::NetworkContextHttpAuthPreferences:: +@@ -611,7 +611,7 @@ NetworkContext::NetworkContextHttpAuthPreferences:: NetworkContext::NetworkContextHttpAuthPreferences:: ~NetworkContextHttpAuthPreferences() = default; @@ -9,7 +9,7 @@ bool NetworkContext::NetworkContextHttpAuthPreferences::AllowGssapiLibraryLoad() const { if (network_service_) { -@@ -2277,7 +2277,7 @@ void NetworkContext::OnHttpAuthDynamicParamsChanged( +@@ -2556,7 +2556,7 @@ void NetworkContext::OnHttpAuthDynamicParamsChanged( http_auth_dynamic_network_service_params->android_negotiate_account_type); #endif // BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-services_network_network__context.h b/www/chromium/files/patch-services_network_network__context.h index 7f5a7a0945c5..f7cb52d775ad 100644 --- a/www/chromium/files/patch-services_network_network__context.h +++ b/www/chromium/files/patch-services_network_network__context.h @@ -1,6 +1,6 @@ ---- services/network/network_context.h.orig 2024-04-19 13:02:56 UTC +--- services/network/network_context.h.orig 2025-07-02 06:08:04 UTC +++ services/network/network_context.h -@@ -670,7 +670,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext +@@ -730,7 +730,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext public: explicit NetworkContextHttpAuthPreferences(NetworkService* network_service); ~NetworkContextHttpAuthPreferences() override; diff --git a/www/chromium/files/patch-services_network_network__service.cc b/www/chromium/files/patch-services_network_network__service.cc index 39ac727da28d..2087a12e2163 100644 --- a/www/chromium/files/patch-services_network_network__service.cc +++ b/www/chromium/files/patch-services_network_network__service.cc @@ -1,15 +1,20 @@ ---- services/network/network_service.cc.orig 2024-04-19 13:02:56 UTC +--- services/network/network_service.cc.orig 2025-07-02 06:08:04 UTC +++ services/network/network_service.cc -@@ -97,7 +97,7 @@ +@@ -102,11 +102,11 @@ #include "third_party/boringssl/src/include/openssl/cpu.h" #endif --#if (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CASTOS)) || \ -+#if ((BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CASTOS)) || BUILDFLAG(IS_BSD)) || \ - BUILDFLAG(IS_CHROMEOS_LACROS) - +-#if BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CASTOS) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && !BUILDFLAG(IS_CASTOS) #include "components/os_crypt/sync/key_storage_config_linux.h" -@@ -978,7 +978,7 @@ void NetworkService::SetExplicitlyAllowedPorts( + #endif + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "services/network/network_change_notifier_passive_factory.h" + #endif + +@@ -1042,7 +1042,7 @@ void NetworkService::SetExplicitlyAllowedPorts( net::SetExplicitlyAllowedPorts(ports); } @@ -18,7 +23,7 @@ void NetworkService::SetGssapiLibraryLoadObserver( mojo::PendingRemote<mojom::GssapiLibraryLoadObserver> gssapi_library_load_observer) { -@@ -1060,7 +1060,7 @@ NetworkService::CreateHttpAuthHandlerFactory(NetworkCo +@@ -1148,7 +1148,7 @@ NetworkService::CreateHttpAuthHandlerFactory(NetworkCo ); } diff --git a/www/chromium/files/patch-services_network_network__service.h b/www/chromium/files/patch-services_network_network__service.h index fd7270da64d6..c2de826ab678 100644 --- a/www/chromium/files/patch-services_network_network__service.h +++ b/www/chromium/files/patch-services_network_network__service.h @@ -1,15 +1,15 @@ ---- services/network/network_service.h.orig 2024-04-19 13:02:56 UTC +--- services/network/network_service.h.orig 2025-07-02 06:08:04 UTC +++ services/network/network_service.h -@@ -229,7 +229,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkService - mojo::PendingReceiver<mojom::NetworkServiceTest> receiver) override; - void SetFirstPartySets(net::GlobalFirstPartySets sets) override; +@@ -251,7 +251,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkService + const std::vector<ContentSettingPatternSource>& settings) override; + void SetExplicitlyAllowedPorts(const std::vector<uint16_t>& ports) override; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) void SetGssapiLibraryLoadObserver( mojo::PendingRemote<mojom::GssapiLibraryLoadObserver> gssapi_library_load_observer) override; -@@ -255,7 +255,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkService +@@ -294,7 +294,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkService std::unique_ptr<net::HttpAuthHandlerFactory> CreateHttpAuthHandlerFactory( NetworkContext* network_context); @@ -18,7 +18,7 @@ // This is called just before a GSSAPI library may be loaded. void OnBeforeGssapiLibraryLoad(); #endif // BUILDFLAG(IS_LINUX) -@@ -481,7 +481,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkService +@@ -552,7 +552,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkService // leaking stale listeners between tests. std::unique_ptr<net::NetworkChangeNotifier> mock_network_change_notifier_; diff --git a/www/chromium/files/patch-services_network_public_cpp_BUILD.gn b/www/chromium/files/patch-services_network_public_cpp_BUILD.gn index 4f89278f6c1d..d3a3ec7f95e4 100644 --- a/www/chromium/files/patch-services_network_public_cpp_BUILD.gn +++ b/www/chromium/files/patch-services_network_public_cpp_BUILD.gn @@ -1,6 +1,6 @@ ---- services/network/public/cpp/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- services/network/public/cpp/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ services/network/public/cpp/BUILD.gn -@@ -486,7 +486,7 @@ component("cpp_base") { +@@ -654,7 +654,7 @@ component("cpp_base") { sources += [ "transferable_directory_fuchsia.cc" ] } diff --git a/www/chromium/files/patch-services_network_public_cpp_features.cc b/www/chromium/files/patch-services_network_public_cpp_features.cc index bd768ce9937e..255576606b5e 100644 --- a/www/chromium/files/patch-services_network_public_cpp_features.cc +++ b/www/chromium/files/patch-services_network_public_cpp_features.cc @@ -1,6 +1,6 @@ ---- services/network/public/cpp/features.cc.orig 2023-12-10 06:10:27 UTC +--- services/network/public/cpp/features.cc.orig 2025-07-02 06:08:04 UTC +++ services/network/public/cpp/features.cc -@@ -98,7 +98,7 @@ BASE_FEATURE(kSplitAuthCacheByNetworkIsolationKey, +@@ -109,7 +109,7 @@ BASE_FEATURE(kSplitAuthCacheByNetworkIsolationKey, BASE_FEATURE(kDnsOverHttpsUpgrade, "DnsOverHttpsUpgrade", #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ @@ -9,3 +9,12 @@ base::FEATURE_ENABLED_BY_DEFAULT #else base::FEATURE_DISABLED_BY_DEFAULT +@@ -359,7 +359,7 @@ BASE_FEATURE(kAvoidResourceRequestCopies, + BASE_FEATURE(kDocumentIsolationPolicy, + "DocumentIsolationPolicy", + #if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS) || \ +- BUILDFLAG(IS_LINUX) ++ BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT + #else + base::FEATURE_DISABLED_BY_DEFAULT diff --git a/www/chromium/files/patch-services_network_public_mojom_BUILD.gn b/www/chromium/files/patch-services_network_public_mojom_BUILD.gn index 4c4b8d386c12..a456691abc98 100644 --- a/www/chromium/files/patch-services_network_public_mojom_BUILD.gn +++ b/www/chromium/files/patch-services_network_public_mojom_BUILD.gn @@ -1,6 +1,6 @@ ---- services/network/public/mojom/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- services/network/public/mojom/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ services/network/public/mojom/BUILD.gn -@@ -522,11 +522,11 @@ mojom("url_loader_base") { +@@ -679,11 +679,11 @@ mojom("url_loader_base") { } enabled_features = [] @@ -11,15 +11,15 @@ - if (is_linux) { + if (is_linux && !is_bsd) { - # TODO(crbug.com/1431866): Remove this once is_linux in the mojom IDL does + # TODO(crbug.com/40263697): Remove this once is_linux in the mojom IDL does # not include lacros. enabled_features += [ "use_network_interface_change_listener" ] -@@ -1457,7 +1457,7 @@ mojom("mojom") { +@@ -1795,7 +1795,7 @@ mojom("mojom") { } } - if (is_linux) { + if (is_linux && !is_bsd) { - # TODO(crbug.com/1431866): Remove this once is_linux in the mojom IDL does + # TODO(crbug.com/40263697): Remove this once is_linux in the mojom IDL does # not include lacros. enabled_features += [ "use_network_interface_change_listener" ] diff --git a/www/chromium/files/patch-services_on__device__model_on__device__model__service.h b/www/chromium/files/patch-services_on__device__model_on__device__model__service.h index 134640cdf676..8ac8fd1a0d0f 100644 --- a/www/chromium/files/patch-services_on__device__model_on__device__model__service.h +++ b/www/chromium/files/patch-services_on__device__model_on__device__model__service.h @@ -1,8 +1,8 @@ ---- services/on_device_model/on_device_model_service.h.orig 2024-03-22 08:19:40 UTC +--- services/on_device_model/on_device_model_service.h.orig 2024-11-14 07:57:23 UTC +++ services/on_device_model/on_device_model_service.h -@@ -20,6 +20,10 @@ - #include "sandbox/policy/linux/sandbox_linux.h" - #endif +@@ -31,6 +31,10 @@ class OnDeviceModelInternalImpl; + class TsHolder; + } +#if BUILDFLAG(IS_BSD) +#include "sandbox/policy/sandbox.h" @@ -11,10 +11,10 @@ namespace on_device_model { class COMPONENT_EXPORT(ON_DEVICE_MODEL) OnDeviceModelService -@@ -29,7 +33,7 @@ class COMPONENT_EXPORT(ON_DEVICE_MODEL) OnDeviceModelS - // These are defined separately in pre_sandbox_init.cc for explicit security - // review coverage. - [[nodiscard]] static bool PreSandboxInit(); +@@ -44,7 +48,7 @@ class COMPONENT_EXPORT(ON_DEVICE_MODEL) OnDeviceModelS + // Must be called in the service's process after the run loop finished. + [[nodiscard]] static bool Shutdown(); + -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) static void AddSandboxLinuxOptions( diff --git a/www/chromium/files/patch-services_on__device__model_pre__sandbox__init.cc b/www/chromium/files/patch-services_on__device__model_pre__sandbox__init.cc index cff9a6577e68..f2c3ca39d2b4 100644 --- a/www/chromium/files/patch-services_on__device__model_pre__sandbox__init.cc +++ b/www/chromium/files/patch-services_on__device__model_pre__sandbox__init.cc @@ -1,4 +1,4 @@ ---- services/on_device_model/pre_sandbox_init.cc.orig 2024-01-30 07:53:34 UTC +--- services/on_device_model/pre_sandbox_init.cc.orig 2025-07-02 06:08:04 UTC +++ services/on_device_model/pre_sandbox_init.cc @@ -14,7 +14,7 @@ #include "services/on_device_model/ml/chrome_ml.h" // nogncheck @@ -7,9 +7,9 @@ -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "gpu/config/gpu_info_collector.h" // nogncheck - #include "third_party/dawn/include/dawn/dawn_proc.h" // nogncheck - #include "third_party/dawn/include/dawn/native/DawnNative.h" // nogncheck -@@ -25,7 +25,7 @@ namespace on_device_model { + #endif + +@@ -28,7 +28,7 @@ namespace on_device_model { namespace { @@ -18,16 +18,16 @@ constexpr uint32_t kVendorIdAMD = 0x1002; constexpr uint32_t kVendorIdIntel = 0x8086; constexpr uint32_t kVendorIdNVIDIA = 0x10DE; -@@ -74,7 +74,7 @@ bool OnDeviceModelService::PreSandboxInit() { - } - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Warm any relevant drivers before attempting to bring up the sandbox. For - // good measure we initialize a device instance for any adapter with an - // appropriate backend on top of any integrated or discrete GPU. -@@ -100,7 +100,7 @@ bool OnDeviceModelService::PreSandboxInit() { +@@ -62,7 +62,7 @@ void UpdateSandboxOptionsForGpu( + // enabling the sandbox. + BASE_FEATURE(kOnDeviceModelWarmDrivers, + "OnDeviceModelWarmDrivers", +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT + #else + base::FEATURE_DISABLED_BY_DEFAULT +@@ -127,7 +127,7 @@ bool OnDeviceModelService::PreSandboxInit() { return true; } diff --git a/www/chromium/files/patch-services_resource__coordinator_memory__instrumentation_queued__request__dispatcher.cc b/www/chromium/files/patch-services_resource__coordinator_memory__instrumentation_queued__request__dispatcher.cc index 6e06f87f08d7..11be16df0415 100644 --- a/www/chromium/files/patch-services_resource__coordinator_memory__instrumentation_queued__request__dispatcher.cc +++ b/www/chromium/files/patch-services_resource__coordinator_memory__instrumentation_queued__request__dispatcher.cc @@ -1,4 +1,4 @@ ---- services/resource_coordinator/memory_instrumentation/queued_request_dispatcher.cc.orig 2024-01-30 07:53:34 UTC +--- services/resource_coordinator/memory_instrumentation/queued_request_dispatcher.cc.orig 2025-06-17 06:32:04 UTC +++ services/resource_coordinator/memory_instrumentation/queued_request_dispatcher.cc @@ -54,7 +54,7 @@ uint32_t CalculatePrivateFootprintKb(const mojom::RawO uint32_t shared_resident_kb) { @@ -17,17 +17,17 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) os_dump->private_footprint_swap_kb = internal_os_dump.platform_private_footprint->vm_swap_bytes / 1024; - #endif -@@ -219,7 +219,7 @@ void QueuedRequestDispatcher::SetUpAndDispatch( + os_dump->mappings_count = internal_os_dump.mappings_count; +@@ -222,7 +222,7 @@ void QueuedRequestDispatcher::SetUpAndDispatch( // On most platforms each process can dump data about their own process // so ask each process to do so Linux is special see below. -#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) +#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS) && !BUILDFLAG(IS_BSD) request->pending_responses.insert({client_info.pid, ResponseType::kOSDump}); - client->RequestOSMemoryDump(request->memory_map_option(), - {base::kNullProcessId}, -@@ -234,7 +234,7 @@ void QueuedRequestDispatcher::SetUpAndDispatch( + client->RequestOSMemoryDump( + request->memory_map_option(), request->memory_dump_flags(), +@@ -237,7 +237,7 @@ void QueuedRequestDispatcher::SetUpAndDispatch( // In some cases, OS stats can only be dumped from a privileged process to // get around to sandboxing/selinux restrictions (see crbug.com/461788). @@ -36,7 +36,7 @@ std::vector<base::ProcessId> pids; mojom::ClientProcess* browser_client = nullptr; base::ProcessId browser_client_pid = base::kNullProcessId; -@@ -280,7 +280,7 @@ void QueuedRequestDispatcher::SetUpAndDispatchVmRegion +@@ -284,7 +284,7 @@ void QueuedRequestDispatcher::SetUpAndDispatchVmRegion const OsCallback& os_callback) { // On Linux, OS stats can only be dumped from a privileged process to // get around to sandboxing/selinux restrictions (see crbug.com/461788). @@ -45,7 +45,7 @@ mojom::ClientProcess* browser_client = nullptr; base::ProcessId browser_client_pid = 0; for (const auto& client_info : clients) { -@@ -330,7 +330,7 @@ QueuedRequestDispatcher::FinalizeVmRegionRequest( +@@ -334,7 +334,7 @@ QueuedRequestDispatcher::FinalizeVmRegionRequest( // each client process provides 1 OS dump, % the case where the client is // disconnected mid dump. OSMemDumpMap& extra_os_dumps = response.second.os_dumps; @@ -54,7 +54,7 @@ for (auto& kv : extra_os_dumps) { auto pid = kv.first == base::kNullProcessId ? original_pid : kv.first; DCHECK(results.find(pid) == results.end()); -@@ -391,7 +391,7 @@ void QueuedRequestDispatcher::Finalize(QueuedRequest* +@@ -395,7 +395,7 @@ void QueuedRequestDispatcher::Finalize(QueuedRequest* // crash). In the latter case (OS_LINUX) we expect the full map to come // from the browser process response. OSMemDumpMap& extra_os_dumps = response.second.os_dumps; diff --git a/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_BUILD.gn b/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_BUILD.gn index 7186abe305de..c39e93b3e49c 100644 --- a/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_BUILD.gn +++ b/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_BUILD.gn @@ -1,6 +1,6 @@ ---- services/resource_coordinator/public/cpp/memory_instrumentation/BUILD.gn.orig 2023-05-31 08:12:17 UTC +--- services/resource_coordinator/public/cpp/memory_instrumentation/BUILD.gn.orig 2025-02-19 07:43:18 UTC +++ services/resource_coordinator/public/cpp/memory_instrumentation/BUILD.gn -@@ -29,8 +29,12 @@ component("memory_instrumentation") { +@@ -27,8 +27,12 @@ component("memory_instrumentation") { sources += [ "os_metrics_win.cc" ] } diff --git a/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics.h b/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics.h index f91b0917c11f..4ed74d748c4c 100644 --- a/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics.h +++ b/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics.h @@ -1,17 +1,17 @@ ---- services/resource_coordinator/public/cpp/memory_instrumentation/os_metrics.h.orig 2022-02-28 16:54:41 UTC +--- services/resource_coordinator/public/cpp/memory_instrumentation/os_metrics.h.orig 2025-06-17 06:32:04 UTC +++ services/resource_coordinator/public/cpp/memory_instrumentation/os_metrics.h -@@ -45,7 +45,7 @@ class COMPONENT_EXPORT( - mojom::RawOSMemDump*); - static std::vector<mojom::VmRegionPtr> GetProcessMemoryMaps(base::ProcessId); +@@ -65,7 +65,7 @@ class COMPONENT_EXPORT( + static std::vector<mojom::VmRegionPtr> GetProcessMemoryMaps( + base::ProcessHandle); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) static void SetProcSmapsForTesting(FILE*); #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || // BUILDFLAG(IS_ANDROID) -@@ -62,7 +62,7 @@ class COMPONENT_EXPORT( - static std::vector<mojom::VmRegionPtr> GetProcessModules(base::ProcessId); - #endif +@@ -87,7 +87,7 @@ class COMPONENT_EXPORT( + GetMemoryInfo(base::ProcessHandle handle); + #endif // !BUILDFLAG(IS_APPLE) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics__bsd.cc b/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics__bsd.cc index cec6a7646af2..facff4f9072b 100644 --- a/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics__bsd.cc +++ b/www/chromium/files/patch-services_resource__coordinator_public_cpp_memory__instrumentation_os__metrics__bsd.cc @@ -1,6 +1,6 @@ ---- services/resource_coordinator/public/cpp/memory_instrumentation/os_metrics_bsd.cc.orig 2022-03-25 21:59:56 UTC +--- services/resource_coordinator/public/cpp/memory_instrumentation/os_metrics_bsd.cc.orig 2025-06-17 06:32:04 UTC +++ services/resource_coordinator/public/cpp/memory_instrumentation/os_metrics_bsd.cc -@@ -0,0 +1,58 @@ +@@ -0,0 +1,59 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. @@ -26,6 +26,7 @@ + +// static +bool OSMetrics::FillOSMemoryDump(base::ProcessId pid, ++ const MemDumpFlagSet& flags, + mojom::RawOSMemDump* dump) { + base::Process process = pid == base::kNullProcessId + ? base::Process::Current() diff --git a/www/chromium/files/patch-services_screen__ai_public_cpp_utilities.cc b/www/chromium/files/patch-services_screen__ai_public_cpp_utilities.cc index ba2d7ddc302e..58e4acfd7b3a 100644 --- a/www/chromium/files/patch-services_screen__ai_public_cpp_utilities.cc +++ b/www/chromium/files/patch-services_screen__ai_public_cpp_utilities.cc @@ -1,15 +1,15 @@ ---- services/screen_ai/public/cpp/utilities.cc.orig 2024-04-19 13:02:56 UTC +--- services/screen_ai/public/cpp/utilities.cc.orig 2025-07-02 06:08:04 UTC +++ services/screen_ai/public/cpp/utilities.cc -@@ -19,7 +19,7 @@ namespace screen_ai { - - namespace { +@@ -21,7 +21,7 @@ namespace { + // The maximum image dimension which is processed without downsampling by OCR. + constexpr uint32_t kMaxImageDimensionForOcr = 2048; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) constexpr char kBinaryPathSwitch[] = "screen-ai-binary"; #endif -@@ -40,7 +40,7 @@ constexpr char kScreenAIDlcRootPath[] = +@@ -42,7 +42,7 @@ constexpr char kScreenAIDlcRootPath[] = #endif #if BUILDFLAG(ENABLE_SCREEN_AI_BROWSERTESTS) @@ -18,7 +18,7 @@ constexpr base::FilePath::CharType kScreenAIResourcePathForTests[] = FILE_PATH_LITERAL("third_party/screen-ai/linux/resources"); #elif BUILDFLAG(IS_MAC) -@@ -127,7 +127,7 @@ base::FilePath GetComponentBinaryPathForTests() { +@@ -131,7 +131,7 @@ base::FilePath GetComponentBinaryPathForTests() { const char* GetBinaryPathSwitch() { // This is only used on Linux and ChromeOS. diff --git a/www/chromium/files/patch-services_screen__ai_sandbox_screen__ai__sandbox__hook__linux.cc b/www/chromium/files/patch-services_screen__ai_sandbox_screen__ai__sandbox__hook__linux.cc index 8b9d2a942f5c..6f0894c533ea 100644 --- a/www/chromium/files/patch-services_screen__ai_sandbox_screen__ai__sandbox__hook__linux.cc +++ b/www/chromium/files/patch-services_screen__ai_sandbox_screen__ai__sandbox__hook__linux.cc @@ -1,6 +1,6 @@ ---- services/screen_ai/sandbox/screen_ai_sandbox_hook_linux.cc.orig 2024-04-19 13:02:56 UTC +--- services/screen_ai/sandbox/screen_ai_sandbox_hook_linux.cc.orig 2025-03-05 08:14:56 UTC +++ services/screen_ai/sandbox/screen_ai_sandbox_hook_linux.cc -@@ -53,6 +53,7 @@ bool ScreenAIPreSandboxHook(base::FilePath binary_path +@@ -58,6 +58,7 @@ bool ScreenAIPreSandboxHook(base::FilePath binary_path } } @@ -8,7 +8,7 @@ auto* instance = sandbox::policy::SandboxLinux::GetInstance(); std::vector<BrokerFilePermission> permissions{ -@@ -75,6 +76,7 @@ bool ScreenAIPreSandboxHook(base::FilePath binary_path +@@ -79,6 +80,7 @@ bool ScreenAIPreSandboxHook(base::FilePath binary_path sandbox::syscall_broker::COMMAND_OPEN}), permissions, options); instance->EngageNamespaceSandboxIfPossible(); diff --git a/www/chromium/files/patch-services_service__manager_BUILD.gn b/www/chromium/files/patch-services_service__manager_BUILD.gn index feeef0b864c2..66121a4ca8ac 100644 --- a/www/chromium/files/patch-services_service__manager_BUILD.gn +++ b/www/chromium/files/patch-services_service__manager_BUILD.gn @@ -1,6 +1,6 @@ ---- services/service_manager/BUILD.gn.orig 2021-12-31 00:57:38 UTC +--- services/service_manager/BUILD.gn.orig 2025-02-19 07:43:18 UTC +++ services/service_manager/BUILD.gn -@@ -67,7 +67,7 @@ source_set("service_manager") { +@@ -65,7 +65,7 @@ source_set("service_manager") { ] } diff --git a/www/chromium/files/patch-services_tracing_public_cpp_system__metrics__sampler.cc b/www/chromium/files/patch-services_tracing_public_cpp_system__metrics__sampler.cc new file mode 100644 index 000000000000..1522c753e19e --- /dev/null +++ b/www/chromium/files/patch-services_tracing_public_cpp_system__metrics__sampler.cc @@ -0,0 +1,13 @@ +--- services/tracing/public/cpp/system_metrics_sampler.cc.orig 2025-05-28 14:55:43 UTC ++++ services/tracing/public/cpp/system_metrics_sampler.cc +@@ -166,8 +166,8 @@ void SystemMetricsSampler::ProcessSampler::SampleProce + TRACE_COUNTER(TRACE_DISABLED_BY_DEFAULT("system_metrics"), + "PhysicalMemoryFootprint", + memory_info->physical_footprint_bytes); +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ +- BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) ++#elif (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA)) && defined(notyet) + TRACE_COUNTER(TRACE_DISABLED_BY_DEFAULT("system_metrics"), "VmSwapMemory", + memory_info->vm_swap_bytes); + TRACE_COUNTER(TRACE_DISABLED_BY_DEFAULT("system_metrics"), "RssAnonMemory", diff --git a/www/chromium/files/patch-services_tracing_public_cpp_trace__startup.cc b/www/chromium/files/patch-services_tracing_public_cpp_trace__startup.cc new file mode 100644 index 000000000000..72c022d67d2b --- /dev/null +++ b/www/chromium/files/patch-services_tracing_public_cpp_trace__startup.cc @@ -0,0 +1,11 @@ +--- services/tracing/public/cpp/trace_startup.cc.orig 2025-07-02 06:08:04 UTC ++++ services/tracing/public/cpp/trace_startup.cc +@@ -66,7 +66,7 @@ void EnableStartupTracingIfNeeded(bool with_thread) { + // Create the PerfettoTracedProcess. + if (with_thread) { + g_tracing_with_thread = true; +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + PerfettoTracedProcess::MaybeCreateInstanceWithThread( + /*will_trace_thread_restart=*/true); + #else diff --git a/www/chromium/files/patch-services_video__capture_video__capture__service__impl.cc b/www/chromium/files/patch-services_video__capture_video__capture__service__impl.cc deleted file mode 100644 index 6b3eb915dba5..000000000000 --- a/www/chromium/files/patch-services_video__capture_video__capture__service__impl.cc +++ /dev/null @@ -1,38 +0,0 @@ ---- services/video_capture/video_capture_service_impl.cc.orig 2024-02-23 21:04:38 UTC -+++ services/video_capture/video_capture_service_impl.cc -@@ -41,7 +41,7 @@ - #include "services/video_capture/lacros/device_factory_adapter_lacros.h" - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "media/capture/capture_switches.h" - #include "media/capture/video/video_capture_gpu_channel_host.h" - #include "services/viz/public/cpp/gpu/context_provider_command_buffer.h" -@@ -109,7 +109,7 @@ class VideoCaptureServiceImpl::GpuDependenciesContext - this}; - }; - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - // Intended usage of this class is to create viz::Gpu in utility process and - // connect to viz::GpuClient of browser process, which will call to Gpu service. - // Also, this class holds the viz::ContextProvider to listen and monitor Gpu -@@ -307,7 +307,7 @@ void VideoCaptureServiceImpl::LazyInitializeGpuDepende - gpu_dependencies_context_ = std::make_unique<GpuDependenciesContext>(); - - #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) --#if BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - { - #else - if (switches::IsVideoCaptureUseGpuMemoryBufferEnabled()) { -@@ -421,7 +421,7 @@ void VideoCaptureServiceImpl::OnGpuInfoUpdate(const CH - } - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - void VideoCaptureServiceImpl::SetVizGpu(std::unique_ptr<viz::Gpu> viz_gpu) { - viz_gpu_ = std::move(viz_gpu); - } diff --git a/www/chromium/files/patch-services_video__capture_video__capture__service__impl.h b/www/chromium/files/patch-services_video__capture_video__capture__service__impl.h deleted file mode 100644 index c387ac95d5c0..000000000000 --- a/www/chromium/files/patch-services_video__capture_video__capture__service__impl.h +++ /dev/null @@ -1,29 +0,0 @@ ---- services/video_capture/video_capture_service_impl.h.orig 2024-02-23 21:04:38 UTC -+++ services/video_capture/video_capture_service_impl.h -@@ -26,7 +26,7 @@ - #include "services/video_capture/ash/video_capture_device_factory_ash.h" - #endif // BUILDFLAG(IS_CHROMEOS_ASH) - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - #include "services/viz/public/cpp/gpu/gpu.h" - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || - // BUILDFLAG(IS_CHROMEOS_ASH) -@@ -70,7 +70,7 @@ class VideoCaptureServiceImpl : public mojom::VideoCap - #if BUILDFLAG(IS_WIN) - void OnGpuInfoUpdate(const CHROME_LUID& luid) override; - #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - void SetVizGpu(std::unique_ptr<viz::Gpu> viz_gpu); - #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || - // BUILDFLAG(IS_CHROMEOS_ASH) -@@ -107,7 +107,7 @@ class VideoCaptureServiceImpl : public mojom::VideoCap - factory_receivers_ash_; - #endif - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_BSD) - class VizGpuContextProvider; - std::unique_ptr<VizGpuContextProvider> viz_gpu_context_provider_; - std::unique_ptr<viz::Gpu> viz_gpu_; diff --git a/www/chromium/files/patch-services_video__effects_video__effects__sandbox__hook__linux.cc b/www/chromium/files/patch-services_video__effects_video__effects__sandbox__hook__linux.cc new file mode 100644 index 000000000000..99b5d37be9e1 --- /dev/null +++ b/www/chromium/files/patch-services_video__effects_video__effects__sandbox__hook__linux.cc @@ -0,0 +1,27 @@ +--- services/video_effects/video_effects_sandbox_hook_linux.cc.orig 2025-02-19 07:43:18 UTC ++++ services/video_effects/video_effects_sandbox_hook_linux.cc +@@ -6,7 +6,13 @@ + + #include <dlfcn.h> + ++#include "build/build_config.h" ++ ++#if BUILDFLAG(IS_BSD) ++#include "sandbox/policy/sandbox.h" ++#else + #include "sandbox/policy/linux/sandbox_linux.h" ++#endif + #include "services/on_device_model/ml/chrome_ml_holder.h" + + namespace video_effects { +@@ -29,8 +35,10 @@ bool VideoEffectsPreSandboxHook( + DVLOG(1) << "Successfully opened Chrome ML shared library."; + } + ++#if !BUILDFLAG(IS_BSD) + auto* instance = sandbox::policy::SandboxLinux::GetInstance(); + instance->EngageNamespaceSandboxIfPossible(); ++#endif + return true; + } + diff --git a/www/chromium/files/patch-services_video__effects_video__effects__sandbox__hook__linux.h b/www/chromium/files/patch-services_video__effects_video__effects__sandbox__hook__linux.h new file mode 100644 index 000000000000..2db51ef5a895 --- /dev/null +++ b/www/chromium/files/patch-services_video__effects_video__effects__sandbox__hook__linux.h @@ -0,0 +1,16 @@ +--- services/video_effects/video_effects_sandbox_hook_linux.h.orig 2024-11-14 07:57:23 UTC ++++ services/video_effects/video_effects_sandbox_hook_linux.h +@@ -5,7 +5,13 @@ + #ifndef SERVICES_VIDEO_EFFECTS_VIDEO_EFFECTS_SANDBOX_HOOK_LINUX_H_ + #define SERVICES_VIDEO_EFFECTS_VIDEO_EFFECTS_SANDBOX_HOOK_LINUX_H_ + ++#include "build/build_config.h" ++ ++#if BUILDFLAG(IS_BSD) ++#include "sandbox/policy/sandbox.h" ++#else + #include "sandbox/policy/linux/sandbox_linux.h" ++#endif + + namespace video_effects { + diff --git a/www/chromium/files/patch-services_viz_public_mojom_BUILD.gn b/www/chromium/files/patch-services_viz_public_mojom_BUILD.gn new file mode 100644 index 000000000000..d5893839ff74 --- /dev/null +++ b/www/chromium/files/patch-services_viz_public_mojom_BUILD.gn @@ -0,0 +1,11 @@ +--- services/viz/public/mojom/BUILD.gn.orig 2025-05-28 14:55:43 UTC ++++ services/viz/public/mojom/BUILD.gn +@@ -57,7 +57,7 @@ mojom("mojom") { + + # Used in thread.mojom + enabled_features = [] +- if (is_fuchsia || is_apple) { ++ if (is_fuchsia || is_apple || is_bsd) { + enabled_features += [ "thread_id_is_64_bit" ] + } else { + enabled_features += [ "thread_id_is_32_bit" ] diff --git a/www/chromium/files/patch-skia_ext_SkMemory__new__handler.cpp b/www/chromium/files/patch-skia_ext_SkMemory__new__handler.cpp index 15ca4c0a510d..f1eecda7f683 100644 --- a/www/chromium/files/patch-skia_ext_SkMemory__new__handler.cpp +++ b/www/chromium/files/patch-skia_ext_SkMemory__new__handler.cpp @@ -1,6 +1,6 @@ ---- skia/ext/SkMemory_new_handler.cpp.orig 2024-04-19 13:02:56 UTC +--- skia/ext/SkMemory_new_handler.cpp.orig 2025-03-05 08:14:56 UTC +++ skia/ext/SkMemory_new_handler.cpp -@@ -19,7 +19,7 @@ +@@ -24,7 +24,7 @@ #include <windows.h> #elif BUILDFLAG(IS_APPLE) #include <malloc/malloc.h> @@ -9,7 +9,7 @@ #include <malloc.h> #endif -@@ -92,7 +92,7 @@ static void* malloc_nothrow(size_t size) { +@@ -110,7 +110,7 @@ static void* malloc_nothrow(size_t size, int debug_sen // TODO(b.kelemen): we should always use UncheckedMalloc but currently it // doesn't work as intended everywhere. void* result; diff --git a/www/chromium/files/patch-skia_ext_font__utils.cc b/www/chromium/files/patch-skia_ext_font__utils.cc index da9f64719fac..ab91a0543b0e 100644 --- a/www/chromium/files/patch-skia_ext_font__utils.cc +++ b/www/chromium/files/patch-skia_ext_font__utils.cc @@ -1,6 +1,6 @@ ---- skia/ext/font_utils.cc.orig 2024-02-23 21:04:38 UTC +--- skia/ext/font_utils.cc.orig 2025-05-05 10:57:53 UTC +++ skia/ext/font_utils.cc -@@ -19,7 +19,7 @@ +@@ -21,7 +21,7 @@ #include "third_party/skia/include/ports/SkFontMgr_mac_ct.h" #endif @@ -8,13 +8,13 @@ +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "third_party/skia/include/ports/SkFontConfigInterface.h" #include "third_party/skia/include/ports/SkFontMgr_FontConfigInterface.h" - #endif -@@ -60,7 +60,7 @@ static sk_sp<SkFontMgr> fontmgr_factory() { - return SkFontMgr_New_Android(nullptr); + #include "third_party/skia/include/ports/SkFontScanner_Fontations.h" +@@ -67,7 +67,7 @@ static sk_sp<SkFontMgr> fontmgr_factory() { + } #elif BUILDFLAG(IS_APPLE) return SkFontMgr_New_CoreText(nullptr); -#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) sk_sp<SkFontConfigInterface> fci(SkFontConfigInterface::RefGlobal()); - return fci ? SkFontMgr_New_FCI(std::move(fci)) : nullptr; - #elif BUILDFLAG(IS_FUCHSIA) + if (base::FeatureList::IsEnabled(skia::kFontationsLinuxSystemFonts)) { + return fci ? SkFontMgr_New_FCI(std::move(fci), diff --git a/www/chromium/files/patch-skia_ext_skcolorspace__trfn.cc b/www/chromium/files/patch-skia_ext_skcolorspace__trfn.cc index aa190c198a0b..7e7dd2bfef35 100644 --- a/www/chromium/files/patch-skia_ext_skcolorspace__trfn.cc +++ b/www/chromium/files/patch-skia_ext_skcolorspace__trfn.cc @@ -1,4 +1,4 @@ ---- skia/ext/skcolorspace_trfn.cc.orig 2023-08-17 07:33:31 UTC +--- skia/ext/skcolorspace_trfn.cc.orig 2025-03-05 08:14:56 UTC +++ skia/ext/skcolorspace_trfn.cc @@ -2,6 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be @@ -8,4 +8,4 @@ + #include "skia/ext/skcolorspace_trfn.h" - #include <cmath> + #include <array> diff --git a/www/chromium/files/patch-third__party_abseil-cpp_absl_base_config.h b/www/chromium/files/patch-third__party_abseil-cpp_absl_base_config.h index 1b735cf9bda2..7f72dc12f3ed 100644 --- a/www/chromium/files/patch-third__party_abseil-cpp_absl_base_config.h +++ b/www/chromium/files/patch-third__party_abseil-cpp_absl_base_config.h @@ -1,6 +1,6 @@ ---- third_party/abseil-cpp/absl/base/config.h.orig 2024-03-22 08:19:40 UTC +--- third_party/abseil-cpp/absl/base/config.h.orig 2025-05-05 10:57:53 UTC +++ third_party/abseil-cpp/absl/base/config.h -@@ -448,7 +448,7 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != +@@ -409,7 +409,7 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != #ifdef ABSL_HAVE_SCHED_YIELD #error ABSL_HAVE_SCHED_YIELD cannot be directly set #elif defined(__linux__) || defined(__ros__) || defined(__native_client__) || \ @@ -9,7 +9,7 @@ #define ABSL_HAVE_SCHED_YIELD 1 #endif -@@ -463,7 +463,8 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != +@@ -424,7 +424,8 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != // platforms. #ifdef ABSL_HAVE_SEMAPHORE_H #error ABSL_HAVE_SEMAPHORE_H cannot be directly set diff --git a/www/chromium/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc b/www/chromium/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc index 6d0470330d08..21ed864d5f1a 100644 --- a/www/chromium/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc +++ b/www/chromium/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc @@ -1,4 +1,4 @@ ---- third_party/abseil-cpp/absl/base/internal/sysinfo.cc.orig 2023-11-03 10:09:45 UTC +--- third_party/abseil-cpp/absl/base/internal/sysinfo.cc.orig 2024-09-30 07:45:04 UTC +++ third_party/abseil-cpp/absl/base/internal/sysinfo.cc @@ -30,7 +30,7 @@ #include <sys/syscall.h> @@ -9,7 +9,7 @@ #include <sys/sysctl.h> #endif -@@ -194,6 +194,7 @@ static double GetNominalCPUFrequency() { +@@ -198,6 +198,7 @@ static double GetNominalCPUFrequency() { #else @@ -17,7 +17,7 @@ // Helper function for reading a long from a file. Returns true if successful // and the memory location pointed to by value is set to the value read. static bool ReadLongFromFile(const char *file, long *value) { -@@ -226,6 +227,7 @@ static bool ReadLongFromFile(const char *file, long *v +@@ -230,6 +231,7 @@ static bool ReadLongFromFile(const char *file, long *v } return ret; } @@ -25,7 +25,7 @@ #if defined(ABSL_INTERNAL_UNSCALED_CYCLECLOCK_FREQUENCY_IS_CPU_FREQUENCY) -@@ -325,9 +327,11 @@ static double GetNominalCPUFrequency() { +@@ -329,9 +331,11 @@ static double GetNominalCPUFrequency() { // a new mode (turbo mode). Essentially, those frequencies cannot // always be relied upon. The same reasons apply to /proc/cpuinfo as // well. @@ -37,7 +37,7 @@ #if defined(ABSL_INTERNAL_UNSCALED_CYCLECLOCK_FREQUENCY_IS_CPU_FREQUENCY) // On these platforms, the TSC frequency is the nominal CPU -@@ -346,10 +350,12 @@ static double GetNominalCPUFrequency() { +@@ -350,10 +354,12 @@ static double GetNominalCPUFrequency() { // If CPU scaling is in effect, we want to use the *maximum* // frequency, not whatever CPU speed some random processor happens // to be using now. @@ -50,7 +50,7 @@ return 1.0; #endif // !ABSL_INTERNAL_UNSCALED_CYCLECLOCK_FREQUENCY_IS_CPU_FREQUENCY -@@ -459,6 +465,12 @@ pid_t GetTID() { +@@ -463,6 +469,12 @@ pid_t GetTID() { static_assert(sizeof(pid_t) == sizeof(thread), "In NaCL int expected to be the same size as a pointer"); return reinterpret_cast<pid_t>(thread); @@ -62,4 +62,4 @@ + return getthrid(); } - #else + #elif defined(__Fuchsia__) diff --git a/www/chromium/files/patch-third__party_abseil-cpp_absl_debugging_internal_elf__mem__image.h b/www/chromium/files/patch-third__party_abseil-cpp_absl_debugging_internal_elf__mem__image.h index 0508ad5bfa24..056ea45c4f02 100644 --- a/www/chromium/files/patch-third__party_abseil-cpp_absl_debugging_internal_elf__mem__image.h +++ b/www/chromium/files/patch-third__party_abseil-cpp_absl_debugging_internal_elf__mem__image.h @@ -1,11 +1,12 @@ ---- third_party/abseil-cpp/absl/debugging/internal/elf_mem_image.h.orig 2023-09-13 12:11:42 UTC +--- third_party/abseil-cpp/absl/debugging/internal/elf_mem_image.h.orig 2025-01-15 09:18:26 UTC +++ third_party/abseil-cpp/absl/debugging/internal/elf_mem_image.h -@@ -34,7 +34,7 @@ +@@ -35,7 +35,8 @@ #if defined(__ELF__) && !defined(__OpenBSD__) && !defined(__QNX__) && \ !defined(__native_client__) && !defined(__asmjs__) && \ !defined(__wasm__) && !defined(__HAIKU__) && !defined(__sun) && \ -- !defined(__VXWORKS__) && !defined(__hexagon__) -+ !defined(__VXWORKS__) && !defined(__hexagon__) && !defined(__FreeBSD__) +- !defined(__VXWORKS__) && !defined(__hexagon__) && !defined(__XTENSA__) ++ !defined(__VXWORKS__) && !defined(__hexagon__) && !defined(__XTENSA__) && \ ++ !defined(__FreeBSD__) #define ABSL_HAVE_ELF_MEM_IMAGE 1 #endif diff --git a/www/chromium/files/patch-third__party_angle_BUILD.gn b/www/chromium/files/patch-third__party_angle_BUILD.gn index 156a5b389d2c..2a40c4629f1c 100644 --- a/www/chromium/files/patch-third__party_angle_BUILD.gn +++ b/www/chromium/files/patch-third__party_angle_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/angle/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- third_party/angle/BUILD.gn.orig 2025-05-28 14:55:43 UTC +++ third_party/angle/BUILD.gn -@@ -335,7 +335,6 @@ config("extra_warnings") { +@@ -360,7 +360,6 @@ config("extra_warnings") { "-Wtautological-type-limit-compare", "-Wundefined-reinterpret-cast", "-Wunneeded-internal-declaration", @@ -8,7 +8,7 @@ "-Wsuggest-destructor-override", "-Wsuggest-override", -@@ -506,7 +505,7 @@ template("angle_common_lib") { +@@ -537,7 +536,7 @@ template("angle_common_lib") { all_dependent_configs = [ ":angle_disable_pool_alloc" ] } @@ -17,7 +17,7 @@ libs = [ "dl" ] } -@@ -661,6 +660,9 @@ angle_static_library("angle_gpu_info_util") { +@@ -692,6 +691,9 @@ angle_static_library("angle_gpu_info_util") { "Xi", "Xext", ] diff --git a/www/chromium/files/patch-third__party_angle_src_common_platform.h b/www/chromium/files/patch-third__party_angle_src_common_platform.h index 19c34403d542..1669015e497a 100644 --- a/www/chromium/files/patch-third__party_angle_src_common_platform.h +++ b/www/chromium/files/patch-third__party_angle_src_common_platform.h @@ -1,6 +1,6 @@ ---- third_party/angle/src/common/platform.h.orig 2022-02-07 13:39:41 UTC +--- third_party/angle/src/common/platform.h.orig 2025-05-05 10:57:53 UTC +++ third_party/angle/src/common/platform.h -@@ -26,7 +26,15 @@ +@@ -23,7 +23,15 @@ #elif defined(__linux__) || defined(EMSCRIPTEN) # define ANGLE_PLATFORM_LINUX 1 # define ANGLE_PLATFORM_POSIX 1 diff --git a/www/chromium/files/patch-third__party_angle_src_common_system__utils__linux.cpp b/www/chromium/files/patch-third__party_angle_src_common_system__utils__linux.cpp index f76afa7e10d6..54e9b2220087 100644 --- a/www/chromium/files/patch-third__party_angle_src_common_system__utils__linux.cpp +++ b/www/chromium/files/patch-third__party_angle_src_common_system__utils__linux.cpp @@ -1,20 +1,22 @@ ---- third_party/angle/src/common/system_utils_linux.cpp.orig 2024-01-30 07:53:34 UTC +--- third_party/angle/src/common/system_utils_linux.cpp.orig 2025-02-19 07:43:18 UTC +++ third_party/angle/src/common/system_utils_linux.cpp -@@ -15,8 +15,13 @@ - - #include <array> +@@ -15,10 +15,15 @@ + #include <sys/types.h> + #include <unistd.h> +#if ANGLE_PLATFORM_OPENBSD +#include <pthread_np.h> +#endif + + #include <array> + namespace angle { +#if ANGLE_PLATFORM_LINUX std::string GetExecutablePath() { // We cannot use lstat to get the size of /proc/self/exe as it always returns 0 -@@ -32,6 +37,7 @@ std::string GetExecutablePath() +@@ -34,6 +39,7 @@ std::string GetExecutablePath() path[result] = '\0'; return path; } @@ -22,10 +24,10 @@ std::string GetExecutableDirectory() { -@@ -56,6 +62,10 @@ void SetCurrentThreadName(const char *name) - { +@@ -59,6 +65,10 @@ void SetCurrentThreadName(const char *name) // There's a 15-character (16 including '\0') limit. If the name is too big (and ERANGE is - // returned), just ignore the name. + // returned), name will be ignored. + ASSERT(strlen(name) < 16); +#if ANGLE_PLATFORM_OPENBSD + pthread_set_name_np(pthread_self(), name); +#else diff --git a/www/chromium/files/patch-third__party_angle_src_libANGLE_Display.cpp b/www/chromium/files/patch-third__party_angle_src_libANGLE_Display.cpp index 1efaa5b7a797..cc9c21c8f280 100644 --- a/www/chromium/files/patch-third__party_angle_src_libANGLE_Display.cpp +++ b/www/chromium/files/patch-third__party_angle_src_libANGLE_Display.cpp @@ -1,16 +1,16 @@ ---- third_party/angle/src/libANGLE/Display.cpp.orig 2024-04-19 13:02:56 UTC +--- third_party/angle/src/libANGLE/Display.cpp.orig 2025-05-28 14:55:43 UTC +++ third_party/angle/src/libANGLE/Display.cpp -@@ -60,7 +60,7 @@ +@@ -58,7 +58,7 @@ + # include "libANGLE/renderer/gl/wgl/DisplayWGL.h" + # elif ANGLE_ENABLE_CGL # include "libANGLE/renderer/gl/cgl/DisplayCGL.h" - # elif ANGLE_ENABLE_EAGL - # include "libANGLE/renderer/gl/eagl/DisplayEAGL.h" -# elif defined(ANGLE_PLATFORM_LINUX) +# elif defined(ANGLE_PLATFORM_LINUX) || defined(ANGLE_PLATFORM_BSD) # include "libANGLE/renderer/gl/egl/DisplayEGL.h" # if defined(ANGLE_USE_X11) # include "libANGLE/renderer/gl/glx/DisplayGLX_api.h" -@@ -419,7 +419,7 @@ rx::DisplayImpl *CreateDisplayFromAttribs(EGLAttrib di - impl = new rx::DisplayEAGL(state); +@@ -422,7 +422,7 @@ rx::DisplayImpl *CreateDisplayFromAttribs(EGLAttrib di + impl = new rx::DisplayCGL(state); break; -# elif defined(ANGLE_PLATFORM_LINUX) @@ -18,7 +18,7 @@ # if defined(ANGLE_USE_GBM) if (platformType == 0) { -@@ -465,7 +465,7 @@ rx::DisplayImpl *CreateDisplayFromAttribs(EGLAttrib di +@@ -468,7 +468,7 @@ rx::DisplayImpl *CreateDisplayFromAttribs(EGLAttrib di #if defined(ANGLE_ENABLE_OPENGL) # if defined(ANGLE_PLATFORM_WINDOWS) impl = new rx::DisplayWGL(state); @@ -27,7 +27,7 @@ # if defined(ANGLE_USE_GBM) if (platformType == 0) { -@@ -516,7 +516,7 @@ rx::DisplayImpl *CreateDisplayFromAttribs(EGLAttrib di +@@ -519,7 +519,7 @@ rx::DisplayImpl *CreateDisplayFromAttribs(EGLAttrib di impl = rx::CreateVulkanWin32Display(state); } break; @@ -36,7 +36,16 @@ # if defined(ANGLE_USE_GBM) if (platformType == EGL_PLATFORM_GBM_KHR && rx::IsVulkanGbmDisplayAvailable()) { -@@ -2158,7 +2158,7 @@ static ClientExtensions GenerateClientExtensions() +@@ -2136,7 +2136,7 @@ static ClientExtensions GenerateClientExtensions() + extensions.platformWaylandEXT = true; + #endif + +-#if defined(ANGLE_PLATFORM_LINUX) && (defined(ANGLE_ENABLE_OPENGL) || defined(ANGLE_ENABLE_VULKAN)) ++#if (defined(ANGLE_PLATFORM_LINUX) || defined(ANGLE_PLATFORM_BSD)) && (defined(ANGLE_ENABLE_OPENGL) || defined(ANGLE_ENABLE_VULKAN)) + extensions.platformSurfacelessMESA = true; + #endif + +@@ -2183,7 +2183,7 @@ static ClientExtensions GenerateClientExtensions() extensions.x11Visual = true; #endif diff --git a/www/chromium/files/patch-third__party_angle_src_libANGLE_formatutils.cpp b/www/chromium/files/patch-third__party_angle_src_libANGLE_formatutils.cpp deleted file mode 100644 index e9a1110eb55c..000000000000 --- a/www/chromium/files/patch-third__party_angle_src_libANGLE_formatutils.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- third_party/angle/src/libANGLE/formatutils.cpp.orig 2023-10-11 18:22:24 UTC -+++ third_party/angle/src/libANGLE/formatutils.cpp -@@ -1475,7 +1475,7 @@ static InternalFormatInfoMap BuildInternalFormatInfoMa - AddYUVFormat(&map, GL_G8_B8R8_2PLANE_420_UNORM_ANGLE, true, 8, 8, 8, 0, 0, GL_G8_B8R8_2PLANE_420_UNORM_ANGLE, GL_UNSIGNED_BYTE, GL_UNSIGNED_NORMALIZED, false, RequireExt<&Extensions::yuvInternalFormatANGLE>, RequireExt<&Extensions::yuvInternalFormatANGLE>, RequireExt<&Extensions::yuvInternalFormatANGLE>, NeverSupported, NeverSupported); - AddYUVFormat(&map, GL_G8_B8_R8_3PLANE_420_UNORM_ANGLE, true, 8, 8, 8, 0, 0, GL_G8_B8_R8_3PLANE_420_UNORM_ANGLE, GL_UNSIGNED_BYTE, GL_UNSIGNED_NORMALIZED, false, RequireExt<&Extensions::yuvInternalFormatANGLE>, RequireExt<&Extensions::yuvInternalFormatANGLE>, RequireExt<&Extensions::yuvInternalFormatANGLE>, NeverSupported, NeverSupported); - --#if defined(ANGLE_PLATFORM_LINUX) -+#if defined(ANGLE_PLATFORM_LINUX) || defined(ANGLE_PLATFORM_BSD) - // From GL_OES_required_internalformat - // The |shared| bit shouldn't be 2. But given this hits assertion when bits - // are checked, it's fine to have this bit set as 2 as a workaround. diff --git a/www/chromium/files/patch-third__party_angle_util_BUILD.gn b/www/chromium/files/patch-third__party_angle_util_BUILD.gn index fbf8a53a5840..2bd296520ce2 100644 --- a/www/chromium/files/patch-third__party_angle_util_BUILD.gn +++ b/www/chromium/files/patch-third__party_angle_util_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/angle/util/BUILD.gn.orig 2023-08-17 07:33:31 UTC +--- third_party/angle/util/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ third_party/angle/util/BUILD.gn -@@ -311,7 +311,7 @@ foreach(is_shared_library, +@@ -332,7 +332,7 @@ foreach(is_shared_library, ] libs = [] diff --git a/www/chromium/files/patch-third__party_blink_common_renderer__preferences_renderer__preferences__mojom__traits.cc b/www/chromium/files/patch-third__party_blink_common_renderer__preferences_renderer__preferences__mojom__traits.cc index 058231b2beb8..d2dd295605bb 100644 --- a/www/chromium/files/patch-third__party_blink_common_renderer__preferences_renderer__preferences__mojom__traits.cc +++ b/www/chromium/files/patch-third__party_blink_common_renderer__preferences_renderer__preferences__mojom__traits.cc @@ -1,6 +1,6 @@ ---- third_party/blink/common/renderer_preferences/renderer_preferences_mojom_traits.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/common/renderer_preferences/renderer_preferences_mojom_traits.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/blink/common/renderer_preferences/renderer_preferences_mojom_traits.cc -@@ -68,7 +68,7 @@ bool StructTraits<blink::mojom::RendererPreferencesDat +@@ -77,7 +77,7 @@ bool StructTraits<blink::mojom::RendererPreferencesDat out->send_subresource_notification = data.send_subresource_notification(); diff --git a/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences.h b/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences.h index 9aa5fadb915f..09a660bc7f41 100644 --- a/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences.h +++ b/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences.h @@ -1,4 +1,4 @@ ---- third_party/blink/public/common/renderer_preferences/renderer_preferences.h.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/public/common/renderer_preferences/renderer_preferences.h.orig 2025-02-19 07:43:18 UTC +++ third_party/blink/public/common/renderer_preferences/renderer_preferences.h @@ -65,7 +65,7 @@ struct BLINK_COMMON_EXPORT RendererPreferences { UserAgentOverride user_agent_override; diff --git a/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences__mojom__traits.h b/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences__mojom__traits.h index eec17aa652b5..55383cb9bf0b 100644 --- a/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences__mojom__traits.h +++ b/www/chromium/files/patch-third__party_blink_public_common_renderer__preferences_renderer__preferences__mojom__traits.h @@ -1,6 +1,6 @@ ---- third_party/blink/public/common/renderer_preferences/renderer_preferences_mojom_traits.h.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/public/common/renderer_preferences/renderer_preferences_mojom_traits.h.orig 2025-02-19 07:43:18 UTC +++ third_party/blink/public/common/renderer_preferences/renderer_preferences_mojom_traits.h -@@ -166,7 +166,7 @@ struct BLINK_COMMON_EXPORT +@@ -180,7 +180,7 @@ struct BLINK_COMMON_EXPORT return data.send_subresource_notification; } diff --git a/www/chromium/files/patch-third__party_blink_public_platform_platform.h b/www/chromium/files/patch-third__party_blink_public_platform_platform.h index 9f079a88b353..9f817dd4a559 100644 --- a/www/chromium/files/patch-third__party_blink_public_platform_platform.h +++ b/www/chromium/files/patch-third__party_blink_public_platform_platform.h @@ -1,6 +1,6 @@ ---- third_party/blink/public/platform/platform.h.orig 2024-04-12 16:47:14 UTC +--- third_party/blink/public/platform/platform.h.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/public/platform/platform.h -@@ -347,7 +347,7 @@ class BLINK_PLATFORM_EXPORT Platform { +@@ -371,7 +371,7 @@ class BLINK_PLATFORM_EXPORT Platform { return nullptr; } diff --git a/www/chromium/files/patch-third__party_blink_public_platform_web__vector.h b/www/chromium/files/patch-third__party_blink_public_platform_web__vector.h deleted file mode 100644 index aeb9a158b110..000000000000 --- a/www/chromium/files/patch-third__party_blink_public_platform_web__vector.h +++ /dev/null @@ -1,11 +0,0 @@ ---- third_party/blink/public/platform/web_vector.h.orig 2024-01-30 07:53:34 UTC -+++ third_party/blink/public/platform/web_vector.h -@@ -86,7 +86,7 @@ class WebVector { - // The vector can be populated using reserve() and emplace_back(). - WebVector() = default; - --#if defined(ARCH_CPU_64_BITS) -+#if defined(ARCH_CPU_64_BITS) || defined(__OpenBSD__) - // Create a vector with |size| default-constructed elements. We define - // a constructor with size_t otherwise we'd have a duplicate define. - explicit WebVector(size_t size) : data_(size) {} diff --git a/www/chromium/files/patch-third__party_blink_renderer_bindings_scripts_bind__gen_style__format.py b/www/chromium/files/patch-third__party_blink_renderer_bindings_scripts_bind__gen_style__format.py index 85f535fc625d..d4a1bd36f219 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_bindings_scripts_bind__gen_style__format.py +++ b/www/chromium/files/patch-third__party_blink_renderer_bindings_scripts_bind__gen_style__format.py @@ -1,9 +1,9 @@ ---- third_party/blink/renderer/bindings/scripts/bind_gen/style_format.py.orig 2022-02-07 13:39:41 UTC +--- third_party/blink/renderer/bindings/scripts/bind_gen/style_format.py.orig 2024-06-17 12:56:06 UTC +++ third_party/blink/renderer/bindings/scripts/bind_gen/style_format.py -@@ -28,7 +28,7 @@ def init(root_src_dir, enable_style_format=True): - root_src_dir = os.path.abspath(root_src_dir) +@@ -30,7 +30,7 @@ def init(root_src_dir, enable_style_format=True): # Determine //buildtools/<platform>/ directory + new_path_platform_suffix = "" - if sys.platform.startswith("linux"): + if sys.platform.startswith(("linux","openbsd","freebsd")): platform = "linux64" diff --git a/www/chromium/files/patch-third__party_blink_renderer_controller_blink__initializer.cc b/www/chromium/files/patch-third__party_blink_renderer_controller_blink__initializer.cc index 0ea962d87022..8229d26be7fb 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_controller_blink__initializer.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_controller_blink__initializer.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/controller/blink_initializer.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/controller/blink_initializer.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/blink/renderer/controller/blink_initializer.cc -@@ -80,12 +80,12 @@ +@@ -82,12 +82,12 @@ #include "third_party/blink/renderer/controller/private_memory_footprint_provider.h" #endif @@ -24,8 +24,8 @@ binders.Add<mojom::blink::MemoryUsageMonitorLinux>( ConvertToBaseRepeatingCallback( CrossThreadBindRepeating(&MemoryUsageMonitorPosix::Bind)), -@@ -294,7 +294,7 @@ void BlinkInitializer::RegisterMemoryWatchers(Platform - #endif +@@ -303,7 +303,7 @@ void BlinkInitializer::RegisterMemoryWatchers(Platform + MemorySaverController::Initialize(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ - BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-third__party_blink_renderer_controller_memory__usage__monitor__posix.cc b/www/chromium/files/patch-third__party_blink_renderer_controller_memory__usage__monitor__posix.cc index acc849ff4976..c5c0e5b6dc37 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_controller_memory__usage__monitor__posix.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_controller_memory__usage__monitor__posix.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/controller/memory_usage_monitor_posix.cc.orig 2023-09-13 12:11:42 UTC +--- third_party/blink/renderer/controller/memory_usage_monitor_posix.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/blink/renderer/controller/memory_usage_monitor_posix.cc -@@ -128,15 +128,17 @@ void MemoryUsageMonitorPosix::ResetFileDescriptors() { +@@ -132,15 +132,17 @@ void MemoryUsageMonitorPosix::ResetFileDescriptors() { void MemoryUsageMonitorPosix::SetProcFiles(base::File statm_file, base::File status_file) { diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_editing_editing__behavior.cc b/www/chromium/files/patch-third__party_blink_renderer_core_editing_editing__behavior.cc index 9bb9d79b6e44..9c44202bb41b 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_editing_editing__behavior.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_editing_editing__behavior.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/core/editing/editing_behavior.cc.orig 2023-12-10 06:10:27 UTC +--- third_party/blink/renderer/core/editing/editing_behavior.cc.orig 2024-08-26 12:06:38 UTC +++ third_party/blink/renderer/core/editing/editing_behavior.cc -@@ -324,7 +324,7 @@ bool EditingBehavior::ShouldInsertCharacter(const Keyb +@@ -304,7 +304,7 @@ bool EditingBehavior::ShouldInsertCharacter(const Keyb // unexpected behaviour if (ch < ' ') return false; diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_exported_web__view__impl.cc b/www/chromium/files/patch-third__party_blink_renderer_core_exported_web__view__impl.cc index c2658692af35..30a3fd0d4c7d 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_exported_web__view__impl.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_exported_web__view__impl.cc @@ -1,20 +1,20 @@ ---- third_party/blink/renderer/core/exported/web_view_impl.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/core/exported/web_view_impl.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/core/exported/web_view_impl.cc -@@ -425,7 +425,7 @@ SkFontHinting RendererPreferencesToSkiaHinting( +@@ -430,7 +430,7 @@ void RecordPrerenderActivationSignalDelay(const String + #if !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_WIN) + SkFontHinting RendererPreferencesToSkiaHinting( const blink::RendererPreferences& prefs) { - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) if (!prefs.should_antialias_text) { // When anti-aliasing is off, GTK maps all non-zero hinting settings to // 'Normal' hinting so we do the same. Otherwise, folks who have 'Slight' -@@ -3385,7 +3385,7 @@ void WebViewImpl::UpdateFontRenderingFromRendererPrefs +@@ -3422,7 +3422,7 @@ void WebViewImpl::UpdateFontRenderingFromRendererPrefs + gfx::FontRenderParams::SUBPIXEL_RENDERING_NONE); + WebFontRenderStyle::SetSubpixelPositioning( renderer_preferences_.use_subpixel_positioning); - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) && \ - !BUILDFLAG(IS_ANDROID) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) if (!renderer_preferences_.system_font_family_name.empty()) { WebFontRenderStyle::SetSystemFontFamily(blink::WebString::FromUTF8( + renderer_preferences_.system_font_family_name)); diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_frame_web__frame__test.cc b/www/chromium/files/patch-third__party_blink_renderer_core_frame_web__frame__test.cc index f8ccf482fb24..5643c6672e18 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_frame_web__frame__test.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_frame_web__frame__test.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/core/frame/web_frame_test.cc.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/core/frame/web_frame_test.cc.orig 2025-04-04 08:52:13 UTC +++ third_party/blink/renderer/core/frame/web_frame_test.cc -@@ -6469,7 +6469,7 @@ TEST_F(WebFrameTest, DISABLED_PositionForPointTest) { +@@ -6471,7 +6471,7 @@ TEST_F(WebFrameTest, DISABLED_PositionForPointTest) { } #if BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_LINUX) || \ @@ -9,7 +9,7 @@ // TODO(crbug.com/1090246): Fix these tests on Fuchsia and re-enable. // TODO(crbug.com/1317375): Build these tests on all platforms. #define MAYBE_SelectRangeStaysHorizontallyAlignedWhenMoved \ -@@ -6878,7 +6878,7 @@ TEST_F(CompositedSelectionBoundsTest, LargeSelectionSc +@@ -6880,7 +6880,7 @@ TEST_F(CompositedSelectionBoundsTest, LargeSelectionSc TEST_F(CompositedSelectionBoundsTest, LargeSelectionNoScroll) { RunTest("composited_selection_bounds_large_selection_noscroll.html"); } diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_html_canvas_canvas__async__blob__creator.cc b/www/chromium/files/patch-third__party_blink_renderer_core_html_canvas_canvas__async__blob__creator.cc index 5db1b6d2a235..43625137dabe 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_html_canvas_canvas__async__blob__creator.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_html_canvas_canvas__async__blob__creator.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/core/html/canvas/canvas_async_blob_creator.cc.orig 2024-01-30 07:53:34 UTC +--- third_party/blink/renderer/core/html/canvas/canvas_async_blob_creator.cc.orig 2025-05-05 10:57:53 UTC +++ third_party/blink/renderer/core/html/canvas/canvas_async_blob_creator.cc -@@ -50,7 +50,7 @@ constexpr base::TimeDelta kEncodeRowSlackBeforeDeadlin +@@ -51,7 +51,7 @@ constexpr base::TimeDelta kEncodeRowSlackBeforeDeadlin /* The value is based on user statistics on Nov 2017. */ #if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \ diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_inspector_inspector__memory__agent.cc b/www/chromium/files/patch-third__party_blink_renderer_core_inspector_inspector__memory__agent.cc index 71733a9b0845..e62709ecbee3 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_inspector_inspector__memory__agent.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_inspector_inspector__memory__agent.cc @@ -1,9 +1,9 @@ ---- third_party/blink/renderer/core/inspector/inspector_memory_agent.cc.orig 2024-01-30 07:53:34 UTC +--- third_party/blink/renderer/core/inspector/inspector_memory_agent.cc.orig 2025-03-05 08:14:56 UTC +++ third_party/blink/renderer/core/inspector/inspector_memory_agent.cc @@ -192,7 +192,7 @@ InspectorMemoryAgent::GetSamplingProfileById(uint32_t Vector<String> InspectorMemoryAgent::Symbolize( - const WebVector<const void*>& addresses) { + const std::vector<const void*>& addresses) { -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // TODO(alph): Move symbolization to the client. diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_layout_layout__view.cc b/www/chromium/files/patch-third__party_blink_renderer_core_layout_layout__view.cc index 213b880bd866..60ebeed946b1 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_layout_layout__view.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_layout_layout__view.cc @@ -1,15 +1,15 @@ ---- third_party/blink/renderer/core/layout/layout_view.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/core/layout/layout_view.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/core/layout/layout_view.cc -@@ -73,7 +73,7 @@ +@@ -74,7 +74,7 @@ + #include "ui/display/screen_info.h" #include "ui/gfx/geometry/quad_f.h" - #include "ui/gfx/geometry/size_conversions.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "third_party/blink/renderer/platform/fonts/font_cache.h" #endif -@@ -832,7 +832,7 @@ void LayoutView::UpdateLayout() { +@@ -789,7 +789,7 @@ void LayoutView::LayoutRoot() { intrinsic_logical_widths_ = LogicalWidth(); } diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_loader_mixed__content__checker.cc b/www/chromium/files/patch-third__party_blink_renderer_core_loader_mixed__content__checker.cc new file mode 100644 index 000000000000..d6ea42d34c5b --- /dev/null +++ b/www/chromium/files/patch-third__party_blink_renderer_core_loader_mixed__content__checker.cc @@ -0,0 +1,11 @@ +--- third_party/blink/renderer/core/loader/mixed_content_checker.cc.orig 2025-07-02 06:08:04 UTC ++++ third_party/blink/renderer/core/loader/mixed_content_checker.cc +@@ -510,7 +510,7 @@ bool MixedContentChecker::ShouldBlockFetch( + switch (context_type) { + case mojom::blink::MixedContentContextType::kOptionallyBlockable: + +-#if (BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX)) && \ ++#if (BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && \ + BUILDFLAG(ENABLE_CAST_RECEIVER) + // Fuchsia WebEngine can be configured to allow loading Mixed Content from + // an insecure IP address. This is a workaround to revert Fuchsia Cast diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_origin__trials_origin__trial__context.cc b/www/chromium/files/patch-third__party_blink_renderer_core_origin__trials_origin__trial__context.cc new file mode 100644 index 000000000000..1b49f55c076f --- /dev/null +++ b/www/chromium/files/patch-third__party_blink_renderer_core_origin__trials_origin__trial__context.cc @@ -0,0 +1,11 @@ +--- third_party/blink/renderer/core/origin_trials/origin_trial_context.cc.orig 2025-07-02 06:08:04 UTC ++++ third_party/blink/renderer/core/origin_trials/origin_trial_context.cc +@@ -568,7 +568,7 @@ bool OriginTrialContext::CanEnableTrialFromName(const + } + + if (trial_name == "TranslationAPI") { +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return base::FeatureList::IsEnabled(features::kTranslationAPI); + #else + return false; diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_page_context__menu__controller.cc b/www/chromium/files/patch-third__party_blink_renderer_core_page_context__menu__controller.cc new file mode 100644 index 000000000000..7abee87bc8c0 --- /dev/null +++ b/www/chromium/files/patch-third__party_blink_renderer_core_page_context__menu__controller.cc @@ -0,0 +1,11 @@ +--- third_party/blink/renderer/core/page/context_menu_controller.cc.orig 2025-07-02 06:08:04 UTC ++++ third_party/blink/renderer/core/page/context_menu_controller.cc +@@ -654,7 +654,7 @@ bool ContextMenuController::ShowContextMenu(LocalFrame + if (potential_image_node != nullptr && + IsA<HTMLCanvasElement>(potential_image_node)) { + data.media_type = mojom::blink::ContextMenuDataMediaType::kCanvas; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // TODO(crbug.com/40902474): Support reading from the WebGPU front buffer + // on Linux and remove the below code, which results in "Copy Image" and + // "Save Image To" being grayed out in the context menu. diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_paint_paint__layer.cc b/www/chromium/files/patch-third__party_blink_renderer_core_paint_paint__layer.cc index 322b3a6045e3..a5092cac50e9 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_paint_paint__layer.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_paint_paint__layer.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/core/paint/paint_layer.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/core/paint/paint_layer.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/core/paint/paint_layer.cc -@@ -122,7 +122,7 @@ namespace blink { +@@ -125,7 +125,7 @@ namespace blink { namespace { diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_scroll_scrollbar__theme__aura.cc b/www/chromium/files/patch-third__party_blink_renderer_core_scroll_scrollbar__theme__aura.cc index f8cef9710413..81de50bf1c1e 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_scroll_scrollbar__theme__aura.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_scroll_scrollbar__theme__aura.cc @@ -1,20 +1,20 @@ ---- third_party/blink/renderer/core/scroll/scrollbar_theme_aura.cc.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/core/scroll/scrollbar_theme_aura.cc.orig 2025-04-04 08:52:13 UTC +++ third_party/blink/renderer/core/scroll/scrollbar_theme_aura.cc -@@ -149,7 +149,7 @@ bool ScrollbarThemeAura::SupportsDragSnapBack() const +@@ -146,7 +146,7 @@ bool ScrollbarThemeAura::SupportsDragSnapBack() const + // Disable snapback on desktop Linux to better integrate with the desktop + // behavior. Typically, Linux apps do not implement scrollbar snapback (this // is true for at least GTK and QT apps). - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return false; #else return true; -@@ -368,7 +368,7 @@ bool ScrollbarThemeAura::ShouldCenterOnThumb(const Scr - const WebMouseEvent& event) { - // TODO(crbug.com/1052397): Revisit once build flag switch of lacros-chrome is - // complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +@@ -423,7 +423,7 @@ ScrollbarPart ScrollbarThemeAura::PartsToInvalidateOnT + + bool ScrollbarThemeAura::ShouldCenterOnThumb(const Scrollbar& scrollbar, + const WebMouseEvent& event) const { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) if (event.button == WebPointerProperties::Button::kMiddle) return true; #endif diff --git a/www/chromium/files/patch-third__party_blink_renderer_core_xml_xslt__processor__libxslt.cc b/www/chromium/files/patch-third__party_blink_renderer_core_xml_xslt__processor__libxslt.cc index 9e11b5e7bdcc..7f546d1705c7 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_core_xml_xslt__processor__libxslt.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_core_xml_xslt__processor__libxslt.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/core/xml/xslt_processor_libxslt.cc.orig 2024-02-23 21:04:38 UTC +--- third_party/blink/renderer/core/xml/xslt_processor_libxslt.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/blink/renderer/core/xml/xslt_processor_libxslt.cc -@@ -66,7 +66,11 @@ void XSLTProcessor::GenericErrorFunc(void*, const char +@@ -68,7 +68,11 @@ void XSLTProcessor::GenericErrorFunc(void*, const char // It would be nice to do something with this error message. } diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__device__factory.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__device__factory.cc index b457652aa3dc..ddfe7f3df77c 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__device__factory.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__device__factory.cc @@ -1,11 +1,11 @@ ---- third_party/blink/renderer/modules/media/audio/audio_device_factory.cc.orig 2022-11-30 08:12:58 UTC +--- third_party/blink/renderer/modules/media/audio/audio_device_factory.cc.orig 2025-04-04 08:52:13 UTC +++ third_party/blink/renderer/modules/media/audio/audio_device_factory.cc -@@ -35,7 +35,7 @@ namespace { +@@ -33,7 +33,7 @@ namespace { + // Set when the default factory is overridden. AudioDeviceFactory* g_factory_override = nullptr; - #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ -- BUILDFLAG(IS_CHROMEOS_LACROS) -+ BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Due to driver deadlock issues on Windows (http://crbug/422522) there is a // chance device authorization response is never received from the browser side. // In this case we will time out, to avoid renderer hang forever waiting for diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__renderer__mixer__manager__test.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__renderer__mixer__manager__test.cc index 2dc30279c060..a1e16069f938 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__renderer__mixer__manager__test.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_media_audio_audio__renderer__mixer__manager__test.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/modules/media/audio/audio_renderer_mixer_manager_test.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/modules/media/audio/audio_renderer_mixer_manager_test.cc.orig 2025-05-05 10:57:53 UTC +++ third_party/blink/renderer/modules/media/audio/audio_renderer_mixer_manager_test.cc -@@ -813,7 +813,7 @@ TEST_F(AudioRendererMixerManagerTest, MixerParamsLaten +@@ -857,7 +857,7 @@ TEST_F(AudioRendererMixerManagerTest, MixerParamsLaten mixer->get_output_params_for_testing().sample_rate()); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_APPLE) || \ diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_ml_webnn_features.gni b/www/chromium/files/patch-third__party_blink_renderer_modules_ml_webnn_features.gni deleted file mode 100644 index 1b186e79d497..000000000000 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_ml_webnn_features.gni +++ /dev/null @@ -1,11 +0,0 @@ ---- third_party/blink/renderer/modules/ml/webnn/features.gni.orig 2024-04-19 13:02:56 UTC -+++ third_party/blink/renderer/modules/ml/webnn/features.gni -@@ -6,7 +6,7 @@ import("//build/config/chrome_build.gni") - declare_args() { - # This enables building WebNN with XNNPACK. Currently only available for - # Windows, macOS and Linux on x64, x86 and arm64. -- build_webnn_with_xnnpack = (is_linux || is_win || is_mac) && -+ build_webnn_with_xnnpack = !is_bsd && (is_linux || is_win || is_mac) && - (current_cpu == "x64" || current_cpu == "x86" || - (current_cpu == "arm64" && !is_win)) - } diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_ml_webnn_ml__graph__xnnpack.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_ml_webnn_ml__graph__xnnpack.cc deleted file mode 100644 index 52afa88caa76..000000000000 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_ml_webnn_ml__graph__xnnpack.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- third_party/blink/renderer/modules/ml/webnn/ml_graph_xnnpack.cc.orig 2024-04-19 13:02:56 UTC -+++ third_party/blink/renderer/modules/ml/webnn/ml_graph_xnnpack.cc -@@ -204,7 +204,7 @@ class SharedXnnpackContext : public ThreadSafeRefCount - - ~SharedXnnpackContext() { - base::AutoLock auto_lock(SharedXnnpackContextLock()); --#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) -+#if !(BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) - // For Linux and ChromeOS, cpuinfo needs to parse /proc/cpuinfo to - // initialize in pre sandbox stage. Calling xnn_deinitialize() here will - // deinitialize cpuinfo within sandbox and cannot access /proc/cpuinfo diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_rtc__data__channel.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_rtc__data__channel.cc new file mode 100644 index 000000000000..733377f47069 --- /dev/null +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_rtc__data__channel.cc @@ -0,0 +1,10 @@ +--- third_party/blink/renderer/modules/peerconnection/rtc_data_channel.cc.orig 2024-11-14 07:57:23 UTC ++++ third_party/blink/renderer/modules/peerconnection/rtc_data_channel.cc +@@ -542,6 +542,7 @@ void RTCDataChannel::send(Blob* data, ExceptionState& + pending_messages_.push_back(message); + } + ++#undef close + void RTCDataChannel::close() { + DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); + if (state_ == webrtc::DataChannelInterface::kClosing || diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_webrtc__audio__renderer__test.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_webrtc__audio__renderer__test.cc index 6af7b58b929d..c33751d275b0 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_webrtc__audio__renderer__test.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_peerconnection_webrtc__audio__renderer__test.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/modules/peerconnection/webrtc_audio_renderer_test.cc.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/modules/peerconnection/webrtc_audio_renderer_test.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/modules/peerconnection/webrtc_audio_renderer_test.cc -@@ -301,7 +301,7 @@ TEST_F(WebRtcAudioRendererTest, DISABLED_VerifySinkPar +@@ -382,7 +382,7 @@ TEST_F(WebRtcAudioRendererTest, DISABLED_VerifySinkPar SetupRenderer(kDefaultOutputDeviceId); renderer_proxy_->Start(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_APPLE) || \ diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_webaudio_audio__worklet__thread__test.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_webaudio_audio__worklet__thread__test.cc index 14c790623fd5..c2bb19e11bb9 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_webaudio_audio__worklet__thread__test.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_webaudio_audio__worklet__thread__test.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/modules/webaudio/audio_worklet_thread_test.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/modules/webaudio/audio_worklet_thread_test.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/blink/renderer/modules/webaudio/audio_worklet_thread_test.cc -@@ -463,7 +463,7 @@ class AudioWorkletThreadPriorityTest +@@ -465,7 +465,7 @@ class AudioWorkletThreadPriorityTest // TODO(crbug.com/1022888): The worklet thread priority is always NORMAL // on OS_LINUX and OS_CHROMEOS regardless of the thread priority setting. diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_webgl_webgl__rendering__context__base.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_webgl_webgl__rendering__context__base.cc index 37f837a8db08..2c74017131b9 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_webgl_webgl__rendering__context__base.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_webgl_webgl__rendering__context__base.cc @@ -1,8 +1,8 @@ ---- third_party/blink/renderer/modules/webgl/webgl_rendering_context_base.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/modules/webgl/webgl_rendering_context_base.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/modules/webgl/webgl_rendering_context_base.cc -@@ -6358,7 +6358,7 @@ void WebGLRenderingContextBase::TexImageHelperMediaVid - constexpr bool kAllowZeroCopyImages = true; - #endif +@@ -6383,7 +6383,7 @@ void WebGLRenderingContextBase::TexImageHelperMediaVid + // unmultiply has been requested or we need to never premultiply for Image + // creation from a VideoFrame. -#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__canvas__context.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__canvas__context.cc new file mode 100644 index 000000000000..48553cdfcd95 --- /dev/null +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__canvas__context.cc @@ -0,0 +1,11 @@ +--- third_party/blink/renderer/modules/webgpu/gpu_canvas_context.cc.orig 2025-07-02 06:08:04 UTC ++++ third_party/blink/renderer/modules/webgpu/gpu_canvas_context.cc +@@ -218,7 +218,7 @@ CanvasResourceProvider* GPUCanvasContext::PaintRenderi + + scoped_refptr<WebGPUMailboxTexture> front_buffer_texture; + if (source_buffer == kFrontBuffer) { +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // By returning false here the canvas will show up as black in the scenarios + // that copy the front buffer, such as printing. + // TODO(crbug.com/40902474): Support concurrent SharedImage reads via Dawn diff --git a/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__queue.cc b/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__queue.cc index 889cf513eb74..be88472afd3f 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__queue.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_modules_webgpu_gpu__queue.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/modules/webgpu/gpu_queue.cc.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/modules/webgpu/gpu_queue.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/blink/renderer/modules/webgpu/gpu_queue.cc -@@ -785,7 +785,7 @@ bool GPUQueue::CopyFromCanvasSourceImage( +@@ -814,7 +814,7 @@ bool GPUQueue::CopyFromCanvasSourceImage( // on linux platform. // TODO(crbug.com/1424119): using a webgpu mailbox texture on the OpenGLES // backend is failing for unknown reasons. diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_BUILD.gn b/www/chromium/files/patch-third__party_blink_renderer_platform_BUILD.gn index 7832e8964278..e718dbe47673 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_BUILD.gn +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/platform/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/platform/BUILD.gn.orig 2025-05-28 14:55:43 UTC +++ third_party/blink/renderer/platform/BUILD.gn -@@ -1947,7 +1947,7 @@ static_library("test_support") { +@@ -2060,7 +2060,7 @@ static_library("test_support") { ] # fuzzed_data_provider may not work with a custom toolchain. diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.cc index 5298059b7dc0..723187ec8f5e 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/platform/fonts/font_cache.cc.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/platform/fonts/font_cache.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/platform/fonts/font_cache.cc -@@ -73,7 +73,7 @@ extern const char kNotoColorEmojiCompat[] = "Noto Colo +@@ -82,7 +82,7 @@ extern const char kNotoColorEmojiCompat[] = "Noto Colo SkFontMgr* FontCache::static_font_manager_ = nullptr; @@ -9,7 +9,7 @@ float FontCache::device_scale_factor_ = 1.0; #endif -@@ -124,7 +124,7 @@ const FontPlatformData* FontCache::SystemFontPlatformD +@@ -136,7 +136,7 @@ const FontPlatformData* FontCache::SystemFontPlatformD const FontDescription& font_description) { const AtomicString& family = FontCache::SystemFontFamily(); #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || \ diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.h b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.h index 765f6ddc2f05..a111a5a16fe2 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.h +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__cache.h @@ -1,4 +1,4 @@ ---- third_party/blink/renderer/platform/fonts/font_cache.h.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/platform/fonts/font_cache.h.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/platform/fonts/font_cache.h @@ -55,7 +55,7 @@ #include "third_party/skia/include/core/SkFontMgr.h" @@ -9,16 +9,16 @@ #include "ui/gfx/font_fallback_linux.h" #endif -@@ -163,7 +163,7 @@ class PLATFORM_EXPORT FontCache final { - static void PrewarmFamily(const AtomicString& family_name) {} - #endif +@@ -171,7 +171,7 @@ class PLATFORM_EXPORT FontCache final { + + static void MaybePreloadSystemFonts(); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // These are needed for calling QueryRenderStyleForStrike, since // gfx::GetFontRenderParams makes distinctions based on DSF. static float DeviceScaleFactor() { return device_scale_factor_; } -@@ -239,7 +239,7 @@ class PLATFORM_EXPORT FontCache final { +@@ -247,7 +247,7 @@ class PLATFORM_EXPORT FontCache final { const char* locale_family_name); #endif // BUILDFLAG(IS_ANDROID) @@ -27,7 +27,7 @@ static bool GetFontForCharacter(UChar32, const char* preferred_locale, gfx::FallbackFontData*); -@@ -312,7 +312,7 @@ class PLATFORM_EXPORT FontCache final { +@@ -320,7 +320,7 @@ class PLATFORM_EXPORT FontCache final { const FontFaceCreationParams&, std::string& name); @@ -36,7 +36,7 @@ static AtomicString GetFamilyNameForCharacter(SkFontMgr*, UChar32, const FontDescription&, -@@ -349,7 +349,7 @@ class PLATFORM_EXPORT FontCache final { +@@ -357,7 +357,7 @@ class PLATFORM_EXPORT FontCache final { bool is_test_font_mgr_ = false; #endif // BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__description.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__description.cc index d51497f12a3b..45053d8e8fee 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__description.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__description.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/platform/fonts/font_description.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/platform/fonts/font_description.cc.orig 2025-05-05 10:57:53 UTC +++ third_party/blink/renderer/platform/fonts/font_description.cc -@@ -39,7 +39,7 @@ +@@ -41,7 +41,7 @@ #include "third_party/blink/renderer/platform/wtf/text/string_hash.h" #include "third_party/blink/renderer/platform/wtf/text/string_hasher.h" @@ -9,7 +9,7 @@ #include "third_party/blink/renderer/platform/fonts/font_cache.h" #endif -@@ -275,7 +275,7 @@ FontCacheKey FontDescription::CacheKey( +@@ -280,7 +280,7 @@ FontCacheKey FontDescription::CacheKey( static_cast<unsigned>(fields_.orientation_) << 1 | // bit 2-3 static_cast<unsigned>(fields_.subpixel_text_position_); // bit 1 diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__platform__data.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__platform__data.cc deleted file mode 100644 index a0c76030a290..000000000000 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_font__platform__data.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- third_party/blink/renderer/platform/fonts/font_platform_data.cc.orig 2023-02-08 09:03:45 UTC -+++ third_party/blink/renderer/platform/fonts/font_platform_data.cc -@@ -48,7 +48,7 @@ - namespace blink { - namespace { - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // Getting the system font render style takes a significant amount of time on - // Linux because looking up fonts using fontconfig can be very slow. We fetch - // the render style for each font family and text size, while it's very -@@ -127,7 +127,7 @@ FontPlatformData::FontPlatformData(sk_sp<SkTypeface> t - style_ = WebFontRenderStyle::GetDefault(); - #if !BUILDFLAG(IS_WIN) - WebFontRenderStyle system_style; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - bool override_font_name_and_size = - base::FeatureList::IsEnabled(kOptimizeLinuxFonts); - #else diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_skia_font__cache__skia.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_skia_font__cache__skia.cc index 54157d2bc81f..5e3e9f188986 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_skia_font__cache__skia.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_fonts_skia_font__cache__skia.cc @@ -1,7 +1,7 @@ ---- third_party/blink/renderer/platform/fonts/skia/font_cache_skia.cc.orig 2024-03-22 08:19:40 UTC +--- third_party/blink/renderer/platform/fonts/skia/font_cache_skia.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/blink/renderer/platform/fonts/skia/font_cache_skia.cc @@ -65,7 +65,7 @@ AtomicString ToAtomicString(const SkString& str) { - return AtomicString::FromUTF8(str.c_str(), str.size()); + return AtomicString::FromUTF8(std::string_view(str.begin(), str.end())); } -#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_begin__frame__provider.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_begin__frame__provider.cc index ccd9de6e442a..2d67c82fbbaf 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_begin__frame__provider.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_begin__frame__provider.cc @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/platform/graphics/begin_frame_provider.cc.orig 2023-08-17 07:33:31 UTC +--- third_party/blink/renderer/platform/graphics/begin_frame_provider.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/blink/renderer/platform/graphics/begin_frame_provider.cc -@@ -71,8 +71,12 @@ void BeginFrameProvider::CreateCompositorFrameSinkIfNe +@@ -70,8 +70,12 @@ void BeginFrameProvider::CreateCompositorFrameSinkIfNe // Once we are using RAF, this thread is driving user interactive display // updates. Update priority accordingly. diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_gpu_image__layer__bridge.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_gpu_image__layer__bridge.cc new file mode 100644 index 000000000000..aafbf15e688a --- /dev/null +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_gpu_image__layer__bridge.cc @@ -0,0 +1,11 @@ +--- third_party/blink/renderer/platform/graphics/gpu/image_layer_bridge.cc.orig 2025-05-05 10:57:53 UTC ++++ third_party/blink/renderer/platform/graphics/gpu/image_layer_bridge.cc +@@ -47,7 +47,7 @@ scoped_refptr<StaticBitmapImage> MakeAccelerated( + + const auto paint_image = source->PaintImageForCurrentFrame(); + const auto image_info = paint_image.GetSkImageInfo(); +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // TODO(b/330865436): On Linux, CanvasResourceProvider doesn't always check + // for SCANOUT support correctly on X11 and it's never supported in + // practice. Therefore, don't include it until this flow is reworked. diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_video__frame__submitter.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_video__frame__submitter.cc index f002779c7ec5..8c41a5962ed1 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_video__frame__submitter.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_graphics_video__frame__submitter.cc @@ -1,9 +1,9 @@ ---- third_party/blink/renderer/platform/graphics/video_frame_submitter.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/platform/graphics/video_frame_submitter.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/platform/graphics/video_frame_submitter.cc -@@ -400,7 +400,7 @@ void VideoFrameSubmitter::OnBeginFrame( - continue; - auto& feedback = - timing_details.find(frame_token)->value.presentation_feedback; +@@ -394,7 +394,7 @@ void VideoFrameSubmitter::OnBeginFrame( + auto& details = timing_details.find(frame_token)->value; + auto& feedback = details.presentation_feedback; + -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // TODO: On Linux failure flag is unreliable, and perfectly rendered frames diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_peerconnection_rtc__video__encoder__factory.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_peerconnection_rtc__video__encoder__factory.cc index c2b35310b6f4..9cc3e05ffb4c 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_peerconnection_rtc__video__encoder__factory.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_peerconnection_rtc__video__encoder__factory.cc @@ -1,17 +1,17 @@ ---- third_party/blink/renderer/platform/peerconnection/rtc_video_encoder_factory.cc.orig 2024-01-30 07:53:34 UTC +--- third_party/blink/renderer/platform/peerconnection/rtc_video_encoder_factory.cc.orig 2025-05-05 10:57:53 UTC +++ third_party/blink/renderer/platform/peerconnection/rtc_video_encoder_factory.cc -@@ -202,12 +202,12 @@ SupportedFormats GetSupportedFormatsInternal( - supported_formats.scalability_modes.push_back(profile.scalability_modes); +@@ -324,12 +324,12 @@ SupportedFormats GetSupportedFormatsInternal( + supported_formats.profiles.push_back(profile.profile); supported_formats.sdp_formats.push_back(std::move(*format)); --#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #if BUILDFLAG(IS_WIN) const bool kShouldAddH264Cbp = base::FeatureList::IsEnabled(kMediaFoundationH264CbpEncoding) && profile.profile == media::VideoCodecProfile::H264PROFILE_BASELINE; --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) const bool kShouldAddH264Cbp = profile.profile == media::VideoCodecProfile::H264PROFILE_BASELINE; #endif diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_runtime__enabled__features.json5 b/www/chromium/files/patch-third__party_blink_renderer_platform_runtime__enabled__features.json5 index e8b0df090779..9d8835996847 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_runtime__enabled__features.json5 +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_runtime__enabled__features.json5 @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/platform/runtime_enabled_features.json5.orig 2024-04-19 13:02:56 UTC +--- third_party/blink/renderer/platform/runtime_enabled_features.json5.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/platform/runtime_enabled_features.json5 -@@ -321,7 +321,7 @@ +@@ -501,7 +501,7 @@ name: "AppTitle", status: "experimental", origin_trial_feature_name: "AppTitle", @@ -9,25 +9,34 @@ base_feature: "WebAppEnableAppTitle", }, { -@@ -1969,7 +1969,7 @@ - base_feature_status: "enabled", - copied_from_base_feature_if: "overridden", - origin_trial_feature_name: "FullscreenPopupWindows", +@@ -1840,7 +1840,7 @@ + name: "DocumentIsolationPolicy", + status: "experimental", + origin_trial_feature_name: "DocumentIsolationPolicy", - origin_trial_os: ["win", "mac", "linux", "chromeos"], + origin_trial_os: ["win", "mac", "linux", "chromeos", "openbsd", "freebsd"], + base_feature: "none", }, { - name: "GamepadButtonAxisEvents", -@@ -2890,7 +2890,7 @@ - name: "PaymentHandlerMinimalHeaderUX", - origin_trial_feature_name: "PaymentHandlerMinimalHeaderUX", +@@ -2101,7 +2101,7 @@ + base_feature: "none", + public: true, + origin_trial_feature_name: "FedCmMultipleIdentityProviders", +- origin_trial_os: ["win", "mac", "linux", "chromeos"], ++ origin_trial_os: ["win", "mac", "linux", "chromeos", "openbsd", "freebsd"], origin_trial_allows_third_party: true, -- origin_trial_os: ["win", "mac", "linux", "fuchsia", "chromeos"], -+ origin_trial_os: ["win", "mac", "linux", "fuchsia", "chromeos", "openbsd", "freebsd"], - status: "stable", }, { -@@ -3082,7 +3082,7 @@ +@@ -3594,7 +3594,7 @@ + // Tracking bug for the implementation: https://crbug.com/1462930 + name: "PermissionElement", + origin_trial_feature_name: "PermissionElement", +- origin_trial_os: ["win", "mac", "linux", "fuchsia", "chromeos", "android"], ++ origin_trial_os: ["win", "mac", "linux", "fuchsia", "chromeos", "android", "openbsd", "freebsd"], + status: "experimental", + public: true, + base_feature_status: "enabled", +@@ -3758,7 +3758,7 @@ { name: "PrivateNetworkAccessPermissionPrompt", origin_trial_feature_name: "PrivateNetworkAccessPermissionPrompt", @@ -36,7 +45,7 @@ status: "stable", public: true, base_feature: "none", -@@ -3950,7 +3950,7 @@ +@@ -5047,7 +5047,7 @@ name: "UnrestrictedSharedArrayBuffer", base_feature: "none", origin_trial_feature_name: "UnrestrictedSharedArrayBuffer", @@ -45,7 +54,7 @@ }, // Enables using policy-controlled feature "usb-unrestricted" to allow // isolated context to access protected USB interface classes and to -@@ -4110,7 +4110,7 @@ +@@ -5217,7 +5217,7 @@ { name: "WebAppScopeExtensions", origin_trial_feature_name: "WebAppScopeExtensions", @@ -54,3 +63,12 @@ status: "experimental", base_feature: "none", }, +@@ -5504,7 +5504,7 @@ + { + name: "WebIdentityDigitalCredentials", + origin_trial_feature_name: "WebIdentityDigitalCredentials", +- origin_trial_os: ["android", "win", "mac", "linux", "chromeos"], ++ origin_trial_os: ["android", "win", "mac", "linux", "chromeos", "openbsd", "freebsd"], + origin_trial_allows_third_party: true, + implied_by: ["WebIdentityDigitalCredentialsCreation"], + public: true, diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_scheduler_common_thread.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_scheduler_common_thread.cc index 37cba26564fe..458b6d28e5fe 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_scheduler_common_thread.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_scheduler_common_thread.cc @@ -1,8 +1,8 @@ ---- third_party/blink/renderer/platform/scheduler/common/thread.cc.orig 2023-04-28 17:01:32 UTC +--- third_party/blink/renderer/platform/scheduler/common/thread.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/platform/scheduler/common/thread.cc -@@ -82,7 +82,7 @@ void Thread::CreateAndSetCompositorThread() { - std::make_unique<scheduler::CompositorThread>(params); - compositor_thread->Init(); +@@ -95,7 +95,7 @@ void Thread::CreateAndSetCompositorThread() { + // the program's lifetime once assigned. + base::Unretained(compositor_thread.get()))); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && !BUILDFLAG(IS_OPENBSD) diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_video__capture_video__capture__impl.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_video__capture_video__capture__impl.cc deleted file mode 100644 index e00f3587712a..000000000000 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_video__capture_video__capture__impl.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- third_party/blink/renderer/platform/video_capture/video_capture_impl.cc.orig 2024-04-19 13:02:56 UTC -+++ third_party/blink/renderer/platform/video_capture/video_capture_impl.cc -@@ -676,7 +676,7 @@ bool VideoCaptureImpl::BindVideoFrameOnMediaTaskRunner - } - - const unsigned texture_target = --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Explicitly set GL_TEXTURE_EXTERNAL_OES if necessary: - // `media::VideoFrame::RequiresExternalSampler()` requires it for NV12 - // format, while `ClientSharedImage::GetTextureTarget(BufferUsage, diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_container__annotations.h b/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_container__annotations.h index 25658e65ff2b..44b323ca11ef 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_container__annotations.h +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_container__annotations.h @@ -1,6 +1,6 @@ ---- third_party/blink/renderer/platform/wtf/container_annotations.h.orig 2022-03-25 21:59:56 UTC +--- third_party/blink/renderer/platform/wtf/container_annotations.h.orig 2025-04-04 08:52:13 UTC +++ third_party/blink/renderer/platform/wtf/container_annotations.h -@@ -12,7 +12,7 @@ +@@ -11,7 +11,7 @@ // TODO(ochang): Remove the ARCH_CPU_X86_64 condition to enable this for X86 // once the crashes there have been fixed: http://crbug.com/461406 #if defined(ADDRESS_SANITIZER) && \ diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_stack__util.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_stack__util.cc index 205ded2ac3ab..3585f22d214a 100644 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_stack__util.cc +++ b/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_stack__util.cc @@ -1,7 +1,7 @@ ---- third_party/blink/renderer/platform/wtf/stack_util.cc.orig 2023-03-09 06:31:50 UTC +--- third_party/blink/renderer/platform/wtf/stack_util.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/blink/renderer/platform/wtf/stack_util.cc -@@ -18,6 +18,11 @@ - extern "C" void* __libc_stack_end; // NOLINT +@@ -27,6 +27,11 @@ extern "C" void* __libc_stack_end; // NOLINT + #include <sanitizer/asan_interface.h> #endif +#if BUILDFLAG(IS_BSD) @@ -12,7 +12,7 @@ namespace WTF { size_t GetUnderestimatedStackSize() { -@@ -62,6 +67,8 @@ size_t GetUnderestimatedStackSize() { +@@ -71,6 +76,8 @@ size_t GetUnderestimatedStackSize() { // low as 512k. // return 512 * 1024; @@ -21,7 +21,7 @@ #elif BUILDFLAG(IS_APPLE) // pthread_get_stacksize_np() returns too low a value for the main thread on // OSX 10.9, -@@ -148,6 +155,13 @@ void* GetStackStart() { +@@ -161,6 +168,13 @@ void* GetStackStartImpl() { ::GetCurrentThreadStackLimits(&lowLimit, &highLimit); return reinterpret_cast<void*>(highLimit); #endif diff --git a/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_text_text__codec__icu.cc b/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_text_text__codec__icu.cc deleted file mode 100644 index ff10a2d7b858..000000000000 --- a/www/chromium/files/patch-third__party_blink_renderer_platform_wtf_text_text__codec__icu.cc +++ /dev/null @@ -1,18 +0,0 @@ ---- third_party/blink/renderer/platform/wtf/text/text_codec_icu.cc.orig 2024-04-19 13:02:56 UTC -+++ third_party/blink/renderer/platform/wtf/text/text_codec_icu.cc -@@ -615,6 +615,7 @@ static void GbkUrlEscapedEntityCallack( - code_point, reason, err); - } - -+#if !BUILDFLAG(IS_BSD) - static void GbkCallbackSubstitute(const void* context, - UConverterFromUnicodeArgs* from_unicode_args, - const UChar* code_units, -@@ -632,6 +633,7 @@ static void GbkCallbackSubstitute(const void* context, - UCNV_FROM_U_CALLBACK_SUBSTITUTE(context, from_unicode_args, code_units, - length, code_point, reason, err); - } -+#endif - #endif // USING_SYSTEM_ICU - - static void NotReachedEntityCallback(const void* context, diff --git a/www/chromium/files/patch-third__party_boringssl_src_util_generate__build__files.py b/www/chromium/files/patch-third__party_boringssl_src_util_generate__build__files.py deleted file mode 100644 index e7e6c332c8f3..000000000000 --- a/www/chromium/files/patch-third__party_boringssl_src_util_generate__build__files.py +++ /dev/null @@ -1,34 +0,0 @@ ---- third_party/boringssl/src/util/generate_build_files.py.orig 2024-04-19 13:02:56 UTC -+++ third_party/boringssl/src/util/generate_build_files.py -@@ -807,10 +807,10 @@ def main(platforms): - ] - - # Generate err_data.c -- with open('err_data.c', 'w+') as err_data: -- subprocess.check_call(['go', 'run', 'err_data_generate.go'], -- cwd=os.path.join('src', 'crypto', 'err'), -- stdout=err_data) -+# with open('err_data.c', 'w+') as err_data: -+# subprocess.check_call(['go', 'run', 'err_data_generate.go'], -+# cwd=os.path.join('src', 'crypto', 'err'), -+# stdout=err_data) - crypto_c_files.append('err_data.c') - crypto_c_files.sort() - -@@ -821,11 +821,11 @@ def main(platforms): - crypto_test_files = [] - if EMBED_TEST_DATA: - # Generate crypto_test_data.cc -- with open('crypto_test_data.cc', 'w+') as out: -- subprocess.check_call( -- ['go', 'run', 'util/embed_test_data.go'] + cmake['CRYPTO_TEST_DATA'], -- cwd='src', -- stdout=out) -+# with open('crypto_test_data.cc', 'w+') as out: -+# subprocess.check_call( -+# ['go', 'run', 'util/embed_test_data.go'] + cmake['CRYPTO_TEST_DATA'], -+# cwd='src', -+# stdout=out) - crypto_test_files.append('crypto_test_data.cc') - - crypto_test_files += PrefixWithSrc(cmake['CRYPTO_TEST_SOURCES']) diff --git a/www/chromium/files/patch-third__party_crashpad_crashpad_build_crashpad__buildconfig.gni b/www/chromium/files/patch-third__party_crashpad_crashpad_build_crashpad__buildconfig.gni index 9b1981211642..9ab634aac0f0 100644 --- a/www/chromium/files/patch-third__party_crashpad_crashpad_build_crashpad__buildconfig.gni +++ b/www/chromium/files/patch-third__party_crashpad_crashpad_build_crashpad__buildconfig.gni @@ -1,7 +1,7 @@ ---- third_party/crashpad/crashpad/build/crashpad_buildconfig.gni.orig 2023-09-13 12:11:42 UTC +--- third_party/crashpad/crashpad/build/crashpad_buildconfig.gni.orig 2025-05-28 14:55:43 UTC +++ third_party/crashpad/crashpad/build/crashpad_buildconfig.gni -@@ -61,7 +61,7 @@ if (crashpad_is_in_chromium) { - crashpad_is_ios = is_ios +@@ -67,7 +67,7 @@ if (crashpad_is_in_chromium) { + crashpad_is_tvos = is_ios && target_platform == "tvos" crashpad_is_apple = is_apple crashpad_is_win = is_win - crashpad_is_linux = is_linux || is_chromeos diff --git a/www/chromium/files/patch-third__party_crashpad_crashpad_client_BUILD.gn b/www/chromium/files/patch-third__party_crashpad_crashpad_client_BUILD.gn index 8e01c2a42972..2c534e9b9b3c 100644 --- a/www/chromium/files/patch-third__party_crashpad_crashpad_client_BUILD.gn +++ b/www/chromium/files/patch-third__party_crashpad_crashpad_client_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/crashpad/crashpad/client/BUILD.gn.orig 2023-09-13 12:11:42 UTC +--- third_party/crashpad/crashpad/client/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ third_party/crashpad/crashpad/client/BUILD.gn -@@ -137,6 +137,13 @@ static_library("common") { +@@ -148,6 +148,13 @@ static_library("common") { if (crashpad_is_win) { sources += [ "crash_report_database_win.cc" ] } diff --git a/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_capture__context.h b/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_capture__context.h index c7a9411e7f2f..4def4d0d97f7 100644 --- a/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_capture__context.h +++ b/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_capture__context.h @@ -1,6 +1,6 @@ ---- third_party/crashpad/crashpad/util/misc/capture_context.h.orig 2023-09-13 12:11:42 UTC +--- third_party/crashpad/crashpad/util/misc/capture_context.h.orig 2025-07-02 06:08:04 UTC +++ third_party/crashpad/crashpad/util/misc/capture_context.h -@@ -21,7 +21,8 @@ +@@ -21,8 +21,11 @@ #include <mach/mach.h> #elif BUILDFLAG(IS_WIN) #include <windows.h> @@ -8,9 +8,12 @@ +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || \ + BUILDFLAG(IS_FREEBSD) #include <ucontext.h> ++#elif BUILDFLAG(IS_OPENBSD) ++#include <sys/signal.h> #endif // BUILDFLAG(IS_APPLE) -@@ -35,7 +36,8 @@ using NativeCPUContext = arm_unified_thread_state; + namespace crashpad { +@@ -35,7 +38,8 @@ using NativeCPUContext = arm_unified_thread_state; #endif #elif BUILDFLAG(IS_WIN) using NativeCPUContext = CONTEXT; diff --git a/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_uuid.cc b/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_uuid.cc index 8a8a4052b862..52c37d1bd6c6 100644 --- a/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_uuid.cc +++ b/www/chromium/files/patch-third__party_crashpad_crashpad_util_misc_uuid.cc @@ -1,6 +1,6 @@ ---- third_party/crashpad/crashpad/util/misc/uuid.cc.orig 2024-01-30 07:53:34 UTC +--- third_party/crashpad/crashpad/util/misc/uuid.cc.orig 2024-06-17 12:56:06 UTC +++ third_party/crashpad/crashpad/util/misc/uuid.cc -@@ -102,7 +102,7 @@ bool UUID::InitializeWithNew() { +@@ -110,7 +110,7 @@ bool UUID::InitializeWithNew() { InitializeFromBytes(uuid); return true; #elif BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ diff --git a/www/chromium/files/patch-third__party_crashpad_crashpad_util_posix_symbolic__constants__posix.cc b/www/chromium/files/patch-third__party_crashpad_crashpad_util_posix_symbolic__constants__posix.cc index ade30531a9b6..d7779cb87f3e 100644 --- a/www/chromium/files/patch-third__party_crashpad_crashpad_util_posix_symbolic__constants__posix.cc +++ b/www/chromium/files/patch-third__party_crashpad_crashpad_util_posix_symbolic__constants__posix.cc @@ -1,6 +1,6 @@ ---- third_party/crashpad/crashpad/util/posix/symbolic_constants_posix.cc.orig 2022-04-21 18:48:31 UTC +--- third_party/crashpad/crashpad/util/posix/symbolic_constants_posix.cc.orig 2024-08-26 12:06:38 UTC +++ third_party/crashpad/crashpad/util/posix/symbolic_constants_posix.cc -@@ -67,7 +67,7 @@ constexpr const char* kSignalNames[] = { +@@ -68,7 +68,7 @@ constexpr const char* kSignalNames[] = { "INFO", "USR1", "USR2", @@ -9,7 +9,7 @@ #if defined(ARCH_CPU_MIPS_FAMILY) "HUP", "INT", -@@ -138,7 +138,7 @@ constexpr const char* kSignalNames[] = { +@@ -139,7 +139,7 @@ constexpr const char* kSignalNames[] = { #endif // defined(ARCH_CPU_MIPS_FAMILY) #endif }; diff --git a/www/chromium/files/patch-third__party_dawn_include_dawn_native_VulkanBackend.h b/www/chromium/files/patch-third__party_dawn_include_dawn_native_VulkanBackend.h index e1cb50cd8016..446299bfb0ff 100644 --- a/www/chromium/files/patch-third__party_dawn_include_dawn_native_VulkanBackend.h +++ b/www/chromium/files/patch-third__party_dawn_include_dawn_native_VulkanBackend.h @@ -1,11 +1,11 @@ ---- third_party/dawn/include/dawn/native/VulkanBackend.h.orig 2023-12-10 06:10:27 UTC +--- third_party/dawn/include/dawn/native/VulkanBackend.h.orig 2024-06-17 12:56:06 UTC +++ third_party/dawn/include/dawn/native/VulkanBackend.h @@ -83,7 +83,7 @@ struct ExternalImageExportInfoVk : ExternalImageExport }; // Can't use DAWN_PLATFORM_IS(LINUX) since header included in both Dawn and Chrome --#ifdef __linux__ -+#if defined(__linux__) || defined(__OpenBSD__) || defined(__FreeBSD__) +-#if defined(__linux__) || defined(__Fuchsia__) ++#if defined(__linux__) || defined(__Fuchsia__) || defined(__OpenBSD__) || defined(__FreeBSD__) // Common properties of external images represented by FDs. On successful import the file // descriptor's ownership is transferred to the Dawn implementation and they shouldn't be diff --git a/www/chromium/files/patch-third__party_dawn_src_dawn_common_Platform.h b/www/chromium/files/patch-third__party_dawn_src_dawn_common_Platform.h index 4e818e74f998..93d63f7106d1 100644 --- a/www/chromium/files/patch-third__party_dawn_src_dawn_common_Platform.h +++ b/www/chromium/files/patch-third__party_dawn_src_dawn_common_Platform.h @@ -1,6 +1,6 @@ ---- third_party/dawn/src/dawn/common/Platform.h.orig 2023-12-10 06:10:27 UTC +--- third_party/dawn/src/dawn/common/Platform.h.orig 2025-04-04 08:52:13 UTC +++ third_party/dawn/src/dawn/common/Platform.h -@@ -59,6 +59,11 @@ +@@ -60,6 +60,11 @@ #error "Unsupported Windows platform." #endif diff --git a/www/chromium/files/patch-third__party_dawn_src_dawn_native_vulkan_BackendVk.cpp b/www/chromium/files/patch-third__party_dawn_src_dawn_native_vulkan_BackendVk.cpp index f36b7ba1418b..2a5fe46d0392 100644 --- a/www/chromium/files/patch-third__party_dawn_src_dawn_native_vulkan_BackendVk.cpp +++ b/www/chromium/files/patch-third__party_dawn_src_dawn_native_vulkan_BackendVk.cpp @@ -1,4 +1,4 @@ ---- third_party/dawn/src/dawn/native/vulkan/BackendVk.cpp.orig 2024-02-23 21:04:38 UTC +--- third_party/dawn/src/dawn/native/vulkan/BackendVk.cpp.orig 2025-05-28 14:55:43 UTC +++ third_party/dawn/src/dawn/native/vulkan/BackendVk.cpp @@ -56,7 +56,7 @@ constexpr char kSwiftshaderLibName[] = "libvk_swiftsha #endif diff --git a/www/chromium/files/patch-third__party_ffmpeg_BUILD.gn b/www/chromium/files/patch-third__party_ffmpeg_BUILD.gn index 8256c0dc6015..f1d36333ae9c 100644 --- a/www/chromium/files/patch-third__party_ffmpeg_BUILD.gn +++ b/www/chromium/files/patch-third__party_ffmpeg_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/ffmpeg/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- third_party/ffmpeg/BUILD.gn.orig 2025-05-28 14:55:43 UTC +++ third_party/ffmpeg/BUILD.gn -@@ -343,7 +343,6 @@ target(link_target_type, "ffmpeg_internal") { +@@ -355,7 +355,6 @@ target(link_target_type, "ffmpeg_internal") { libs += [ "m", "z", diff --git a/www/chromium/files/patch-third__party_ffmpeg_configure b/www/chromium/files/patch-third__party_ffmpeg_configure index 4ef45be429b6..c474d6eed528 100644 --- a/www/chromium/files/patch-third__party_ffmpeg_configure +++ b/www/chromium/files/patch-third__party_ffmpeg_configure @@ -1,6 +1,6 @@ ---- third_party/ffmpeg/configure.orig 2024-04-25 07:48:13 UTC +--- third_party/ffmpeg/configure.orig 2025-07-02 06:08:04 UTC +++ third_party/ffmpeg/configure -@@ -6713,8 +6713,8 @@ if ! disabled pthreads && ! enabled w32threads && ! en +@@ -6885,8 +6885,8 @@ if ! disabled pthreads && ! enabled w32threads && ! en if enabled pthread_np_h; then hdrs="$hdrs pthread_np.h" fi diff --git a/www/chromium/files/patch-third__party_ffmpeg_libavutil_x86_x86inc.asm b/www/chromium/files/patch-third__party_ffmpeg_libavutil_x86_x86inc.asm index 2f17fb106b09..4f4d7614c9a7 100644 --- a/www/chromium/files/patch-third__party_ffmpeg_libavutil_x86_x86inc.asm +++ b/www/chromium/files/patch-third__party_ffmpeg_libavutil_x86_x86inc.asm @@ -1,6 +1,6 @@ ---- third_party/ffmpeg/libavutil/x86/x86inc.asm.orig 2024-01-30 07:53:34 UTC +--- third_party/ffmpeg/libavutil/x86/x86inc.asm.orig 2024-06-17 12:56:06 UTC +++ third_party/ffmpeg/libavutil/x86/x86inc.asm -@@ -53,6 +53,12 @@ +@@ -46,6 +46,12 @@ %endif %endif @@ -13,7 +13,7 @@ %define WIN64 0 %define UNIX64 0 %if ARCH_X86_64 -@@ -778,6 +784,7 @@ BRANCH_INSTR jz, je, jnz, jne, jl, jle, jnl, jnle, jg, +@@ -861,6 +867,7 @@ BRANCH_INSTR jz, je, jnz, jne, jl, jle, jnl, jnle, jg, %endif align function_align %2: diff --git a/www/chromium/files/patch-third__party_fontconfig_include_config.h b/www/chromium/files/patch-third__party_fontconfig_include_meson-config.h index bc9a9cfaa835..a0b1b54538de 100644 --- a/www/chromium/files/patch-third__party_fontconfig_include_config.h +++ b/www/chromium/files/patch-third__party_fontconfig_include_meson-config.h @@ -1,24 +1,15 @@ ---- third_party/fontconfig/include/config.h.orig 2024-03-22 08:19:40 UTC -+++ third_party/fontconfig/include/config.h -@@ -13,7 +13,7 @@ +--- third_party/fontconfig/include/meson-config.h.orig 2025-07-02 06:08:04 UTC ++++ third_party/fontconfig/include/meson-config.h +@@ -17,7 +17,7 @@ #define FC_CACHEDIR "/var/cache/fontconfig" -#define FC_DEFAULT_FONTS "\t<dir>/usr/share/fonts</dir>\n\t<dir>/usr/local/share/fonts</dir>\n" -+#define FC_DEFAULT_FONTS "\t<dir>/usr/X11R6/lib/X11/fonts</dir>" ++#define FC_DEFAULT_FONTS "\t<dir>/usr/X11R6/lib/X11/fonts</dir>\n" #define FC_FONTPATH "" -@@ -66,7 +66,7 @@ - - #define HAVE_MMAP 1 - --#define HAVE_POSIX_FADVISE 1 -+#define HAVE_POSIX_FADVISE 0 - - #define HAVE_PTHREAD 1 - -@@ -74,10 +74,13 @@ +@@ -92,10 +92,13 @@ #define HAVE_RANDOM 1 @@ -33,7 +24,7 @@ #define HAVE_READLINK 1 #define HAVE_STDATOMIC_PRIMITIVES 1 -@@ -92,11 +95,11 @@ +@@ -122,7 +125,7 @@ #define HAVE_SYS_PARAM_H 1 @@ -42,8 +33,12 @@ #define HAVE_SYS_STATVFS_H 1 +@@ -130,7 +133,7 @@ + + #define HAVE_SYS_TYPES_H 1 + -#define HAVE_SYS_VFS_H 1 +/* #undef HAVE_SYS_VFS_H */ - #define HAVE_UNISTD_H 1 + #define HAVE_TIME_H 1 diff --git a/www/chromium/files/patch-third__party_fontconfig_src_src_fccompat.c b/www/chromium/files/patch-third__party_fontconfig_src_src_fccompat.c index 76245ce2e3d4..5244dd445d6f 100644 --- a/www/chromium/files/patch-third__party_fontconfig_src_src_fccompat.c +++ b/www/chromium/files/patch-third__party_fontconfig_src_src_fccompat.c @@ -1,6 +1,6 @@ ---- third_party/fontconfig/src/src/fccompat.c.orig 2023-04-05 11:05:06 UTC +--- third_party/fontconfig/src/src/fccompat.c.orig 2025-07-02 06:08:04 UTC +++ third_party/fontconfig/src/src/fccompat.c -@@ -184,7 +184,9 @@ FcRandom(void) +@@ -175,7 +175,9 @@ FcRandom (void) { int32_t result; @@ -9,5 +9,5 @@ + result = arc4random() & 0x7fffffff; +#elif HAVE_RANDOM_R static struct random_data fcrandbuf; - static char statebuf[256]; - static FcBool initialized = FcFalse; + static char statebuf[256]; + static FcBool initialized = FcFalse; diff --git a/www/chromium/files/patch-third__party_ipcz_src_BUILD.gn b/www/chromium/files/patch-third__party_ipcz_src_BUILD.gn new file mode 100644 index 000000000000..7b38079188da --- /dev/null +++ b/www/chromium/files/patch-third__party_ipcz_src_BUILD.gn @@ -0,0 +1,11 @@ +--- third_party/ipcz/src/BUILD.gn.orig 2025-04-04 08:52:13 UTC ++++ third_party/ipcz/src/BUILD.gn +@@ -7,7 +7,7 @@ import("//build_overrides/ipcz.gni") + import("//testing/libfuzzer/fuzzer_test.gni") + import("//testing/test.gni") + +-enable_multiprocess_tests = is_linux ++enable_multiprocess_tests = is_linux && !is_bsd + + buildflag_header("test_buildflags") { + header = "test_buildflags.h" diff --git a/www/chromium/files/patch-third__party_ipcz_src_reference__drivers_random.cc b/www/chromium/files/patch-third__party_ipcz_src_reference__drivers_random.cc index d7204e397b43..2e57899d408c 100644 --- a/www/chromium/files/patch-third__party_ipcz_src_reference__drivers_random.cc +++ b/www/chromium/files/patch-third__party_ipcz_src_reference__drivers_random.cc @@ -1,20 +1,20 @@ ---- third_party/ipcz/src/reference_drivers/random.cc.orig 2023-09-13 12:11:42 UTC +--- third_party/ipcz/src/reference_drivers/random.cc.orig 2025-04-04 08:52:13 UTC +++ third_party/ipcz/src/reference_drivers/random.cc -@@ -14,7 +14,7 @@ - #include <windows.h> - #elif BUILDFLAG(IS_FUCHSIA) - #include <zircon/syscalls.h> --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - #include <asm/unistd.h> - #include <sys/syscall.h> - #include <unistd.h> -@@ -86,7 +86,7 @@ void RandomBytes(absl::Span<uint8_t> destination) { - process_prng_fn(destination.data(), destination.size()); - #elif BUILDFLAG(IS_FUCHSIA) - zx_cprng_draw(destination.data(), destination.size()); --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) - while (!destination.empty()) { - ssize_t result = - syscall(__NR_getrandom, destination.data(), destination.size(), 0); +@@ -55,7 +55,7 @@ decltype(&ProcessPrng) GetProcessPrng() { + } + #endif + +-#if defined(OS_POSIX) && !BUILDFLAG(IS_MAC) ++#if defined(OS_POSIX) && !BUILDFLAG(IS_MAC) && !BUILDFLAG(IS_BSD) + void RandomBytesFromDevUrandom(absl::Span<uint8_t> destination) { + static int urandom_fd = [] { + for (;;) { +@@ -99,7 +99,7 @@ void RandomBytes(absl::Span<uint8_t> destination) { + return; + } + } +-#elif BUILDFLAG(IS_MAC) ++#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_BSD) + const bool ok = getentropy(destination.data(), destination.size()) == 0; + ABSL_ASSERT(ok); + #elif BUILDFLAG(IS_IOS) diff --git a/www/chromium/files/patch-third__party_ipcz_src_standalone_base_logging.cc b/www/chromium/files/patch-third__party_ipcz_src_standalone_base_logging.cc index e78ffde6fb39..b28bf070e23c 100644 --- a/www/chromium/files/patch-third__party_ipcz_src_standalone_base_logging.cc +++ b/www/chromium/files/patch-third__party_ipcz_src_standalone_base_logging.cc @@ -1,6 +1,6 @@ ---- third_party/ipcz/src/standalone/base/logging.cc.orig 2022-05-19 14:06:27 UTC +--- third_party/ipcz/src/standalone/base/logging.cc.orig 2025-03-05 08:14:56 UTC +++ third_party/ipcz/src/standalone/base/logging.cc -@@ -50,6 +50,9 @@ LogMessage::LogMessage(const char* file, int line, Lev +@@ -55,6 +55,9 @@ LogMessage::LogMessage(const char* file, int line, Lev #elif BUILDFLAG(IS_ANDROID) stream_ << getpid() << ":" << gettid() << ":"; const char* trimmed_file = strrchr(file, '/') + 1; diff --git a/www/chromium/files/patch-third__party_leveldatabase_env__chromium.cc b/www/chromium/files/patch-third__party_leveldatabase_env__chromium.cc index 4ebf1fcf6385..a266c66d9ff6 100644 --- a/www/chromium/files/patch-third__party_leveldatabase_env__chromium.cc +++ b/www/chromium/files/patch-third__party_leveldatabase_env__chromium.cc @@ -1,6 +1,6 @@ ---- third_party/leveldatabase/env_chromium.cc.orig 2024-02-23 21:04:38 UTC +--- third_party/leveldatabase/env_chromium.cc.orig 2024-10-22 08:31:56 UTC +++ third_party/leveldatabase/env_chromium.cc -@@ -326,7 +326,8 @@ ChromiumWritableFile::ChromiumWritableFile(const std:: +@@ -329,7 +329,8 @@ ChromiumWritableFile::ChromiumWritableFile(const std:: Status ChromiumWritableFile::SyncParent() { TRACE_EVENT0("leveldb", "SyncParent"); diff --git a/www/chromium/files/patch-third__party_libaom_source_libaom_aom__ports_aarch64__cpudetect.c b/www/chromium/files/patch-third__party_libaom_source_libaom_aom__ports_aarch64__cpudetect.c index a18b66eb4f9a..4e1bd4a57ff4 100644 --- a/www/chromium/files/patch-third__party_libaom_source_libaom_aom__ports_aarch64__cpudetect.c +++ b/www/chromium/files/patch-third__party_libaom_source_libaom_aom__ports_aarch64__cpudetect.c @@ -1,6 +1,6 @@ ---- third_party/libaom/source/libaom/aom_ports/aarch64_cpudetect.c.orig 2024-04-19 13:02:56 UTC +--- third_party/libaom/source/libaom/aom_ports/aarch64_cpudetect.c.orig 2024-11-14 07:57:23 UTC +++ third_party/libaom/source/libaom/aom_ports/aarch64_cpudetect.c -@@ -99,9 +99,45 @@ static int arm_get_cpu_caps(void) { +@@ -127,9 +127,45 @@ static int arm_get_cpu_caps(void) { return flags; } @@ -21,7 +21,7 @@ + if (sysctl(isar0_mib, 2, &cpu_id, &len, NULL, 0) < 0) + return flags; + -+ if (ID_AA64ISAR0_AES(cpu_id) >= ID_AA64ISAR0_CRC32_BASE) ++ if (ID_AA64ISAR0_CRC32(cpu_id) >= ID_AA64ISAR0_CRC32_BASE) + flags |= HAS_ARM_CRC32; + + return flags; diff --git a/www/chromium/files/patch-third__party_libc++_src_src_chrono.cpp b/www/chromium/files/patch-third__party_libc++_src_src_chrono.cpp index 74549d1bed4b..52bbe5fe11c7 100644 --- a/www/chromium/files/patch-third__party_libc++_src_src_chrono.cpp +++ b/www/chromium/files/patch-third__party_libc++_src_src_chrono.cpp @@ -1,11 +1,11 @@ ---- third_party/libc++/src/src/chrono.cpp.orig 2024-02-23 21:04:38 UTC +--- third_party/libc++/src/src/chrono.cpp.orig 2025-02-19 07:43:18 UTC +++ third_party/libc++/src/src/chrono.cpp -@@ -31,7 +31,7 @@ - # include <sys/time.h> // for gettimeofday and timeval - #endif - --#if defined(__APPLE__) || defined(__gnu_hurd__) || (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) -+#if defined(__APPLE__) || defined(__gnu_hurd__) || (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) || defined(__OpenBSD__) || defined(__FreeBSD__) +@@ -38,7 +38,7 @@ + // OpenBSD and GPU do not have a fully conformant suite of POSIX timers, but + // it does have clock_gettime and CLOCK_MONOTONIC which is all we need. + #if defined(__APPLE__) || defined(__gnu_hurd__) || defined(__OpenBSD__) || defined(__AMDGPU__) || \ +- defined(__NVPTX__) || (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) ++ defined(__NVPTX__) || (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) || defined(__FreeBSD__) # define _LIBCPP_HAS_CLOCK_GETTIME #endif diff --git a/www/chromium/files/patch-third__party_libc++_src_src_filesystem_filesystem__clock.cpp b/www/chromium/files/patch-third__party_libc++_src_src_filesystem_filesystem__clock.cpp index ec65ec24208f..82dff2d04520 100644 --- a/www/chromium/files/patch-third__party_libc++_src_src_filesystem_filesystem__clock.cpp +++ b/www/chromium/files/patch-third__party_libc++_src_src_filesystem_filesystem__clock.cpp @@ -1,11 +1,11 @@ ---- third_party/libc++/src/src/filesystem/filesystem_clock.cpp.orig 2024-02-23 21:04:38 UTC +--- third_party/libc++/src/src/filesystem/filesystem_clock.cpp.orig 2025-02-19 07:43:18 UTC +++ third_party/libc++/src/src/filesystem/filesystem_clock.cpp -@@ -29,7 +29,7 @@ - # include <sys/time.h> // for gettimeofday and timeval +@@ -35,7 +35,7 @@ #endif --#if defined(__APPLE__) || defined(__gnu_hurd__) || (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) -+#if defined(__APPLE__) || defined(__gnu_hurd__) || (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) || defined(__OpenBSD__) || defined(__FreeBSD__) + #if defined(__APPLE__) || defined(__gnu_hurd__) || defined(__AMDGPU__) || defined(__NVPTX__) || \ +- (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) ++ (defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0) || defined(__OpenBSD__) || defined(__FreeBSD__) # define _LIBCPP_HAS_CLOCK_GETTIME #endif diff --git a/www/chromium/files/patch-third__party_libc++abi_src_src_cxa__guard__impl.h b/www/chromium/files/patch-third__party_libc++abi_src_src_cxa__guard__impl.h deleted file mode 100644 index 342e353236ff..000000000000 --- a/www/chromium/files/patch-third__party_libc++abi_src_src_cxa__guard__impl.h +++ /dev/null @@ -1,24 +0,0 @@ ---- third_party/libc++abi/src/src/cxa_guard_impl.h.orig 2024-01-30 07:53:34 UTC -+++ third_party/libc++abi/src/src/cxa_guard_impl.h -@@ -411,7 +411,20 @@ struct InitByteGlobalMutex { (private) - // Futex Implementation - //===----------------------------------------------------------------------===// - --#if defined(SYS_futex) -+#ifdef __OpenBSD__ -+#include <sys/futex.h> -+ -+void PlatformFutexWait(int* addr, int expect) { -+ constexpr int WAIT = 0; -+ futex((volatile uint32_t *)addr, WAIT, expect, NULL, NULL); -+ __tsan_acquire(addr); -+} -+void PlatformFutexWake(int* addr) { -+ constexpr int WAKE = 1; -+ __tsan_release(addr); -+ futex((volatile uint32_t *)addr, WAKE, INT_MAX, NULL, NULL); -+} -+#elif defined(SYS_futex) - void PlatformFutexWait(int* addr, int expect) { - constexpr int WAIT = 0; - syscall(SYS_futex, addr, WAIT, expect, 0); diff --git a/www/chromium/files/patch-third__party_libusb_src_libusb_libusb.h b/www/chromium/files/patch-third__party_libusb_src_libusb_libusb.h deleted file mode 100644 index 195e21568483..000000000000 --- a/www/chromium/files/patch-third__party_libusb_src_libusb_libusb.h +++ /dev/null @@ -1,11 +0,0 @@ ---- third_party/libusb/src/libusb/libusb.h.orig 2024-04-19 13:02:56 UTC -+++ third_party/libusb/src/libusb/libusb.h -@@ -60,7 +60,7 @@ typedef unsigned __int32 uint32_t; - #include <sys/types.h> - #endif - --#if defined(__linux) || defined(__APPLE__) || defined(__CYGWIN__) -+#if defined(__linux) || defined(__APPLE__) || defined(__CYGWIN__) || defined(__OpenBSD__) || defined(__FreeBSD__) - #include <sys/time.h> - #endif - diff --git a/www/chromium/files/patch-third__party_libvpx_source_libvpx_vpx__ports_aarch64__cpudetect.c b/www/chromium/files/patch-third__party_libvpx_source_libvpx_vpx__ports_aarch64__cpudetect.c index 263d9f1a106f..5bc574e37a09 100644 --- a/www/chromium/files/patch-third__party_libvpx_source_libvpx_vpx__ports_aarch64__cpudetect.c +++ b/www/chromium/files/patch-third__party_libvpx_source_libvpx_vpx__ports_aarch64__cpudetect.c @@ -1,6 +1,6 @@ ---- third_party/libvpx/source/libvpx/vpx_ports/aarch64_cpudetect.c.orig 2024-01-30 07:53:34 UTC +--- third_party/libvpx/source/libvpx/vpx_ports/aarch64_cpudetect.c.orig 2024-11-14 07:57:23 UTC +++ third_party/libvpx/source/libvpx/vpx_ports/aarch64_cpudetect.c -@@ -91,9 +91,23 @@ static int arm_get_cpu_caps(void) { +@@ -120,9 +120,23 @@ static int arm_get_cpu_caps(void) { return flags; } diff --git a/www/chromium/files/patch-third__party_lzma__sdk_C_CpuArch.c b/www/chromium/files/patch-third__party_lzma__sdk_C_CpuArch.c index e5faa231f03f..fc8c3b1b38a1 100644 --- a/www/chromium/files/patch-third__party_lzma__sdk_C_CpuArch.c +++ b/www/chromium/files/patch-third__party_lzma__sdk_C_CpuArch.c @@ -1,11 +1,11 @@ ---- third_party/lzma_sdk/C/CpuArch.c.orig 2022-09-04 11:56:14 UTC +--- third_party/lzma_sdk/C/CpuArch.c.orig 2025-05-05 10:57:53 UTC +++ third_party/lzma_sdk/C/CpuArch.c -@@ -412,12 +412,40 @@ BoolInt CPU_IsSupported_SHA1(void) { return APPLE_CRYP +@@ -854,6 +854,34 @@ BoolInt CPU_IsSupported_SHA1(void) { return APPLE_CRYP BoolInt CPU_IsSupported_SHA2(void) { return APPLE_CRYPTO_SUPPORT_VAL; } BoolInt CPU_IsSupported_AES (void) { return APPLE_CRYPTO_SUPPORT_VAL; } +#elif defined(__OpenBSD__) - ++ +#include <sys/param.h> +#include <sys/sysctl.h> +#include <machine/cpu.h> @@ -32,13 +32,6 @@ +MY_HWCAP_CHECK_FUNC (SHA1) +MY_HWCAP_CHECK_FUNC (SHA2) +MY_HWCAP_CHECK_FUNC (AES) -+ - #else // __APPLE__ - - #include <sys/auxv.h> --#if !defined(ARMV8_OS_FUCHSIA) -+#if !defined(ARMV8_OS_FUCHSIA) && !defined(__FreeBSD__) - #define USE_HWCAP - #endif // !defined(ARMV8_OS_FUCHSIA) + #else // __APPLE__ diff --git a/www/chromium/files/patch-third__party_maldoca_BUILD.gn b/www/chromium/files/patch-third__party_maldoca_BUILD.gn deleted file mode 100644 index ac216fd83808..000000000000 --- a/www/chromium/files/patch-third__party_maldoca_BUILD.gn +++ /dev/null @@ -1,13 +0,0 @@ ---- third_party/maldoca/BUILD.gn.orig 2023-04-05 11:05:06 UTC -+++ third_party/maldoca/BUILD.gn -@@ -264,6 +264,10 @@ source_set("maldoca-public-headers") { - ":maldoca_chromium_config", - ":maldoca_flags", - ] -+ -+ if (is_bsd) { -+ libs = [ "iconv" ] -+ } - } - - static_library("maldoca") { diff --git a/www/chromium/files/patch-third__party_maldoca_src_maldoca_base_get__runfiles__dir.cc b/www/chromium/files/patch-third__party_maldoca_src_maldoca_base_get__runfiles__dir.cc deleted file mode 100644 index 4bf69e6e6f3c..000000000000 --- a/www/chromium/files/patch-third__party_maldoca_src_maldoca_base_get__runfiles__dir.cc +++ /dev/null @@ -1,32 +0,0 @@ ---- third_party/maldoca/src/maldoca/base/get_runfiles_dir.cc.orig 2023-11-03 10:09:45 UTC -+++ third_party/maldoca/src/maldoca/base/get_runfiles_dir.cc -@@ -25,11 +25,6 @@ - #error "__APPLE__ not supported." - #endif - --#if defined(__FreeBSD__) --// TODO(#110) FreeBSD-specific headers. --#error "__FreeBSD__ not supported." --#endif -- - #if defined(_WIN32) - #include <windows.h> - #define PATH_MAX MAX_PATH -@@ -51,8 +46,6 @@ std::string GetExecutablePath() { - char exe_path[PATH_MAX] = {0}; - #ifdef __APPLE__ - #error "__APPLE__ not supported."; --#elif defined(__FreeBSD__) --#error "__FreeBSD__ not supported."; - #elif defined(_WIN32) - HMODULE hModule = GetModuleHandleW(NULL); - WCHAR wc_file_path[MAX_PATH] = {0}; -@@ -98,8 +91,6 @@ std::string GetExecutablePath() { - absl::Status IsDirectory(const std::string& name) { - #ifdef __APPLE__ - #error "__APPLE__ not supported."; --#elif defined(__FreeBSD__) --#error "__FreeBSD__ not supported."; - #else - struct stat sbuf; - if (stat(name.c_str(), &sbuf) != 0) { diff --git a/www/chromium/files/patch-third__party_maldoca_src_maldoca_service_common_process__doc__wrapper.cc b/www/chromium/files/patch-third__party_maldoca_src_maldoca_service_common_process__doc__wrapper.cc deleted file mode 100644 index a299789a8335..000000000000 --- a/www/chromium/files/patch-third__party_maldoca_src_maldoca_service_common_process__doc__wrapper.cc +++ /dev/null @@ -1,29 +0,0 @@ ---- third_party/maldoca/src/maldoca/service/common/process_doc_wrapper.cc.orig 2023-09-13 12:11:42 UTC -+++ third_party/maldoca/src/maldoca/service/common/process_doc_wrapper.cc -@@ -7,7 +7,7 @@ - #include "build/build_config.h" - - #include "base/files/file_util.h" --#if defined(OS_LINUX) -+#if defined(OS_LINUX) || BUILDFLAG(IS_BSD) - #include "base/strings/string_util.h" - #else - #include "base/strings/string_util_win.h" -@@ -21,7 +21,7 @@ namespace third_party_maldoca { - - - bool ExtensionEqualInCaseSensitive(base::FilePath file_path, std::string extension){ -- #if defined(OS_LINUX) -+ #if defined(OS_LINUX) || BUILDFLAG(IS_BSD) - std::string file_extension = file_path.FinalExtension(); - return base::CompareCaseInsensitiveASCII(file_extension, extension) == 0; - #else -@@ -74,7 +74,7 @@ void AnalyzeOfficeDocument(base::File office_file, - maldoca::DocProcessor doc_processor(processor_config); - - maldoca::ProcessDocumentRequest process_doc_request; -- #if defined(OS_LINUX) -+ #if defined(OS_LINUX) || BUILDFLAG(IS_BSD) - const std::string file_name = file_path.BaseName().value().c_str(); - process_doc_request.set_file_name(file_name); - #endif diff --git a/www/chromium/files/patch-third__party_nasm_BUILD.gn b/www/chromium/files/patch-third__party_nasm_BUILD.gn index a056b77b8a9a..0f80d077e042 100644 --- a/www/chromium/files/patch-third__party_nasm_BUILD.gn +++ b/www/chromium/files/patch-third__party_nasm_BUILD.gn @@ -1,4 +1,4 @@ ---- third_party/nasm/BUILD.gn.orig 2023-01-11 09:17:16 UTC +--- third_party/nasm/BUILD.gn.orig 2024-07-30 19:22:51 UTC +++ third_party/nasm/BUILD.gn @@ -63,6 +63,13 @@ config("nasm_config") { @@ -6,7 +6,7 @@ + _string_h_lines = + read_file("/usr/include/string.h", "list lines") -+ _mempcpy = filter_include(_string_h_lines, [ "*\*mempcpy*" ]) ++ _mempcpy = filter_include(_string_h_lines, [ "*mempcpy*" ]) + if (_mempcpy != []) { + defines += [ "HAVE_MEMPCPY=1" ] + } diff --git a/www/chromium/files/patch-third__party_nasm_config_config-linux.h b/www/chromium/files/patch-third__party_nasm_config_config-linux.h index 0fe3d559929e..cfe941f33d33 100644 --- a/www/chromium/files/patch-third__party_nasm_config_config-linux.h +++ b/www/chromium/files/patch-third__party_nasm_config_config-linux.h @@ -1,27 +1,18 @@ ---- third_party/nasm/config/config-linux.h.orig 2023-01-11 09:17:16 UTC +--- third_party/nasm/config/config-linux.h.orig 2025-05-28 14:55:43 UTC +++ third_party/nasm/config/config-linux.h -@@ -160,7 +160,7 @@ - - /* Define to 1 if you have the declaration of `strlcpy', and to 0 if you - don't. */ --#define HAVE_DECL_STRLCPY 0 -+#define HAVE_DECL_STRLCPY 1 - - /* Define to 1 if you have the declaration of `strncasecmp', and to 0 if you - don't. */ -@@ -183,7 +183,7 @@ +@@ -209,7 +209,7 @@ #define HAVE_DECL_STRSEP 1 /* Define to 1 if you have the <endian.h> header file. */ -#define HAVE_ENDIAN_H 1 +/* #undef HAVE_ENDIAN_H */ - /* Define to 1 if you have the `faccessat' function. */ + /* Define to 1 if you have the 'faccessat' function. */ #define HAVE_FACCESSAT 1 -@@ -327,16 +327,16 @@ +@@ -351,13 +351,13 @@ #define HAVE_ISASCII 1 - /* Define to 1 if you have the `iscntrl' function. */ + /* Define to 1 if you have the 'iscntrl' function. */ -/* #undef HAVE_ISCNTRL */ +#define HAVE_ISCNTRL 1 @@ -29,16 +20,13 @@ -/* #undef HAVE_MACHINE_ENDIAN_H */ +#define HAVE_MACHINE_ENDIAN_H 1 - /* Define to 1 if you have the <memory.h> header file. */ - #define HAVE_MEMORY_H 1 - - /* Define to 1 if you have the `mempcpy' function. */ + /* Define to 1 if you have the 'mempcpy' function. */ -#define HAVE_MEMPCPY 1 +/* #undef HAVE_MEMPCPY */ - /* Define to 1 if you have a working `mmap' system call. */ - #define HAVE_MMAP 1 -@@ -357,7 +357,7 @@ + /* Define to 1 if you have the 'mempset' function. */ + /* #undef HAVE_MEMPSET */ +@@ -384,7 +384,7 @@ #define HAVE_STDARG_H 1 /* Define to 1 if stdbool.h conforms to C99. */ @@ -47,16 +35,16 @@ /* Define to 1 if your compiler supports C99 extern inline */ #define HAVE_STDC_INLINE 1 -@@ -384,7 +384,7 @@ +@@ -414,7 +414,7 @@ #define HAVE_STRING_H 1 - /* Define to 1 if you have the `strlcpy' function. */ --/* #undef HAVE_STRLCPY */ + /* Define to 1 if you have the 'strlcpy' function. */ +-/* #undef HAVE_STRLCPY */ // Shouldn\'t work with -std=c11, but configure still detects it. +#define HAVE_STRLCPY 1 - /* Define to 1 if you have the `strncasecmp' function. */ + /* Define to 1 if you have the 'strncasecmp' function. */ #define HAVE_STRNCASECMP 1 -@@ -411,7 +411,7 @@ +@@ -441,7 +441,7 @@ #define HAVE_SYSCONF 1 /* Define to 1 if you have the <sys/endian.h> header file. */ @@ -65,7 +53,7 @@ /* Define to 1 if you have the <sys/mman.h> header file. */ #define HAVE_SYS_MMAN_H 1 -@@ -486,13 +486,13 @@ +@@ -522,13 +522,13 @@ /* #undef HAVE__STATI64 */ /* Define to 1 if you have the `__bswap_16' intrinsic function. */ @@ -82,21 +70,3 @@ /* Define to 1 if you have the `__builtin_bswap16' intrinsic function. */ #define HAVE___BUILTIN_BSWAP16 1 -@@ -620,7 +620,7 @@ - /* Define to the equivalent of the C99 'restrict' keyword, or to - nothing if this is not supported. Do not define if restrict is - supported directly. */ --#define restrict __restrict -+#define restrict __restrict__ - /* Work around a bug in Sun C++: it does not support _Restrict or - __restrict__, even though the corresponding Sun C compiler ends up with - "#define restrict _Restrict" or "#define restrict __restrict__" in the -@@ -637,7 +637,7 @@ - /* Define if your snprintf function is not named snprintf. */ - /* #undef snprintf */ - --/* Define if your typeof operator is not named typeof. */ -+/* Define if your typeof operator is not named `typeof'. */ - #define typeof __typeof - - /* Define to the type of an unsigned integer type wide enough to hold a diff --git a/www/chromium/files/patch-third__party_node_check__version.py b/www/chromium/files/patch-third__party_node_check__version.py new file mode 100644 index 000000000000..33076fe6b3c2 --- /dev/null +++ b/www/chromium/files/patch-third__party_node_check__version.py @@ -0,0 +1,14 @@ +--- third_party/node/check_version.py.orig 2025-07-02 06:08:04 UTC ++++ third_party/node/check_version.py +@@ -17,11 +17,6 @@ def main(argv): + parser.add_argument('--out_file', required=True) + args = parser.parse_args(argv) + +- node.RunNode([ +- os.path.join(_HERE_PATH, 'check_version.js'), +- '--expected_version_file', args.expected_version_file, +- ]) +- + # If the above script succeeded, write a dummy output file, since Ninja + # requires every target to have an output. + with open(args.out_file, "w") as file: diff --git a/www/chromium/files/patch-third__party_node_node.gni b/www/chromium/files/patch-third__party_node_node.gni index f5ef9b82df8b..acd78c9939cb 100644 --- a/www/chromium/files/patch-third__party_node_node.gni +++ b/www/chromium/files/patch-third__party_node_node.gni @@ -1,11 +1,11 @@ ---- third_party/node/node.gni.orig 2023-12-10 06:10:27 UTC +--- third_party/node/node.gni.orig 2025-07-02 06:08:04 UTC +++ third_party/node/node.gni -@@ -19,7 +19,7 @@ template("node") { +@@ -22,7 +22,7 @@ template("node") { - # When use_remoteexec=true or use_siso=true, node actions run on remote + # When use_remoteexec=true, node actions may run on remote # Linux worker. So it should include linux node binary in inputs. -- if (is_linux || is_chromeos || use_remoteexec || use_siso) { -+ if ((is_linux || is_chromeos || use_remoteexec || use_siso) && !is_bsd) { - inputs += [ - "//third_party/node/linux/node-linux-x64.tar.gz.sha1", - "//third_party/node/linux/node-linux-x64/bin/node", +- if (is_linux || is_chromeos || use_remoteexec) { ++ if ((is_linux || is_chromeos || use_remoteexec) && !is_bsd) { + inputs += [ "//third_party/node/linux/node-linux-x64/bin/node" ] + } + if (is_win && host_os == "win") { diff --git a/www/chromium/files/patch-third__party_node_node.py b/www/chromium/files/patch-third__party_node_node.py index f13b8b6b458d..96bef3eb5cb3 100644 --- a/www/chromium/files/patch-third__party_node_node.py +++ b/www/chromium/files/patch-third__party_node_node.py @@ -1,8 +1,8 @@ ---- third_party/node/node.py.orig 2022-02-07 13:39:41 UTC +--- third_party/node/node.py.orig 2025-04-04 08:52:13 UTC +++ third_party/node/node.py -@@ -16,6 +16,8 @@ def GetBinaryPath(): +@@ -20,6 +20,8 @@ def GetBinaryPath(): return os_path.join(os_path.dirname(__file__), *{ - 'Darwin': ('mac', darwin_name, 'bin', 'node'), + 'Darwin': (darwin_path, darwin_name, 'bin', 'node'), 'Linux': ('linux', 'node-linux-x64', 'bin', 'node'), + 'OpenBSD': ('openbsd', 'node-openbsd', 'bin', 'node'), + 'FreeBSD': ('freebsd', 'node-freebsd', 'bin', 'node'), diff --git a/www/chromium/files/patch-third__party_pdfium_core_fxge_cfx__fontmapper.cpp b/www/chromium/files/patch-third__party_pdfium_core_fxge_cfx__fontmapper.cpp index 4bcfef4e9bea..7f7ed80eb1e8 100644 --- a/www/chromium/files/patch-third__party_pdfium_core_fxge_cfx__fontmapper.cpp +++ b/www/chromium/files/patch-third__party_pdfium_core_fxge_cfx__fontmapper.cpp @@ -1,4 +1,4 @@ ---- third_party/pdfium/core/fxge/cfx_fontmapper.cpp.orig 2023-09-13 12:11:42 UTC +--- third_party/pdfium/core/fxge/cfx_fontmapper.cpp.orig 2024-07-30 11:12:21 UTC +++ third_party/pdfium/core/fxge/cfx_fontmapper.cpp @@ -157,7 +157,7 @@ constexpr AltFontFamily kAltFontFamilies[] = { {"ForteMT", "Forte"}, diff --git a/www/chromium/files/patch-third__party_pdfium_core_fxge_linux_fx__linux__impl.cpp b/www/chromium/files/patch-third__party_pdfium_core_fxge_linux_fx__linux__impl.cpp index 8a5956e8610a..e60381f5e696 100644 --- a/www/chromium/files/patch-third__party_pdfium_core_fxge_linux_fx__linux__impl.cpp +++ b/www/chromium/files/patch-third__party_pdfium_core_fxge_linux_fx__linux__impl.cpp @@ -1,6 +1,6 @@ ---- third_party/pdfium/core/fxge/linux/fx_linux_impl.cpp.orig 2024-04-19 13:02:56 UTC +--- third_party/pdfium/core/fxge/linux/fx_linux_impl.cpp.orig 2025-07-02 06:08:04 UTC +++ third_party/pdfium/core/fxge/linux/fx_linux_impl.cpp -@@ -17,7 +17,7 @@ +@@ -19,7 +19,7 @@ #include "core/fxge/fx_font.h" #include "core/fxge/systemfontinfo_iface.h" @@ -9,7 +9,7 @@ #error "Included on the wrong platform" #endif -@@ -165,9 +165,8 @@ class CLinuxPlatform : public CFX_GEModule::PlatformIf +@@ -179,9 +179,8 @@ class CLinuxPlatform : public CFX_GEModule::PlatformIf std::unique_ptr<SystemFontInfoIface> CreateDefaultSystemFontInfo() override { auto pInfo = std::make_unique<CFX_LinuxFontInfo>(); if (!pInfo->ParseFontCfg(CFX_GEModule::Get()->GetUserFontPaths())) { diff --git a/www/chromium/files/patch-third__party_pdfium_fxjs_fx__date__helpers.cpp b/www/chromium/files/patch-third__party_pdfium_fxjs_fx__date__helpers.cpp index b59251adcb62..ec12f53b2c58 100644 --- a/www/chromium/files/patch-third__party_pdfium_fxjs_fx__date__helpers.cpp +++ b/www/chromium/files/patch-third__party_pdfium_fxjs_fx__date__helpers.cpp @@ -1,7 +1,7 @@ ---- third_party/pdfium/fxjs/fx_date_helpers.cpp.orig 2022-06-17 14:20:10 UTC +--- third_party/pdfium/fxjs/fx_date_helpers.cpp.orig 2025-05-28 14:55:43 UTC +++ third_party/pdfium/fxjs/fx_date_helpers.cpp -@@ -37,6 +37,11 @@ double GetLocalTZA() { - return 0; +@@ -41,6 +41,11 @@ double GetLocalTZA() { + } time_t t = 0; FXSYS_time(&t); +#ifdef __FreeBSD__ @@ -12,7 +12,7 @@ FXSYS_localtime(&t); #if BUILDFLAG(IS_WIN) // In gcc 'timezone' is a global variable declared in time.h. In VC++, that -@@ -45,6 +50,7 @@ double GetLocalTZA() { +@@ -49,6 +54,7 @@ double GetLocalTZA() { _get_timezone(&timezone); #endif return (double)(-(timezone * 1000)); diff --git a/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_build__config.h b/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_build__config.h index 4ff5bff8c746..6201b0152a2a 100644 --- a/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_build__config.h +++ b/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_build__config.h @@ -1,66 +1,70 @@ ---- third_party/perfetto/include/perfetto/base/build_config.h.orig 2022-02-07 13:39:41 UTC +--- third_party/perfetto/include/perfetto/base/build_config.h.orig 2025-04-04 08:52:13 UTC +++ third_party/perfetto/include/perfetto/base/build_config.h @@ -27,6 +27,7 @@ #if defined(__ANDROID__) #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 1 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 0 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 0 -@@ -38,6 +39,7 @@ +@@ -41,6 +42,7 @@ #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 1 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 0 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WASM() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_FUCHSIA() 0 -@@ -51,9 +53,10 @@ - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 1 +@@ -62,9 +64,10 @@ #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_IOS() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE_TVOS() 0 #endif -#elif defined(__linux__) +#elif defined(__linux__) || defined(__OpenBSD__) || defined(__FreeBSD__) #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 1 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 1 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 1 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 0 -@@ -64,6 +67,8 @@ +@@ -78,6 +81,7 @@ + #elif defined(__QNXNTO__) + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 1 ++#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 0 +@@ -91,6 +95,7 @@ #elif defined(_WIN32) #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 0 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 -+#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_FREEBSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 1 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 0 -@@ -74,6 +79,8 @@ +@@ -104,6 +109,7 @@ #elif defined(__EMSCRIPTEN__) #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 0 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 -+#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_FREEBSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 0 -@@ -87,6 +94,8 @@ +@@ -120,6 +126,7 @@ #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_IOS() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 0 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 -+#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_FREEBSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WASM() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_FUCHSIA() 1 -@@ -94,6 +103,8 @@ +@@ -130,6 +137,7 @@ #elif defined(__native_client__) #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_ANDROID() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX() 0 +#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_BSD() 0 -+#define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_FREEBSD() 0 + #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_LINUX_BUT_NOT_QNX() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_WIN() 0 #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_APPLE() 0 - #define PERFETTO_BUILDFLAG_DEFINE_PERFETTO_OS_MAC() 0 diff --git a/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_thread__utils.h b/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_thread__utils.h index a18f0949d83f..3e54365b9d9a 100644 --- a/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_thread__utils.h +++ b/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_thread__utils.h @@ -1,6 +1,6 @@ ---- third_party/perfetto/include/perfetto/base/thread_utils.h.orig 2023-01-11 09:17:16 UTC +--- third_party/perfetto/include/perfetto/base/thread_utils.h.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/include/perfetto/base/thread_utils.h -@@ -34,6 +34,7 @@ __declspec(dllimport) unsigned long __stdcall GetCurre +@@ -37,6 +37,7 @@ __declspec(dllimport) unsigned long __stdcall GetCurre #include <sys/syscall.h> #include <sys/types.h> #include <unistd.h> @@ -8,7 +8,7 @@ #else #include <pthread.h> #endif -@@ -45,6 +46,11 @@ namespace base { +@@ -49,6 +50,11 @@ namespace base { using PlatformThreadId = pid_t; inline PlatformThreadId GetThreadId() { return gettid(); diff --git a/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_time.h b/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_time.h index 9d497ab71c3e..64d3c03b64a8 100644 --- a/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_time.h +++ b/www/chromium/files/patch-third__party_perfetto_include_perfetto_base_time.h @@ -1,6 +1,6 @@ ---- third_party/perfetto/include/perfetto/base/time.h.orig 2024-01-30 07:53:34 UTC +--- third_party/perfetto/include/perfetto/base/time.h.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/include/perfetto/base/time.h -@@ -193,6 +193,9 @@ inline TimeNanos GetTimeInternalNs(clockid_t clk_id) { +@@ -227,6 +227,9 @@ inline TimeNanos GetTimeInternalNs(clockid_t clk_id) { // Return ns from boot. Conversely to GetWallTimeNs, this clock counts also time // during suspend (when supported). inline TimeNanos GetBootTimeNs() { @@ -10,7 +10,7 @@ // Determine if CLOCK_BOOTTIME is available on the first call. static const clockid_t kBootTimeClockSource = [] { struct timespec ts = {}; -@@ -200,6 +203,7 @@ inline TimeNanos GetBootTimeNs() { +@@ -234,6 +237,7 @@ inline TimeNanos GetBootTimeNs() { return res == 0 ? CLOCK_BOOTTIME : kWallTimeClockSource; }(); return GetTimeInternalNs(kBootTimeClockSource); @@ -18,7 +18,7 @@ } inline TimeNanos GetWallTimeNs() { -@@ -207,7 +211,13 @@ inline TimeNanos GetWallTimeNs() { +@@ -241,7 +245,13 @@ inline TimeNanos GetWallTimeNs() { } inline TimeNanos GetWallTimeRawNs() { diff --git a/www/chromium/files/patch-third__party_perfetto_include_perfetto_ext_base_event__fd.h b/www/chromium/files/patch-third__party_perfetto_include_perfetto_ext_base_event__fd.h index 7d9883a23e8f..752ca756f12d 100644 --- a/www/chromium/files/patch-third__party_perfetto_include_perfetto_ext_base_event__fd.h +++ b/www/chromium/files/patch-third__party_perfetto_include_perfetto_ext_base_event__fd.h @@ -1,6 +1,6 @@ ---- third_party/perfetto/include/perfetto/ext/base/event_fd.h.orig 2022-02-07 13:39:41 UTC +--- third_party/perfetto/include/perfetto/ext/base/event_fd.h.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/include/perfetto/ext/base/event_fd.h -@@ -55,6 +55,8 @@ class EventFd { +@@ -58,6 +58,8 @@ class EventFd { // On Mac and other non-Linux UNIX platforms a pipe-based fallback is used. // The write end of the wakeup pipe. ScopedFile write_fd_; diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_clock__snapshots.cc b/www/chromium/files/patch-third__party_perfetto_src_base_clock__snapshots.cc new file mode 100644 index 000000000000..8a82b8bef25f --- /dev/null +++ b/www/chromium/files/patch-third__party_perfetto_src_base_clock__snapshots.cc @@ -0,0 +1,10 @@ +--- third_party/perfetto/src/base/clock_snapshots.cc.orig 2025-02-19 07:43:18 UTC ++++ third_party/perfetto/src/base/clock_snapshots.cc +@@ -27,6 +27,7 @@ ClockSnapshotVector CaptureClockSnapshots() { + #if !PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_WIN) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_NACL) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_QNX) + struct { + clockid_t id; diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_event__fd.cc b/www/chromium/files/patch-third__party_perfetto_src_base_event__fd.cc index 5ea355851d89..b01b16758987 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_event__fd.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_event__fd.cc @@ -1,21 +1,21 @@ ---- third_party/perfetto/src/base/event_fd.cc.orig 2022-02-07 13:39:41 UTC +--- third_party/perfetto/src/base/event_fd.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/src/base/event_fd.cc -@@ -22,7 +22,8 @@ - #if PERFETTO_BUILDFLAG(PERFETTO_OS_WIN) - #include <Windows.h> +@@ -24,7 +24,8 @@ #include <synchapi.h> + #elif PERFETTO_BUILDFLAG(PERFETTO_OS_QNX) + #include <unistd.h> -#elif PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ +#elif (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) #include <sys/eventfd.h> #include <unistd.h> -@@ -57,7 +58,8 @@ void EventFd::Clear() { +@@ -59,7 +60,8 @@ void EventFd::Clear() { PERFETTO_DFATAL("EventFd::Clear()"); } --#elif PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+#elif (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && \ +-#elif PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#elif (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_periodic__task.cc b/www/chromium/files/patch-third__party_perfetto_src_base_periodic__task.cc index 4da1db3824c3..cd2fd35437be 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_periodic__task.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_periodic__task.cc @@ -1,11 +1,11 @@ ---- third_party/perfetto/src/base/periodic_task.cc.orig 2023-04-05 11:05:06 UTC +--- third_party/perfetto/src/base/periodic_task.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/src/base/periodic_task.cc @@ -24,7 +24,7 @@ #include "perfetto/base/time.h" #include "perfetto/ext/base/file_utils.h" --#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ (PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) && __ANDROID_API__ >= 19) #include <sys/timerfd.h> #endif @@ -13,8 +13,8 @@ } ScopedPlatformHandle CreateTimerFd(const PeriodicTask::Args& args) { --#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ (PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) && __ANDROID_API__ >= 19) ScopedPlatformHandle tfd( timerfd_create(CLOCK_BOOTTIME, TFD_CLOEXEC | TFD_NONBLOCK)); diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_string__utils.cc b/www/chromium/files/patch-third__party_perfetto_src_base_string__utils.cc index 967d0d287190..9b27684773da 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_string__utils.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_string__utils.cc @@ -1,15 +1,12 @@ ---- third_party/perfetto/src/base/string_utils.cc.orig 2023-12-10 06:10:27 UTC +--- third_party/perfetto/src/base/string_utils.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/perfetto/src/base/string_utils.cc -@@ -38,9 +38,10 @@ namespace base { - +@@ -39,7 +39,8 @@ namespace base { // Locale-independant as possible version of strtod. double StrToD(const char* nptr, char** endptr) { --#if PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) || \ -+#if (PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) || \ - PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -- PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) -+ PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE)) && \ -+ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) + #if PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) || \ +- PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++ (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ + PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) static auto c_locale = newlocale(LC_ALL, "C", nullptr); return strtod_l(nptr, endptr, c_locale); - #else diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_subprocess__posix.cc b/www/chromium/files/patch-third__party_perfetto_src_base_subprocess__posix.cc index f38b23a79ca9..75983f911424 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_subprocess__posix.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_subprocess__posix.cc @@ -1,11 +1,11 @@ ---- third_party/perfetto/src/base/subprocess_posix.cc.orig 2022-02-07 13:39:41 UTC +--- third_party/perfetto/src/base/subprocess_posix.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/src/base/subprocess_posix.cc @@ -35,7 +35,8 @@ #include <thread> #include <tuple> --#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && \ +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) #include <sys/prctl.h> @@ -14,8 +14,8 @@ // Don't add any dynamic allocation in this function. This will be invoked // under a fork(), potentially in a state where the allocator lock is held. void __attribute__((noreturn)) ChildProcess(ChildProcessArgs* args) { --#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && \ +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ + !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) // In no case we want a child process to outlive its parent process. This is diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_test_vm__test__utils.cc b/www/chromium/files/patch-third__party_perfetto_src_base_test_vm__test__utils.cc index 17ebe05dd570..168e2db04fa6 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_test_vm__test__utils.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_test_vm__test__utils.cc @@ -1,6 +1,6 @@ ---- third_party/perfetto/src/base/test/vm_test_utils.cc.orig 2022-06-17 14:20:10 UTC +--- third_party/perfetto/src/base/test/vm_test_utils.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/perfetto/src/base/test/vm_test_utils.cc -@@ -91,7 +91,7 @@ bool IsMapped(void* start, size_t size) { +@@ -93,7 +93,7 @@ bool IsMapped(void* start, size_t size) { // Fuchsia doesn't yet support paging (b/119503290). ignore_result(page_size); return true; diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_thread__task__runner.cc b/www/chromium/files/patch-third__party_perfetto_src_base_thread__task__runner.cc index 3cedb601c7a0..f74e47a717e4 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_thread__task__runner.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_thread__task__runner.cc @@ -1,14 +1,12 @@ ---- third_party/perfetto/src/base/thread_task_runner.cc.orig 2022-02-07 13:39:41 UTC +--- third_party/perfetto/src/base/thread_task_runner.cc.orig 2025-02-19 07:43:18 UTC +++ third_party/perfetto/src/base/thread_task_runner.cc -@@ -27,8 +27,9 @@ +@@ -27,7 +27,8 @@ #include "perfetto/ext/base/thread_utils.h" #include "perfetto/ext/base/unix_task_runner.h" --#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -- PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) -+#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID)) && \ -+ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ + PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) #include <sys/prctl.h> #endif - diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_unix__socket.cc b/www/chromium/files/patch-third__party_perfetto_src_base_unix__socket.cc index dc81d6fc5613..b61d544bfdbf 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_base_unix__socket.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_base_unix__socket.cc @@ -1,6 +1,6 @@ ---- third_party/perfetto/src/base/unix_socket.cc.orig 2023-09-13 12:11:42 UTC +--- third_party/perfetto/src/base/unix_socket.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/perfetto/src/base/unix_socket.cc -@@ -44,7 +44,7 @@ +@@ -45,7 +45,7 @@ #include <unistd.h> #endif @@ -9,12 +9,12 @@ #include <sys/ucred.h> #endif -@@ -917,9 +917,13 @@ void UnixSocket::ReadPeerCredentialsPosix() { - return; - PERFETTO_CHECK(peer_cred_mode_ != SockPeerCredMode::kIgnore); - --#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ -+#if !defined(__FreeBSD__) && PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ +@@ -1031,9 +1031,13 @@ void UnixSocket::ReadPeerCredentialsPosix() { + int res = getpeereid(fd, &peer_uid_, nullptr); + PERFETTO_CHECK(res == 0); + // There is no pid when obtaining peer credentials for QNX +-#elif PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ ++#elif !defined(__FreeBSD__) && PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) +#if PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) + struct sockpeercred user_cred; diff --git a/www/chromium/files/patch-third__party_perfetto_src_base_utils.cc b/www/chromium/files/patch-third__party_perfetto_src_base_utils.cc new file mode 100644 index 000000000000..f2fd4750cd1f --- /dev/null +++ b/www/chromium/files/patch-third__party_perfetto_src_base_utils.cc @@ -0,0 +1,47 @@ +--- third_party/perfetto/src/base/utils.cc.orig 2025-04-04 08:52:13 UTC ++++ third_party/perfetto/src/base/utils.cc +@@ -38,7 +38,8 @@ + #include <mach/vm_page_size.h> + #endif + +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ + PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) + #include <sys/prctl.h> + +@@ -279,14 +280,22 @@ void Daemonize(std::function<int()> parent_cb) { + + std::string GetCurExecutablePath() { + std::string self_path; +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ + PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) || \ +- PERFETTO_BUILDFLAG(PERFETTO_OS_FUCHSIA) ++ PERFETTO_BUILDFLAG(PERFETTO_OS_FUCHSIA)) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) + char buf[PATH_MAX]; + ssize_t size = readlink("/proc/self/exe", buf, sizeof(buf)); + PERFETTO_CHECK(size != -1); + // readlink does not null terminate. + self_path = std::string(buf, static_cast<size_t>(size)); ++#elif PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) ++ char *buf; ++ const char *cpath = "/usr/local/chrome/chrome"; ++ if ((buf = getenv("CHROME_EXE_PATH")) != NULL) ++ self_path = std::string(buf); ++ else ++ self_path = std::string(cpath); + #elif PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) + uint32_t size = 0; + PERFETTO_CHECK(_NSGetExecutablePath(nullptr, &size)); +@@ -338,7 +347,8 @@ void AlignedFree(void* ptr) { + } + + bool IsSyncMemoryTaggingEnabled() { +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) || \ ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) || \ + PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) + // Compute only once per lifetime of the process. + static bool cached_value = [] { diff --git a/www/chromium/files/patch-third__party_perfetto_src_trace__processor_importers_ftrace_v4l2__tracker.cc b/www/chromium/files/patch-third__party_perfetto_src_trace__processor_importers_ftrace_v4l2__tracker.cc new file mode 100644 index 000000000000..3be7582fbb99 --- /dev/null +++ b/www/chromium/files/patch-third__party_perfetto_src_trace__processor_importers_ftrace_v4l2__tracker.cc @@ -0,0 +1,56 @@ +--- third_party/perfetto/src/trace_processor/importers/ftrace/v4l2_tracker.cc.orig 2025-02-19 07:43:18 UTC ++++ third_party/perfetto/src/trace_processor/importers/ftrace/v4l2_tracker.cc +@@ -62,7 +62,7 @@ void V4l2Tracker::ParseV4l2Event(uint64_t fld_id, + case FtraceEvent::kV4l2QbufFieldNumber: { + V4l2QbufFtraceEvent::Decoder pb_evt(bytes); + BufferEvent evt; +- evt.device_minor = pb_evt.minor(); ++ evt.device_minor = pb_evt.gminor(); + evt.index = pb_evt.index(); + evt.type = pb_evt.type(); + evt.bytesused = pb_evt.bytesused(); +@@ -103,7 +103,7 @@ void V4l2Tracker::ParseV4l2Event(uint64_t fld_id, + case FtraceEvent::kV4l2DqbufFieldNumber: { + V4l2DqbufFtraceEvent::Decoder pb_evt(bytes); + BufferEvent evt; +- evt.device_minor = pb_evt.minor(); ++ evt.device_minor = pb_evt.gminor(); + evt.index = pb_evt.index(); + evt.type = pb_evt.type(); + evt.bytesused = pb_evt.bytesused(); +@@ -149,7 +149,7 @@ void V4l2Tracker::ParseV4l2Event(uint64_t fld_id, + case FtraceEvent::kVb2V4l2BufQueueFieldNumber: { + Vb2V4l2BufQueueFtraceEvent::Decoder pb_evt(bytes); + BufferEvent evt; +- evt.device_minor = pb_evt.minor(); ++ evt.device_minor = pb_evt.gminor(); + evt.index = std::nullopt; + evt.type = std::nullopt; + evt.bytesused = std::nullopt; +@@ -180,7 +180,7 @@ void V4l2Tracker::ParseV4l2Event(uint64_t fld_id, + case FtraceEvent::kVb2V4l2BufDoneFieldNumber: { + Vb2V4l2BufDoneFtraceEvent::Decoder pb_evt(bytes); + BufferEvent evt; +- evt.device_minor = pb_evt.minor(); ++ evt.device_minor = pb_evt.gminor(); + evt.index = std::nullopt; + evt.type = std::nullopt; + evt.bytesused = std::nullopt; +@@ -211,7 +211,7 @@ void V4l2Tracker::ParseV4l2Event(uint64_t fld_id, + case FtraceEvent::kVb2V4l2QbufFieldNumber: { + Vb2V4l2QbufFtraceEvent::Decoder pb_evt(bytes); + BufferEvent evt; +- evt.device_minor = pb_evt.minor(); ++ evt.device_minor = pb_evt.gminor(); + evt.index = std::nullopt; + evt.type = std::nullopt; + evt.bytesused = std::nullopt; +@@ -242,7 +242,7 @@ void V4l2Tracker::ParseV4l2Event(uint64_t fld_id, + case FtraceEvent::kVb2V4l2DqbufFieldNumber: { + Vb2V4l2DqbufFtraceEvent::Decoder pb_evt(bytes); + BufferEvent evt; +- evt.device_minor = pb_evt.minor(); ++ evt.device_minor = pb_evt.gminor(); + evt.index = std::nullopt; + evt.type = std::nullopt; + evt.bytesused = std::nullopt; diff --git a/www/chromium/files/patch-third__party_perfetto_src_tracing_core_clock__snapshots.cc b/www/chromium/files/patch-third__party_perfetto_src_tracing_core_clock__snapshots.cc deleted file mode 100644 index d627e835db6c..000000000000 --- a/www/chromium/files/patch-third__party_perfetto_src_tracing_core_clock__snapshots.cc +++ /dev/null @@ -1,12 +0,0 @@ ---- third_party/perfetto/src/tracing/core/clock_snapshots.cc.orig 2024-04-19 13:02:56 UTC -+++ third_party/perfetto/src/tracing/core/clock_snapshots.cc -@@ -26,7 +26,8 @@ ClockSnapshotVector CaptureClockSnapshots() { - ClockSnapshotVector snapshot_data; - #if !PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) && \ - !PERFETTO_BUILDFLAG(PERFETTO_OS_WIN) && \ -- !PERFETTO_BUILDFLAG(PERFETTO_OS_NACL) -+ !PERFETTO_BUILDFLAG(PERFETTO_OS_NACL) && \ -+ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) - struct { - clockid_t id; - protos::pbzero::BuiltinClock type; diff --git a/www/chromium/files/patch-third__party_perfetto_src_tracing_ipc_memfd.cc b/www/chromium/files/patch-third__party_perfetto_src_tracing_ipc_memfd.cc index 5a523cba002b..6f899b6aec23 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_tracing_ipc_memfd.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_tracing_ipc_memfd.cc @@ -1,12 +1,12 @@ ---- third_party/perfetto/src/tracing/ipc/memfd.cc.orig 2023-09-13 18:23:44 UTC +--- third_party/perfetto/src/tracing/ipc/memfd.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/perfetto/src/tracing/ipc/memfd.cc @@ -20,7 +20,8 @@ #define PERFETTO_MEMFD_ENABLED() \ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) || \ -- PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) -+ (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) && \ -+ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) +- PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) ++ (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX_BUT_NOT_QNX) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD)) #if PERFETTO_MEMFD_ENABLED() diff --git a/www/chromium/files/patch-third__party_perfetto_src_tracing_platform__posix.cc b/www/chromium/files/patch-third__party_perfetto_src_tracing_platform__posix.cc new file mode 100644 index 000000000000..de931549fb4d --- /dev/null +++ b/www/chromium/files/patch-third__party_perfetto_src_tracing_platform__posix.cc @@ -0,0 +1,19 @@ +--- third_party/perfetto/src/tracing/platform_posix.cc.orig 2024-11-14 07:57:23 UTC ++++ third_party/perfetto/src/tracing/platform_posix.cc +@@ -110,12 +110,13 @@ std::unique_ptr<base::TaskRunner> PlatformPosix::Creat + } + + std::string PlatformPosix::GetCurrentProcessName() { +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ +- PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ ++ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID)) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) + std::string cmdline; + base::ReadFile("/proc/self/cmdline", &cmdline); + return cmdline.substr(0, cmdline.find('\0')); +-#elif PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) ++#elif PERFETTO_BUILDFLAG(PERFETTO_OS_APPLE) || PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) + return std::string(getprogname()); + #else + return "unknown_producer"; diff --git a/www/chromium/files/patch-third__party_perfetto_src_tracing_track.cc b/www/chromium/files/patch-third__party_perfetto_src_tracing_track.cc index fa76ae94eed5..c91ff51ae7b6 100644 --- a/www/chromium/files/patch-third__party_perfetto_src_tracing_track.cc +++ b/www/chromium/files/patch-third__party_perfetto_src_tracing_track.cc @@ -1,6 +1,18 @@ ---- third_party/perfetto/src/tracing/track.cc.orig 2023-05-31 08:12:17 UTC +--- third_party/perfetto/src/tracing/track.cc.orig 2025-01-15 09:18:26 UTC +++ third_party/perfetto/src/tracing/track.cc -@@ -143,7 +143,7 @@ namespace internal { +@@ -60,8 +60,9 @@ protos::gen::TrackDescriptor ProcessTrack::Serialize() + auto desc = Track::Serialize(); + auto pd = desc.mutable_process(); + pd->set_pid(static_cast<int32_t>(pid)); +-#if PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ +- PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID) ++#if (PERFETTO_BUILDFLAG(PERFETTO_OS_LINUX) || \ ++ PERFETTO_BUILDFLAG(PERFETTO_OS_ANDROID)) && \ ++ !PERFETTO_BUILDFLAG(PERFETTO_OS_BSD) + std::string cmdline; + if (base::ReadFile("/proc/self/cmdline", &cmdline)) { + // Since cmdline is a zero-terminated list of arguments, this ends up +@@ -170,7 +171,7 @@ namespace internal { namespace { uint64_t GetProcessStartTime() { diff --git a/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_arenastring.cc b/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_arenastring.cc deleted file mode 100644 index 5ecfe8529421..000000000000 --- a/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_arenastring.cc +++ /dev/null @@ -1,12 +0,0 @@ ---- third_party/protobuf/src/google/protobuf/arenastring.cc.orig 2022-09-01 14:18:43 UTC -+++ third_party/protobuf/src/google/protobuf/arenastring.cc -@@ -64,7 +64,9 @@ constexpr size_t kNewAlign = alignof(std::max_align_t) - #endif - constexpr size_t kStringAlign = alignof(std::string); - -+#if !(defined(__FreeBSD__) && defined(__i386__)) - static_assert((kStringAlign > kNewAlign ? kStringAlign : kNewAlign) >= 8, ""); -+#endif - static_assert(alignof(ExplicitlyConstructedArenaString) >= 8, ""); - - } // namespace diff --git a/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_stubs_platform__macros.h b/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_stubs_platform__macros.h index 249b75357b53..ba249445dbe2 100644 --- a/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_stubs_platform__macros.h +++ b/www/chromium/files/patch-third__party_protobuf_src_google_protobuf_stubs_platform__macros.h @@ -1,11 +1,11 @@ ---- third_party/protobuf/src/google/protobuf/stubs/platform_macros.h.orig 2022-08-31 12:19:35 UTC +--- third_party/protobuf/src/google/protobuf/stubs/platform_macros.h.orig 2025-04-04 08:52:13 UTC +++ third_party/protobuf/src/google/protobuf/stubs/platform_macros.h -@@ -122,7 +122,7 @@ GOOGLE_PROTOBUF_PLATFORM_ERROR +@@ -99,7 +99,7 @@ GOOGLE_PROTOBUF_PLATFORM_ERROR #undef GOOGLE_PROTOBUF_PLATFORM_ERROR --#if defined(GOOGLE_PROTOBUF_OS_ANDROID) || defined(GOOGLE_PROTOBUF_OS_IPHONE) || defined(__OpenBSD__) -+#if defined(GOOGLE_PROTOBUF_OS_ANDROID) || defined(GOOGLE_PROTOBUF_OS_IPHONE) +-#if defined(GOOGLE_PROTOBUF_OS_ANDROID) || defined(GOOGLE_PROTOBUF_OS_IPHONE) ++#if defined(GOOGLE_PROTOBUF_OS_ANDROID) || defined(GOOGLE_PROTOBUF_OS_IPHONE) || defined(__OpenBSD__) // Android ndk does not support the __thread keyword very well yet. Here // we use pthread_key_create()/pthread_getspecific()/... methods for // TLS support on android. diff --git a/www/chromium/files/patch-third__party_sqlite_BUILD.gn b/www/chromium/files/patch-third__party_sqlite_BUILD.gn index 12e24499246a..bf7e563d38bd 100644 --- a/www/chromium/files/patch-third__party_sqlite_BUILD.gn +++ b/www/chromium/files/patch-third__party_sqlite_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/sqlite/BUILD.gn.orig 2021-12-31 00:58:29 UTC +--- third_party/sqlite/BUILD.gn.orig 2025-03-05 08:14:56 UTC +++ third_party/sqlite/BUILD.gn -@@ -142,7 +142,7 @@ config("sqlite_warnings") { +@@ -155,7 +155,7 @@ config("sqlite_warnings") { ] } } diff --git a/www/chromium/files/patch-third__party_sqlite_src_amalgamation__dev_sqlite3.c b/www/chromium/files/patch-third__party_sqlite_src_amalgamation__dev_sqlite3.c new file mode 100644 index 000000000000..e0b2c7479d0f --- /dev/null +++ b/www/chromium/files/patch-third__party_sqlite_src_amalgamation__dev_sqlite3.c @@ -0,0 +1,11 @@ +--- third_party/sqlite/src/amalgamation_dev/sqlite3.c.orig 2025-05-07 06:38:02 UTC ++++ third_party/sqlite/src/amalgamation_dev/sqlite3.c +@@ -14486,7 +14486,7 @@ struct fts5_api { + ** But _XOPEN_SOURCE define causes problems for Mac OS X, so omit + ** it. + */ +-#if !defined(_XOPEN_SOURCE) && !defined(__DARWIN__) && !defined(__APPLE__) ++#if !defined(_XOPEN_SOURCE) && !defined(__DARWIN__) && !defined(__APPLE__) && !defined(__FreeBSD__) + # define _XOPEN_SOURCE 600 + #endif + diff --git a/www/chromium/files/patch-third__party_sqlite_src_amalgamation_sqlite3.c b/www/chromium/files/patch-third__party_sqlite_src_amalgamation_sqlite3.c index 159d76175df2..0faabed12327 100644 --- a/www/chromium/files/patch-third__party_sqlite_src_amalgamation_sqlite3.c +++ b/www/chromium/files/patch-third__party_sqlite_src_amalgamation_sqlite3.c @@ -1,6 +1,15 @@ ---- third_party/sqlite/src/amalgamation/sqlite3.c.orig 2024-04-19 13:02:56 UTC +--- third_party/sqlite/src/amalgamation/sqlite3.c.orig 2025-07-02 06:08:04 UTC +++ third_party/sqlite/src/amalgamation/sqlite3.c -@@ -44768,7 +44768,12 @@ static int unixRandomness(sqlite3_vfs *NotUsed, int nB +@@ -14486,7 +14486,7 @@ struct fts5_api { + ** But _XOPEN_SOURCE define causes problems for Mac OS X, so omit + ** it. + */ +-#if !defined(_XOPEN_SOURCE) && !defined(__DARWIN__) && !defined(__APPLE__) ++#if !defined(_XOPEN_SOURCE) && !defined(__DARWIN__) && !defined(__APPLE__) && !defined(__FreeBSD__) + # define _XOPEN_SOURCE 600 + #endif + +@@ -45388,7 +45388,12 @@ static int unixRandomness(sqlite3_vfs *NotUsed, int nB memset(zBuf, 0, nBuf); randomnessPid = osGetpid(0); #if !defined(SQLITE_TEST) && !defined(SQLITE_OMIT_RANDOMNESS) @@ -13,7 +22,7 @@ int fd, got; fd = robust_open("/dev/urandom", O_RDONLY, 0); if( fd<0 ){ -@@ -44783,6 +44788,7 @@ static int unixRandomness(sqlite3_vfs *NotUsed, int nB +@@ -45403,6 +45408,7 @@ static int unixRandomness(sqlite3_vfs *NotUsed, int nB robust_close(0, fd, __LINE__); } } diff --git a/www/chromium/files/patch-third__party_test__fonts_fontconfig_BUILD.gn b/www/chromium/files/patch-third__party_test__fonts_fontconfig_BUILD.gn index 180446a881d8..fceeb1231855 100644 --- a/www/chromium/files/patch-third__party_test__fonts_fontconfig_BUILD.gn +++ b/www/chromium/files/patch-third__party_test__fonts_fontconfig_BUILD.gn @@ -1,4 +1,4 @@ ---- third_party/test_fonts/fontconfig/BUILD.gn.orig 2022-03-01 11:59:41 UTC +--- third_party/test_fonts/fontconfig/BUILD.gn.orig 2025-01-19 09:23:37 UTC +++ third_party/test_fonts/fontconfig/BUILD.gn @@ -26,7 +26,11 @@ if (is_linux || is_chromeos) { @@ -13,3 +13,16 @@ } if (current_toolchain == host_toolchain) { +@@ -47,7 +51,11 @@ if (is_linux || is_chromeos) { + "//third_party/test_fonts", + ] + args = [] +- inputs = [ "$root_out_dir/etc/fonts/fonts.conf" ] ++ if (is_freebsd) { ++ inputs = [ "$root_out_dir/usr/local/etc/fonts/fonts.conf" ] ++ } else { ++ inputs = [ "$root_out_dir/etc/fonts/fonts.conf" ] ++ } + outputs = [ + "$root_out_dir/fontconfig_caches/fb5c91b2895aa445d23aebf7f9e2189c-le64.cache-9", + "$root_out_dir/fontconfig_caches/CACHEDIR.TAG", diff --git a/www/chromium/files/patch-third__party_tflite_features.gni b/www/chromium/files/patch-third__party_tflite_features.gni index 910ded3d18b4..40486cd4ad5c 100644 --- a/www/chromium/files/patch-third__party_tflite_features.gni +++ b/www/chromium/files/patch-third__party_tflite_features.gni @@ -1,14 +1,11 @@ ---- third_party/tflite/features.gni.orig 2023-12-10 06:10:27 UTC +--- third_party/tflite/features.gni.orig 2025-05-28 14:55:43 UTC +++ third_party/tflite/features.gni -@@ -8,9 +8,9 @@ declare_args() { - # This enables building TFLite with XNNPACK. Currently only available for - # Linux or macOS arm64/x64 and Windows x64 targets. - build_tflite_with_xnnpack = -- ((is_linux || is_mac) && -+ (((is_linux || is_mac) && - (current_cpu == "arm64" || current_cpu == "x64")) || -- (is_win && current_cpu == "x64") -+ (is_win && current_cpu == "x64")) && !is_bsd +@@ -8,7 +8,7 @@ import("//services/on_device_model/on_device_model.gni + + declare_args() { + # This enables building TFLite with XNNPACK. +- build_tflite_with_xnnpack = current_cpu != "arm" && !is_fuchsia ++ build_tflite_with_xnnpack = current_cpu != "arm" && !is_fuchsia && !is_bsd # Turns on TFLITE_WITH_RUY, using ruy as the gemm backend instead of gemmlowp. build_tflite_with_ruy = true diff --git a/www/chromium/files/patch-third__party_unrar_src_crypt.cpp b/www/chromium/files/patch-third__party_unrar_src_crypt.cpp index 0276654cea97..29db09a3bb3b 100644 --- a/www/chromium/files/patch-third__party_unrar_src_crypt.cpp +++ b/www/chromium/files/patch-third__party_unrar_src_crypt.cpp @@ -1,7 +1,7 @@ ---- third_party/unrar/src/crypt.cpp.orig 2024-04-19 13:02:56 UTC +--- third_party/unrar/src/crypt.cpp.orig 2024-07-30 11:12:21 UTC +++ third_party/unrar/src/crypt.cpp -@@ -117,6 +117,8 @@ void GetRnd(byte *RndBuf,size_t BufSize) - Success=CryptGenRandom(hProvider, (DWORD)BufSize, RndBuf) == TRUE; +@@ -116,6 +116,8 @@ void GetRnd(byte *RndBuf,size_t BufSize) + Success=CryptGenRandom(hProvider, (DWORD)BufSize, RndBuf) != FALSE; CryptReleaseContext(hProvider, 0); } +#elif defined(__OpenBSD__) diff --git a/www/chromium/files/patch-third__party_vulkan-deps_vulkan-loader_src_BUILD.gn b/www/chromium/files/patch-third__party_vulkan-loader_src_BUILD.gn index 17c1f0897882..e6180bd84e27 100644 --- a/www/chromium/files/patch-third__party_vulkan-deps_vulkan-loader_src_BUILD.gn +++ b/www/chromium/files/patch-third__party_vulkan-loader_src_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/vulkan-deps/vulkan-loader/src/BUILD.gn.orig 2024-02-23 21:04:38 UTC -+++ third_party/vulkan-deps/vulkan-loader/src/BUILD.gn -@@ -59,7 +59,7 @@ config("vulkan_internal_config") { +--- third_party/vulkan-loader/src/BUILD.gn.orig 2024-09-30 07:45:04 UTC ++++ third_party/vulkan-loader/src/BUILD.gn +@@ -57,7 +57,7 @@ config("vulkan_internal_config") { defines += [ "SYSCONFDIR=\"/etc\"", "FALLBACK_CONFIG_DIRS=\"/etc/xdg\"", diff --git a/www/chromium/files/patch-third__party_vulkan-deps_vulkan-loader_src_loader_vk__loader__platform.h b/www/chromium/files/patch-third__party_vulkan-loader_src_loader_vk__loader__platform.h index 5fc7f565c62b..0c32c818e4d9 100644 --- a/www/chromium/files/patch-third__party_vulkan-deps_vulkan-loader_src_loader_vk__loader__platform.h +++ b/www/chromium/files/patch-third__party_vulkan-loader_src_loader_vk__loader__platform.h @@ -1,6 +1,6 @@ ---- third_party/vulkan-deps/vulkan-loader/src/loader/vk_loader_platform.h.orig 2024-02-23 21:04:38 UTC -+++ third_party/vulkan-deps/vulkan-loader/src/loader/vk_loader_platform.h -@@ -327,7 +327,15 @@ static inline char *loader_platform_executable_path(ch +--- third_party/vulkan-loader/src/loader/vk_loader_platform.h.orig 2025-03-05 08:14:56 UTC ++++ third_party/vulkan-loader/src/loader/vk_loader_platform.h +@@ -353,7 +353,15 @@ static inline char *loader_platform_executable_path(ch return buffer; } diff --git a/www/chromium/files/patch-third__party_vulkan-deps_vulkan-validation-layers_src_layers_external_vma_vk__mem__alloc.h b/www/chromium/files/patch-third__party_vulkan-validation-layers_src_layers_external_vma_vk__mem__alloc.h index 5a66a44b579e..a4f92af117c8 100644 --- a/www/chromium/files/patch-third__party_vulkan-deps_vulkan-validation-layers_src_layers_external_vma_vk__mem__alloc.h +++ b/www/chromium/files/patch-third__party_vulkan-validation-layers_src_layers_external_vma_vk__mem__alloc.h @@ -1,6 +1,6 @@ ---- third_party/vulkan-deps/vulkan-validation-layers/src/layers/external/vma/vk_mem_alloc.h.orig 2023-05-31 08:12:17 UTC -+++ third_party/vulkan-deps/vulkan-validation-layers/src/layers/external/vma/vk_mem_alloc.h -@@ -2740,7 +2740,7 @@ static void* vma_aligned_alloc(size_t alignment, size_ +--- third_party/vulkan-validation-layers/src/layers/external/vma/vk_mem_alloc.h.orig 2025-03-05 08:14:56 UTC ++++ third_party/vulkan-validation-layers/src/layers/external/vma/vk_mem_alloc.h +@@ -2971,7 +2971,7 @@ static void* vma_aligned_alloc(size_t alignment, size_ return memalign(alignment, size); } diff --git a/www/chromium/files/patch-third__party_wayland_BUILD.gn b/www/chromium/files/patch-third__party_wayland_BUILD.gn index 79de827f9927..8ce30a9de459 100644 --- a/www/chromium/files/patch-third__party_wayland_BUILD.gn +++ b/www/chromium/files/patch-third__party_wayland_BUILD.gn @@ -1,14 +1,14 @@ ---- third_party/wayland/BUILD.gn.orig 2023-02-08 15:40:14 UTC +--- third_party/wayland/BUILD.gn.orig 2024-08-26 12:06:38 UTC +++ third_party/wayland/BUILD.gn -@@ -22,6 +22,11 @@ config("wayland_config") { - "src/src", - ] +@@ -24,6 +24,11 @@ if (!use_system_libwayland) { + "src/src", + ] -+ if (is_bsd) { -+ include_dirs += [ "/usr/local/include/libepoll-shim" ] -+ libs = [ "epoll-shim" ] -+ } ++ if (is_bsd) { ++ include_dirs += [ "/usr/local/include/libepoll-shim" ] ++ libs = [ "epoll-shim" ] ++ } + - # Client/Server headers are automatically generated. Though, we still need - # to pass the path where these headers are located. - include_dirs += [ "$root_gen_dir/third_party/wayland/src/protocol" ] + # Client/Server headers are automatically generated. Though, we still need + # to pass the path where these headers are located. + include_dirs += [ "$root_gen_dir/third_party/wayland/src/protocol" ] diff --git a/www/chromium/files/patch-third__party_webrtc_BUILD.gn b/www/chromium/files/patch-third__party_webrtc_BUILD.gn index 9e88da1ae282..cb06e967f3a9 100644 --- a/www/chromium/files/patch-third__party_webrtc_BUILD.gn +++ b/www/chromium/files/patch-third__party_webrtc_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/webrtc/BUILD.gn.orig 2023-11-03 10:09:45 UTC +--- third_party/webrtc/BUILD.gn.orig 2025-04-04 08:52:13 UTC +++ third_party/webrtc/BUILD.gn -@@ -217,6 +217,9 @@ config("common_inherited_config") { +@@ -219,6 +219,9 @@ config("common_inherited_config") { if (is_linux || is_chromeos) { defines += [ "WEBRTC_LINUX" ] } diff --git a/www/chromium/files/patch-third__party_webrtc_modules_audio__device_BUILD.gn b/www/chromium/files/patch-third__party_webrtc_modules_audio__device_BUILD.gn index 4e1694dfd571..c4f9918e79f0 100644 --- a/www/chromium/files/patch-third__party_webrtc_modules_audio__device_BUILD.gn +++ b/www/chromium/files/patch-third__party_webrtc_modules_audio__device_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/webrtc/modules/audio_device/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- third_party/webrtc/modules/audio_device/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ third_party/webrtc/modules/audio_device/BUILD.gn -@@ -348,7 +348,7 @@ rtc_library("audio_device_impl") { +@@ -337,7 +337,7 @@ rtc_library("audio_device_impl") { if (rtc_use_dummy_audio_file_devices) { defines += [ "WEBRTC_DUMMY_FILE_DEVICES" ] } else { diff --git a/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_wayland_egl__dmabuf.cc b/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_wayland_egl__dmabuf.cc index 3606a669f405..f248da33adcc 100644 --- a/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_wayland_egl__dmabuf.cc +++ b/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_wayland_egl__dmabuf.cc @@ -1,18 +1,12 @@ ---- third_party/webrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc.orig 2023-08-23 11:41:11 UTC +--- third_party/webrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc.orig 2025-05-05 18:35:31 UTC +++ third_party/webrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc -@@ -10,11 +10,15 @@ - +@@ -11,7 +11,9 @@ #include "modules/desktop_capture/linux/wayland/egl_dmabuf.h" + #include <EGL/eglext.h> +#if !defined(WEBRTC_BSD) #include <asm/ioctl.h> +#endif #include <dlfcn.h> #include <fcntl.h> #include <libdrm/drm_fourcc.h> -+#if !defined(WEBRTC_BSD) - #include <linux/types.h> -+#endif - #include <spa/param/video/format-utils.h> - #include <unistd.h> - #include <xf86drm.h> diff --git a/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_x11_x__server__pixel__buffer.cc b/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_x11_x__server__pixel__buffer.cc index 84acc5c1e876..5d110486a6b1 100644 --- a/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_x11_x__server__pixel__buffer.cc +++ b/www/chromium/files/patch-third__party_webrtc_modules_desktop__capture_linux_x11_x__server__pixel__buffer.cc @@ -1,23 +1,15 @@ ---- third_party/webrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/webrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/webrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc -@@ -201,6 +201,12 @@ bool XServerPixelBuffer::Init(XAtomCache* cache, Windo - } - +@@ -207,6 +207,12 @@ bool XServerPixelBuffer::Init(XAtomCache* cache, Windo void XServerPixelBuffer::InitShm(const XWindowAttributes& attributes) { + Visual* default_visual = attributes.visual; + int default_depth = attributes.depth; +#if defined(__OpenBSD__) +// pledge(2) + RTC_LOG(LS_WARNING) << "Unable to use shmget(2) while using pledge(2). " + "Performance may be degraded."; + return; -+#else - Visual* default_visual = attributes.visual; - int default_depth = attributes.depth; - -@@ -261,6 +267,7 @@ void XServerPixelBuffer::InitShm(const XWindowAttribut - RTC_LOG(LS_VERBOSE) << "Using X shared memory extension v" << major << "." - << minor << " with" << (have_pixmaps ? "" : "out") - << " pixmaps."; +#endif - } - bool XServerPixelBuffer::InitPixmaps(int depth) { + int major, minor; + Bool have_pixmaps; diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_ip__address.cc b/www/chromium/files/patch-third__party_webrtc_rtc__base_ip__address.cc index 5bd234bc4b29..401272424b51 100644 --- a/www/chromium/files/patch-third__party_webrtc_rtc__base_ip__address.cc +++ b/www/chromium/files/patch-third__party_webrtc_rtc__base_ip__address.cc @@ -1,9 +1,9 @@ ---- third_party/webrtc/rtc_base/ip_address.cc.orig 2022-05-19 14:06:27 UTC +--- third_party/webrtc/rtc_base/ip_address.cc.orig 2024-10-22 08:31:56 UTC +++ third_party/webrtc/rtc_base/ip_address.cc -@@ -13,7 +13,8 @@ - #include <sys/socket.h> - - #include "absl/strings/string_view.h" +@@ -14,7 +14,8 @@ + #include <cstring> + #include <string> + #if defined(WEBRTC_POSIX) -#ifdef OPENBSD +#if defined(WEBRTC_BSD) +#include <sys/types.h> diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_net__helpers.cc b/www/chromium/files/patch-third__party_webrtc_rtc__base_net__helpers.cc new file mode 100644 index 000000000000..9998d5416b12 --- /dev/null +++ b/www/chromium/files/patch-third__party_webrtc_rtc__base_net__helpers.cc @@ -0,0 +1,10 @@ +--- third_party/webrtc/rtc_base/net_helpers.cc.orig 2025-05-28 14:55:43 UTC ++++ third_party/webrtc/rtc_base/net_helpers.cc +@@ -21,6 +21,7 @@ + #endif + #if defined(WEBRTC_POSIX) && !defined(__native_client__) + #include <arpa/inet.h> ++#include <sys/socket.h> + #endif // defined(WEBRTC_POSIX) && !defined(__native_client__) + + namespace webrtc { diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_net__test__helpers.cc b/www/chromium/files/patch-third__party_webrtc_rtc__base_net__test__helpers.cc deleted file mode 100644 index dd03595f0110..000000000000 --- a/www/chromium/files/patch-third__party_webrtc_rtc__base_net__test__helpers.cc +++ /dev/null @@ -1,10 +0,0 @@ ---- third_party/webrtc/rtc_base/net_test_helpers.cc.orig 2023-09-13 12:11:42 UTC -+++ third_party/webrtc/rtc_base/net_test_helpers.cc -@@ -21,6 +21,7 @@ - #endif - #if defined(WEBRTC_POSIX) && !defined(__native_client__) - #include <arpa/inet.h> -+#include <sys/socket.h> - #if defined(WEBRTC_ANDROID) - #include "rtc_base/ifaddrs_android.h" - #else diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_network.cc b/www/chromium/files/patch-third__party_webrtc_rtc__base_network.cc index d9c597c4f16b..eaeae177f93e 100644 --- a/www/chromium/files/patch-third__party_webrtc_rtc__base_network.cc +++ b/www/chromium/files/patch-third__party_webrtc_rtc__base_network.cc @@ -1,12 +1,12 @@ ---- third_party/webrtc/rtc_base/network.cc.orig 2023-05-31 08:12:17 UTC +--- third_party/webrtc/rtc_base/network.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/webrtc/rtc_base/network.cc -@@ -292,7 +292,12 @@ AdapterType GetAdapterTypeFromName(absl::string_view n +@@ -306,7 +306,12 @@ AdapterType GetAdapterTypeFromName(absl::string_view n } #endif +#if defined(WEBRTC_BSD) + // Treat all other network interface names as ethernet on BSD -+ return ADAPTER_TYPE_ETHERNET; ++ return webrtc::ADAPTER_TYPE_ETHERNET; +#else return ADAPTER_TYPE_UNKNOWN; +#endif diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.cc b/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.cc index e05c71a79d4b..90459c8dfb87 100644 --- a/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.cc +++ b/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.cc @@ -1,15 +1,15 @@ ---- third_party/webrtc/rtc_base/physical_socket_server.cc.orig 2024-04-19 13:02:56 UTC +--- third_party/webrtc/rtc_base/physical_socket_server.cc.orig 2025-07-02 06:08:04 UTC +++ third_party/webrtc/rtc_base/physical_socket_server.cc -@@ -54,7 +54,7 @@ +@@ -65,7 +65,7 @@ + #include "rtc_base/synchronization/mutex.h" #include "rtc_base/time_utils.h" - #include "system_wrappers/include/field_trial.h" -#if defined(WEBRTC_LINUX) +#if defined(WEBRTC_LINUX) && !defined(WEBRTC_BSD) #include <linux/sockios.h> #endif -@@ -74,7 +74,7 @@ typedef void* SockOptArg; +@@ -85,7 +85,7 @@ typedef void* SockOptArg; #endif // WEBRTC_POSIX @@ -18,7 +18,7 @@ int64_t GetSocketRecvTimestamp(int socket) { struct timeval tv_ioctl; -@@ -336,7 +336,7 @@ int PhysicalSocket::GetOption(Option opt, int* value) +@@ -340,7 +340,7 @@ int PhysicalSocket::GetOption(Option opt, int* value) return -1; } if (opt == OPT_DONTFRAGMENT) { @@ -27,7 +27,7 @@ *value = (*value != IP_PMTUDISC_DONT) ? 1 : 0; #endif } else if (opt == OPT_DSCP) { -@@ -365,7 +365,7 @@ int PhysicalSocket::SetOption(Option opt, int value) { +@@ -369,7 +369,7 @@ int PhysicalSocket::SetOption(Option opt, int value) { if (TranslateOption(opt, &slevel, &sopt) == -1) return -1; if (opt == OPT_DONTFRAGMENT) { @@ -36,7 +36,7 @@ value = (value) ? IP_PMTUDISC_DO : IP_PMTUDISC_DONT; #endif } else if (opt == OPT_DSCP) { -@@ -396,7 +396,7 @@ int PhysicalSocket::SetOption(Option opt, int value) { +@@ -400,7 +400,7 @@ int PhysicalSocket::SetOption(Option opt, int value) { int PhysicalSocket::Send(const void* pv, size_t cb) { int sent = DoSend( s_, reinterpret_cast<const char*>(pv), static_cast<int>(cb), @@ -45,7 +45,7 @@ // Suppress SIGPIPE. Without this, attempting to send on a socket whose // other end is closed will result in a SIGPIPE signal being raised to // our process, which by default will terminate the process, which we -@@ -425,7 +425,7 @@ int PhysicalSocket::SendTo(const void* buffer, +@@ -429,7 +429,7 @@ int PhysicalSocket::SendTo(const void* buffer, size_t len = addr.ToSockAddrStorage(&saddr); int sent = DoSendTo(s_, static_cast<const char*>(buffer), static_cast<int>(length), @@ -54,7 +54,7 @@ // Suppress SIGPIPE. See above for explanation. MSG_NOSIGNAL, #else -@@ -718,7 +718,7 @@ int PhysicalSocket::TranslateOption(Option opt, int* s +@@ -707,7 +707,7 @@ int PhysicalSocket::TranslateOption(Option opt, int* s *slevel = IPPROTO_IP; *sopt = IP_DONTFRAGMENT; break; @@ -63,7 +63,7 @@ RTC_LOG(LS_WARNING) << "Socket::OPT_DONTFRAGMENT not supported."; return -1; #elif defined(WEBRTC_POSIX) -@@ -767,7 +767,7 @@ int PhysicalSocket::TranslateOption(Option opt, int* s +@@ -756,7 +756,7 @@ int PhysicalSocket::TranslateOption(Option opt, int* s return -1; #endif case OPT_RECV_ECN: @@ -72,7 +72,7 @@ if (family_ == AF_INET6) { *slevel = IPPROTO_IPV6; *sopt = IPV6_RECVTCLASS; -@@ -787,10 +787,19 @@ int PhysicalSocket::TranslateOption(Option opt, int* s +@@ -776,10 +776,19 @@ int PhysicalSocket::TranslateOption(Option opt, int* s *sopt = SO_KEEPALIVE; break; case OPT_TCP_KEEPCNT: @@ -92,7 +92,7 @@ *slevel = IPPROTO_TCP; #if !defined(WEBRTC_MAC) *sopt = TCP_KEEPIDLE; -@@ -798,12 +807,18 @@ int PhysicalSocket::TranslateOption(Option opt, int* s +@@ -787,12 +796,18 @@ int PhysicalSocket::TranslateOption(Option opt, int* s *sopt = TCP_KEEPALIVE; #endif break; diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.h b/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.h index 259b1192c029..0edb8bc356be 100644 --- a/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.h +++ b/www/chromium/files/patch-third__party_webrtc_rtc__base_physical__socket__server.h @@ -1,6 +1,6 @@ ---- third_party/webrtc/rtc_base/physical_socket_server.h.orig 2023-12-10 06:10:27 UTC +--- third_party/webrtc/rtc_base/physical_socket_server.h.orig 2025-05-28 14:55:43 UTC +++ third_party/webrtc/rtc_base/physical_socket_server.h -@@ -18,7 +18,7 @@ +@@ -21,7 +21,7 @@ #include "rtc_base/third_party/sigslot/sigslot.h" #if defined(WEBRTC_POSIX) diff --git a/www/chromium/files/patch-third__party_webrtc_rtc__base_platform__thread__types.cc b/www/chromium/files/patch-third__party_webrtc_rtc__base_platform__thread__types.cc index 77f9e44af9fb..1a359b6a988a 100644 --- a/www/chromium/files/patch-third__party_webrtc_rtc__base_platform__thread__types.cc +++ b/www/chromium/files/patch-third__party_webrtc_rtc__base_platform__thread__types.cc @@ -1,8 +1,8 @@ ---- third_party/webrtc/rtc_base/platform_thread_types.cc.orig 2023-02-08 09:03:45 UTC +--- third_party/webrtc/rtc_base/platform_thread_types.cc.orig 2025-05-28 14:55:43 UTC +++ third_party/webrtc/rtc_base/platform_thread_types.cc -@@ -11,7 +11,9 @@ - #include "rtc_base/platform_thread_types.h" +@@ -12,7 +12,9 @@ + // IWYU pragma: begin_keep #if defined(WEBRTC_LINUX) +#if !defined(WEBRTC_BSD) #include <sys/prctl.h> @@ -10,7 +10,7 @@ #include <sys/syscall.h> #endif -@@ -44,6 +46,8 @@ PlatformThreadId CurrentThreadId() { +@@ -46,6 +48,8 @@ PlatformThreadId CurrentThreadId() { return gettid(); #elif defined(WEBRTC_FUCHSIA) return zx_thread_self(); @@ -19,7 +19,7 @@ #elif defined(WEBRTC_LINUX) return syscall(__NR_gettid); #elif defined(__EMSCRIPTEN__) -@@ -74,6 +78,7 @@ bool IsThreadRefEqual(const PlatformThreadRef& a, cons +@@ -76,6 +80,7 @@ bool IsThreadRefEqual(const PlatformThreadRef& a, cons } void SetCurrentThreadName(const char* name) { @@ -27,7 +27,7 @@ #if defined(WEBRTC_WIN) // The SetThreadDescription API works even if no debugger is attached. // The names set with this API also show up in ETW traces. Very handy. -@@ -120,6 +125,7 @@ void SetCurrentThreadName(const char* name) { +@@ -122,6 +127,7 @@ void SetCurrentThreadName(const char* name) { zx_status_t status = zx_object_set_property(zx_thread_self(), ZX_PROP_NAME, name, strlen(name)); RTC_DCHECK_EQ(status, ZX_OK); diff --git a/www/chromium/files/patch-third__party_webrtc_system__wrappers_BUILD.gn b/www/chromium/files/patch-third__party_webrtc_system__wrappers_BUILD.gn index 40fb708a359e..f9b6ffc90bb0 100644 --- a/www/chromium/files/patch-third__party_webrtc_system__wrappers_BUILD.gn +++ b/www/chromium/files/patch-third__party_webrtc_system__wrappers_BUILD.gn @@ -1,6 +1,6 @@ ---- third_party/webrtc/system_wrappers/BUILD.gn.orig 2022-05-19 14:06:27 UTC +--- third_party/webrtc/system_wrappers/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ third_party/webrtc/system_wrappers/BUILD.gn -@@ -64,8 +64,6 @@ rtc_library("system_wrappers") { +@@ -56,8 +56,6 @@ rtc_library("system_wrappers") { if (!build_with_chromium) { sources += [ "source/cpu_features_linux.cc" ] } diff --git a/www/chromium/files/patch-third__party_zlib_BUILD.gn b/www/chromium/files/patch-third__party_zlib_BUILD.gn index efe9830be204..0c2dd64188ed 100644 --- a/www/chromium/files/patch-third__party_zlib_BUILD.gn +++ b/www/chromium/files/patch-third__party_zlib_BUILD.gn @@ -1,4 +1,4 @@ ---- third_party/zlib/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- third_party/zlib/BUILD.gn.orig 2024-07-30 11:12:21 UTC +++ third_party/zlib/BUILD.gn @@ -128,7 +128,7 @@ if (use_arm_neon_optimizations) { defines = [ "CRC32_ARMV8_CRC32" ] @@ -20,7 +20,7 @@ } else { assert(false, "Unsupported ARM OS") } -@@ -407,7 +411,7 @@ static_library("minizip") { +@@ -413,7 +417,7 @@ static_library("minizip") { ] } diff --git a/www/chromium/files/patch-third__party_zlib_cpu__features.c b/www/chromium/files/patch-third__party_zlib_cpu__features.c index d2b248501655..ad94c2d9d9e8 100644 --- a/www/chromium/files/patch-third__party_zlib_cpu__features.c +++ b/www/chromium/files/patch-third__party_zlib_cpu__features.c @@ -1,4 +1,4 @@ ---- third_party/zlib/cpu_features.c.orig 2024-04-19 13:02:56 UTC +--- third_party/zlib/cpu_features.c.orig 2024-06-03 12:51:57 UTC +++ third_party/zlib/cpu_features.c @@ -39,7 +39,8 @@ int ZLIB_INTERNAL riscv_cpu_enable_vclmul = 0; #ifndef CPU_NO_SIMD @@ -44,7 +44,7 @@ + if (ID_AA64ISAR0_AES(cpu_id) >= ID_AA64ISAR0_AES_PMULL) + arm_cpu_enable_pmull = 1; + -+ if (ID_AA64ISAR0_AES(cpu_id) >= ID_AA64ISAR0_CRC32_BASE) ++ if (ID_AA64ISAR0_CRC32(cpu_id) >= ID_AA64ISAR0_CRC32_BASE) + arm_cpu_enable_crc32 = 1; #elif defined(ARMV8_OS_FUCHSIA) uint32_t features; diff --git a/www/chromium/files/patch-tools_gn_bootstrap_bootstrap.py b/www/chromium/files/patch-tools_gn_bootstrap_bootstrap.py deleted file mode 100644 index 8f51d62c3310..000000000000 --- a/www/chromium/files/patch-tools_gn_bootstrap_bootstrap.py +++ /dev/null @@ -1,11 +0,0 @@ ---- tools/gn/bootstrap/bootstrap.py.orig 2024-04-19 13:02:56 UTC -+++ tools/gn/bootstrap/bootstrap.py -@@ -122,7 +122,7 @@ def main(argv): - - shutil.copy2( - os.path.join(BOOTSTRAP_DIR, 'last_commit_position.h'), gn_build_dir) -- cmd = [ninja_binary, '-C', gn_build_dir, '-w', 'dupbuild=err', 'gn'] -+ cmd = [ninja_binary, '-C', gn_build_dir, 'gn'] - if options.jobs: - cmd += ['-j', str(options.jobs)] - subprocess.check_call(cmd) diff --git a/www/chromium/files/patch-tools_gn_build_build__linux.ninja.template b/www/chromium/files/patch-tools_gn_build_build__linux.ninja.template index 2636120143e8..4d16470b744d 100644 --- a/www/chromium/files/patch-tools_gn_build_build__linux.ninja.template +++ b/www/chromium/files/patch-tools_gn_build_build__linux.ninja.template @@ -1,11 +1,11 @@ ---- tools/gn/build/build_linux.ninja.template.orig 2022-02-07 13:39:41 UTC +--- tools/gn/build/build_linux.ninja.template.orig 2024-06-17 12:56:06 UTC +++ tools/gn/build/build_linux.ninja.template @@ -5,7 +5,7 @@ rule cxx deps = gcc rule alink_thin -- command = rm -f $out && $ar rcsT $out $in -+ command = rm -f $out && $ar rcs $out $in +- command = $ar rcsT $out $in ++ command = $ar rcs $out $in description = AR $out rule link diff --git a/www/chromium/files/patch-tools_gn_build_gen.py b/www/chromium/files/patch-tools_gn_build_gen.py index 0d474b4eee9b..c670f8b1a570 100644 --- a/www/chromium/files/patch-tools_gn_build_gen.py +++ b/www/chromium/files/patch-tools_gn_build_gen.py @@ -1,4 +1,4 @@ ---- tools/gn/build/gen.py.orig 2024-04-19 13:02:56 UTC +--- tools/gn/build/gen.py.orig 2025-05-28 14:55:43 UTC +++ tools/gn/build/gen.py @@ -94,6 +94,12 @@ class Platform(object): def is_solaris(self): @@ -13,7 +13,7 @@ def is_posix(self): return self._platform in ['linux', 'freebsd', 'darwin', 'aix', 'openbsd', 'haiku', 'solaris', 'msys', 'netbsd', 'serenity'] -@@ -304,7 +310,7 @@ def WriteGenericNinja(path, static_libraries, executab +@@ -308,7 +314,7 @@ def WriteGenericNinja(path, static_libraries, executab 'linux': 'build_linux.ninja.template', 'freebsd': 'build_linux.ninja.template', 'aix': 'build_aix.ninja.template', @@ -22,7 +22,7 @@ 'haiku': 'build_haiku.ninja.template', 'solaris': 'build_linux.ninja.template', 'netbsd': 'build_linux.ninja.template', -@@ -539,6 +545,9 @@ def WriteGNNinja(path, platform, host, options, args_l +@@ -551,6 +557,9 @@ def WriteGNNinja(path, platform, host, options, args_l if platform.is_posix() and not platform.is_haiku(): ldflags.append('-pthread') diff --git a/www/chromium/files/patch-tools_gn_src_base_files_file__posix.cc b/www/chromium/files/patch-tools_gn_src_base_files_file__posix.cc index de2fe5444183..1488107524d3 100644 --- a/www/chromium/files/patch-tools_gn_src_base_files_file__posix.cc +++ b/www/chromium/files/patch-tools_gn_src_base_files_file__posix.cc @@ -1,6 +1,6 @@ ---- tools/gn/src/base/files/file_posix.cc.orig 2022-09-24 10:57:32 UTC +--- tools/gn/src/base/files/file_posix.cc.orig 2024-10-22 08:31:56 UTC +++ tools/gn/src/base/files/file_posix.cc -@@ -371,7 +371,7 @@ void File::DoInitialize(const FilePath& path, uint32_t +@@ -359,7 +359,7 @@ void File::DoInitialize(const FilePath& path, uint32_t bool File::Flush() { DCHECK(IsValid()); diff --git a/www/chromium/files/patch-tools_grit_grit_node_base.py b/www/chromium/files/patch-tools_grit_grit_node_base.py index 94bb1b10e40b..798d6c3ecddd 100644 --- a/www/chromium/files/patch-tools_grit_grit_node_base.py +++ b/www/chromium/files/patch-tools_grit_grit_node_base.py @@ -1,6 +1,6 @@ ---- tools/grit/grit/node/base.py.orig 2024-02-23 21:04:38 UTC +--- tools/grit/grit/node/base.py.orig 2025-05-28 14:55:43 UTC +++ tools/grit/grit/node/base.py -@@ -498,7 +498,8 @@ class Node: +@@ -497,7 +497,8 @@ class Node: value = defs elif name == 'is_linux': diff --git a/www/chromium/files/patch-tools_json__schema__compiler_cpp__bundle__generator.py b/www/chromium/files/patch-tools_json__schema__compiler_cpp__bundle__generator.py index 389f705b24da..cf827d8163e4 100644 --- a/www/chromium/files/patch-tools_json__schema__compiler_cpp__bundle__generator.py +++ b/www/chromium/files/patch-tools_json__schema__compiler_cpp__bundle__generator.py @@ -1,8 +1,8 @@ ---- tools/json_schema_compiler/cpp_bundle_generator.py.orig 2023-03-09 06:31:50 UTC +--- tools/json_schema_compiler/cpp_bundle_generator.py.orig 2025-04-04 08:52:13 UTC +++ tools/json_schema_compiler/cpp_bundle_generator.py -@@ -149,7 +149,7 @@ class CppBundleGenerator(object): - # BUILDFLAG(IS_CHROMEOS) && BUILDFLAG(IS_CHROMEOS_LACROS). - ifdefs.append('BUILDFLAG(IS_CHROMEOS_LACROS)') +@@ -140,7 +140,7 @@ class CppBundleGenerator(object): + elif platform == Platforms.FUCHSIA: + ifdefs.append('BUILDFLAG(IS_FUCHSIA)') elif platform == Platforms.LINUX: - ifdefs.append('BUILDFLAG(IS_LINUX)') + ifdefs.append('BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)') diff --git a/www/chromium/files/patch-tools_json__schema__compiler_feature__compiler.py b/www/chromium/files/patch-tools_json__schema__compiler_feature__compiler.py index 5ee0f1c00bf1..76b5fd2c1daa 100644 --- a/www/chromium/files/patch-tools_json__schema__compiler_feature__compiler.py +++ b/www/chromium/files/patch-tools_json__schema__compiler_feature__compiler.py @@ -1,6 +1,6 @@ ---- tools/json_schema_compiler/feature_compiler.py.orig 2024-02-23 21:04:38 UTC +--- tools/json_schema_compiler/feature_compiler.py.orig 2025-04-04 08:52:13 UTC +++ tools/json_schema_compiler/feature_compiler.py -@@ -276,6 +276,8 @@ FEATURE_GRAMMAR = ({ +@@ -289,6 +289,8 @@ FEATURE_GRAMMAR = ({ 'linux': 'Feature::LINUX_PLATFORM', 'mac': 'Feature::MACOSX_PLATFORM', 'win': 'Feature::WIN_PLATFORM', diff --git a/www/chromium/files/patch-tools_perf_chrome__telemetry__build_BUILD.gn b/www/chromium/files/patch-tools_perf_chrome__telemetry__build_BUILD.gn index 9a690e52a2e7..4bd7e01333d0 100644 --- a/www/chromium/files/patch-tools_perf_chrome__telemetry__build_BUILD.gn +++ b/www/chromium/files/patch-tools_perf_chrome__telemetry__build_BUILD.gn @@ -1,15 +1,15 @@ ---- tools/perf/chrome_telemetry_build/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- tools/perf/chrome_telemetry_build/BUILD.gn.orig 2025-05-05 10:57:53 UTC +++ tools/perf/chrome_telemetry_build/BUILD.gn -@@ -47,7 +47,7 @@ group("telemetry_chrome_test") { +@@ -56,7 +56,7 @@ group("telemetry_chrome_test") { data_deps += [ "//chrome:reorder_imports" ] } - if (is_linux || is_chromeos) { + if ((is_linux || is_chromeos) && !is_bsd) { - data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ] + data_deps += [ "//third_party/breakpad:dump_syms" ] # CrOS currently has issues with the locally compiled version of -@@ -178,7 +178,7 @@ group("telemetry_chrome_test_without_chrome") { +@@ -210,7 +210,7 @@ group("telemetry_chrome_test_without_chrome") { ] # Cr-Fuchsia doesn't support breakpad. diff --git a/www/chromium/files/patch-tools_protoc__wrapper_protoc__wrapper.py b/www/chromium/files/patch-tools_protoc__wrapper_protoc__wrapper.py index 10b0f1008a08..ab3d39bd0412 100644 --- a/www/chromium/files/patch-tools_protoc__wrapper_protoc__wrapper.py +++ b/www/chromium/files/patch-tools_protoc__wrapper_protoc__wrapper.py @@ -1,6 +1,6 @@ ---- tools/protoc_wrapper/protoc_wrapper.py.orig 2023-10-11 18:22:24 UTC +--- tools/protoc_wrapper/protoc_wrapper.py.orig 2025-07-02 06:08:04 UTC +++ tools/protoc_wrapper/protoc_wrapper.py -@@ -179,15 +179,19 @@ def main(argv): +@@ -226,15 +226,19 @@ def main(argv): if not options.exclude_imports: protoc_cmd += ["--include_imports"] diff --git a/www/chromium/files/patch-ui_accessibility_accessibility__features.cc b/www/chromium/files/patch-ui_accessibility_accessibility__features.cc new file mode 100644 index 000000000000..6c2927be19c9 --- /dev/null +++ b/www/chromium/files/patch-ui_accessibility_accessibility__features.cc @@ -0,0 +1,11 @@ +--- ui/accessibility/accessibility_features.cc.orig 2025-07-02 06:08:04 UTC ++++ ui/accessibility/accessibility_features.cc +@@ -524,7 +524,7 @@ bool IsBlockRootWindowAccessibleNameChangeEventEnabled + } + #endif // BUILDFLAG(IS_MAC) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + BASE_FEATURE(kWasmTtsComponentUpdaterEnabled, + "WasmTtsComponentUpdaterEnabled", + base::FEATURE_ENABLED_BY_DEFAULT); diff --git a/www/chromium/files/patch-ui_accessibility_accessibility__features.h b/www/chromium/files/patch-ui_accessibility_accessibility__features.h new file mode 100644 index 000000000000..587807596339 --- /dev/null +++ b/www/chromium/files/patch-ui_accessibility_accessibility__features.h @@ -0,0 +1,11 @@ +--- ui/accessibility/accessibility_features.h.orig 2025-07-02 06:08:04 UTC ++++ ui/accessibility/accessibility_features.h +@@ -347,7 +347,7 @@ AX_BASE_EXPORT BASE_DECLARE_FEATURE(kBlockRootWindowAc + AX_BASE_EXPORT bool IsBlockRootWindowAccessibleNameChangeEventEnabled(); + #endif // BUILDFLAG(IS_MAC) + +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Enable the component updater to download the wasm tts engine component. + AX_BASE_EXPORT BASE_DECLARE_FEATURE(kWasmTtsComponentUpdaterEnabled); + AX_BASE_EXPORT bool IsWasmTtsComponentUpdaterEnabled(); diff --git a/www/chromium/files/patch-ui_accessibility_ax__node.cc b/www/chromium/files/patch-ui_accessibility_ax__node.cc new file mode 100644 index 000000000000..0641dea3f3df --- /dev/null +++ b/www/chromium/files/patch-ui_accessibility_ax__node.cc @@ -0,0 +1,20 @@ +--- ui/accessibility/ax_node.cc.orig 2025-07-02 06:08:04 UTC ++++ ui/accessibility/ax_node.cc +@@ -1555,7 +1555,7 @@ AXNode::GetExtraMacNodes() const { + return &table_info->extra_mac_nodes; + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + AXNode* AXNode::GetExtraAnnouncementNode( + ax::mojom::AriaNotificationPriority priority_property) const { + if (!tree_->extra_announcement_nodes()) { +@@ -1583,7 +1583,7 @@ bool AXNode::IsGenerated() const { + GetRole() == ax::mojom::Role::kColumn || + GetRole() == ax::mojom::Role::kTableHeaderContainer; + DCHECK_EQ(is_generated_node, is_extra_mac_node_role); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // On Linux, generated nodes are always children of the root. + if (GetParent() && GetParent()->GetManager()) { + DCHECK(GetParent()->GetManager()->IsRoot()); diff --git a/www/chromium/files/patch-ui_accessibility_ax__node.h b/www/chromium/files/patch-ui_accessibility_ax__node.h new file mode 100644 index 000000000000..a5e2d1d70297 --- /dev/null +++ b/www/chromium/files/patch-ui_accessibility_ax__node.h @@ -0,0 +1,11 @@ +--- ui/accessibility/ax_node.h.orig 2025-05-05 10:57:53 UTC ++++ ui/accessibility/ax_node.h +@@ -587,7 +587,7 @@ class AX_EXPORT AXNode final { + const std::vector<raw_ptr<AXNode, VectorExperimental>>* GetExtraMacNodes() + const; + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + AXNode* GetExtraAnnouncementNode( + ax::mojom::AriaNotificationPriority priority_property) const; + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-ui_accessibility_ax__tree.cc b/www/chromium/files/patch-ui_accessibility_ax__tree.cc new file mode 100644 index 000000000000..8c9999b141f7 --- /dev/null +++ b/www/chromium/files/patch-ui_accessibility_ax__tree.cc @@ -0,0 +1,38 @@ +--- ui/accessibility/ax_tree.cc.orig 2025-07-02 06:08:04 UTC ++++ ui/accessibility/ax_tree.cc +@@ -867,7 +867,7 @@ bool AXTree::ComputeNodeIsIgnoredChanged( + return old_node_is_ignored != new_node_is_ignored; + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + ExtraAnnouncementNodes::ExtraAnnouncementNodes(AXNode* root) { + assertive_node_ = CreateNode("assertive", root); + polite_node_ = CreateNode("polite", root); +@@ -960,7 +960,7 @@ AXNode* AXTree::GetFromId(AXNodeID id) const { + + void AXTree::Destroy() { + base::ElapsedThreadTimer timer; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + ClearExtraAnnouncementNodes(); + #endif // BUILDFLAG(IS_LINUX) + +@@ -2181,7 +2181,7 @@ void AXTree::NotifyNodeAttributesWillChange( + new_data); + } + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void AXTree::ClearExtraAnnouncementNodes() { + if (!extra_announcement_nodes_) { + return; +@@ -2570,7 +2570,7 @@ bool AXTree::CreateNewChildVector( + AXTreeUpdateState* update_state) { + DCHECK(GetTreeUpdateInProgressState()); + bool success = true; +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // If the root node has children added, clear the extra announcement nodes, + // which should always have their indices as the last two children of the root + // node. They will be recreated if needed, and given the correct indices. diff --git a/www/chromium/files/patch-ui_accessibility_ax__tree.h b/www/chromium/files/patch-ui_accessibility_ax__tree.h new file mode 100644 index 000000000000..903c97f6ffef --- /dev/null +++ b/www/chromium/files/patch-ui_accessibility_ax__tree.h @@ -0,0 +1,29 @@ +--- ui/accessibility/ax_tree.h.orig 2025-07-02 06:08:04 UTC ++++ ui/accessibility/ax_tree.h +@@ -63,7 +63,7 @@ enum class AXTreeUnserializeError { + }; + // LINT.ThenChange(/tools/metrics/histograms/metadata/accessibility/enums.xml:AccessibilityTreeUnserializeError) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // To support AriaNotify on older versions of ATK, we need to use the ATK + // signal "Text::text-insert". This signal requires a node that is a + // text type, and it needs to have aria-live properties set in order for +@@ -288,7 +288,7 @@ class AX_EXPORT AXTree { + + void NotifyChildTreeConnectionChanged(AXNode* node, AXTree* child_tree); + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + void ClearExtraAnnouncementNodes(); + void CreateExtraAnnouncementNodes(); + ExtraAnnouncementNodes* extra_announcement_nodes() const { +@@ -550,7 +550,7 @@ class AX_EXPORT AXTree { + + std::unique_ptr<AXEvent> event_data_; + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + std::unique_ptr<ExtraAnnouncementNodes> extra_announcement_nodes_ = nullptr; + #endif // BUILDFLAG(IS_LINUX) + }; diff --git a/www/chromium/files/patch-ui_aura_screen__ozone.cc b/www/chromium/files/patch-ui_aura_screen__ozone.cc index bee75801e24b..0f23cb3ae7a1 100644 --- a/www/chromium/files/patch-ui_aura_screen__ozone.cc +++ b/www/chromium/files/patch-ui_aura_screen__ozone.cc @@ -1,11 +1,11 @@ ---- ui/aura/screen_ozone.cc.orig 2023-11-03 10:09:45 UTC +--- ui/aura/screen_ozone.cc.orig 2025-01-15 09:18:26 UTC +++ ui/aura/screen_ozone.cc -@@ -106,7 +106,7 @@ display::Display ScreenOzone::GetPrimaryDisplay() cons +@@ -107,7 +107,7 @@ display::Display ScreenOzone::GetPrimaryDisplay() cons return platform_screen_->GetPrimaryDisplay(); } --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) ScreenOzone::ScreenSaverSuspenderOzone::ScreenSaverSuspenderOzone( std::unique_ptr<ui::PlatformScreen::PlatformScreenSaverSuspender> suspender) : suspender_(std::move(suspender)) {} diff --git a/www/chromium/files/patch-ui_aura_screen__ozone.h b/www/chromium/files/patch-ui_aura_screen__ozone.h index 7bbc9022c000..c8a5adf022f3 100644 --- a/www/chromium/files/patch-ui_aura_screen__ozone.h +++ b/www/chromium/files/patch-ui_aura_screen__ozone.h @@ -1,20 +1,20 @@ ---- ui/aura/screen_ozone.h.orig 2023-11-03 10:09:45 UTC +--- ui/aura/screen_ozone.h.orig 2025-01-15 09:18:26 UTC +++ ui/aura/screen_ozone.h @@ -44,7 +44,7 @@ class AURA_EXPORT ScreenOzone : public display::Screen display::Display GetDisplayMatching( const gfx::Rect& match_rect) const override; display::Display GetPrimaryDisplay() const override; --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) std::unique_ptr<display::Screen::ScreenSaverSuspender> SuspendScreenSaver() override; - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -@@ -71,7 +71,7 @@ class AURA_EXPORT ScreenOzone : public display::Screen + #endif // BUILDFLAG(IS_LINUX) +@@ -68,7 +68,7 @@ class AURA_EXPORT ScreenOzone : public display::Screen ui::PlatformScreen* platform_screen() { return platform_screen_.get(); } private: --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) class ScreenSaverSuspenderOzone : public display::Screen::ScreenSaverSuspender { public: diff --git a/www/chromium/files/patch-ui_base_accelerators_accelerator.cc b/www/chromium/files/patch-ui_base_accelerators_accelerator.cc new file mode 100644 index 000000000000..7f03e9bf9d73 --- /dev/null +++ b/www/chromium/files/patch-ui_base_accelerators_accelerator.cc @@ -0,0 +1,11 @@ +--- ui/base/accelerators/accelerator.cc.orig 2025-07-02 06:08:04 UTC ++++ ui/base/accelerators/accelerator.cc +@@ -335,7 +335,7 @@ std::vector<std::u16string> Accelerator::GetLongFormMo + modifiers.push_back(l10n_util::GetStringUTF16(IDS_APP_SEARCH_KEY)); + #elif BUILDFLAG(IS_WIN) + modifiers.push_back(l10n_util::GetStringUTF16(IDS_APP_WINDOWS_KEY)); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + modifiers.push_back(l10n_util::GetStringUTF16(IDS_APP_SUPER_KEY)); + #else + NOTREACHED(); diff --git a/www/chromium/files/patch-ui_base_accelerators_command.cc b/www/chromium/files/patch-ui_base_accelerators_command.cc new file mode 100644 index 000000000000..16aa6f5e4f64 --- /dev/null +++ b/www/chromium/files/patch-ui_base_accelerators_command.cc @@ -0,0 +1,11 @@ +--- ui/base/accelerators/command.cc.orig 2025-04-04 08:52:13 UTC ++++ ui/base/accelerators/command.cc +@@ -81,7 +81,7 @@ std::string Command::CommandPlatform() { + return ui::kKeybindingPlatformMac; + #elif BUILDFLAG(IS_CHROMEOS) + return ui::kKeybindingPlatformChromeOs; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return ui::kKeybindingPlatformLinux; + #elif BUILDFLAG(IS_FUCHSIA) + // TODO(crbug.com/40220501): Change this once we decide what string should be diff --git a/www/chromium/files/patch-ui_base_accelerators_global__accelerator__listener_global__accelerator__listener__ozone.cc b/www/chromium/files/patch-ui_base_accelerators_global__accelerator__listener_global__accelerator__listener__ozone.cc new file mode 100644 index 000000000000..de4618bc2d6c --- /dev/null +++ b/www/chromium/files/patch-ui_base_accelerators_global__accelerator__listener_global__accelerator__listener__ozone.cc @@ -0,0 +1,29 @@ +--- ui/base/accelerators/global_accelerator_listener/global_accelerator_listener_ozone.cc.orig 2025-07-02 06:08:04 UTC ++++ ui/base/accelerators/global_accelerator_listener/global_accelerator_listener_ozone.cc +@@ -12,7 +12,7 @@ + #include "ui/base/accelerators/accelerator.h" + #include "ui/ozone/public/ozone_platform.h" + +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(USE_DBUS) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(USE_DBUS) + #include "base/environment.h" + #include "base/feature_list.h" + #include "build/branding_buildflags.h" +@@ -22,7 +22,7 @@ + using content::BrowserThread; + + namespace { +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(USE_DBUS) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(USE_DBUS) + BASE_FEATURE(kGlobalShortcutsPortal, + "GlobalShortcutsPortal", + base::FEATURE_ENABLED_BY_DEFAULT); +@@ -74,7 +74,7 @@ GlobalAcceleratorListener* GlobalAcceleratorListener:: + return instance->get(); + } + +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(USE_DBUS) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(USE_DBUS) + if (base::FeatureList::IsEnabled(kGlobalShortcutsPortal)) { + static GlobalAcceleratorListenerLinux* const linux_instance = + new GlobalAcceleratorListenerLinux(nullptr, GetSessionName()); diff --git a/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.cc b/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.cc deleted file mode 100644 index c72732c1e00e..000000000000 --- a/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/base/clipboard/clipboard_constants.cc.orig 2023-12-10 06:10:27 UTC -+++ ui/base/clipboard/clipboard_constants.cc -@@ -25,7 +25,7 @@ const char kMimeTypeOctetStream[] = "application/octet - // Used for window dragging on some platforms. - const char kMimeTypeWindowDrag[] = "chromium/x-window-drag"; - --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - const char kMimeTypeLinuxUtf8String[] = "UTF8_STRING"; - const char kMimeTypeLinuxString[] = "STRING"; - const char kMimeTypeLinuxText[] = "TEXT"; diff --git a/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.h b/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.h index 9d2e3a41a8fe..14c0e2882e75 100644 --- a/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.h +++ b/www/chromium/files/patch-ui_base_clipboard_clipboard__constants.h @@ -1,11 +1,20 @@ ---- ui/base/clipboard/clipboard_constants.h.orig 2023-12-10 06:10:27 UTC +--- ui/base/clipboard/clipboard_constants.h.orig 2025-05-28 14:55:43 UTC +++ ui/base/clipboard/clipboard_constants.h -@@ -48,7 +48,7 @@ extern const char kMimeTypeDataTransferEndpoint[]; +@@ -44,7 +44,7 @@ inline constexpr char kMimeTypeWindowDrag[] = "chromiu // ----- LINUX & CHROMEOS & FUCHSIA MIME TYPES ----- -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - COMPONENT_EXPORT(UI_BASE_CLIPBOARD_TYPES) - extern const char kMimeTypeLinuxUtf8String[]; - COMPONENT_EXPORT(UI_BASE_CLIPBOARD_TYPES) + inline constexpr char kMimeTypeLinuxUtf8String[] = "UTF8_STRING"; + inline constexpr char kMimeTypeLinuxString[] = "STRING"; + inline constexpr char kMimeTypeLinuxText[] = "TEXT"; +@@ -52,7 +52,7 @@ inline constexpr char kMimeTypeLinuxText[] = "TEXT"; + // BUILDFLAG(IS_FUCHSIA) + + #if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || \ +- BUILDFLAG(IS_ANDROID) ++ BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD) + inline constexpr char kMimeTypeSourceUrl[] = "chromium/x-source-url"; + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || + // BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_ANDROID) diff --git a/www/chromium/files/patch-ui_base_clipboard_clipboard__non__backed.cc b/www/chromium/files/patch-ui_base_clipboard_clipboard__non__backed.cc index c714ddb33051..b5218a9b8d57 100644 --- a/www/chromium/files/patch-ui_base_clipboard_clipboard__non__backed.cc +++ b/www/chromium/files/patch-ui_base_clipboard_clipboard__non__backed.cc @@ -1,6 +1,6 @@ ---- ui/base/clipboard/clipboard_non_backed.cc.orig 2024-02-23 21:04:38 UTC +--- ui/base/clipboard/clipboard_non_backed.cc.orig 2024-06-17 12:56:06 UTC +++ ui/base/clipboard/clipboard_non_backed.cc -@@ -460,7 +460,7 @@ ClipboardNonBacked::ClipboardNonBacked() { +@@ -461,7 +461,7 @@ ClipboardNonBacked::ClipboardNonBacked() { // so create internal clipboards for platform supported clipboard buffers. constexpr ClipboardBuffer kClipboardBuffers[] = { ClipboardBuffer::kCopyPaste, diff --git a/www/chromium/files/patch-ui_base_cursor_cursor__factory.cc b/www/chromium/files/patch-ui_base_cursor_cursor__factory.cc index 45450ad553f8..d6b71e79ac85 100644 --- a/www/chromium/files/patch-ui_base_cursor_cursor__factory.cc +++ b/www/chromium/files/patch-ui_base_cursor_cursor__factory.cc @@ -1,6 +1,6 @@ ---- ui/base/cursor/cursor_factory.cc.orig 2024-03-22 08:19:40 UTC +--- ui/base/cursor/cursor_factory.cc.orig 2024-11-14 07:57:23 UTC +++ ui/base/cursor/cursor_factory.cc -@@ -97,7 +97,7 @@ void CursorFactory::ObserveThemeChanges() { +@@ -96,7 +96,7 @@ void CursorFactory::ObserveThemeChanges() { NOTIMPLEMENTED(); } diff --git a/www/chromium/files/patch-ui_base_dragdrop_os__exchange__data__provider__non__backed.cc b/www/chromium/files/patch-ui_base_dragdrop_os__exchange__data__provider__non__backed.cc index 1a4a2b62d1d1..ce1640183881 100644 --- a/www/chromium/files/patch-ui_base_dragdrop_os__exchange__data__provider__non__backed.cc +++ b/www/chromium/files/patch-ui_base_dragdrop_os__exchange__data__provider__non__backed.cc @@ -1,6 +1,6 @@ ---- ui/base/dragdrop/os_exchange_data_provider_non_backed.cc.orig 2024-04-19 13:02:56 UTC +--- ui/base/dragdrop/os_exchange_data_provider_non_backed.cc.orig 2025-05-05 10:57:53 UTC +++ ui/base/dragdrop/os_exchange_data_provider_non_backed.cc -@@ -99,7 +99,7 @@ void OSExchangeDataProviderNonBacked::SetPickledData( +@@ -101,7 +101,7 @@ void OSExchangeDataProviderNonBacked::SetPickledData( std::optional<std::u16string> OSExchangeDataProviderNonBacked::GetString() const { diff --git a/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.cc b/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.cc index 0a400c2d5ac9..878688514585 100644 --- a/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.cc +++ b/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.cc @@ -1,6 +1,6 @@ ---- ui/base/ime/dummy_text_input_client.cc.orig 2022-10-24 13:33:33 UTC +--- ui/base/ime/dummy_text_input_client.cc.orig 2025-01-15 09:18:26 UTC +++ ui/base/ime/dummy_text_input_client.cc -@@ -159,7 +159,7 @@ bool DummyTextInputClient::ShouldDoLearning() { +@@ -175,7 +175,7 @@ bool DummyTextInputClient::ShouldDoLearning() { return false; } diff --git a/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.h b/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.h index fd686d8daf7d..d9d5f9fe9c4e 100644 --- a/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.h +++ b/www/chromium/files/patch-ui_base_ime_dummy__text__input__client.h @@ -1,6 +1,6 @@ ---- ui/base/ime/dummy_text_input_client.h.orig 2022-08-31 12:19:35 UTC +--- ui/base/ime/dummy_text_input_client.h.orig 2025-01-15 09:18:26 UTC +++ ui/base/ime/dummy_text_input_client.h -@@ -65,7 +65,7 @@ class DummyTextInputClient : public TextInputClient { +@@ -73,7 +73,7 @@ class DummyTextInputClient : public TextInputClient { ukm::SourceId GetClientSourceForMetrics() const override; bool ShouldDoLearning() override; diff --git a/www/chromium/files/patch-ui_base_ime_fake__text__input__client.cc b/www/chromium/files/patch-ui_base_ime_fake__text__input__client.cc index 80adc68ac0b7..a81a458e95ca 100644 --- a/www/chromium/files/patch-ui_base_ime_fake__text__input__client.cc +++ b/www/chromium/files/patch-ui_base_ime_fake__text__input__client.cc @@ -1,7 +1,7 @@ ---- ui/base/ime/fake_text_input_client.cc.orig 2024-03-22 08:19:40 UTC +--- ui/base/ime/fake_text_input_client.cc.orig 2025-01-15 09:18:26 UTC +++ ui/base/ime/fake_text_input_client.cc -@@ -205,7 +205,7 @@ bool FakeTextInputClient::ShouldDoLearning() { - return false; +@@ -227,7 +227,7 @@ bool FakeTextInputClient::ShouldDoLearning() { + return should_do_learning_; } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) diff --git a/www/chromium/files/patch-ui_base_ime_fake__text__input__client.h b/www/chromium/files/patch-ui_base_ime_fake__text__input__client.h index 06b024ce120e..8f15764112d7 100644 --- a/www/chromium/files/patch-ui_base_ime_fake__text__input__client.h +++ b/www/chromium/files/patch-ui_base_ime_fake__text__input__client.h @@ -1,6 +1,6 @@ ---- ui/base/ime/fake_text_input_client.h.orig 2024-03-22 08:19:40 UTC +--- ui/base/ime/fake_text_input_client.h.orig 2025-01-15 09:18:26 UTC +++ ui/base/ime/fake_text_input_client.h -@@ -96,7 +96,7 @@ class FakeTextInputClient : public TextInputClient { +@@ -107,7 +107,7 @@ class FakeTextInputClient : public TextInputClient { void SetTextEditCommandForNextKeyEvent(TextEditCommand command) override; ukm::SourceId GetClientSourceForMetrics() const override; bool ShouldDoLearning() override; diff --git a/www/chromium/files/patch-ui_base_ime_init_input__method__initializer.cc b/www/chromium/files/patch-ui_base_ime_init_input__method__initializer.cc index 50064ea128ac..865d383945e1 100644 --- a/www/chromium/files/patch-ui_base_ime_init_input__method__initializer.cc +++ b/www/chromium/files/patch-ui_base_ime_init_input__method__initializer.cc @@ -1,15 +1,15 @@ ---- ui/base/ime/init/input_method_initializer.cc.orig 2024-04-19 13:02:56 UTC +--- ui/base/ime/init/input_method_initializer.cc.orig 2025-02-19 07:43:18 UTC +++ ui/base/ime/init/input_method_initializer.cc -@@ -10,7 +10,7 @@ - #include "build/chromeos_buildflags.h" +@@ -9,7 +9,7 @@ + #include "base/trace_event/trace_event.h" + #include "build/build_config.h" - #if !BUILDFLAG(IS_CHROMEOS_ASH) && defined(USE_AURA) && \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +-#if defined(USE_AURA) && BUILDFLAG(IS_LINUX) ++#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) #include "ui/base/ime/linux/fake_input_method_context.h" #include "ui/base/ime/linux/linux_input_method_context_factory.h" #elif BUILDFLAG(IS_WIN) -@@ -43,7 +43,7 @@ void RestartInputMethod() { +@@ -33,7 +33,7 @@ void ShutdownInputMethod() { } void InitializeInputMethodForTesting() { @@ -18,12 +18,12 @@ GetInputMethodContextFactoryForTest() = base::BindRepeating([](LinuxInputMethodContextDelegate* delegate) -> std::unique_ptr<LinuxInputMethodContext> { -@@ -56,7 +56,7 @@ void InitializeInputMethodForTesting() { +@@ -45,7 +45,7 @@ void InitializeInputMethodForTesting() { + } void ShutdownInputMethodForTesting() { - #if !BUILDFLAG(IS_CHROMEOS_ASH) && defined(USE_AURA) && \ -- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) +-#if defined(USE_AURA) && BUILDFLAG(IS_LINUX) ++#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) // The function owns the factory (as a static variable that's returned by // reference), so setting this to an empty factory will free the old one. GetInputMethodContextFactoryForTest() = LinuxInputMethodContextFactory(); diff --git a/www/chromium/files/patch-ui_base_ime_text__input__client.h b/www/chromium/files/patch-ui_base_ime_text__input__client.h index 42f87d362249..b6a2cf4fb2e0 100644 --- a/www/chromium/files/patch-ui_base_ime_text__input__client.h +++ b/www/chromium/files/patch-ui_base_ime_text__input__client.h @@ -1,6 +1,6 @@ ---- ui/base/ime/text_input_client.h.orig 2023-07-16 15:47:57 UTC +--- ui/base/ime/text_input_client.h.orig 2025-03-05 08:14:56 UTC +++ ui/base/ime/text_input_client.h -@@ -265,7 +265,7 @@ class COMPONENT_EXPORT(UI_BASE_IME) TextInputClient +@@ -337,7 +337,7 @@ class COMPONENT_EXPORT(UI_BASE_IME) TextInputClient { // fields that are considered 'private' (e.g. in incognito tabs). virtual bool ShouldDoLearning() = 0; diff --git a/www/chromium/files/patch-ui_base_resource_resource__bundle.cc b/www/chromium/files/patch-ui_base_resource_resource__bundle.cc index 81567323b96f..823c2db72053 100644 --- a/www/chromium/files/patch-ui_base_resource_resource__bundle.cc +++ b/www/chromium/files/patch-ui_base_resource_resource__bundle.cc @@ -1,6 +1,6 @@ ---- ui/base/resource/resource_bundle.cc.orig 2024-01-30 07:53:34 UTC +--- ui/base/resource/resource_bundle.cc.orig 2025-07-02 06:08:04 UTC +++ ui/base/resource/resource_bundle.cc -@@ -926,7 +926,7 @@ void ResourceBundle::ReloadFonts() { +@@ -971,7 +971,7 @@ void ResourceBundle::ReloadFonts() { } ResourceScaleFactor ResourceBundle::GetMaxResourceScaleFactor() const { diff --git a/www/chromium/files/patch-ui_base_test_skia__gold__pixel__diff.cc b/www/chromium/files/patch-ui_base_test_skia__gold__pixel__diff.cc index 43cf1c8e77d5..0a9e4249ae59 100644 --- a/www/chromium/files/patch-ui_base_test_skia__gold__pixel__diff.cc +++ b/www/chromium/files/patch-ui_base_test_skia__gold__pixel__diff.cc @@ -1,11 +1,11 @@ ---- ui/base/test/skia_gold_pixel_diff.cc.orig 2023-09-13 12:11:42 UTC +--- ui/base/test/skia_gold_pixel_diff.cc.orig 2025-03-05 08:14:56 UTC +++ ui/base/test/skia_gold_pixel_diff.cc -@@ -115,7 +115,7 @@ const char* GetPlatformName() { +@@ -117,7 +117,7 @@ const char* GetPlatformName() { + return "windows"; + #elif BUILDFLAG(IS_APPLE) return "macOS"; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return "linux"; - #elif BUILDFLAG(IS_CHROMEOS_LACROS) - return "lacros"; + #elif BUILDFLAG(IS_CHROMEOS) + return "ash"; diff --git a/www/chromium/files/patch-ui_base_test_ui__controls.h b/www/chromium/files/patch-ui_base_test_ui__controls.h index c850d8481dd9..2cd8ab9dd66f 100644 --- a/www/chromium/files/patch-ui_base_test_ui__controls.h +++ b/www/chromium/files/patch-ui_base_test_ui__controls.h @@ -1,6 +1,6 @@ ---- ui/base/test/ui_controls.h.orig 2024-03-22 08:19:40 UTC +--- ui/base/test/ui_controls.h.orig 2025-05-05 10:57:53 UTC +++ ui/base/test/ui_controls.h -@@ -186,7 +186,7 @@ bool SendTouchEventsNotifyWhenDone(int action, +@@ -191,7 +191,7 @@ bool SendTouchEventsNotifyWhenDone(int action, base::OnceClosure task); #endif diff --git a/www/chromium/files/patch-ui_base_ui__base__features.cc b/www/chromium/files/patch-ui_base_ui__base__features.cc index d0da3c97ac93..c4639aee3311 100644 --- a/www/chromium/files/patch-ui_base_ui__base__features.cc +++ b/www/chromium/files/patch-ui_base_ui__base__features.cc @@ -1,15 +1,33 @@ ---- ui/base/ui_base_features.cc.orig 2024-04-19 13:02:56 UTC +--- ui/base/ui_base_features.cc.orig 2025-07-02 06:08:04 UTC +++ ui/base/ui_base_features.cc -@@ -227,7 +227,7 @@ BASE_FEATURE(kExperimentalFlingAnimation, +@@ -119,7 +119,7 @@ BASE_FEATURE(kWaylandLinuxDrmSyncobj, + // Controls whether support for Wayland's per-surface scaling is enabled. + BASE_FEATURE(kWaylandPerSurfaceScale, + "WaylandPerSurfaceScale", +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + base::FEATURE_ENABLED_BY_DEFAULT + #else + base::FEATURE_DISABLED_BY_DEFAULT +@@ -143,7 +143,7 @@ BASE_FEATURE(kWaylandSessionManagement, + base::FEATURE_DISABLED_BY_DEFAULT); + #endif // BUILDFLAG(IS_OZONE) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // If this feature is enabled, users not specify --ozone-platform-hint switch + // will get --ozone-platform-hint=auto treatment. https://crbug.com/40250220. + COMPONENT_EXPORT(UI_BASE_FEATURES) +@@ -231,7 +231,7 @@ BASE_FEATURE(kUiCompositorUsesLayerLists, + // native apps on Windows. + BASE_FEATURE(kExperimentalFlingAnimation, "ExperimentalFlingAnimation", - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_WIN) || \ -+#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) || \ - (BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_CHROMEOS_ASH) && \ - !BUILDFLAG(IS_CHROMEOS_LACROS)) +-#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) base::FEATURE_ENABLED_BY_DEFAULT -@@ -326,7 +326,7 @@ bool IsForcedColorsEnabled() { + #else + base::FEATURE_DISABLED_BY_DEFAULT +@@ -323,7 +323,7 @@ bool IsForcedColorsEnabled() { BASE_FEATURE(kEyeDropper, "EyeDropper", #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-ui_base_ui__base__features.h b/www/chromium/files/patch-ui_base_ui__base__features.h new file mode 100644 index 000000000000..99bce9421f17 --- /dev/null +++ b/www/chromium/files/patch-ui_base_ui__base__features.h @@ -0,0 +1,11 @@ +--- ui/base/ui_base_features.h.orig 2025-07-02 06:08:04 UTC ++++ ui/base/ui_base_features.h +@@ -129,7 +129,7 @@ COMPONENT_EXPORT(UI_BASE_FEATURES) + BASE_DECLARE_FEATURE(kWaylandSessionManagement); + #endif // BUILDFLAG(IS_OZONE) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + COMPONENT_EXPORT(UI_BASE_FEATURES) + BASE_DECLARE_FEATURE(kOverrideDefaultOzonePlatformHintToAuto); + #endif // BUILDFLAG(IS_LINUX) diff --git a/www/chromium/files/patch-ui_base_ui__base__switches.cc b/www/chromium/files/patch-ui_base_ui__base__switches.cc index 10cdf4702755..a0a276ae3efd 100644 --- a/www/chromium/files/patch-ui_base_ui__base__switches.cc +++ b/www/chromium/files/patch-ui_base_ui__base__switches.cc @@ -1,7 +1,7 @@ ---- ui/base/ui_base_switches.cc.orig 2023-10-11 18:22:24 UTC +--- ui/base/ui_base_switches.cc.orig 2025-07-02 06:08:04 UTC +++ ui/base/ui_base_switches.cc -@@ -31,13 +31,13 @@ const char kShowMacOverlayBorders[] = "show-mac-overla - const char kEnableResourcesFileSharing[] = "enable-resources-file-sharing"; +@@ -24,13 +24,13 @@ const char kDisableModalAnimations[] = "disable-modal- + const char kShowMacOverlayBorders[] = "show-mac-overlay-borders"; #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -15,4 +15,4 @@ +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Specify the toolkit used to construct the Linux GUI. const char kUiToolkitFlag[] = "ui-toolkit"; - #endif + // Specify the GTK version to be loaded. diff --git a/www/chromium/files/patch-ui_base_ui__base__switches.h b/www/chromium/files/patch-ui_base_ui__base__switches.h index 35466f255482..cb812fc6078e 100644 --- a/www/chromium/files/patch-ui_base_ui__base__switches.h +++ b/www/chromium/files/patch-ui_base_ui__base__switches.h @@ -1,7 +1,7 @@ ---- ui/base/ui_base_switches.h.orig 2023-10-11 18:22:24 UTC +--- ui/base/ui_base_switches.h.orig 2025-07-02 06:08:04 UTC +++ ui/base/ui_base_switches.h -@@ -27,11 +27,11 @@ COMPONENT_EXPORT(UI_BASE) extern const char kShowMacOv - COMPONENT_EXPORT(UI_BASE) extern const char kEnableResourcesFileSharing[]; +@@ -22,11 +22,11 @@ COMPONENT_EXPORT(UI_BASE) extern const char kDisableMo + COMPONENT_EXPORT(UI_BASE) extern const char kShowMacOverlayBorders[]; #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -12,5 +12,5 @@ -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) COMPONENT_EXPORT(UI_BASE) extern const char kUiToolkitFlag[]; - #endif - + COMPONENT_EXPORT(UI_BASE) extern const char kGtkVersionFlag[]; + COMPONENT_EXPORT(UI_BASE) extern const char kQtVersionFlag[]; diff --git a/www/chromium/files/patch-ui_base_webui_web__ui__util.cc b/www/chromium/files/patch-ui_base_webui_web__ui__util.cc index 956b744f20fd..b2db60b59594 100644 --- a/www/chromium/files/patch-ui_base_webui_web__ui__util.cc +++ b/www/chromium/files/patch-ui_base_webui_web__ui__util.cc @@ -1,6 +1,6 @@ ---- ui/base/webui/web_ui_util.cc.orig 2024-01-30 07:53:34 UTC +--- ui/base/webui/web_ui_util.cc.orig 2025-07-02 06:08:04 UTC +++ ui/base/webui/web_ui_util.cc -@@ -39,7 +39,7 @@ namespace { +@@ -42,7 +42,7 @@ namespace { constexpr float kMaxScaleFactor = 1000.0f; std::string GetFontFamilyMd() { @@ -9,12 +9,12 @@ return "Roboto, " + GetFontFamily(); #else return GetFontFamily(); -@@ -217,7 +217,7 @@ std::string GetFontFamily() { +@@ -217,7 +217,7 @@ void AppendWebUiCssTextDefaults(std::string* html) { + std::string GetFontFamily() { + std::string font_family = l10n_util::GetStringUTF8(IDS_WEB_FONT_FAMILY); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) std::string font_name = ui::ResourceBundle::GetSharedInstance() .GetFont(ui::ResourceBundle::BaseFont) .GetFontName(); diff --git a/www/chromium/files/patch-ui_base_x_x11__cursor__loader.cc b/www/chromium/files/patch-ui_base_x_x11__cursor__loader.cc index a9743e8d4bc5..470404c9220a 100644 --- a/www/chromium/files/patch-ui_base_x_x11__cursor__loader.cc +++ b/www/chromium/files/patch-ui_base_x_x11__cursor__loader.cc @@ -1,6 +1,6 @@ ---- ui/base/x/x11_cursor_loader.cc.orig 2024-01-30 07:53:34 UTC +--- ui/base/x/x11_cursor_loader.cc.orig 2025-05-28 14:55:43 UTC +++ ui/base/x/x11_cursor_loader.cc -@@ -31,7 +31,7 @@ +@@ -42,7 +42,7 @@ #include "ui/gfx/x/connection.h" #include "ui/gfx/x/xproto.h" @@ -9,7 +9,7 @@ #include "ui/linux/linux_ui.h" #endif -@@ -137,7 +137,11 @@ std::string CursorPathFromLibXcursor() { +@@ -84,7 +84,11 @@ std::string CursorPathFromLibXcursor() { void operator()(void* ptr) const { dlclose(ptr); } }; @@ -21,7 +21,7 @@ if (!lib) return ""; -@@ -248,7 +252,7 @@ scoped_refptr<base::RefCountedMemory> ReadCursorFile( +@@ -229,7 +233,7 @@ scoped_refptr<base::RefCountedMemory> ReadCursorFile( const std::string& rm_xcursor_theme) { constexpr const char kDefaultTheme[] = "default"; std::string themes[] = { @@ -30,7 +30,7 @@ // The toolkit theme has the highest priority. LinuxUi::instance() ? LinuxUi::instance()->GetCursorThemeName() : std::string(), -@@ -440,7 +444,7 @@ uint32_t XCursorLoader::GetPreferredCursorSize() const +@@ -419,7 +423,7 @@ uint32_t XCursorLoader::GetPreferredCursorSize() const return size; } diff --git a/www/chromium/files/patch-ui_base_x_x11__display__util.cc b/www/chromium/files/patch-ui_base_x_x11__display__util.cc deleted file mode 100644 index 1b5a6ad09de3..000000000000 --- a/www/chromium/files/patch-ui_base_x_x11__display__util.cc +++ /dev/null @@ -1,365 +0,0 @@ ---- ui/base/x/x11_display_util.cc.orig 2024-04-19 13:02:56 UTC -+++ ui/base/x/x11_display_util.cc -@@ -14,7 +14,6 @@ - - #include "base/bits.h" - #include "base/command_line.h" --#include "base/containers/flat_map.h" - #include "base/logging.h" - #include "base/numerics/clamped_math.h" - #include "base/ranges/algorithm.h" -@@ -28,7 +27,6 @@ - #include "ui/gfx/geometry/rect.h" - #include "ui/gfx/geometry/rect_conversions.h" - #include "ui/gfx/geometry/rect_f.h" --#include "ui/gfx/switches.h" - #include "ui/gfx/x/atom_cache.h" - #include "ui/gfx/x/connection.h" - #include "ui/gfx/x/randr.h" -@@ -43,89 +41,42 @@ constexpr std::pair<uint32_t, uint32_t> kMinVersionXra - - constexpr const char kRandrEdidProperty[] = "EDID"; - --std::map<x11::RandR::Output, size_t> GetMonitors( -- const x11::Response<x11::RandR::GetMonitorsReply>& reply) { -- std::map<x11::RandR::Output, size_t> output_to_monitor; -- if (!reply) { -- return output_to_monitor; -- } -- for (size_t monitor = 0; monitor < reply->monitors.size(); monitor++) { -- for (x11::RandR::Output output : reply->monitors[monitor].outputs) { -- output_to_monitor[output] = monitor; -+std::map<x11::RandR::Output, int> GetMonitors( -+ std::pair<uint32_t, uint32_t> version, -+ x11::RandR* randr, -+ x11::Window window) { -+ std::map<x11::RandR::Output, int> output_to_monitor; -+ if (version >= std::pair<uint32_t, uint32_t>{1, 5}) { -+ if (auto reply = randr->GetMonitors({window}).Sync()) { -+ for (size_t monitor = 0; monitor < reply->monitors.size(); monitor++) { -+ for (x11::RandR::Output output : reply->monitors[monitor].outputs) { -+ output_to_monitor[output] = monitor; -+ } -+ } - } - } - return output_to_monitor; - } - --x11::Future<x11::GetPropertyReply> GetWorkAreaFuture( -- x11::Connection* connection) { -- return connection->GetProperty({ -- .window = connection->default_root(), -- .property = connection->GetAtom("_NET_WORKAREA"), -- .long_length = 4, -- }); --} -- --gfx::Rect GetWorkAreaSync(x11::Future<x11::GetPropertyReply> future) { -- auto response = future.Sync(); -- if (!response || response->format != 32 || response->value_len != 4) { -- return gfx::Rect(); -- } -- const uint32_t* value = response->value->front_as<uint32_t>(); -- return gfx::Rect(value[0], value[1], value[2], value[3]); --} -- --x11::Future<x11::GetPropertyReply> GetIccProfileFuture( -- x11::Connection* connection, -- size_t monitor) { -- std::string atom_name = monitor == 0 -- ? "_ICC_PROFILE" -- : base::StringPrintf("_ICC_PROFILE_%zu", monitor); -- auto future = connection->GetProperty({ -- .window = connection->default_root(), -- .property = x11::GetAtom(atom_name.c_str()), -- .long_length = std::numeric_limits<uint32_t>::max(), -- }); -- future.IgnoreError(); -- return future; --} -- --gfx::ICCProfile GetIccProfileSync(x11::Future<x11::GetPropertyReply> future) { -- auto response = future.Sync(); -- if (!response || !response->value->size()) { -- return gfx::ICCProfile(); -- } -- return gfx::ICCProfile::FromData(response->value->data(), -- response->value->size()); --} -- --x11::Future<x11::RandR::GetOutputPropertyReply> GetEdidFuture( -- x11::Connection* connection, -- x11::RandR::Output output) { -- auto future = connection->randr().GetOutputProperty({ -- .output = output, -- .property = x11::GetAtom(kRandrEdidProperty), -- .long_length = 128, -- }); -- future.IgnoreError(); -- return future; --} -- - // Sets the work area on a list of displays. The work area for each display - // must already be initialized to the display bounds. At most one display out - // of |displays| will be affected. - void ClipWorkArea(std::vector<display::Display>* displays, -- size_t primary_display_index, -- const gfx::Rect& net_workarea) { -- if (net_workarea.IsEmpty()) { -+ size_t primary_display_index) { -+ x11::Window x_root_window = ui::GetX11RootWindow(); -+ -+ std::vector<int32_t> value; -+ if (!x11::Connection::Get()->GetArrayProperty( -+ x_root_window, x11::GetAtom("_NET_WORKAREA"), &value) || -+ value.size() < 4) { - return; - } -- - auto get_work_area = [&](const display::Display& display) { - float scale = display::Display::HasForceDeviceScaleFactor() - ? display::Display::GetForcedDeviceScaleFactor() - : display.device_scale_factor(); -- return gfx::ScaleToEnclosingRect(net_workarea, 1.0f / scale); -+ return gfx::ScaleToEnclosingRect( -+ gfx::Rect(value[0], value[1], value[2], value[3]), 1.0f / scale); - }; - - // If the work area entirely contains exactly one display, assume it's meant -@@ -207,9 +158,14 @@ int DefaultBitsPerComponent() { - return visual.bits_per_rgb_value; - } - --// Get the EDID data from the `output` and stores to `edid`. --std::vector<uint8_t> GetEdidProperty( -- x11::Response<x11::RandR::GetOutputPropertyReply> response) { -+// Get the EDID data from the |output| and stores to |edid|. -+std::vector<uint8_t> GetEDIDProperty(x11::RandR* randr, -+ x11::RandR::Output output) { -+ auto future = randr->GetOutputProperty(x11::RandR::GetOutputPropertyRequest{ -+ .output = output, -+ .property = x11::GetAtom(kRandrEdidProperty), -+ .long_length = 128}); -+ auto response = future.Sync(); - std::vector<uint8_t> edid; - if (response && response->format == 8 && response->type != x11::Atom::None) { - edid = std::move(response->data); -@@ -261,8 +217,7 @@ gfx::PointF DisplayOriginPxToDip(const display::Displa - std::vector<display::Display> GetFallbackDisplayList( - float scale, - size_t* primary_display_index_out) { -- auto* connection = x11::Connection::Get(); -- const auto& screen = connection->default_screen(); -+ const auto& screen = x11::Connection::Get()->default_screen(); - gfx::Size physical_size(screen.width_in_millimeters, - screen.height_in_millimeters); - -@@ -289,9 +244,7 @@ std::vector<display::Display> GetFallbackDisplayList( - std::vector<display::Display> displays{gfx_display}; - *primary_display_index_out = 0; - -- ClipWorkArea(&displays, *primary_display_index_out, -- GetWorkAreaSync(GetWorkAreaFuture(connection))); -- -+ ClipWorkArea(&displays, *primary_display_index_out); - return displays; - } - -@@ -307,16 +260,7 @@ std::vector<display::Display> BuildDisplaysFromXRandRI - auto x_root_window = ui::GetX11RootWindow(); - std::vector<display::Display> displays; - -- auto resources_future = randr.GetScreenResourcesCurrent({x_root_window}); -- auto output_primary_future = randr.GetOutputPrimary({x_root_window}); -- x11::Future<x11::RandR::GetMonitorsReply> monitors_future; -- if (connection->randr_version() >= std::pair<uint32_t, uint32_t>{1, 5}) { -- monitors_future = randr.GetMonitors(x_root_window); -- } -- auto work_area_future = GetWorkAreaFuture(connection); -- connection->Flush(); -- -- auto resources = resources_future.Sync(); -+ auto resources = randr.GetScreenResourcesCurrent({x_root_window}).Sync(); - if (!resources) { - LOG(ERROR) << "XRandR returned no displays; falling back to root window"; - return GetFallbackDisplayList(primary_scale, primary_display_index_out); -@@ -325,65 +269,21 @@ std::vector<display::Display> BuildDisplaysFromXRandRI - const int depth = connection->default_screen().root_depth; - const int bits_per_component = DefaultBitsPerComponent(); - -- auto output_primary = output_primary_future.Sync(); -+ std::map<x11::RandR::Output, int> output_to_monitor = -+ GetMonitors(connection->randr_version(), &randr, x_root_window); -+ auto output_primary = randr.GetOutputPrimary({x_root_window}).Sync(); - if (!output_primary) { - return GetFallbackDisplayList(primary_scale, primary_display_index_out); - } - x11::RandR::Output primary_display_id = output_primary->output; - -- const auto monitors_reply = monitors_future.Sync(); -- const auto output_to_monitor = GetMonitors(monitors_reply); -- const size_t n_iccs = -- monitors_reply ? std::max<size_t>(1, monitors_reply->monitors.size()) : 1; -- - int explicit_primary_display_index = -1; - int monitor_order_primary_display_index = -1; - -- std::vector<x11::Future<x11::RandR::GetCrtcInfoReply>> crtc_futures{}; -- crtc_futures.reserve(resources->crtcs.size()); -- for (auto crtc : resources->crtcs) { -- crtc_futures.push_back( -- randr.GetCrtcInfo({crtc, resources->config_timestamp})); -- } -- connection->Flush(); -- -- std::vector<x11::Future<x11::GetPropertyReply>> icc_futures{n_iccs}; -- if (!base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kHeadless)) { -- for (size_t monitor = 0; monitor < n_iccs; ++monitor) { -- icc_futures[monitor] = GetIccProfileFuture(connection, monitor); -- } -- connection->Flush(); -- } -- -- std::vector<x11::Future<x11::RandR::GetOutputInfoReply>> output_futures{}; -- output_futures.reserve(resources->outputs.size()); -- for (auto output : resources->outputs) { -- output_futures.push_back( -- randr.GetOutputInfo({output, resources->config_timestamp})); -- } -- connection->Flush(); -- -- std::vector<x11::Future<x11::RandR::GetOutputPropertyReply>> edid_futures{}; -- edid_futures.reserve(resources->outputs.size()); -- for (auto output : resources->outputs) { -- edid_futures.push_back(GetEdidFuture(connection, output)); -- } -- connection->Flush(); -- -- base::flat_map<x11::RandR::Crtc, x11::RandR::GetCrtcInfoResponse> crtcs; -- for (size_t i = 0; i < resources->crtcs.size(); ++i) { -- crtcs.emplace(resources->crtcs[i], crtc_futures[i].Sync()); -- } -- -- std::vector<gfx::ICCProfile> iccs; -- iccs.reserve(n_iccs); -- for (auto& future : icc_futures) { -- iccs.push_back(GetIccProfileSync(std::move(future))); -- } -- - for (size_t i = 0; i < resources->outputs.size(); i++) { - x11::RandR::Output output_id = resources->outputs[i]; -- auto output_info = output_futures[i].Sync(); -+ auto output_info = -+ randr.GetOutputInfo({output_id, resources->config_timestamp}).Sync(); - if (!output_info) { - continue; - } -@@ -398,16 +298,15 @@ std::vector<display::Display> BuildDisplaysFromXRandRI - continue; - } - -- auto crtc_it = crtcs.find(output_info->crtc); -- if (crtc_it == crtcs.end()) { -- continue; -- } -- const auto& crtc = crtc_it->second; -+ auto crtc = -+ randr.GetCrtcInfo({output_info->crtc, resources->config_timestamp}) -+ .Sync(); - if (!crtc) { - continue; - } - -- display::EdidParser edid_parser(GetEdidProperty(edid_futures[i].Sync())); -+ display::EdidParser edid_parser( -+ GetEDIDProperty(&randr, static_cast<x11::RandR::Output>(output_id))); - auto output_32 = static_cast<uint32_t>(output_id); - int64_t display_id = - output_32 > 0xff ? 0 : edid_parser.GetIndexBasedDisplayId(output_32); -@@ -462,9 +361,8 @@ std::vector<display::Display> BuildDisplaysFromXRandRI - } - - if (!display::HasForceDisplayColorProfile()) { -- const size_t monitor = -- monitor_iter == output_to_monitor.end() ? 0 : monitor_iter->second; -- const auto& icc_profile = iccs[monitor < iccs.size() ? monitor : 0]; -+ gfx::ICCProfile icc_profile = ui::GetICCProfileForMonitor( -+ monitor_iter == output_to_monitor.end() ? 0 : monitor_iter->second); - gfx::ColorSpace color_space = icc_profile.GetPrimariesOnlyColorSpace(); - - // Most folks do not have an ICC profile set up, but we still want to -@@ -509,24 +407,63 @@ std::vector<display::Display> BuildDisplaysFromXRandRI - ConvertDisplayBoundsToDips(&displays, *primary_display_index_out); - } - -- ClipWorkArea(&displays, *primary_display_index_out, -- GetWorkAreaSync(std::move(work_area_future))); -+ ClipWorkArea(&displays, *primary_display_index_out); - return displays; - } - - base::TimeDelta GetPrimaryDisplayRefreshIntervalFromXrandr() { - constexpr base::TimeDelta kDefaultInterval = base::Seconds(1. / 60); -- -- size_t primary_display_index = 0; -- auto displays = BuildDisplaysFromXRandRInfo(display::DisplayConfig(), -- &primary_display_index); -- CHECK_LT(primary_display_index, displays.size()); -- -+ x11::RandR randr = x11::Connection::Get()->randr(); -+ auto root = ui::GetX11RootWindow(); -+ auto resources = randr.GetScreenResourcesCurrent({root}).Sync(); -+ if (!resources) { -+ return kDefaultInterval; -+ } - // TODO(crbug.com/726842): It might make sense here to pick the output that - // the window is on. On the other hand, if compositing is enabled, all drawing - // might be synced to the primary output anyway. Needs investigation. -- auto frequency = displays[primary_display_index].display_frequency(); -- return frequency > 0 ? base::Seconds(1. / frequency) : kDefaultInterval; -+ auto output_primary = randr.GetOutputPrimary({root}).Sync(); -+ if (!output_primary) { -+ return kDefaultInterval; -+ } -+ x11::RandR::Output primary_output = output_primary->output; -+ bool disconnected_primary = false; -+ for (size_t i = 0; i < resources->outputs.size(); i++) { -+ if (!disconnected_primary && resources->outputs[i] != primary_output) { -+ continue; -+ } -+ -+ auto output_info = -+ randr.GetOutputInfo({primary_output, resources->config_timestamp}) -+ .Sync(); -+ if (!output_info) { -+ continue; -+ } -+ -+ if (output_info->connection != x11::RandR::RandRConnection::Connected) { -+ // If the primary monitor is disconnected, then start over and choose the -+ // first connected monitor instead. -+ if (!disconnected_primary) { -+ disconnected_primary = true; -+ i = -1; -+ } -+ continue; -+ } -+ auto crtc = -+ randr.GetCrtcInfo({output_info->crtc, resources->config_timestamp}) -+ .Sync(); -+ if (!crtc) { -+ continue; -+ } -+ float refresh_rate = -+ GetRefreshRateFromXRRModeInfo(resources->modes, crtc->mode); -+ if (refresh_rate == 0) { -+ continue; -+ } -+ -+ return base::Seconds(1. / refresh_rate); -+ } -+ return kDefaultInterval; - } - - int RangeDistance(int min1, int max1, int min2, int max2) { diff --git a/www/chromium/files/patch-ui_base_x_x11__shm__image__pool.cc b/www/chromium/files/patch-ui_base_x_x11__shm__image__pool.cc index 8dd3ee6e1bd4..257b1e8c0cd7 100644 --- a/www/chromium/files/patch-ui_base_x_x11__shm__image__pool.cc +++ b/www/chromium/files/patch-ui_base_x_x11__shm__image__pool.cc @@ -1,4 +1,4 @@ ---- ui/base/x/x11_shm_image_pool.cc.orig 2024-04-19 13:02:56 UTC +--- ui/base/x/x11_shm_image_pool.cc.orig 2025-01-15 09:18:26 UTC +++ ui/base/x/x11_shm_image_pool.cc @@ -16,6 +16,7 @@ #include "base/functional/callback.h" @@ -6,9 +6,9 @@ #include "base/strings/string_util.h" +#include "base/system/sys_info.h" #include "build/build_config.h" - #include "build/chromeos_buildflags.h" #include "net/base/url_util.h" -@@ -45,10 +46,14 @@ constexpr float kShmResizeShrinkThreshold = + #include "ui/events/platform/platform_event_dispatcher.h" +@@ -44,10 +45,14 @@ constexpr float kShmResizeShrinkThreshold = 1.0f / (kShmResizeThreshold * kShmResizeThreshold); std::size_t MaxShmSegmentSizeImpl() { @@ -23,10 +23,10 @@ } std::size_t MaxShmSegmentSize() { -@@ -57,14 +62,19 @@ std::size_t MaxShmSegmentSize() { +@@ -56,14 +61,19 @@ std::size_t MaxShmSegmentSize() { } - #if !BUILDFLAG(IS_CHROMEOS_ASH) + #if !BUILDFLAG(IS_CHROMEOS) +#if !BUILDFLAG(IS_BSD) bool IsRemoteHost(const std::string& name) { if (name.empty()) @@ -43,15 +43,15 @@ // MIT-SHM may be available on remote connetions, but it will be unusable. Do // a best-effort check to see if the host is remote to disable the SHM // codepath. It may be possible in contrived cases for there to be a -@@ -93,6 +103,7 @@ bool ShouldUseMitShm(x11::Connection* connection) { +@@ -92,6 +102,7 @@ bool ShouldUseMitShm(x11::Connection* connection) { return false; return true; +#endif } - #endif + #endif // !BUILDFLAG(IS_CHROMEOS) -@@ -183,7 +194,7 @@ bool XShmImagePool::Resize(const gfx::Size& pixel_size +@@ -182,7 +193,7 @@ bool XShmImagePool::Resize(const gfx::Size& pixel_size shmctl(state.shmid, IPC_RMID, nullptr); return false; } @@ -60,7 +60,7 @@ // On Linux, a shmid can still be attached after IPC_RMID if otherwise // kept alive. Detach before XShmAttach to prevent a memory leak in case // the process dies. -@@ -202,7 +213,7 @@ bool XShmImagePool::Resize(const gfx::Size& pixel_size +@@ -201,7 +212,7 @@ bool XShmImagePool::Resize(const gfx::Size& pixel_size return false; state.shmseg = shmseg; state.shmem_attached_to_server = true; diff --git a/www/chromium/files/patch-ui_base_x_x11__util.cc b/www/chromium/files/patch-ui_base_x_x11__util.cc deleted file mode 100644 index 8e53d0051144..000000000000 --- a/www/chromium/files/patch-ui_base_x_x11__util.cc +++ /dev/null @@ -1,23 +0,0 @@ ---- ui/base/x/x11_util.cc.orig 2024-02-23 21:04:38 UTC -+++ ui/base/x/x11_util.cc -@@ -699,4 +699,20 @@ gfx::ImageSkia GetNativeWindowIcon(intptr_t target_win - return gfx::ImageSkia::CreateFrom1xBitmap(result); - } - -+gfx::ICCProfile GetICCProfileForMonitor(int monitor) { -+ gfx::ICCProfile icc_profile; -+ if (base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kHeadless)) { -+ return icc_profile; -+ } -+ std::string atom_name = monitor == 0 -+ ? "_ICC_PROFILE" -+ : base::StringPrintf("_ICC_PROFILE_%d", monitor); -+ scoped_refptr<base::RefCountedMemory> data; -+ if (GetRawBytesOfProperty(GetX11RootWindow(), x11::GetAtom(atom_name.c_str()), -+ &data, nullptr)) { -+ icc_profile = gfx::ICCProfile::FromData(data->data(), data->size()); -+ } -+ return icc_profile; -+} -+ - } // namespace ui diff --git a/www/chromium/files/patch-ui_base_x_x11__util.h b/www/chromium/files/patch-ui_base_x_x11__util.h deleted file mode 100644 index 4431a90d1676..000000000000 --- a/www/chromium/files/patch-ui_base_x_x11__util.h +++ /dev/null @@ -1,13 +0,0 @@ ---- ui/base/x/x11_util.h.orig 2024-02-23 21:04:38 UTC -+++ ui/base/x/x11_util.h -@@ -256,6 +256,10 @@ COMPONENT_EXPORT(UI_BASE_X) bool IsVulkanSurfaceSuppor - COMPONENT_EXPORT(UI_BASE_X) - gfx::ImageSkia GetNativeWindowIcon(intptr_t target_window_id); - -+// Returns the ICCProfile corresponding to |monitor| using XGetWindowProperty. -+COMPONENT_EXPORT(UI_BASE_X) -+gfx::ICCProfile GetICCProfileForMonitor(int monitor); -+ - } // namespace ui - - #endif // UI_BASE_X_X11_UTIL_H_ diff --git a/www/chromium/files/patch-ui_color_color__id.h b/www/chromium/files/patch-ui_color_color__id.h index d580b0aea026..4d1c784b2f4f 100644 --- a/www/chromium/files/patch-ui_color_color__id.h +++ b/www/chromium/files/patch-ui_color_color__id.h @@ -1,11 +1,11 @@ ---- ui/color/color_id.h.orig 2024-03-22 08:19:40 UTC +--- ui/color/color_id.h.orig 2025-07-02 06:08:04 UTC +++ ui/color/color_id.h -@@ -611,7 +611,7 @@ - E_CPONLY(kColorNativeColor6) \ - E_CPONLY(kColorNativeBaseColor) \ - E_CPONLY(kColorNativeSecondaryColor) +@@ -648,7 +648,7 @@ + E_CPONLY(kColorCrosSysPositive) \ + E_CPONLY(kColorCrosSysComplementVariant) \ + E_CPONLY(kColorCrosSysInputFieldOnBase) -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #define PLATFORM_SPECIFIC_COLOR_IDS \ - E_CPONLY(kColorNativeButtonBorder)\ + E_CPONLY(kColorNativeBoxFrameBorder)\ E_CPONLY(kColorNativeHeaderButtonBorderActive) \ diff --git a/www/chromium/files/patch-ui_color_color__provider__utils.cc b/www/chromium/files/patch-ui_color_color__provider__utils.cc index fb6d892016ed..09548c17aec6 100644 --- a/www/chromium/files/patch-ui_color_color__provider__utils.cc +++ b/www/chromium/files/patch-ui_color_color__provider__utils.cc @@ -1,6 +1,6 @@ ---- ui/color/color_provider_utils.cc.orig 2024-04-19 13:02:56 UTC +--- ui/color/color_provider_utils.cc.orig 2025-05-28 14:55:43 UTC +++ ui/color/color_provider_utils.cc -@@ -200,7 +200,7 @@ base::StringPiece SystemThemeName(ui::SystemTheme syst +@@ -194,7 +194,7 @@ std::string_view SystemThemeName(ui::SystemTheme syste switch (system_theme) { case ui::SystemTheme::kDefault: return "kDefault"; diff --git a/www/chromium/files/patch-ui_compositor_compositor.cc b/www/chromium/files/patch-ui_compositor_compositor.cc index fbd6a8157e5f..ec5a76119066 100644 --- a/www/chromium/files/patch-ui_compositor_compositor.cc +++ b/www/chromium/files/patch-ui_compositor_compositor.cc @@ -1,11 +1,11 @@ ---- ui/compositor/compositor.cc.orig 2024-04-19 13:02:56 UTC +--- ui/compositor/compositor.cc.orig 2025-07-02 06:08:04 UTC +++ ui/compositor/compositor.cc -@@ -910,7 +910,7 @@ void Compositor::OnResume() { +@@ -979,7 +979,7 @@ void Compositor::OnResume() { obs.ResetIfActive(); } -#if BUILDFLAG(IS_LINUX) && BUILDFLAG(IS_OZONE_X11) +#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(IS_OZONE_X11) void Compositor::OnCompleteSwapWithNewSize(const gfx::Size& size) { - for (auto& observer : observer_list_) - observer.OnCompositingCompleteSwapWithNewSize(this, size); + observer_list_.Notify( + &CompositorObserver::OnCompositingCompleteSwapWithNewSize, this, size); diff --git a/www/chromium/files/patch-ui_compositor_compositor.h b/www/chromium/files/patch-ui_compositor_compositor.h index 4ca7bf54f599..45784c46cc33 100644 --- a/www/chromium/files/patch-ui_compositor_compositor.h +++ b/www/chromium/files/patch-ui_compositor_compositor.h @@ -1,6 +1,6 @@ ---- ui/compositor/compositor.h.orig 2024-04-19 13:02:56 UTC +--- ui/compositor/compositor.h.orig 2025-05-05 10:57:53 UTC +++ ui/compositor/compositor.h -@@ -455,7 +455,7 @@ class COMPOSITOR_EXPORT Compositor : public base::Powe +@@ -463,7 +463,7 @@ class COMPOSITOR_EXPORT Compositor : public base::Powe // base::PowerSuspendObserver: void OnResume() override; diff --git a/www/chromium/files/patch-ui_compositor_compositor__observer.h b/www/chromium/files/patch-ui_compositor_compositor__observer.h index 71087c757b0e..ee873852efd6 100644 --- a/www/chromium/files/patch-ui_compositor_compositor__observer.h +++ b/www/chromium/files/patch-ui_compositor_compositor__observer.h @@ -1,6 +1,6 @@ ---- ui/compositor/compositor_observer.h.orig 2024-02-23 21:04:38 UTC +--- ui/compositor/compositor_observer.h.orig 2025-02-19 07:43:18 UTC +++ ui/compositor/compositor_observer.h -@@ -46,7 +46,7 @@ class COMPOSITOR_EXPORT CompositorObserver { +@@ -56,7 +56,7 @@ class COMPOSITOR_EXPORT CompositorObserver { // Called when a child of the compositor is resizing. virtual void OnCompositingChildResizing(Compositor* compositor) {} diff --git a/www/chromium/files/patch-ui_display_screen.cc b/www/chromium/files/patch-ui_display_screen.cc index c113f555157e..302f4f997952 100644 --- a/www/chromium/files/patch-ui_display_screen.cc +++ b/www/chromium/files/patch-ui_display_screen.cc @@ -1,11 +1,11 @@ ---- ui/display/screen.cc.orig 2022-10-24 13:33:33 UTC +--- ui/display/screen.cc.orig 2025-05-28 14:55:43 UTC +++ ui/display/screen.cc -@@ -85,7 +85,7 @@ void Screen::SetDisplayForNewWindows(int64_t display_i +@@ -82,7 +82,7 @@ void Screen::SetDisplayForNewWindows(int64_t display_i display_id_for_new_windows_ = display_id; } --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) Screen::ScreenSaverSuspender::~ScreenSaverSuspender() = default; std::unique_ptr<Screen::ScreenSaverSuspender> Screen::SuspendScreenSaver() { diff --git a/www/chromium/files/patch-ui_display_screen.h b/www/chromium/files/patch-ui_display_screen.h index b7c63eb38143..1bd4c187feb2 100644 --- a/www/chromium/files/patch-ui_display_screen.h +++ b/www/chromium/files/patch-ui_display_screen.h @@ -1,20 +1,20 @@ ---- ui/display/screen.h.orig 2024-01-30 07:53:34 UTC +--- ui/display/screen.h.orig 2025-05-05 10:57:53 UTC +++ ui/display/screen.h -@@ -131,7 +131,7 @@ class DISPLAY_EXPORT Screen { +@@ -140,7 +140,7 @@ class DISPLAY_EXPORT Screen { // (both of which may or may not be `nearest_id`). display::ScreenInfos GetScreenInfosNearestDisplay(int64_t nearest_id) const; --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Object which suspends the platform-specific screensaver for the duration of // its existence. class ScreenSaverSuspender { -@@ -231,7 +231,7 @@ class DISPLAY_EXPORT Screen { +@@ -246,7 +246,7 @@ class DISPLAY_EXPORT Screen { int64_t display_id_for_new_windows_; int64_t scoped_display_id_for_new_windows_ = display::kInvalidDisplayId; --#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) uint32_t screen_saver_suspension_count_ = 0; - #endif // BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_LINUX) + #endif // BUILDFLAG(IS_LINUX) }; diff --git a/www/chromium/files/patch-ui_events_devices_x11_device__data__manager__x11.cc b/www/chromium/files/patch-ui_events_devices_x11_device__data__manager__x11.cc index 2afd5a0b00fb..7db69e95c85e 100644 --- a/www/chromium/files/patch-ui_events_devices_x11_device__data__manager__x11.cc +++ b/www/chromium/files/patch-ui_events_devices_x11_device__data__manager__x11.cc @@ -1,6 +1,6 @@ ---- ui/events/devices/x11/device_data_manager_x11.cc.orig 2024-01-30 07:53:34 UTC +--- ui/events/devices/x11/device_data_manager_x11.cc.orig 2025-07-02 06:08:04 UTC +++ ui/events/devices/x11/device_data_manager_x11.cc -@@ -844,6 +844,7 @@ void DeviceDataManagerX11::SetDisabledKeyboardAllowedK +@@ -855,6 +855,7 @@ void DeviceDataManagerX11::SetDisabledKeyboardAllowedK } void DeviceDataManagerX11::DisableDevice(x11::Input::DeviceId deviceid) { diff --git a/www/chromium/files/patch-ui_events_event.cc b/www/chromium/files/patch-ui_events_event.cc index ef707428af2d..6b66f09cfb0d 100644 --- a/www/chromium/files/patch-ui_events_event.cc +++ b/www/chromium/files/patch-ui_events_event.cc @@ -1,6 +1,6 @@ ---- ui/events/event.cc.orig 2024-03-22 08:19:40 UTC +--- ui/events/event.cc.orig 2025-07-02 06:08:04 UTC +++ ui/events/event.cc -@@ -438,7 +438,7 @@ std::string LocatedEvent::ToString() const { +@@ -375,7 +375,7 @@ std::string LocatedEvent::ToString() const { MouseEvent::MouseEvent(const PlatformEvent& native_event) : LocatedEvent(native_event), changed_button_flags_(GetChangedMouseButtonFlagsFromNative(native_event)), @@ -9,7 +9,7 @@ movement_(GetMouseMovementFromNative(native_event)), #endif pointer_details_(GetMousePointerDetailsFromNative(native_event)) { -@@ -688,7 +688,7 @@ std::unique_ptr<Event> MouseWheelEvent::Clone() const +@@ -631,7 +631,7 @@ std::unique_ptr<Event> MouseWheelEvent::Clone() const return std::make_unique<MouseWheelEvent>(*this); } @@ -18,9 +18,9 @@ // This value matches Windows, Fuchsia WHEEL_DELTA, and (roughly) Firefox on // Linux. // static -@@ -948,7 +948,7 @@ void KeyEvent::InitializeNative() { - if (synthesize_key_repeat_enabled_ && IsRepeated(GetLastKeyEvent())) +@@ -894,7 +894,7 @@ void KeyEvent::InitializeNative() { SetFlags(flags() | EF_IS_REPEAT); + } -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.cc b/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.cc index e3ac5296cccb..bf85a0e0958e 100644 --- a/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.cc +++ b/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.cc @@ -1,6 +1,6 @@ ---- ui/events/keycodes/dom/keycode_converter.cc.orig 2024-02-23 21:04:38 UTC +--- ui/events/keycodes/dom/keycode_converter.cc.orig 2024-09-30 07:45:04 UTC +++ ui/events/keycodes/dom/keycode_converter.cc -@@ -11,7 +11,7 @@ +@@ -18,7 +18,7 @@ #include "ui/events/keycodes/dom/dom_code.h" #include "ui/events/keycodes/dom/dom_key.h" @@ -9,7 +9,7 @@ #include <linux/input.h> #endif -@@ -24,7 +24,7 @@ namespace { +@@ -31,7 +31,7 @@ namespace { #if BUILDFLAG(IS_WIN) #define DOM_CODE(usb, evdev, xkb, win, mac, code, id) \ { usb, win, code } @@ -18,7 +18,7 @@ #define DOM_CODE(usb, evdev, xkb, win, mac, code, id) \ { usb, xkb, code } #elif BUILDFLAG(IS_APPLE) -@@ -63,7 +63,7 @@ struct DomKeyMapEntry { +@@ -70,7 +70,7 @@ struct DomKeyMapEntry { #undef DOM_KEY_UNI #undef DOM_KEY_MAP_DECLARATION_END @@ -27,7 +27,7 @@ // The offset between XKB Keycode and evdev code. constexpr int kXkbKeycodeOffset = 8; -@@ -184,7 +184,7 @@ int KeycodeConverter::DomCodeToNativeKeycode(DomCode c +@@ -191,7 +191,7 @@ int KeycodeConverter::DomCodeToNativeKeycode(DomCode c return UsbKeycodeToNativeKeycode(static_cast<uint32_t>(code)); } diff --git a/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.h b/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.h index 2570b8068bdd..0fec07e61fd1 100644 --- a/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.h +++ b/www/chromium/files/patch-ui_events_keycodes_dom_keycode__converter.h @@ -1,6 +1,6 @@ ---- ui/events/keycodes/dom/keycode_converter.h.orig 2024-02-23 21:04:38 UTC +--- ui/events/keycodes/dom/keycode_converter.h.orig 2024-06-17 12:56:06 UTC +++ ui/events/keycodes/dom/keycode_converter.h -@@ -63,7 +63,7 @@ class KeycodeConverter { +@@ -64,7 +64,7 @@ class KeycodeConverter { // Convert a DomCode into a native keycode. static int DomCodeToNativeKeycode(DomCode code); diff --git a/www/chromium/files/patch-ui_gfx_BUILD.gn b/www/chromium/files/patch-ui_gfx_BUILD.gn index 125041728f71..5032d31cfec6 100644 --- a/www/chromium/files/patch-ui_gfx_BUILD.gn +++ b/www/chromium/files/patch-ui_gfx_BUILD.gn @@ -1,4 +1,4 @@ ---- ui/gfx/BUILD.gn.orig 2024-02-23 21:04:38 UTC +--- ui/gfx/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/BUILD.gn @@ -664,7 +664,7 @@ source_set("memory_buffer_sources") { deps += [ "//build/config/linux/libdrm" ] diff --git a/www/chromium/files/patch-ui_gfx_canvas__skia.cc b/www/chromium/files/patch-ui_gfx_canvas__skia.cc index 9481b44bdab6..0db881085f16 100644 --- a/www/chromium/files/patch-ui_gfx_canvas__skia.cc +++ b/www/chromium/files/patch-ui_gfx_canvas__skia.cc @@ -1,6 +1,6 @@ ---- ui/gfx/canvas_skia.cc.orig 2024-02-23 21:04:38 UTC +--- ui/gfx/canvas_skia.cc.orig 2025-04-04 08:52:13 UTC +++ ui/gfx/canvas_skia.cc -@@ -213,7 +213,7 @@ void Canvas::DrawStringRectWithFlags(const std::u16str +@@ -219,7 +219,7 @@ void Canvas::DrawStringRectWithFlags(std::u16string_vi Range range = StripAcceleratorChars(flags, &adjusted_text); bool elide_text = ((flags & NO_ELLIPSIS) == 0); diff --git a/www/chromium/files/patch-ui_gfx_codec_png__codec.cc b/www/chromium/files/patch-ui_gfx_codec_png__codec.cc deleted file mode 100644 index 1f47a3f99d25..000000000000 --- a/www/chromium/files/patch-ui_gfx_codec_png__codec.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/gfx/codec/png_codec.cc.orig 2023-10-11 18:22:24 UTC -+++ ui/gfx/codec/png_codec.cc -@@ -12,7 +12,7 @@ - #include "base/metrics/histogram_macros.h" - #include "base/notreached.h" - #include "base/strings/string_util.h" --#include "third_party/libpng/png.h" -+#include <png.h> - #include "third_party/skia/include/core/SkBitmap.h" - #include "third_party/skia/include/core/SkColorPriv.h" - #include "third_party/skia/include/core/SkUnPreMultiply.h" diff --git a/www/chromium/files/patch-ui_gfx_font__fallback__linux.cc b/www/chromium/files/patch-ui_gfx_font__fallback__linux.cc index a5f41a7d9b73..cb92aba46c15 100644 --- a/www/chromium/files/patch-ui_gfx_font__fallback__linux.cc +++ b/www/chromium/files/patch-ui_gfx_font__fallback__linux.cc @@ -1,6 +1,6 @@ ---- ui/gfx/font_fallback_linux.cc.orig 2024-01-30 07:53:34 UTC +--- ui/gfx/font_fallback_linux.cc.orig 2024-09-30 07:45:04 UTC +++ ui/gfx/font_fallback_linux.cc -@@ -27,6 +27,8 @@ +@@ -32,6 +32,8 @@ #include "ui/gfx/linux/fontconfig_util.h" #include "ui/gfx/platform_font.h" diff --git a/www/chromium/files/patch-ui_gfx_font__render__params.h b/www/chromium/files/patch-ui_gfx_font__render__params.h index b61b423ea238..251368a87e95 100644 --- a/www/chromium/files/patch-ui_gfx_font__render__params.h +++ b/www/chromium/files/patch-ui_gfx_font__render__params.h @@ -1,20 +1,20 @@ ---- ui/gfx/font_render_params.h.orig 2024-04-19 13:02:56 UTC +--- ui/gfx/font_render_params.h.orig 2025-01-15 09:18:26 UTC +++ ui/gfx/font_render_params.h -@@ -115,7 +115,7 @@ GFX_EXPORT FontRenderParams GetFontRenderParams( - const FontRenderParamsQuery& query, - std::string* family_out); +@@ -115,7 +115,7 @@ COMPONENT_EXPORT(GFX) + FontRenderParams GetFontRenderParams(const FontRenderParamsQuery& query, + std::string* family_out); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) // Clears GetFontRenderParams()'s cache. Intended to be called by tests that are // changing Fontconfig's configuration. - GFX_EXPORT void ClearFontRenderParamsCacheForTest(); -@@ -125,7 +125,7 @@ GFX_EXPORT void ClearFontRenderParamsCacheForTest(); - GFX_EXPORT float GetFontRenderParamsDeviceScaleFactor(); + COMPONENT_EXPORT(GFX) void ClearFontRenderParamsCacheForTest(); +@@ -125,7 +125,7 @@ COMPONENT_EXPORT(GFX) void ClearFontRenderParamsCacheF + COMPONENT_EXPORT(GFX) float GetFontRenderParamsDeviceScaleFactor(); #if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || \ - BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) + BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) // Sets the device scale factor for FontRenderParams to decide // if it should enable subpixel positioning. - GFX_EXPORT void SetFontRenderParamsDeviceScaleFactor( + COMPONENT_EXPORT(GFX) diff --git a/www/chromium/files/patch-ui_gfx_font__render__params__linux.cc b/www/chromium/files/patch-ui_gfx_font__render__params__linux.cc index b54ded640f65..f0e4a6f9c62c 100644 --- a/www/chromium/files/patch-ui_gfx_font__render__params__linux.cc +++ b/www/chromium/files/patch-ui_gfx_font__render__params__linux.cc @@ -1,6 +1,6 @@ ---- ui/gfx/font_render_params_linux.cc.orig 2024-03-22 08:19:40 UTC +--- ui/gfx/font_render_params_linux.cc.orig 2025-03-05 08:14:56 UTC +++ ui/gfx/font_render_params_linux.cc -@@ -25,7 +25,7 @@ +@@ -24,7 +24,7 @@ #include "ui/gfx/linux/fontconfig_util.h" #include "ui/gfx/switches.h" @@ -9,7 +9,7 @@ #include "ui/linux/linux_ui.h" #endif -@@ -212,7 +212,7 @@ FontRenderParams GetFontRenderParams(const FontRenderP +@@ -222,7 +222,7 @@ FontRenderParams GetFontRenderParams(const FontRenderP // Start with the delegate's settings, but let Fontconfig have the final say. FontRenderParams params; diff --git a/www/chromium/files/patch-ui_gfx_gpu__extra__info.h b/www/chromium/files/patch-ui_gfx_gpu__extra__info.h new file mode 100644 index 000000000000..f95dc9acbdf7 --- /dev/null +++ b/www/chromium/files/patch-ui_gfx_gpu__extra__info.h @@ -0,0 +1,11 @@ +--- ui/gfx/gpu_extra_info.h.orig 2025-07-02 06:08:04 UTC ++++ ui/gfx/gpu_extra_info.h +@@ -51,7 +51,7 @@ struct COMPONENT_EXPORT(GFX) GpuExtraInfo { + std::vector<gfx::BufferUsageAndFormat> gpu_memory_buffer_support_x11; + #endif // BUILDFLAG(IS_OZONE_X11) + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + bool is_gmb_nv12_supported = false; + #endif + }; diff --git a/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.cc b/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.cc index 5a4d38022d21..be1ef9dbe71e 100644 --- a/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.cc +++ b/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.cc @@ -1,11 +1,20 @@ ---- ui/gfx/gpu_memory_buffer.cc.orig 2023-04-05 11:05:06 UTC +--- ui/gfx/gpu_memory_buffer.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/gpu_memory_buffer.cc -@@ -54,7 +54,7 @@ GpuMemoryBufferHandle GpuMemoryBufferHandle::Clone() c - handle.region = region.Duplicate(); +@@ -100,7 +100,7 @@ GpuMemoryBufferHandle::GpuMemoryBufferHandle(DXGIHandl + } + #endif + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + GpuMemoryBufferHandle::GpuMemoryBufferHandle( + NativePixmapHandle native_pixmap_handle) + : type(GpuMemoryBufferType::NATIVE_PIXMAP), +@@ -138,7 +138,7 @@ GpuMemoryBufferHandle GpuMemoryBufferHandle::Clone() c + handle.id = id; handle.offset = offset; handle.stride = stride; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - handle.native_pixmap_handle = CloneHandleForIPC(native_pixmap_handle); + handle.native_pixmap_handle_ = CloneHandleForIPC(native_pixmap_handle_); #elif BUILDFLAG(IS_APPLE) handle.io_surface = io_surface; diff --git a/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.h b/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.h index 5440650ab84a..cd57adab03c9 100644 --- a/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.h +++ b/www/chromium/files/patch-ui_gfx_gpu__memory__buffer.h @@ -1,20 +1,47 @@ ---- ui/gfx/gpu_memory_buffer.h.orig 2024-03-22 08:19:40 UTC +--- ui/gfx/gpu_memory_buffer.h.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/gpu_memory_buffer.h -@@ -15,7 +15,7 @@ +@@ -17,7 +17,7 @@ + #include "ui/gfx/generic_shared_memory_id.h" #include "ui/gfx/geometry/rect.h" - #include "ui/gfx/gfx_export.h" -#if BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "ui/gfx/native_pixmap_handle.h" #elif BUILDFLAG(IS_APPLE) #include "ui/gfx/mac/io_surface.h" -@@ -76,7 +76,7 @@ struct GFX_EXPORT GpuMemoryBufferHandle { - base::UnsafeSharedMemoryRegion region; - uint32_t offset = 0; - uint32_t stride = 0; +@@ -58,7 +58,7 @@ enum GpuMemoryBufferType { + #if BUILDFLAG(IS_APPLE) + IO_SURFACE_BUFFER, + #endif -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) - NativePixmapHandle native_pixmap_handle; - #elif BUILDFLAG(IS_APPLE) - ScopedIOSurface io_surface; + NATIVE_PIXMAP, + #endif + #if BUILDFLAG(IS_WIN) +@@ -154,7 +154,7 @@ struct COMPONENT_EXPORT(GFX) GpuMemoryBufferHandle { + #if BUILDFLAG(IS_WIN) + explicit GpuMemoryBufferHandle(DXGIHandle handle); + #endif +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + explicit GpuMemoryBufferHandle(gfx::NativePixmapHandle native_pixmap_handle); + #endif + #if BUILDFLAG(IS_ANDROID) +@@ -196,7 +196,7 @@ struct COMPONENT_EXPORT(GFX) GpuMemoryBufferHandle { + return std::move(region_); + } + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + const NativePixmapHandle& native_pixmap_handle() const& { + CHECK_EQ(type, NATIVE_PIXMAP); + return native_pixmap_handle_; +@@ -240,7 +240,7 @@ struct COMPONENT_EXPORT(GFX) GpuMemoryBufferHandle { + // goal is to make `this` an encapsulated class. + base::UnsafeSharedMemoryRegion region_; + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_FUCHSIA) || BUILDFLAG(IS_BSD) + NativePixmapHandle native_pixmap_handle_; + #endif + diff --git a/www/chromium/files/patch-ui_gfx_linux_gbm__wrapper.cc b/www/chromium/files/patch-ui_gfx_linux_gbm__wrapper.cc index d3aeaf960fc3..c0d23d0467bb 100644 --- a/www/chromium/files/patch-ui_gfx_linux_gbm__wrapper.cc +++ b/www/chromium/files/patch-ui_gfx_linux_gbm__wrapper.cc @@ -1,6 +1,6 @@ ---- ui/gfx/linux/gbm_wrapper.cc.orig 2024-04-19 13:02:56 UTC +--- ui/gfx/linux/gbm_wrapper.cc.orig 2025-02-19 07:43:18 UTC +++ ui/gfx/linux/gbm_wrapper.cc -@@ -313,7 +313,7 @@ class Device final : public ui::GbmDevice { +@@ -318,7 +318,7 @@ class Device final : public ui::GbmDevice { // of 1x1 BOs which are destroyed before creating the final BO creation used // to instantiate the returned GbmBuffer. gfx::Size size_for_verification = diff --git a/www/chromium/files/patch-ui_gfx_mojom_buffer__types__mojom__traits.cc b/www/chromium/files/patch-ui_gfx_mojom_buffer__types__mojom__traits.cc deleted file mode 100644 index f8151c2dd6ee..000000000000 --- a/www/chromium/files/patch-ui_gfx_mojom_buffer__types__mojom__traits.cc +++ /dev/null @@ -1,20 +0,0 @@ ---- ui/gfx/mojom/buffer_types_mojom_traits.cc.orig 2023-01-11 09:17:16 UTC -+++ ui/gfx/mojom/buffer_types_mojom_traits.cc -@@ -33,7 +33,7 @@ gfx::mojom::GpuMemoryBufferPlatformHandlePtr StructTra - return gfx::mojom::GpuMemoryBufferPlatformHandle::NewSharedMemoryHandle( - std::move(handle.region)); - case gfx::NATIVE_PIXMAP: --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) - return gfx::mojom::GpuMemoryBufferPlatformHandle::NewNativePixmapHandle( - std::move(handle.native_pixmap_handle)); - #else -@@ -115,7 +115,7 @@ bool StructTraits<gfx::mojom::GpuMemoryBufferHandleDat - out->type = gfx::SHARED_MEMORY_BUFFER; - out->region = std::move(platform_handle->get_shared_memory_handle()); - return true; --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) - case gfx::mojom::GpuMemoryBufferPlatformHandleDataView::Tag:: - kNativePixmapHandle: - out->type = gfx::NATIVE_PIXMAP; diff --git a/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.cc b/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.cc index 0182f2ea879b..43d427ea7d12 100644 --- a/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.cc +++ b/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.cc @@ -1,8 +1,17 @@ ---- ui/gfx/mojom/native_handle_types_mojom_traits.cc.orig 2023-01-11 09:17:16 UTC +--- ui/gfx/mojom/native_handle_types_mojom_traits.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/mojom/native_handle_types_mojom_traits.cc -@@ -8,11 +8,11 @@ +@@ -14,7 +14,7 @@ + #include "ui/gfx/mac/io_surface.h" + #endif // BUILDFLAG(IS_APPLE) - namespace mojo { +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) + #include "ui/gfx/native_pixmap_handle.h" + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) + +@@ -80,11 +80,11 @@ bool StructTraits<gfx::mojom::AHardwareBufferHandleDat + } + #endif // BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) @@ -14,7 +23,7 @@ return mojo::PlatformHandle(std::move(plane.fd)); #elif BUILDFLAG(IS_FUCHSIA) return mojo::PlatformHandle(std::move(plane.vmo)); -@@ -28,7 +28,7 @@ bool StructTraits< +@@ -100,7 +100,7 @@ bool StructTraits< out->size = data.size(); mojo::PlatformHandle handle = data.TakeBufferHandle(); @@ -23,7 +32,7 @@ if (!handle.is_fd()) return false; out->fd = handle.TakeFD(); -@@ -54,7 +54,7 @@ bool StructTraits< +@@ -126,7 +126,7 @@ bool StructTraits< gfx::mojom::NativePixmapHandleDataView, gfx::NativePixmapHandle>::Read(gfx::mojom::NativePixmapHandleDataView data, gfx::NativePixmapHandle* out) { @@ -32,3 +41,21 @@ out->modifier = data.modifier(); out->supports_zero_copy_webgpu_import = data.supports_zero_copy_webgpu_import(); +@@ -187,7 +187,7 @@ gfx::mojom::GpuMemoryBufferPlatformHandleDataView::Tag + case gfx::IO_SURFACE_BUFFER: + return Tag::kMachPort; + #endif // BUILDFLAG(IS_APPLE) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) + case gfx::NATIVE_PIXMAP: + return Tag::kNativePixmapHandle; + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) +@@ -251,7 +251,7 @@ bool UnionTraits<gfx::mojom::GpuMemoryBufferPlatformHa + } + return true; + #endif // BUILDFLAG(IS_APPLE) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) + case Tag::kNativePixmapHandle: + handle->type = gfx::NATIVE_PIXMAP; + return data.ReadNativePixmapHandle(&handle->native_pixmap_handle_); diff --git a/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.h b/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.h index d52fd6337cd3..8552d326e8c1 100644 --- a/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.h +++ b/www/chromium/files/patch-ui_gfx_mojom_native__handle__types__mojom__traits.h @@ -1,24 +1,24 @@ ---- ui/gfx/mojom/native_handle_types_mojom_traits.h.orig 2024-03-22 08:19:40 UTC +--- ui/gfx/mojom/native_handle_types_mojom_traits.h.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/mojom/native_handle_types_mojom_traits.h -@@ -16,7 +16,7 @@ - #include "mojo/public/cpp/system/platform_handle.h" +@@ -18,7 +18,7 @@ + #include "ui/gfx/gpu_memory_buffer.h" #include "ui/gfx/mojom/native_handle_types.mojom-shared.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) #include "ui/gfx/native_pixmap_handle.h" - #endif - -@@ -26,7 +26,7 @@ + #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) - namespace mojo { +@@ -46,7 +46,7 @@ struct COMPONENT_EXPORT(GFX_NATIVE_HANDLE_TYPES_SHARED + }; + #endif // BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) template <> struct COMPONENT_EXPORT(GFX_NATIVE_HANDLE_TYPES_SHARED_MOJOM_TRAITS) StructTraits<gfx::mojom::NativePixmapPlaneDataView, -@@ -54,13 +54,13 @@ struct COMPONENT_EXPORT(GFX_NATIVE_HANDLE_TYPES_SHARED +@@ -74,13 +74,13 @@ struct COMPONENT_EXPORT(GFX_NATIVE_HANDLE_TYPES_SHARED return pixmap_handle.planes; } @@ -34,3 +34,12 @@ static bool supports_zero_copy_webgpu_import( const gfx::NativePixmapHandle& pixmap_handle) { return pixmap_handle.supports_zero_copy_webgpu_import; +@@ -159,7 +159,7 @@ struct COMPONENT_EXPORT(GFX_NATIVE_HANDLE_TYPES_SHARED + static PlatformHandle mach_port(gfx::GpuMemoryBufferHandle& handle); + #endif // BUILDFLAG(IS_APPLE) + +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_OZONE) || BUILDFLAG(IS_BSD) + static gfx::NativePixmapHandle& native_pixmap_handle( + gfx::GpuMemoryBufferHandle& handle) { + return handle.native_pixmap_handle_; diff --git a/www/chromium/files/patch-ui_gfx_native__pixmap__handle.h b/www/chromium/files/patch-ui_gfx_native__pixmap__handle.h index fb54636a86b3..f4f3f4ee150e 100644 --- a/www/chromium/files/patch-ui_gfx_native__pixmap__handle.h +++ b/www/chromium/files/patch-ui_gfx_native__pixmap__handle.h @@ -1,15 +1,15 @@ ---- ui/gfx/native_pixmap_handle.h.orig 2023-01-11 09:17:16 UTC +--- ui/gfx/native_pixmap_handle.h.orig 2025-01-15 09:18:26 UTC +++ ui/gfx/native_pixmap_handle.h @@ -14,7 +14,7 @@ + #include "build/build_config.h" #include "ui/gfx/buffer_types.h" - #include "ui/gfx/gfx_export.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "base/files/scoped_file.h" #endif -@@ -34,7 +34,7 @@ struct GFX_EXPORT NativePixmapPlane { +@@ -34,7 +34,7 @@ struct COMPONENT_EXPORT(GFX) NativePixmapPlane { NativePixmapPlane(int stride, int offset, uint64_t size @@ -18,7 +18,7 @@ , base::ScopedFD fd #elif BUILDFLAG(IS_FUCHSIA) -@@ -55,7 +55,7 @@ struct GFX_EXPORT NativePixmapPlane { +@@ -55,7 +55,7 @@ struct COMPONENT_EXPORT(GFX) NativePixmapPlane { // This is necessary to map the buffers. uint64_t size; @@ -27,7 +27,7 @@ // File descriptor for the underlying memory object (usually dmabuf). base::ScopedFD fd; #elif BUILDFLAG(IS_FUCHSIA) -@@ -78,7 +78,7 @@ struct GFX_EXPORT NativePixmapHandle { +@@ -78,7 +78,7 @@ struct COMPONENT_EXPORT(GFX) NativePixmapHandle { std::vector<NativePixmapPlane> planes; diff --git a/www/chromium/files/patch-ui_gfx_native__widget__types.h b/www/chromium/files/patch-ui_gfx_native__widget__types.h index 5e9219df91d6..3a8f5d86f936 100644 --- a/www/chromium/files/patch-ui_gfx_native__widget__types.h +++ b/www/chromium/files/patch-ui_gfx_native__widget__types.h @@ -1,20 +1,20 @@ ---- ui/gfx/native_widget_types.h.orig 2024-02-23 21:04:38 UTC +--- ui/gfx/native_widget_types.h.orig 2025-05-28 14:55:43 UTC +++ ui/gfx/native_widget_types.h -@@ -104,7 +104,7 @@ class SkBitmap; +@@ -102,7 +102,7 @@ class ViewAndroid; + #endif + class SkBitmap; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) extern "C" { struct _AtkObject; using AtkObject = struct _AtkObject; -@@ -220,7 +220,7 @@ using NativeViewAccessible = struct objc_object*; - #endif - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) - // Linux doesn't have a native font type. +@@ -186,7 +186,7 @@ using NativeViewAccessible = IAccessible*; + using NativeViewAccessible = base::apple::OwnedNSObject; + #elif BUILDFLAG(IS_MAC) + using NativeViewAccessible = base::apple::OwnedNSAccessibility; +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Linux doesn't have a native accessibility type. using NativeViewAccessible = AtkObject*; #else diff --git a/www/chromium/files/patch-ui_gfx_platform__font__skia.cc b/www/chromium/files/patch-ui_gfx_platform__font__skia.cc index c7045886788e..1d867ecf3822 100644 --- a/www/chromium/files/patch-ui_gfx_platform__font__skia.cc +++ b/www/chromium/files/patch-ui_gfx_platform__font__skia.cc @@ -1,6 +1,6 @@ ---- ui/gfx/platform_font_skia.cc.orig 2024-03-22 08:19:40 UTC +--- ui/gfx/platform_font_skia.cc.orig 2024-08-26 12:06:38 UTC +++ ui/gfx/platform_font_skia.cc -@@ -30,7 +30,7 @@ +@@ -29,7 +29,7 @@ #include "ui/gfx/system_fonts_win.h" #endif @@ -9,7 +9,7 @@ #include "ui/linux/linux_ui.h" #endif -@@ -168,7 +168,7 @@ void PlatformFontSkia::EnsuresDefaultFontIsInitialized +@@ -167,7 +167,7 @@ void PlatformFontSkia::EnsuresDefaultFontIsInitialized weight = system_font.GetWeight(); #endif // BUILDFLAG(IS_WIN) diff --git a/www/chromium/files/patch-ui_gfx_render__text__api__fuzzer.cc b/www/chromium/files/patch-ui_gfx_render__text__api__fuzzer.cc index ae9ccd8bf707..91079ce0598c 100644 --- a/www/chromium/files/patch-ui_gfx_render__text__api__fuzzer.cc +++ b/www/chromium/files/patch-ui_gfx_render__text__api__fuzzer.cc @@ -1,6 +1,6 @@ ---- ui/gfx/render_text_api_fuzzer.cc.orig 2022-08-31 12:19:35 UTC +--- ui/gfx/render_text_api_fuzzer.cc.orig 2025-01-15 09:18:26 UTC +++ ui/gfx/render_text_api_fuzzer.cc -@@ -20,7 +20,7 @@ +@@ -19,7 +19,7 @@ #include "ui/gfx/font_util.h" #include "ui/gfx/render_text.h" @@ -9,7 +9,7 @@ #include "third_party/test_fonts/fontconfig/fontconfig_util_linux.h" #endif -@@ -47,7 +47,7 @@ struct Environment { +@@ -46,7 +46,7 @@ struct Environment { CHECK(base::i18n::InitializeICU()); diff --git a/www/chromium/files/patch-ui_gfx_render__text__fuzzer.cc b/www/chromium/files/patch-ui_gfx_render__text__fuzzer.cc index ca6343b440e5..97a711a34209 100644 --- a/www/chromium/files/patch-ui_gfx_render__text__fuzzer.cc +++ b/www/chromium/files/patch-ui_gfx_render__text__fuzzer.cc @@ -1,15 +1,15 @@ ---- ui/gfx/render_text_fuzzer.cc.orig 2022-08-31 12:19:35 UTC +--- ui/gfx/render_text_fuzzer.cc.orig 2024-06-17 12:56:06 UTC +++ ui/gfx/render_text_fuzzer.cc -@@ -14,7 +14,7 @@ +@@ -17,7 +17,7 @@ + #include "ui/gfx/canvas.h" #include "ui/gfx/font_util.h" - #include "ui/gfx/render_text.h" -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) #include "third_party/test_fonts/fontconfig/fontconfig_util_linux.h" #endif -@@ -37,7 +37,7 @@ struct Environment { +@@ -40,7 +40,7 @@ struct Environment { CHECK(base::i18n::InitializeICU()); diff --git a/www/chromium/files/patch-ui_gfx_switches.cc b/www/chromium/files/patch-ui_gfx_switches.cc index dbbc0a733f73..87e6158a8e7f 100644 --- a/www/chromium/files/patch-ui_gfx_switches.cc +++ b/www/chromium/files/patch-ui_gfx_switches.cc @@ -1,8 +1,8 @@ ---- ui/gfx/switches.cc.orig 2024-04-19 13:02:56 UTC +--- ui/gfx/switches.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/switches.cc -@@ -32,7 +32,7 @@ const char kForcePrefersNoReducedMotion[] = "force-pre - // Run in headless mode, i.e., without a UI or display server dependencies. - const char kHeadless[] = "headless"; +@@ -36,7 +36,7 @@ const char kHeadless[] = "headless"; + // See //components/headless/screen_info/README.md for more details. + const char kScreenInfo[] = "screen-info"; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-ui_gfx_switches.h b/www/chromium/files/patch-ui_gfx_switches.h index 0022a2a90a1f..c5f12a549b44 100644 --- a/www/chromium/files/patch-ui_gfx_switches.h +++ b/www/chromium/files/patch-ui_gfx_switches.h @@ -1,8 +1,8 @@ ---- ui/gfx/switches.h.orig 2024-04-19 13:02:56 UTC +--- ui/gfx/switches.h.orig 2025-07-02 06:08:04 UTC +++ ui/gfx/switches.h -@@ -19,7 +19,7 @@ GFX_SWITCHES_EXPORT extern const char kForcePrefersRed - GFX_SWITCHES_EXPORT extern const char kForcePrefersNoReducedMotion[]; +@@ -19,7 +19,7 @@ GFX_SWITCHES_EXPORT extern const char kForcePrefersNoR GFX_SWITCHES_EXPORT extern const char kHeadless[]; + GFX_SWITCHES_EXPORT extern const char kScreenInfo[]; -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-ui_gfx_x_atom__cache.cc b/www/chromium/files/patch-ui_gfx_x_atom__cache.cc new file mode 100644 index 000000000000..3496e0180705 --- /dev/null +++ b/www/chromium/files/patch-ui_gfx_x_atom__cache.cc @@ -0,0 +1,10 @@ +--- ui/gfx/x/atom_cache.cc.orig 2025-05-05 10:57:53 UTC ++++ ui/gfx/x/atom_cache.cc +@@ -157,6 +157,7 @@ constexpr auto kAtomsToCache = std::to_array<const cha + "application/octet-stream", + "application/vnd.chromium.test", + "chromium/filename", ++ "chromium/from-privileged", + "chromium/x-bookmark-entries", + "chromium/x-browser-actions", + "chromium/x-file-system-files", diff --git a/www/chromium/files/patch-ui_gl_BUILD.gn b/www/chromium/files/patch-ui_gl_BUILD.gn index 4628783b179c..a69e2037658f 100644 --- a/www/chromium/files/patch-ui_gl_BUILD.gn +++ b/www/chromium/files/patch-ui_gl_BUILD.gn @@ -1,31 +1,6 @@ ---- ui/gl/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- ui/gl/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ ui/gl/BUILD.gn -@@ -153,8 +153,6 @@ component("gl") { - defines += [ "GPU_ENABLE_SERVICE_LOGGING" ] - } - -- include_dirs = [ "//third_party/mesa_headers" ] -- - all_dependent_configs = [ ":gl_config" ] - - public_configs = [ "//third_party/khronos:khronos_headers" ] -@@ -172,7 +170,6 @@ component("gl") { - ] - public_deps = [ - "//base", -- "//third_party/mesa_headers", - "//ui/events/platform", - "//ui/gfx", - "//ui/gfx/geometry", -@@ -379,7 +376,6 @@ component("gl") { - data_deps += [ - "//third_party/angle:libEGL", - "//third_party/angle:libGLESv2", -- "//third_party/mesa_headers", - ] - if (enable_swiftshader) { - data_deps += [ -@@ -579,7 +575,6 @@ test("gl_unittests") { +@@ -569,7 +569,6 @@ test("gl_unittests") { data_deps = [ "//testing/buildbot/filters:gl_unittests_filters", diff --git a/www/chromium/files/patch-ui_gl_gl__bindings.h b/www/chromium/files/patch-ui_gl_gl__bindings.h deleted file mode 100644 index f6a7c31765dd..000000000000 --- a/www/chromium/files/patch-ui_gl_gl__bindings.h +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/gl/gl_bindings.h.orig 2023-04-28 17:01:32 UTC -+++ ui/gl/gl_bindings.h -@@ -36,7 +36,7 @@ - #include <GL/wglext.h> - #elif BUILDFLAG(IS_MAC) - #include <OpenGL/OpenGL.h> --#elif BUILDFLAG(IS_LINUX) -+#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - using Display = struct _XDisplay; - using Bool = int; - using Status = int; diff --git a/www/chromium/files/patch-ui_gl_gl__context.cc b/www/chromium/files/patch-ui_gl_gl__context.cc index d1fae4e0a158..209d330a6420 100644 --- a/www/chromium/files/patch-ui_gl_gl__context.cc +++ b/www/chromium/files/patch-ui_gl_gl__context.cc @@ -1,6 +1,6 @@ ---- ui/gl/gl_context.cc.orig 2024-02-23 21:04:38 UTC +--- ui/gl/gl_context.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gl/gl_context.cc -@@ -472,7 +472,7 @@ bool GLContext::MakeVirtuallyCurrent( +@@ -517,7 +517,7 @@ bool GLContext::MakeVirtuallyCurrent( DCHECK(virtual_context->IsCurrent(surface)); if (switched_real_contexts || virtual_context != current_virtual_context_) { diff --git a/www/chromium/files/patch-ui_gl_gl__fence.cc b/www/chromium/files/patch-ui_gl_gl__fence.cc index eb38444ceeaf..60d5026e8ff7 100644 --- a/www/chromium/files/patch-ui_gl_gl__fence.cc +++ b/www/chromium/files/patch-ui_gl_gl__fence.cc @@ -1,9 +1,9 @@ ---- ui/gl/gl_fence.cc.orig 2023-09-13 12:11:42 UTC +--- ui/gl/gl_fence.cc.orig 2024-08-26 12:06:38 UTC +++ ui/gl/gl_fence.cc -@@ -20,7 +20,7 @@ - #endif +@@ -17,7 +17,7 @@ + #include "ui/gl/gl_surface_egl.h" + #include "ui/gl/gl_version_info.h" - #if defined(USE_EGL) -#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #define USE_GL_FENCE_ANDROID_NATIVE_FENCE_SYNC diff --git a/www/chromium/files/patch-ui_gl_gl__implementation.cc b/www/chromium/files/patch-ui_gl_gl__implementation.cc index 28bcfd3519e9..23285d47c449 100644 --- a/www/chromium/files/patch-ui_gl_gl__implementation.cc +++ b/www/chromium/files/patch-ui_gl_gl__implementation.cc @@ -1,7 +1,7 @@ ---- ui/gl/gl_implementation.cc.orig 2023-11-03 10:09:45 UTC +--- ui/gl/gl_implementation.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gl/gl_implementation.cc -@@ -276,7 +276,7 @@ GetRequestedGLImplementationFromCommandLine( - *fallback_to_software_gl = false; +@@ -287,7 +287,7 @@ GetRequestedGLImplementationFromCommandLine( + const base::CommandLine* command_line) { bool overrideUseSoftwareGL = command_line->HasSwitch(switches::kOverrideUseSoftwareGLForTests); -#if BUILDFLAG(IS_LINUX) || \ diff --git a/www/chromium/files/patch-ui_gl_gl__switches.cc b/www/chromium/files/patch-ui_gl_gl__switches.cc index 4f330b022936..3dbedfdebacb 100644 --- a/www/chromium/files/patch-ui_gl_gl__switches.cc +++ b/www/chromium/files/patch-ui_gl_gl__switches.cc @@ -1,29 +1,29 @@ ---- ui/gl/gl_switches.cc.orig 2024-04-19 13:02:56 UTC +--- ui/gl/gl_switches.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gl/gl_switches.cc -@@ -11,7 +11,7 @@ - #include "base/android/build_info.h" +@@ -15,7 +15,7 @@ #endif --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(ENABLE_VULKAN) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD)) #include <vulkan/vulkan_core.h> #include "third_party/angle/src/gpu_info_util/SystemInfo.h" // nogncheck - #endif -@@ -298,7 +298,7 @@ bool IsDefaultANGLEVulkan() { - base::android::SDK_VERSION_Q) - return false; + #endif // BUILDFLAG(ENABLE_VULKAN) && (BUILDFLAG(IS_LINUX) || +@@ -323,7 +323,7 @@ bool IsDefaultANGLEVulkan() { + } #endif // BUILDFLAG(IS_ANDROID) --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) + #if BUILDFLAG(ENABLE_VULKAN) && \ +- (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID)) ++ (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_BSD)) angle::SystemInfo system_info; - if (!angle::GetSystemInfoVulkan(&system_info)) - return false; -@@ -310,7 +310,7 @@ bool IsDefaultANGLEVulkan() { - - const auto& active_gpu = system_info.gpus[system_info.activeGPUIndex]; + { + GPU_STARTUP_TRACE_EVENT("angle::GetSystemInfoVulkan"); +@@ -392,7 +392,7 @@ bool IsDefaultANGLEVulkan() { + } + #endif // BUILDFLAG(IS_ANDROID) -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Vulkan 1.1 is required. - if (active_gpu.driverApiVersion < VK_VERSION_1_1) - return false; + // AMDVLK driver is buggy, so disable Vulkan with AMDVLK for now. + // crbug.com/1340081 + if (active_gpu.driverId == VK_DRIVER_ID_AMD_OPEN_SOURCE) diff --git a/www/chromium/files/patch-ui_gl_sync__control__vsync__provider.cc b/www/chromium/files/patch-ui_gl_sync__control__vsync__provider.cc index 539e7fbe08d7..9ba6e8687826 100644 --- a/www/chromium/files/patch-ui_gl_sync__control__vsync__provider.cc +++ b/www/chromium/files/patch-ui_gl_sync__control__vsync__provider.cc @@ -1,4 +1,4 @@ ---- ui/gl/sync_control_vsync_provider.cc.orig 2022-02-28 16:54:41 UTC +--- ui/gl/sync_control_vsync_provider.cc.orig 2024-07-30 11:12:21 UTC +++ ui/gl/sync_control_vsync_provider.cc @@ -11,7 +11,7 @@ #include "base/trace_event/trace_event.h" @@ -24,10 +24,10 @@ TRACE_EVENT0("gpu", "SyncControlVSyncProvider::GetVSyncParameters"); -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // The actual clock used for the system time returned by glXGetSyncValuesOML - // is unspecified. In practice, the clock used is likely to be either - // CLOCK_REALTIME or CLOCK_MONOTONIC, so we compare the returned time to the -@@ -159,7 +159,7 @@ bool SyncControlVSyncProvider::GetVSyncParametersIfAva + // The actual clock used for the system time returned by + // eglGetSyncValuesCHROMIUM is unspecified. In practice, the clock used is + // likely to be either CLOCK_REALTIME or CLOCK_MONOTONIC, so we compare the +@@ -160,7 +160,7 @@ bool SyncControlVSyncProvider::GetVSyncParametersIfAva } bool SyncControlVSyncProvider::SupportGetVSyncParametersIfAvailable() const { diff --git a/www/chromium/files/patch-ui_gtk_gtk__compat.cc b/www/chromium/files/patch-ui_gtk_gtk__compat.cc index 445c1e1b03ed..ab6b71868865 100644 --- a/www/chromium/files/patch-ui_gtk_gtk__compat.cc +++ b/www/chromium/files/patch-ui_gtk_gtk__compat.cc @@ -1,6 +1,6 @@ ---- ui/gtk/gtk_compat.cc.orig 2023-09-13 12:11:42 UTC +--- ui/gtk/gtk_compat.cc.orig 2025-05-05 10:57:53 UTC +++ ui/gtk/gtk_compat.cc -@@ -62,27 +62,47 @@ auto DlCast(void* symbol) { +@@ -65,27 +65,47 @@ auto DlCast(void* symbol) { } void* GetLibGio() { diff --git a/www/chromium/files/patch-ui_gtk_ime__compat__check.cc b/www/chromium/files/patch-ui_gtk_ime__compat__check.cc new file mode 100644 index 000000000000..560688ecdecc --- /dev/null +++ b/www/chromium/files/patch-ui_gtk_ime__compat__check.cc @@ -0,0 +1,21 @@ +--- ui/gtk/ime_compat_check.cc.orig 2025-07-02 06:08:04 UTC ++++ ui/gtk/ime_compat_check.cc +@@ -35,6 +35,10 @@ struct InputMethod { + + std::vector<base::FilePath> GetLibrarySearchPaths() { + std::vector<base::FilePath> search_path; ++#if BUILDFLAG(IS_BSD) ++ // We really only care about this search path. ++ search_path.emplace_back("/usr/local/lib"); ++#else + void* handle = dlopen("libc.so.6", RTLD_GLOBAL | RTLD_LAZY | RTLD_NOLOAD); + if (!handle) { + return search_path; +@@ -60,6 +64,7 @@ std::vector<base::FilePath> GetLibrarySearchPaths() { + // SAFETY: The range is bound by `serinfo.dls_cnt`. + search_path.emplace_back(UNSAFE_BUFFERS(sip->dls_serpath[j].dls_name)); + } ++#endif + + return search_path; + } diff --git a/www/chromium/files/patch-ui_gtk_printing_print__dialog__gtk.cc b/www/chromium/files/patch-ui_gtk_printing_print__dialog__gtk.cc index b48faf4e7997..e93e445851f3 100644 --- a/www/chromium/files/patch-ui_gtk_printing_print__dialog__gtk.cc +++ b/www/chromium/files/patch-ui_gtk_printing_print__dialog__gtk.cc @@ -1,11 +1,11 @@ ---- ui/gtk/printing/print_dialog_gtk.cc.orig 2023-11-03 10:09:45 UTC +--- ui/gtk/printing/print_dialog_gtk.cc.orig 2025-07-02 06:08:04 UTC +++ ui/gtk/printing/print_dialog_gtk.cc -@@ -433,7 +433,7 @@ void PrintDialogGtk::ShowDialog( +@@ -445,7 +445,7 @@ void PrintDialogGtk::ShowDialog( GtkPrintCapabilities cap = static_cast<GtkPrintCapabilities>( GTK_PRINT_CAPABILITY_GENERATE_PDF | GTK_PRINT_CAPABILITY_PAGE_SET | GTK_PRINT_CAPABILITY_COPIES | GTK_PRINT_CAPABILITY_COLLATE | - GTK_PRINT_CAPABILITY_REVERSE); + GTK_PRINT_CAPABILITY_REVERSE | GTK_PRINT_CAPABILITY_GENERATE_PS); - gtk_print_unix_dialog_set_manual_capabilities(GTK_PRINT_UNIX_DIALOG(dialog_), - cap); - gtk_print_unix_dialog_set_embed_page_setup(GTK_PRINT_UNIX_DIALOG(dialog_), + gtk_print_unix_dialog_set_manual_capabilities( + GTK_PRINT_UNIX_DIALOG(dialog_.get()), cap); + gtk_print_unix_dialog_set_embed_page_setup( diff --git a/www/chromium/files/patch-ui_message__center_views_message__popup__view.cc b/www/chromium/files/patch-ui_message__center_views_message__popup__view.cc index 24f1e8424a78..6417f8de5184 100644 --- a/www/chromium/files/patch-ui_message__center_views_message__popup__view.cc +++ b/www/chromium/files/patch-ui_message__center_views_message__popup__view.cc @@ -1,11 +1,11 @@ ---- ui/message_center/views/message_popup_view.cc.orig 2023-12-10 06:10:27 UTC +--- ui/message_center/views/message_popup_view.cc.orig 2025-01-15 09:18:26 UTC +++ ui/message_center/views/message_popup_view.cc -@@ -135,7 +135,7 @@ void MessagePopupView::Show() { +@@ -153,7 +153,7 @@ std::unique_ptr<views::Widget> MessagePopupView::Show( + views::Widget::InitParams::CLIENT_OWNS_WIDGET, + views::Widget::InitParams::TYPE_POPUP); params.z_order = ui::ZOrderLevel::kFloatingWindow; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Make the widget explicitly activatable as TYPE_POPUP is not activatable by // default but we need focus for the inline reply textarea. params.activatable = views::Widget::InitParams::Activatable::kYes; diff --git a/www/chromium/files/patch-ui_native__theme_native__theme__features.cc b/www/chromium/files/patch-ui_native__theme_features_native__theme__features.cc index 739f03590ca8..2dac52433c24 100644 --- a/www/chromium/files/patch-ui_native__theme_native__theme__features.cc +++ b/www/chromium/files/patch-ui_native__theme_features_native__theme__features.cc @@ -1,20 +1,20 @@ ---- ui/native_theme/native_theme_features.cc.orig 2024-01-30 07:53:34 UTC -+++ ui/native_theme/native_theme_features.cc -@@ -54,7 +54,7 @@ bool IsOverlayScrollbarEnabled() { +--- ui/native_theme/features/native_theme_features.cc.orig 2025-05-05 10:57:53 UTC ++++ ui/native_theme/features/native_theme_features.cc +@@ -59,7 +59,7 @@ namespace ui { - bool IsFluentScrollbarEnabled() { + bool IsFluentOverlayScrollbarEnabled() { // Fluent scrollbars are only used for some OSes due to UI design guidelines. -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return base::FeatureList::IsEnabled(features::kFluentScrollbar) || - IsFluentOverlayScrollbarEnabled(); + return base::FeatureList::IsEnabled(features::kFluentOverlayScrollbar); #else -@@ -63,7 +63,7 @@ bool IsFluentScrollbarEnabled() { - } - bool IsFluentOverlayScrollbarEnabled() { + return false; +@@ -68,7 +68,7 @@ bool IsFluentOverlayScrollbarEnabled() { + + bool IsFluentScrollbarEnabled() { // Fluent scrollbars are only used for some OSes due to UI design guidelines. -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - return base::FeatureList::IsEnabled(features::kFluentOverlayScrollbar); + return base::FeatureList::IsEnabled(features::kFluentScrollbar) || + IsFluentOverlayScrollbarEnabled(); #else - return false; diff --git a/www/chromium/files/patch-ui_native__theme_native__theme.h b/www/chromium/files/patch-ui_native__theme_native__theme.h index a91b318f64f6..e9a061594e9f 100644 --- a/www/chromium/files/patch-ui_native__theme_native__theme.h +++ b/www/chromium/files/patch-ui_native__theme_native__theme.h @@ -1,11 +1,11 @@ ---- ui/native_theme/native_theme.h.orig 2023-10-11 18:22:24 UTC +--- ui/native_theme/native_theme.h.orig 2025-05-05 10:57:53 UTC +++ ui/native_theme/native_theme.h -@@ -62,7 +62,7 @@ class NATIVE_THEME_EXPORT NativeTheme { +@@ -61,7 +61,7 @@ class COMPONENT_EXPORT(NATIVE_THEME) NativeTheme { + // The part to be painted / sized. + enum Part { kCheckbox, - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) kFrameTopArea, #endif kInnerSpinButton, diff --git a/www/chromium/files/patch-ui_native__theme_native__theme__base.cc b/www/chromium/files/patch-ui_native__theme_native__theme__base.cc index e1b853aed5cd..c3000486cab6 100644 --- a/www/chromium/files/patch-ui_native__theme_native__theme__base.cc +++ b/www/chromium/files/patch-ui_native__theme_native__theme__base.cc @@ -1,11 +1,11 @@ ---- ui/native_theme/native_theme_base.cc.orig 2023-11-03 10:09:45 UTC +--- ui/native_theme/native_theme_base.cc.orig 2025-05-05 10:57:53 UTC +++ ui/native_theme/native_theme_base.cc -@@ -235,7 +235,7 @@ void NativeThemeBase::Paint(cc::PaintCanvas* canvas, +@@ -240,7 +240,7 @@ void NativeThemeBase::Paint(cc::PaintCanvas* canvas, + std::get<ButtonExtraParams>(extra), color_scheme, + accent_color_opaque); break; - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) case kFrameTopArea: PaintFrameTopArea(canvas, state, rect, - absl::get<FrameTopAreaExtraParams>(extra), + std::get<FrameTopAreaExtraParams>(extra), color_scheme); diff --git a/www/chromium/files/patch-ui_ozone_common_egl__util.cc b/www/chromium/files/patch-ui_ozone_common_egl__util.cc index d12b1989b22a..64e4e1005cdb 100644 --- a/www/chromium/files/patch-ui_ozone_common_egl__util.cc +++ b/www/chromium/files/patch-ui_ozone_common_egl__util.cc @@ -1,6 +1,6 @@ ---- ui/ozone/common/egl_util.cc.orig 2022-07-22 17:30:31 UTC +--- ui/ozone/common/egl_util.cc.orig 2025-07-02 06:08:04 UTC +++ ui/ozone/common/egl_util.cc -@@ -26,9 +26,9 @@ const base::FilePath::CharType kDefaultGlesSoname[] = +@@ -35,9 +35,9 @@ const base::FilePath::CharType kDefaultGlesSoname[] = FILE_PATH_LITERAL("libGLESv2.so"); #else // BUILDFLAG(IS_FUCHSIA) const base::FilePath::CharType kDefaultEglSoname[] = @@ -10,5 +10,5 @@ - FILE_PATH_LITERAL("libGLESv2.so.2"); + FILE_PATH_LITERAL("libGLESv2.so"); #endif + #if !BUILDFLAG(USE_STATIC_ANGLE) const base::FilePath::CharType kAngleEglSoname[] = - FILE_PATH_LITERAL("libEGL.so"); diff --git a/www/chromium/files/patch-ui_ozone_common_features.cc b/www/chromium/files/patch-ui_ozone_common_features.cc deleted file mode 100644 index 7b312489b114..000000000000 --- a/www/chromium/files/patch-ui_ozone_common_features.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/common/features.cc.orig 2023-05-31 08:12:17 UTC -+++ ui/ozone/common/features.cc -@@ -30,7 +30,7 @@ BASE_FEATURE(kWaylandSurfaceSubmissionInPixelCoordinat - // enabled. - BASE_FEATURE(kWaylandFractionalScaleV1, - "WaylandFractionalScaleV1", --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - base::FEATURE_ENABLED_BY_DEFAULT - #else - base::FEATURE_DISABLED_BY_DEFAULT diff --git a/www/chromium/files/patch-ui_ozone_platform_headless_headless__surface__factory.cc b/www/chromium/files/patch-ui_ozone_platform_headless_headless__surface__factory.cc index a14d129acee8..f0810df5f435 100644 --- a/www/chromium/files/patch-ui_ozone_platform_headless_headless__surface__factory.cc +++ b/www/chromium/files/patch-ui_ozone_platform_headless_headless__surface__factory.cc @@ -1,4 +1,4 @@ ---- ui/ozone/platform/headless/headless_surface_factory.cc.orig 2023-03-09 06:31:50 UTC +--- ui/ozone/platform/headless/headless_surface_factory.cc.orig 2025-01-15 09:18:26 UTC +++ ui/ozone/platform/headless/headless_surface_factory.cc @@ -34,7 +34,7 @@ #include "ui/ozone/platform/headless/headless_window_manager.h" diff --git a/www/chromium/files/patch-ui_ozone_platform_headless_ozone__platform__headless.cc b/www/chromium/files/patch-ui_ozone_platform_headless_ozone__platform__headless.cc index abde5e0367d0..e77ccb9e8201 100644 --- a/www/chromium/files/patch-ui_ozone_platform_headless_ozone__platform__headless.cc +++ b/www/chromium/files/patch-ui_ozone_platform_headless_ozone__platform__headless.cc @@ -1,6 +1,6 @@ ---- ui/ozone/platform/headless/ozone_platform_headless.cc.orig 2024-03-27 13:31:02 UTC +--- ui/ozone/platform/headless/ozone_platform_headless.cc.orig 2025-05-05 10:57:53 UTC +++ ui/ozone/platform/headless/ozone_platform_headless.cc -@@ -103,7 +103,7 @@ class OzonePlatformHeadless : public OzonePlatform { +@@ -108,7 +108,7 @@ class OzonePlatformHeadlessImpl : public OzonePlatform } // Desktop Linux, not CastOS. diff --git a/www/chromium/files/patch-ui_ozone_platform_headless_vulkan__implementation__headless.cc b/www/chromium/files/patch-ui_ozone_platform_headless_vulkan__implementation__headless.cc index d395d2c51c33..f6dfe4fafdb9 100644 --- a/www/chromium/files/patch-ui_ozone_platform_headless_vulkan__implementation__headless.cc +++ b/www/chromium/files/patch-ui_ozone_platform_headless_vulkan__implementation__headless.cc @@ -1,6 +1,6 @@ ---- ui/ozone/platform/headless/vulkan_implementation_headless.cc.orig 2024-03-22 08:19:40 UTC +--- ui/ozone/platform/headless/vulkan_implementation_headless.cc.orig 2025-07-02 06:08:04 UTC +++ ui/ozone/platform/headless/vulkan_implementation_headless.cc -@@ -118,7 +118,7 @@ VulkanImplementationHeadless::ExportVkFenceToGpuFence( +@@ -116,7 +116,7 @@ VulkanImplementationHeadless::ExportVkFenceToGpuFence( VkExternalSemaphoreHandleTypeFlagBits VulkanImplementationHeadless::GetExternalSemaphoreHandleType() { @@ -9,7 +9,7 @@ return VK_EXTERNAL_SEMAPHORE_HANDLE_TYPE_SYNC_FD_BIT; #else return VK_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_FD_BIT; -@@ -128,7 +128,7 @@ VulkanImplementationHeadless::GetExternalSemaphoreHand +@@ -126,7 +126,7 @@ VulkanImplementationHeadless::GetExternalSemaphoreHand bool VulkanImplementationHeadless::CanImportGpuMemoryBuffer( gpu::VulkanDeviceQueue* device_queue, gfx::GpuMemoryBufferType memory_buffer_type) { @@ -18,12 +18,12 @@ const auto& enabled_extensions = device_queue->enabled_extensions(); return gfx::HasExtension(enabled_extensions, VK_EXT_EXTERNAL_MEMORY_DMA_BUF_EXTENSION_NAME) && -@@ -151,7 +151,7 @@ VulkanImplementationHeadless::CreateImageFromGpuMemory +@@ -149,7 +149,7 @@ VulkanImplementationHeadless::CreateImageFromGpuMemory VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | VK_IMAGE_USAGE_SAMPLED_BIT | VK_IMAGE_USAGE_TRANSFER_DST_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT; auto tiling = VK_IMAGE_TILING_OPTIMAL; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (gmb_handle.native_pixmap_handle.modifier != + if (gmb_handle.native_pixmap_handle().modifier != gfx::NativePixmapHandle::kNoModifier) { tiling = VK_IMAGE_TILING_DRM_FORMAT_MODIFIER_EXT; diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_common_wayland__util.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_common_wayland__util.cc index e6d500e4b971..9e28805d3a24 100644 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_common_wayland__util.cc +++ b/www/chromium/files/patch-ui_ozone_platform_wayland_common_wayland__util.cc @@ -1,11 +1,18 @@ ---- ui/ozone/platform/wayland/common/wayland_util.cc.orig 2024-04-19 13:02:56 UTC +--- ui/ozone/platform/wayland/common/wayland_util.cc.orig 2025-07-02 06:08:04 UTC +++ ui/ozone/platform/wayland/common/wayland_util.cc -@@ -337,7 +337,7 @@ void TransformToWlArray( - } +@@ -421,6 +421,7 @@ void RecordConnectionMetrics(wl_display* display) { + {"weston", WaylandCompositor::kWeston}, + }; - base::TimeTicks EventMillisecondsToTimeTicks(uint32_t milliseconds) { --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/1499638): `milliseconds` comes from Weston that - // uses timestamp from libinput, which is different from TimeTicks. - // Use EventTimeForNow(), for now. ++#if !BUILDFLAG(IS_BSD) + const int fd = wl_display_get_fd(display); + if (fd == -1) { + return WaylandCompositor::kUnknown; +@@ -446,6 +447,7 @@ void RecordConnectionMetrics(wl_display* display) { + return compositor; + } + } ++#endif + + return WaylandCompositor::kOther; + }; diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_emulate_wayland__input__emulate.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_emulate_wayland__input__emulate.cc deleted file mode 100644 index 88910c87641e..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_emulate_wayland__input__emulate.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/emulate/wayland_input_emulate.cc.orig 2024-03-22 08:19:40 UTC -+++ ui/ozone/platform/wayland/emulate/wayland_input_emulate.cc -@@ -284,7 +284,7 @@ void WaylandInputEmulate::EmulateUpdateDisplay(const s - } - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void WaylandInputEmulate::ForceUseScreenCoordinatesOnce() { - force_use_screen_coordinates_once_ = true; - } diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_emulate_wayland__input__emulate.h b/www/chromium/files/patch-ui_ozone_platform_wayland_emulate_wayland__input__emulate.h deleted file mode 100644 index 7e85663dd503..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_emulate_wayland__input__emulate.h +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/emulate/wayland_input_emulate.h.orig 2024-03-22 08:19:40 UTC -+++ ui/ozone/platform/wayland/emulate/wayland_input_emulate.h -@@ -68,7 +68,7 @@ class WaylandInputEmulate : public wl::WaylandProxy::D - uint32_t request_id); - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void ForceUseScreenCoordinatesOnce(); - #endif - diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__connection.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__connection.cc deleted file mode 100644 index e275c510acba..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__connection.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/host/wayland_connection.cc.orig 2024-04-19 13:02:56 UTC -+++ ui/ozone/platform/wayland/host/wayland_connection.cc -@@ -539,7 +539,7 @@ bool WaylandConnection::ShouldUseOverlayDelegation() c - // isn't present on any non-exo Wayland compositors. - bool should_use_overlay_delegation = - IsWaylandOverlayDelegationEnabled() && !fractional_scale_manager_v1(); --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Overlay delegation also requires a single-pixel-buffer protocol, which - // allows creation of non-backed solid color buffers. Even though only video - // overlays can be supported on Linux, these color buffers are still needed diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__frame__manager.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__frame__manager.cc new file mode 100644 index 000000000000..e106ca3408e3 --- /dev/null +++ b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__frame__manager.cc @@ -0,0 +1,13 @@ +--- ui/ozone/platform/wayland/host/wayland_frame_manager.cc.orig 2025-05-13 08:59:54 UTC ++++ ui/ozone/platform/wayland/host/wayland_frame_manager.cc +@@ -461,8 +461,10 @@ std::optional<bool> WaylandFrameManager::ApplySurfaceC + surface->UpdateBufferDamageRegion( + gfx::ToEnclosingRectIgnoringError(surface_damage)); + ++#if !BUILDFLAG(IS_BSD) + if (!config.access_fence_handle.is_null()) + surface->set_acquire_fence(std::move(config.access_fence_handle)); ++#endif + + bool needs_commit = false; + diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__input__method__context.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__input__method__context.cc deleted file mode 100644 index 9408ca36b7fc..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__input__method__context.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/host/wayland_input_method_context.cc.orig 2024-03-22 08:19:40 UTC -+++ ui/ozone/platform/wayland/host/wayland_input_method_context.cc -@@ -54,7 +54,7 @@ namespace { - // Only enable the preedit string for sequence mode (i.e. when using dead keys - // or the Compose key) on Linux ozone/wayland (see b/220370007). - constexpr CharacterComposer::PreeditStringMode kPreeditStringMode = --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - CharacterComposer::PreeditStringMode::kAlwaysEnabled; - #else - CharacterComposer::PreeditStringMode::kHexModeOnly; diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__toplevel__window.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__toplevel__window.cc deleted file mode 100644 index 7da4f5d6aa20..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__toplevel__window.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/host/wayland_toplevel_window.cc.orig 2024-04-19 13:02:56 UTC -+++ ui/ozone/platform/wayland/host/wayland_toplevel_window.cc -@@ -606,7 +606,7 @@ void WaylandToplevelWindow::HandleAuraToplevelConfigur - const bool did_active_change = is_active_ != window_states.is_activated; - is_active_ = window_states.is_activated; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // The tiled state affects the window geometry, so apply it here. - if (window_states.tiled_edges != tiled_state_) { - // This configure changes the decoration insets. We should adjust the diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__toplevel__window.h b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__toplevel__window.h deleted file mode 100644 index 91708306c24d..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__toplevel__window.h +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/host/wayland_toplevel_window.h.orig 2024-04-19 13:02:56 UTC -+++ ui/ozone/platform/wayland/host/wayland_toplevel_window.h -@@ -265,7 +265,7 @@ class WaylandToplevelWindow : public WaylandWindow, - // The display ID to switch to in case the state is `kFullscreen`. - int64_t fullscreen_display_id_ = display::kInvalidDisplayId; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // Contains the current state of the tiled edges. - WindowTiledEdges tiled_state_; - #endif diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__window.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__window.cc deleted file mode 100644 index df43b637cc76..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__window.cc +++ /dev/null @@ -1,44 +0,0 @@ ---- ui/ozone/platform/wayland/host/wayland_window.cc.orig 2024-03-22 08:19:40 UTC -+++ ui/ozone/platform/wayland/host/wayland_window.cc -@@ -245,7 +245,7 @@ void WaylandWindow::OnPointerFocusChanged(bool focused - // Whenever the window gets the pointer focus back, the cursor shape must be - // updated. Otherwise, it is invalidated upon wl_pointer::leave and is not - // restored by the Wayland compositor. --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (focused && async_cursor_) { - async_cursor_->AddCursorLoadedCallback( - base::BindOnce(&WaylandWindow::OnCursorLoaded, -@@ -506,7 +506,7 @@ bool WaylandWindow::ShouldUseNativeFrame() const { - void WaylandWindow::SetCursor(scoped_refptr<PlatformCursor> platform_cursor) { - DCHECK(platform_cursor); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - auto async_cursor = WaylandAsyncCursor::FromPlatformCursor(platform_cursor); - - if (async_cursor_ == async_cursor) { -@@ -716,7 +716,7 @@ std::string WaylandWindow::WindowStates::ToString() co - } else { - base::TrimString(states, " ", &states); - } --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - states += "; tiled_edges: "; - std::string tiled = ""; - if (tiled_edges.left) { -@@ -1185,12 +1185,12 @@ void WaylandWindow::UpdateCursorShape(scoped_refptr<Bi - cursor->bitmaps(), hotspot_in_dips, - std::ceil(cursor->cursor_image_scale_factor())); - } --#if !BUILDFLAG(IS_LINUX) -+#if !BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD) - cursor_ = cursor; - #endif - } - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void WaylandWindow::OnCursorLoaded(scoped_refptr<WaylandAsyncCursor> cursor, - scoped_refptr<BitmapCursor> bitmap_cursor) { - if (HasPointerFocus() && async_cursor_ == cursor && bitmap_cursor) { diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__window.h b/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__window.h deleted file mode 100644 index c93a9a642594..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_wayland__window.h +++ /dev/null @@ -1,38 +0,0 @@ ---- ui/ozone/platform/wayland/host/wayland_window.h.orig 2024-04-19 13:02:56 UTC -+++ ui/ozone/platform/wayland/host/wayland_window.h -@@ -40,7 +40,7 @@ - #include "ui/platform_window/platform_window_init_properties.h" - #include "ui/platform_window/wm/wm_drag_handler.h" - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "ui/ozone/platform/wayland/host/wayland_async_cursor.h" - #endif - -@@ -251,7 +251,7 @@ class WaylandWindow : public PlatformWindow, - bool is_snapped_primary = false; - bool is_snapped_secondary = false; - bool is_floated = false; --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - WindowTiledEdges tiled_edges; - #endif - -@@ -510,7 +510,7 @@ class WaylandWindow : public PlatformWindow, - - void UpdateCursorShape(scoped_refptr<BitmapCursor> cursor); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - void OnCursorLoaded(scoped_refptr<WaylandAsyncCursor> cursor, - scoped_refptr<BitmapCursor> bitmap_cursor); - #endif -@@ -571,7 +571,7 @@ class WaylandWindow : public PlatformWindow, - - wl::Object<zaura_surface> aura_surface_; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // The current asynchronously loaded cursor (Linux specific). - scoped_refptr<WaylandAsyncCursor> async_cursor_; - #else diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_xdg__toplevel__wrapper__impl.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_xdg__toplevel__wrapper__impl.cc deleted file mode 100644 index 18b8e84ca348..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_xdg__toplevel__wrapper__impl.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/ozone/platform/wayland/host/xdg_toplevel_wrapper_impl.cc.orig 2024-03-22 08:19:40 UTC -+++ ui/ozone/platform/wayland/host/xdg_toplevel_wrapper_impl.cc -@@ -316,7 +316,7 @@ void XDGToplevelWrapperImpl::OnToplevelConfigure(void* - window_states.is_activated = - CheckIfWlArrayHasValue(states, XDG_TOPLEVEL_STATE_ACTIVATED); - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (xdg_toplevel_get_version(toplevel) >= - XDG_TOPLEVEL_STATE_TILED_LEFT_SINCE_VERSION) { - // All four tiled states have the same since version, so it is enough to diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_host_zwp__text__input__wrapper__v1.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_host_zwp__text__input__wrapper__v1.cc deleted file mode 100644 index 4790f9616513..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_host_zwp__text__input__wrapper__v1.cc +++ /dev/null @@ -1,21 +0,0 @@ ---- ui/ozone/platform/wayland/host/zwp_text_input_wrapper_v1.cc.orig 2024-01-30 07:53:34 UTC -+++ ui/ozone/platform/wayland/host/zwp_text_input_wrapper_v1.cc -@@ -226,6 +226,10 @@ void ZWPTextInputWrapperV1::SetSurroundingText( - // so if it exceeds 16 bits, it may be broken. - static constexpr size_t kSizeLimit = 60000; - if (HasAdvancedSurroundingTextSupport() && text.length() > kSizeLimit) { -+#if defined(__FreeBSD_version) && __FreeBSD_version < 1300048 -+ PLOG(ERROR) << "memfd is not supported"; -+ return; -+#else - base::ScopedFD memfd(memfd_create("surrounding_text", MFD_CLOEXEC)); - if (!memfd.get()) { - PLOG(ERROR) << "Failed to create memfd"; -@@ -238,6 +242,7 @@ void ZWPTextInputWrapperV1::SetSurroundingText( - zcr_extended_text_input_v1_set_large_surrounding_text( - extended_obj_.get(), memfd.get(), text.length(), - selection_range.start(), selection_range.end()); -+#endif - } else { - zwp_text_input_v1_set_surrounding_text(obj_.get(), text.c_str(), - selection_range.start(), diff --git a/www/chromium/files/patch-ui_ozone_platform_wayland_ozone__platform__wayland.cc b/www/chromium/files/patch-ui_ozone_platform_wayland_ozone__platform__wayland.cc deleted file mode 100644 index 8521b49f315e..000000000000 --- a/www/chromium/files/patch-ui_ozone_platform_wayland_ozone__platform__wayland.cc +++ /dev/null @@ -1,54 +0,0 @@ ---- ui/ozone/platform/wayland/ozone_platform_wayland.cc.orig 2024-04-19 13:02:56 UTC -+++ ui/ozone/platform/wayland/ozone_platform_wayland.cc -@@ -67,13 +67,13 @@ - #include "ui/events/ozone/layout/stub/stub_keyboard_layout_engine.h" - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "ui/ozone/platform/wayland/host/wayland_cursor_factory.h" - #else - #include "ui/ozone/common/bitmap_cursor_factory.h" - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "ui/ozone/platform/wayland/host/linux_ui_delegate_wayland.h" - #endif - -@@ -268,7 +268,7 @@ class OzonePlatformWayland : public OzonePlatform, - - buffer_manager_connector_ = std::make_unique<WaylandBufferManagerConnector>( - connection_->buffer_manager_host()); --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - cursor_factory_ = std::make_unique<WaylandCursorFactory>(connection_.get()); - #else - cursor_factory_ = std::make_unique<BitmapCursorFactory>(); -@@ -278,7 +278,7 @@ class OzonePlatformWayland : public OzonePlatform, - - supported_buffer_formats_ = - connection_->buffer_manager_host()->GetSupportedBufferFormats(); --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - linux_ui_delegate_ = - std::make_unique<LinuxUiDelegateWayland>(connection_.get()); - #endif -@@ -344,7 +344,7 @@ class OzonePlatformWayland : public OzonePlatform, - properties->supports_global_screen_coordinates = - kDefaultScreenCoordinateEnabled; - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/40800718): Revisit (and maybe remove) once proper - // support, probably backed by org.freedesktop.portal.Screenshot.PickColor - // API is implemented. Note: this is restricted to Linux Desktop as Lacros -@@ -532,7 +532,7 @@ class OzonePlatformWayland : public OzonePlatform, - DrmRenderNodePathFinder path_finder_; - #endif - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - std::unique_ptr<LinuxUiDelegateWayland> linux_ui_delegate_; - #endif - }; diff --git a/www/chromium/files/patch-ui_ozone_platform_x11_x11__screen__ozone.cc b/www/chromium/files/patch-ui_ozone_platform_x11_x11__screen__ozone.cc index 423492dcddb3..d2daaae04de4 100644 --- a/www/chromium/files/patch-ui_ozone_platform_x11_x11__screen__ozone.cc +++ b/www/chromium/files/patch-ui_ozone_platform_x11_x11__screen__ozone.cc @@ -1,4 +1,4 @@ ---- ui/ozone/platform/x11/x11_screen_ozone.cc.orig 2024-03-22 08:19:40 UTC +--- ui/ozone/platform/x11/x11_screen_ozone.cc.orig 2025-03-05 08:14:56 UTC +++ ui/ozone/platform/x11/x11_screen_ozone.cc @@ -22,7 +22,7 @@ #include "ui/ozone/platform/x11/x11_window.h" @@ -18,7 +18,7 @@ if (auto* linux_ui = ui::LinuxUi::instance()) { display_scale_factor_observer_.Observe(linux_ui); } -@@ -260,7 +260,7 @@ void X11ScreenOzone::OnEvent(const x11::Event& xev) { +@@ -267,7 +267,7 @@ void X11ScreenOzone::OnEvent(const x11::Event& xev) { x11_display_manager_->OnEvent(xev); } diff --git a/www/chromium/files/patch-ui_ozone_platform_x11_x11__window.cc b/www/chromium/files/patch-ui_ozone_platform_x11_x11__window.cc index 19f020fa14de..079bee7c4f2f 100644 --- a/www/chromium/files/patch-ui_ozone_platform_x11_x11__window.cc +++ b/www/chromium/files/patch-ui_ozone_platform_x11_x11__window.cc @@ -1,11 +1,11 @@ ---- ui/ozone/platform/x11/x11_window.cc.orig 2024-03-22 08:19:40 UTC +--- ui/ozone/platform/x11/x11_window.cc.orig 2025-07-02 06:08:04 UTC +++ ui/ozone/platform/x11/x11_window.cc -@@ -1501,7 +1501,7 @@ void X11Window::OnXWindowStateChanged() { +@@ -1507,7 +1507,7 @@ void X11Window::OnXWindowStateChanged() { WindowTiledEdges tiled_state = GetTiledState(); if (tiled_state != tiled_state_) { tiled_state_ = tiled_state; -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) platform_window_delegate_->OnWindowTiledStateChanged(tiled_state); + UpdateDecorationInsets(); #endif - } diff --git a/www/chromium/files/patch-ui_ozone_public_ozone__ui__controls__test__helper.h b/www/chromium/files/patch-ui_ozone_public_ozone__ui__controls__test__helper.h new file mode 100644 index 000000000000..70c4d6860293 --- /dev/null +++ b/www/chromium/files/patch-ui_ozone_public_ozone__ui__controls__test__helper.h @@ -0,0 +1,11 @@ +--- ui/ozone/public/ozone_ui_controls_test_helper.h.orig 2025-04-04 08:52:13 UTC ++++ ui/ozone/public/ozone_ui_controls_test_helper.h +@@ -62,7 +62,7 @@ class OzoneUIControlsTestHelper { + // aura::Window. + virtual bool MustUseUiControlsForMoveCursorTo() = 0; + +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + virtual void ForceUseScreenCoordinatesOnce(); + #endif + }; diff --git a/www/chromium/files/patch-ui_ozone_test_mock__platform__window__delegate.h b/www/chromium/files/patch-ui_ozone_test_mock__platform__window__delegate.h index d897cd56b7bd..108c8136eac6 100644 --- a/www/chromium/files/patch-ui_ozone_test_mock__platform__window__delegate.h +++ b/www/chromium/files/patch-ui_ozone_test_mock__platform__window__delegate.h @@ -1,6 +1,6 @@ ---- ui/ozone/test/mock_platform_window_delegate.h.orig 2024-03-22 08:19:40 UTC +--- ui/ozone/test/mock_platform_window_delegate.h.orig 2024-06-17 12:56:06 UTC +++ ui/ozone/test/mock_platform_window_delegate.h -@@ -33,7 +33,7 @@ class MockPlatformWindowDelegate : public PlatformWind +@@ -35,7 +35,7 @@ class MockPlatformWindowDelegate : public PlatformWind MOCK_METHOD2(OnWindowStateChanged, void(PlatformWindowState old_state, PlatformWindowState new_state)); diff --git a/www/chromium/files/patch-ui_platform__window_platform__window__delegate.cc b/www/chromium/files/patch-ui_platform__window_platform__window__delegate.cc index 9f9259ce1dae..2b55098e33ce 100644 --- a/www/chromium/files/patch-ui_platform__window_platform__window__delegate.cc +++ b/www/chromium/files/patch-ui_platform__window_platform__window__delegate.cc @@ -1,8 +1,8 @@ ---- ui/platform_window/platform_window_delegate.cc.orig 2024-03-22 08:19:40 UTC +--- ui/platform_window/platform_window_delegate.cc.orig 2025-04-04 08:52:13 UTC +++ ui/platform_window/platform_window_delegate.cc -@@ -48,7 +48,7 @@ PlatformWindowDelegate::PlatformWindowDelegate() = def - - PlatformWindowDelegate::~PlatformWindowDelegate() = default; +@@ -56,7 +56,7 @@ gfx::Insets PlatformWindowDelegate::CalculateInsetsInD + return gfx::Insets(); + } -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-ui_platform__window_platform__window__delegate.h b/www/chromium/files/patch-ui_platform__window_platform__window__delegate.h index 0412cece8109..df87e6eeac9c 100644 --- a/www/chromium/files/patch-ui_platform__window_platform__window__delegate.h +++ b/www/chromium/files/patch-ui_platform__window_platform__window__delegate.h @@ -1,6 +1,6 @@ ---- ui/platform_window/platform_window_delegate.h.orig 2024-03-22 08:19:40 UTC +--- ui/platform_window/platform_window_delegate.h.orig 2025-05-07 06:38:02 UTC +++ ui/platform_window/platform_window_delegate.h -@@ -166,7 +166,7 @@ class COMPONENT_EXPORT(PLATFORM_WINDOW) PlatformWindow +@@ -144,7 +144,7 @@ class COMPONENT_EXPORT(PLATFORM_WINDOW) PlatformWindow virtual void OnWindowStateChanged(PlatformWindowState old_state, PlatformWindowState new_state) = 0; diff --git a/www/chromium/files/patch-ui_platform__window_platform__window__init__properties.h b/www/chromium/files/patch-ui_platform__window_platform__window__init__properties.h index 3ad5a97e178b..9980beaaf6f3 100644 --- a/www/chromium/files/patch-ui_platform__window_platform__window__init__properties.h +++ b/www/chromium/files/patch-ui_platform__window_platform__window__init__properties.h @@ -1,4 +1,4 @@ ---- ui/platform_window/platform_window_init_properties.h.orig 2024-03-22 08:19:40 UTC +--- ui/platform_window/platform_window_init_properties.h.orig 2025-05-05 10:57:53 UTC +++ ui/platform_window/platform_window_init_properties.h @@ -56,7 +56,7 @@ class WorkspaceExtensionDelegate; class ScenicWindowDelegate; @@ -9,7 +9,7 @@ class X11ExtensionDelegate; #endif -@@ -121,7 +121,7 @@ struct COMPONENT_EXPORT(PLATFORM_WINDOW) PlatformWindo +@@ -120,7 +120,7 @@ struct COMPONENT_EXPORT(PLATFORM_WINDOW) PlatformWindo PlatformWindowShadowType shadow_type = PlatformWindowShadowType::kDefault; diff --git a/www/chromium/files/patch-ui_qt_moc__wrapper.py b/www/chromium/files/patch-ui_qt_moc__wrapper.py new file mode 100644 index 000000000000..f34a282b3c58 --- /dev/null +++ b/www/chromium/files/patch-ui_qt_moc__wrapper.py @@ -0,0 +1,8 @@ +--- ui/qt/moc_wrapper.py.orig 2025-05-28 14:55:43 UTC ++++ ui/qt/moc_wrapper.py +@@ -20,4 +20,4 @@ args = parser.parse_args() + if args.path is None: + subprocess.check_call(["moc", args.input, "-o", args.output]) + else: +- subprocess.check_call([args.path + "/moc", args.input, "-o", args.output]) ++ subprocess.check_call([args.path, args.input, "-o", args.output]) diff --git a/www/chromium/files/patch-ui_views_BUILD.gn b/www/chromium/files/patch-ui_views_BUILD.gn new file mode 100644 index 000000000000..58986bbc19a4 --- /dev/null +++ b/www/chromium/files/patch-ui_views_BUILD.gn @@ -0,0 +1,10 @@ +--- ui/views/BUILD.gn.orig 2025-05-28 14:55:43 UTC ++++ ui/views/BUILD.gn +@@ -833,7 +833,6 @@ component("views") { + sources += [ "accessibility/widget_ax_tree_id_map.cc" ] + } + deps += [ +- "//components/crash/core/common:crash_key", + "//ui/aura", + "//ui/base/cursor/mojom:cursor_type_shared", + "//ui/events", diff --git a/www/chromium/files/patch-ui_views_accessibility_view__accessibility.cc b/www/chromium/files/patch-ui_views_accessibility_view__accessibility.cc new file mode 100644 index 000000000000..275f452aa052 --- /dev/null +++ b/www/chromium/files/patch-ui_views_accessibility_view__accessibility.cc @@ -0,0 +1,20 @@ +--- ui/views/accessibility/view_accessibility.cc.orig 2025-05-05 10:57:53 UTC ++++ ui/views/accessibility/view_accessibility.cc +@@ -34,7 +34,7 @@ + #include "ui/views/accessibility/view_ax_platform_node_delegate_win.h" + #elif BUILDFLAG(IS_MAC) + #include "ui/views/accessibility/view_ax_platform_node_delegate_mac.h" +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + #include "ui/views/accessibility/view_ax_platform_node_delegate_auralinux.h" + #endif + +@@ -101,7 +101,7 @@ std::unique_ptr<ViewAccessibility> ViewAccessibility:: + return ViewAXPlatformNodeDelegateWin::CreatePlatformSpecific(view); + #elif BUILDFLAG(IS_MAC) + return ViewAXPlatformNodeDelegateMac::CreatePlatformSpecific(view); +-#elif BUILDFLAG(IS_LINUX) ++#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + return ViewAXPlatformNodeDelegateAuraLinux::CreatePlatformSpecific(view); + #endif + } diff --git a/www/chromium/files/patch-ui_views_controls_prefix__selector.cc b/www/chromium/files/patch-ui_views_controls_prefix__selector.cc index c0d111d1996c..d17c11f21cd3 100644 --- a/www/chromium/files/patch-ui_views_controls_prefix__selector.cc +++ b/www/chromium/files/patch-ui_views_controls_prefix__selector.cc @@ -1,6 +1,6 @@ ---- ui/views/controls/prefix_selector.cc.orig 2022-09-24 10:57:32 UTC +--- ui/views/controls/prefix_selector.cc.orig 2025-01-15 09:18:26 UTC +++ ui/views/controls/prefix_selector.cc -@@ -174,7 +174,7 @@ bool PrefixSelector::ShouldDoLearning() { +@@ -192,7 +192,7 @@ bool PrefixSelector::ShouldDoLearning() { return false; } diff --git a/www/chromium/files/patch-ui_views_controls_prefix__selector.h b/www/chromium/files/patch-ui_views_controls_prefix__selector.h index d272917a0ffd..b31412c7ff81 100644 --- a/www/chromium/files/patch-ui_views_controls_prefix__selector.h +++ b/www/chromium/files/patch-ui_views_controls_prefix__selector.h @@ -1,6 +1,6 @@ ---- ui/views/controls/prefix_selector.h.orig 2022-08-31 12:19:35 UTC +--- ui/views/controls/prefix_selector.h.orig 2025-01-15 09:18:26 UTC +++ ui/views/controls/prefix_selector.h -@@ -83,7 +83,7 @@ class VIEWS_EXPORT PrefixSelector : public ui::TextInp +@@ -91,7 +91,7 @@ class VIEWS_EXPORT PrefixSelector : public ui::TextInp ukm::SourceId GetClientSourceForMetrics() const override; bool ShouldDoLearning() override; diff --git a/www/chromium/files/patch-ui_views_controls_textfield_textfield.cc b/www/chromium/files/patch-ui_views_controls_textfield_textfield.cc index 8dd995607854..68d3948654b0 100644 --- a/www/chromium/files/patch-ui_views_controls_textfield_textfield.cc +++ b/www/chromium/files/patch-ui_views_controls_textfield_textfield.cc @@ -1,4 +1,4 @@ ---- ui/views/controls/textfield/textfield.cc.orig 2024-04-19 13:02:56 UTC +--- ui/views/controls/textfield/textfield.cc.orig 2025-07-02 06:08:04 UTC +++ ui/views/controls/textfield/textfield.cc @@ -85,7 +85,7 @@ #include "base/win/win_util.h" @@ -9,7 +9,7 @@ #include "ui/base/ime/linux/text_edit_command_auralinux.h" #include "ui/base/ime/text_input_flags.h" #include "ui/linux/linux_ui.h" -@@ -183,7 +183,7 @@ bool IsControlKeyModifier(int flags) { +@@ -182,7 +182,7 @@ bool IsControlKeyModifier(int flags) { // Control-modified key combination, but we cannot extend it to other platforms // as Control has different meanings and behaviors. // https://crrev.com/2580483002/#msg46 @@ -18,47 +18,48 @@ return flags & ui::EF_CONTROL_DOWN; #else return false; -@@ -742,7 +742,7 @@ bool Textfield::OnKeyPressed(const ui::KeyEvent& event - if (!textfield) +@@ -789,7 +789,7 @@ bool Textfield::OnKeyPressed(const ui::KeyEvent& event return handled; + } -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - auto* linux_ui = ui::LinuxUi::instance(); - std::vector<ui::TextEditCommandAuraLinux> commands; - if (!handled && linux_ui && -@@ -925,7 +925,7 @@ void Textfield::AboutToRequestFocusFromTabTraversal(bo + if (!handled) { + if (auto* linux_ui = ui::LinuxUi::instance()) { + const auto command = +@@ -974,7 +974,7 @@ void Textfield::AboutToRequestFocusFromTabTraversal(bo } bool Textfield::SkipDefaultKeyEventProcessing(const ui::KeyEvent& event) { -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Skip any accelerator handling that conflicts with custom keybindings. - auto* linux_ui = ui::LinuxUi::instance(); - std::vector<ui::TextEditCommandAuraLinux> commands; -@@ -1978,7 +1978,7 @@ bool Textfield::ShouldDoLearning() { + if (auto* linux_ui = ui::LinuxUi::instance()) { + if (IsTextEditCommandEnabled(linux_ui->GetTextEditCommandForEvent( +@@ -2062,7 +2062,7 @@ bool Textfield::ShouldDoLearning() { return false; } -#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) - // TODO(https://crbug.com/952355): Implement this method to support Korean IME + // TODO(crbug.com/41452689): Implement this method to support Korean IME // reconversion feature on native text fields (e.g. find bar). bool Textfield::SetCompositionFromExistingText( -@@ -2482,14 +2482,14 @@ ui::TextEditCommand Textfield::GetCommandForKeyEvent( +@@ -2580,7 +2580,7 @@ ui::TextEditCommand Textfield::GetCommandForKeyEvent( #endif return ui::TextEditCommand::DELETE_BACKWARD; } -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Only erase by line break on Linux and ChromeOS. - if (shift) + if (shift) { return ui::TextEditCommand::DELETE_TO_BEGINNING_OF_LINE; +@@ -2588,7 +2588,7 @@ ui::TextEditCommand Textfield::GetCommandForKeyEvent( #endif return ui::TextEditCommand::DELETE_WORD_BACKWARD; case ui::VKEY_DELETE: -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD) // Only erase by line break on Linux and ChromeOS. - if (shift && control) + if (shift && control) { return ui::TextEditCommand::DELETE_TO_END_OF_LINE; diff --git a/www/chromium/files/patch-ui_views_controls_textfield_textfield.h b/www/chromium/files/patch-ui_views_controls_textfield_textfield.h index defb178d2594..3b712975983d 100644 --- a/www/chromium/files/patch-ui_views_controls_textfield_textfield.h +++ b/www/chromium/files/patch-ui_views_controls_textfield_textfield.h @@ -1,6 +1,6 @@ ---- ui/views/controls/textfield/textfield.h.orig 2024-04-19 13:02:56 UTC +--- ui/views/controls/textfield/textfield.h.orig 2025-07-02 06:08:04 UTC +++ ui/views/controls/textfield/textfield.h -@@ -47,7 +47,7 @@ +@@ -48,7 +48,7 @@ #include "ui/views/view_observer.h" #include "ui/views/word_lookup_client.h" @@ -9,7 +9,7 @@ #include <vector> #endif -@@ -461,7 +461,7 @@ class VIEWS_EXPORT Textfield : public View, +@@ -478,7 +478,7 @@ class VIEWS_EXPORT Textfield : public View, // Set whether the text should be used to improve typing suggestions. void SetShouldDoLearning(bool value) { should_do_learning_ = value; } diff --git a/www/chromium/files/patch-ui_views_corewm_tooltip__aura.cc b/www/chromium/files/patch-ui_views_corewm_tooltip__aura.cc index 5514fd7acff4..271c476bfb69 100644 --- a/www/chromium/files/patch-ui_views_corewm_tooltip__aura.cc +++ b/www/chromium/files/patch-ui_views_corewm_tooltip__aura.cc @@ -1,11 +1,11 @@ ---- ui/views/corewm/tooltip_aura.cc.orig 2024-04-19 13:02:56 UTC +--- ui/views/corewm/tooltip_aura.cc.orig 2025-05-05 10:57:53 UTC +++ ui/views/corewm/tooltip_aura.cc -@@ -36,7 +36,7 @@ namespace { +@@ -42,7 +42,7 @@ static constexpr int kTooltipMaxWidth = 800; + + // TODO(varkha): Update if native widget can be transparent on Linux. bool CanUseTranslucentTooltipWidget() { - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_WIN) -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_BSD) return false; #else return true; diff --git a/www/chromium/files/patch-ui_views_examples_widget__example.cc b/www/chromium/files/patch-ui_views_examples_widget__example.cc index f6b4e7ea39db..767ab3d2c1f0 100644 --- a/www/chromium/files/patch-ui_views_examples_widget__example.cc +++ b/www/chromium/files/patch-ui_views_examples_widget__example.cc @@ -1,6 +1,6 @@ ---- ui/views/examples/widget_example.cc.orig 2023-01-11 09:17:16 UTC +--- ui/views/examples/widget_example.cc.orig 2025-05-05 10:57:53 UTC +++ ui/views/examples/widget_example.cc -@@ -49,7 +49,7 @@ void WidgetExample::CreateExampleView(View* container) +@@ -51,7 +51,7 @@ void WidgetExample::CreateExampleView(View* container) modal_button->SetCallback( base::BindRepeating(&WidgetExample::CreateDialogWidget, base::Unretained(this), modal_button, true)); diff --git a/www/chromium/files/patch-ui_views_focus_focus__manager.cc b/www/chromium/files/patch-ui_views_focus_focus__manager.cc index 080c684d70fc..7a38152ac5bf 100644 --- a/www/chromium/files/patch-ui_views_focus_focus__manager.cc +++ b/www/chromium/files/patch-ui_views_focus_focus__manager.cc @@ -1,20 +1,20 @@ ---- ui/views/focus/focus_manager.cc.orig 2024-04-19 13:02:56 UTC +--- ui/views/focus/focus_manager.cc.orig 2025-04-04 08:52:13 UTC +++ ui/views/focus/focus_manager.cc -@@ -579,7 +579,7 @@ bool FocusManager::RedirectAcceleratorToBubbleAnchorWi +@@ -606,7 +606,7 @@ bool FocusManager::RedirectAcceleratorToBubbleAnchorWi + return false; + } - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Processing an accelerator can delete things. Because we // need these objects afterwards on Linux, save widget_ as weak pointer and // save the close_on_deactivate property value of widget_delegate in a -@@ -596,7 +596,7 @@ bool FocusManager::RedirectAcceleratorToBubbleAnchorWi +@@ -621,7 +621,7 @@ bool FocusManager::RedirectAcceleratorToBubbleAnchorWi + const bool accelerator_processed = + focus_manager->ProcessAccelerator(accelerator); - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) // Need to manually close the bubble widget on Linux. On Linux when the // bubble is shown, the main widget remains active. Because of that when // focus is set to the main widget to process accelerator, the main widget diff --git a/www/chromium/files/patch-ui_views_style_platform__style.cc b/www/chromium/files/patch-ui_views_style_platform__style.cc index 413bc8b3c841..1a39a9747b40 100644 --- a/www/chromium/files/patch-ui_views_style_platform__style.cc +++ b/www/chromium/files/patch-ui_views_style_platform__style.cc @@ -1,6 +1,6 @@ ---- ui/views/style/platform_style.cc.orig 2024-03-22 08:19:40 UTC +--- ui/views/style/platform_style.cc.orig 2025-04-04 08:52:13 UTC +++ ui/views/style/platform_style.cc -@@ -17,7 +17,7 @@ +@@ -23,7 +23,7 @@ #include "ui/views/controls/focusable_border.h" #include "ui/views/controls/scrollbar/scroll_bar_views.h" @@ -8,17 +8,8 @@ +#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) #include "ui/views/controls/scrollbar/overlay_scroll_bar.h" #endif - -@@ -50,7 +50,7 @@ const View::FocusBehavior PlatformStyle::kDefaultFocus - // Linux clips bubble windows that extend outside their parent window - // bounds. - const bool PlatformStyle::kAdjustBubbleIfOffscreen = --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - false; - #else - true; -@@ -59,7 +59,7 @@ const bool PlatformStyle::kAdjustBubbleIfOffscreen = + #endif +@@ -35,7 +35,7 @@ namespace views { // static std::unique_ptr<ScrollBar> PlatformStyle::CreateScrollBar( ScrollBar::Orientation orientation) { diff --git a/www/chromium/files/patch-ui_views_style_platform__style.h b/www/chromium/files/patch-ui_views_style_platform__style.h new file mode 100644 index 000000000000..f4c2e51b0f54 --- /dev/null +++ b/www/chromium/files/patch-ui_views_style_platform__style.h @@ -0,0 +1,11 @@ +--- ui/views/style/platform_style.h.orig 2025-04-15 07:33:26 UTC ++++ ui/views/style/platform_style.h +@@ -84,7 +84,7 @@ class VIEWS_EXPORT PlatformStyle { + // Default setting at bubble creation time for whether arrow will be adjusted + // for bubbles going off-screen to bring more bubble area into view. Linux + // clips bubble windows that extend outside their parent window bounds. +- static constexpr bool kAdjustBubbleIfOffscreen = !BUILDFLAG(IS_LINUX); ++ static constexpr bool kAdjustBubbleIfOffscreen = (!BUILDFLAG(IS_LINUX) && !BUILDFLAG(IS_BSD)); + + // Default focus behavior on the platform. + static constexpr View::FocusBehavior kDefaultFocusBehavior = diff --git a/www/chromium/files/patch-ui_views_test_ui__controls__factory__desktop__aura__ozone.cc b/www/chromium/files/patch-ui_views_test_ui__controls__factory__desktop__aura__ozone.cc index f6dca0446540..c5f6b44e9e51 100644 --- a/www/chromium/files/patch-ui_views_test_ui__controls__factory__desktop__aura__ozone.cc +++ b/www/chromium/files/patch-ui_views_test_ui__controls__factory__desktop__aura__ozone.cc @@ -1,8 +1,8 @@ ---- ui/views/test/ui_controls_factory_desktop_aura_ozone.cc.orig 2024-03-22 08:19:40 UTC +--- ui/views/test/ui_controls_factory_desktop_aura_ozone.cc.orig 2025-01-15 09:18:26 UTC +++ ui/views/test/ui_controls_factory_desktop_aura_ozone.cc -@@ -296,7 +296,7 @@ void UpdateDisplaySync(const std::string& display_spec +@@ -237,7 +237,7 @@ bool SendMouseClick(MouseButton type, gfx::NativeWindo + window_hint); } - #endif -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) diff --git a/www/chromium/files/patch-ui_views_views__delegate.cc b/www/chromium/files/patch-ui_views_views__delegate.cc index f28d911af263..b02f52d1a2ec 100644 --- a/www/chromium/files/patch-ui_views_views__delegate.cc +++ b/www/chromium/files/patch-ui_views_views__delegate.cc @@ -1,6 +1,6 @@ ---- ui/views/views_delegate.cc.orig 2024-02-23 21:04:38 UTC +--- ui/views/views_delegate.cc.orig 2025-05-28 14:55:43 UTC +++ ui/views/views_delegate.cc -@@ -95,7 +95,7 @@ bool ViewsDelegate::IsWindowInMetro(gfx::NativeWindow +@@ -91,7 +91,7 @@ bool ViewsDelegate::IsWindowInMetro(gfx::NativeWindow return false; } #elif BUILDFLAG(ENABLE_DESKTOP_AURA) && \ diff --git a/www/chromium/files/patch-ui_views_views__delegate.h b/www/chromium/files/patch-ui_views_views__delegate.h index 6c402c3fd9db..afc59885aa77 100644 --- a/www/chromium/files/patch-ui_views_views__delegate.h +++ b/www/chromium/files/patch-ui_views_views__delegate.h @@ -1,6 +1,6 @@ ---- ui/views/views_delegate.h.orig 2024-02-23 21:04:38 UTC +--- ui/views/views_delegate.h.orig 2025-05-28 14:55:43 UTC +++ ui/views/views_delegate.h -@@ -146,7 +146,7 @@ class VIEWS_EXPORT ViewsDelegate { +@@ -143,7 +143,7 @@ class VIEWS_EXPORT ViewsDelegate { // environment. virtual bool IsWindowInMetro(gfx::NativeWindow window) const; #elif BUILDFLAG(ENABLE_DESKTOP_AURA) && \ diff --git a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.cc b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.cc index 0f0d27f9930a..d5a4a34252f1 100644 --- a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.cc +++ b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.cc @@ -1,6 +1,6 @@ ---- ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone.cc.orig 2024-03-22 08:19:40 UTC +--- ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone.cc.orig 2025-02-19 07:43:18 UTC +++ ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone.cc -@@ -196,7 +196,7 @@ DragOperation DesktopDragDropClientOzone::StartDragAnd +@@ -203,7 +203,7 @@ DragOperation DesktopDragDropClientOzone::StartDragAnd return selected_operation_; } diff --git a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.h b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.h index 044ff317287a..9e79a1f9d358 100644 --- a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.h +++ b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__drag__drop__client__ozone.h @@ -1,6 +1,6 @@ ---- ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone.h.orig 2024-02-23 21:04:38 UTC +--- ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone.h.orig 2024-11-14 07:57:23 UTC +++ ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone.h -@@ -65,7 +65,7 @@ class VIEWS_EXPORT DesktopDragDropClientOzone +@@ -67,7 +67,7 @@ class VIEWS_EXPORT DesktopDragDropClientOzone // The offset of |drag_widget_| relative to the mouse position. gfx::Vector2d offset; @@ -9,7 +9,7 @@ // The last received drag location. The drag widget is moved asynchronously // so its position is updated when the UI thread has time for that. When // the first change to the location happens, a call to UpdateDragWidget() -@@ -86,7 +86,7 @@ class VIEWS_EXPORT DesktopDragDropClientOzone +@@ -88,7 +88,7 @@ class VIEWS_EXPORT DesktopDragDropClientOzone const gfx::Point& root_location, int allowed_operations, ui::mojom::DragEventSource source) override; diff --git a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform.cc b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform.cc index 1cfef206e7d8..49a51910fa1d 100644 --- a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform.cc +++ b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform.cc @@ -1,6 +1,6 @@ ---- ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc.orig 2024-04-19 13:02:56 UTC +--- ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc.orig 2025-05-28 14:55:43 UTC +++ ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc -@@ -47,7 +47,7 @@ +@@ -50,7 +50,7 @@ #include "ui/wm/core/window_util.h" #include "ui/wm/public/window_move_client.h" @@ -9,15 +9,6 @@ #include "ui/views/widget/desktop_aura/desktop_drag_drop_client_ozone_linux.h" #endif -@@ -272,7 +272,7 @@ void DesktopWindowTreeHostPlatform::Init(const Widget: - if (params.type == Widget::InitParams::TYPE_WINDOW) - GetContentWindow()->SetProperty(aura::client::kAnimationsDisabledKey, true); - --#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) - const bool requires_accelerated_widget = params.requires_accelerated_widget; - #else - const bool requires_accelerated_widget = false; @@ -356,7 +356,7 @@ std::unique_ptr<aura::client::DragDropClient> DesktopWindowTreeHostPlatform::CreateDragDropClient() { ui::WmDragHandler* drag_handler = ui::GetWmDragHandler(*(platform_window())); @@ -27,7 +18,7 @@ std::make_unique<DesktopDragDropClientOzoneLinux>(window(), drag_handler); #else std::make_unique<DesktopDragDropClientOzone>(window(), drag_handler); -@@ -1117,7 +1117,7 @@ bool DesktopWindowTreeHostPlatform::RotateFocusForWidg +@@ -1188,7 +1188,7 @@ bool DesktopWindowTreeHostPlatform::RotateFocusForWidg // DesktopWindowTreeHost: // Linux subclasses this host and adds some Linux specific bits. diff --git a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform__impl__interactive__uitest.cc b/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform__impl__interactive__uitest.cc deleted file mode 100644 index cf90e710f117..000000000000 --- a/www/chromium/files/patch-ui_views_widget_desktop__aura_desktop__window__tree__host__platform__impl__interactive__uitest.cc +++ /dev/null @@ -1,11 +0,0 @@ ---- ui/views/widget/desktop_aura/desktop_window_tree_host_platform_impl_interactive_uitest.cc.orig 2024-04-19 13:02:56 UTC -+++ ui/views/widget/desktop_aura/desktop_window_tree_host_platform_impl_interactive_uitest.cc -@@ -23,7 +23,7 @@ - #include "ui/views/widget/widget_delegate.h" - #include "ui/views/window/native_frame_view.h" - --#if BUILDFLAG(IS_LINUX) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - #include "ui/views/widget/desktop_aura/desktop_window_tree_host_linux.h" - #include "ui/views/widget/desktop_aura/window_event_filter_linux.h" - using DesktopWindowTreeHostPlatformImpl = views::DesktopWindowTreeHostLinux; diff --git a/www/chromium/files/patch-ui_views_widget_root__view.cc b/www/chromium/files/patch-ui_views_widget_root__view.cc index ee65b9522e37..d5f99dcf2bdc 100644 --- a/www/chromium/files/patch-ui_views_widget_root__view.cc +++ b/www/chromium/files/patch-ui_views_widget_root__view.cc @@ -1,11 +1,11 @@ ---- ui/views/widget/root_view.cc.orig 2024-02-23 21:04:38 UTC +--- ui/views/widget/root_view.cc.orig 2025-02-19 07:43:18 UTC +++ ui/views/widget/root_view.cc -@@ -127,7 +127,7 @@ class AnnounceTextView : public View { +@@ -169,7 +169,7 @@ class AnnounceTextView : public View { #if BUILDFLAG(IS_CHROMEOS) // On ChromeOS, kAlert role can invoke an unnecessary event on reparenting. - node_data->role = ax::mojom::Role::kStaticText; + GetViewAccessibility().SetRole(ax::mojom::Role::kStaticText); -#elif BUILDFLAG(IS_LINUX) +#elif BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - // TODO(crbug.com/1024898): Use live regions (do not use alerts). + // TODO(crbug.com/40658933): Use live regions (do not use alerts). // May require setting kLiveStatus, kContainerLiveStatus to "polite". - node_data->role = ax::mojom::Role::kAlert; + GetViewAccessibility().SetRole(ax::mojom::Role::kAlert); diff --git a/www/chromium/files/patch-ui_views_widget_widget.cc b/www/chromium/files/patch-ui_views_widget_widget.cc index b7fb4023c802..ed637aa59e62 100644 --- a/www/chromium/files/patch-ui_views_widget_widget.cc +++ b/www/chromium/files/patch-ui_views_widget_widget.cc @@ -1,6 +1,6 @@ ---- ui/views/widget/widget.cc.orig 2024-04-19 13:02:56 UTC +--- ui/views/widget/widget.cc.orig 2025-07-02 06:08:04 UTC +++ ui/views/widget/widget.cc -@@ -54,7 +54,7 @@ +@@ -63,7 +63,7 @@ #include "ui/views/window/custom_frame_view.h" #include "ui/views/window/dialog_delegate.h" @@ -9,12 +9,12 @@ #include "ui/linux/linux_ui.h" #endif -@@ -2106,7 +2106,7 @@ const ui::NativeTheme* Widget::GetNativeTheme() const - if (parent_) +@@ -2473,7 +2473,7 @@ const ui::NativeTheme* Widget::GetNativeTheme() const return parent_->GetNativeTheme(); + } -#if BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) - if (auto* linux_ui_theme = ui::LinuxUiTheme::GetForWindow(GetNativeWindow())) + if (auto* linux_ui_theme = + ui::LinuxUiTheme::GetForWindow(GetNativeWindow())) { return linux_ui_theme->GetNativeTheme(); - #endif diff --git a/www/chromium/files/patch-ui_views_widget_widget.h b/www/chromium/files/patch-ui_views_widget_widget.h index 194c34c4af5d..b4bd08acca8b 100644 --- a/www/chromium/files/patch-ui_views_widget_widget.h +++ b/www/chromium/files/patch-ui_views_widget_widget.h @@ -1,11 +1,11 @@ ---- ui/views/widget/widget.h.orig 2024-04-19 13:02:56 UTC +--- ui/views/widget/widget.h.orig 2025-07-02 06:08:04 UTC +++ ui/views/widget/widget.h -@@ -427,7 +427,7 @@ class VIEWS_EXPORT Widget : public internal::NativeWid - // If set, the widget was created in headless mode. - bool headless_mode = false; +@@ -488,7 +488,7 @@ class VIEWS_EXPORT Widget : public internal::NativeWid + bool force_system_menu_for_frameless = false; + #endif // BUILDFLAG(IS_WIN) --#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) -+#if defined(USE_AURA) && (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD)) - // Indicates whether the desktop native widget is required for the widget. - // This may enforce changing the type of the underlying platform window. - // See crbug.com/1280332 +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) + // Only used by X11, for root level windows. Specifies the res_name and + // res_class fields, respectively, of the WM_CLASS window property. Controls + // window grouping and desktop file matching in Linux window managers. diff --git a/www/chromium/files/patch-ui_views_window_custom__frame__view.cc b/www/chromium/files/patch-ui_views_window_custom__frame__view.cc index afa50f7176c3..122602d00741 100644 --- a/www/chromium/files/patch-ui_views_window_custom__frame__view.cc +++ b/www/chromium/files/patch-ui_views_window_custom__frame__view.cc @@ -1,11 +1,11 @@ ---- ui/views/window/custom_frame_view.cc.orig 2022-10-24 13:33:33 UTC +--- ui/views/window/custom_frame_view.cc.orig 2025-02-19 07:43:18 UTC +++ ui/views/window/custom_frame_view.cc -@@ -266,7 +266,7 @@ int CustomFrameView::CaptionButtonY() const { +@@ -279,7 +279,7 @@ int CustomFrameView::NonClientTopBorderHeight() const + int CustomFrameView::CaptionButtonY() const { + // Maximized buttons start at window top so that even if their images aren't // drawn flush with the screen edge, they still obey Fitts' Law. - // TODO(crbug.com/1052397): Revisit the macro expression once build flag switch - // of lacros-chrome is complete. --#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) -+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS) || BUILDFLAG(IS_BSD) +-#if BUILDFLAG(IS_LINUX) ++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD) return FrameBorderThickness(); #else return frame_->IsMaximized() ? FrameBorderThickness() : kFrameShadowThickness; diff --git a/www/chromium/files/patch-ui_views_window_dialog__delegate.cc b/www/chromium/files/patch-ui_views_window_dialog__delegate.cc index 85484b6dbb1e..e09a6b683102 100644 --- a/www/chromium/files/patch-ui_views_window_dialog__delegate.cc +++ b/www/chromium/files/patch-ui_views_window_dialog__delegate.cc @@ -1,11 +1,11 @@ ---- ui/views/window/dialog_delegate.cc.orig 2023-12-10 06:10:27 UTC +--- ui/views/window/dialog_delegate.cc.orig 2025-07-02 06:08:04 UTC +++ ui/views/window/dialog_delegate.cc -@@ -79,7 +79,7 @@ Widget* DialogDelegate::CreateDialogWidget( +@@ -108,7 +108,7 @@ Widget* DialogDelegate::CreateDialogWidget( // static bool DialogDelegate::CanSupportCustomFrame(gfx::NativeView parent) { --#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)) && \ -+#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)) && \ - BUILDFLAG(ENABLE_DESKTOP_AURA) +-#if BUILDFLAG(IS_LINUX) && BUILDFLAG(ENABLE_DESKTOP_AURA) ++#if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)) && BUILDFLAG(ENABLE_DESKTOP_AURA) // The new style doesn't support unparented dialogs on Linux desktop. return parent != nullptr; + #else diff --git a/www/chromium/files/patch-v8_BUILD.gn b/www/chromium/files/patch-v8_BUILD.gn index ae13e3cd9bfd..07e154e2f8bc 100644 --- a/www/chromium/files/patch-v8_BUILD.gn +++ b/www/chromium/files/patch-v8_BUILD.gn @@ -1,21 +1,28 @@ ---- v8/BUILD.gn.orig 2024-04-19 13:02:56 UTC +--- v8/BUILD.gn.orig 2025-07-02 06:08:04 UTC +++ v8/BUILD.gn -@@ -1455,6 +1455,14 @@ config("toolchain") { - } else if (target_os == "chromeos") { - defines += [ "V8_HAVE_TARGET_OS" ] - defines += [ "V8_TARGET_OS_CHROMEOS" ] -+ } else if (target_os == "openbsd") { -+ defines += [ "V8_HAVE_TARGET_OS" ] -+ defines += [ "V8_TARGET_OS_OPENBSD" ] -+ defines += [ "V8_TARGET_OS_BSD" ] -+ } else if (target_os == "freebsd") { -+ defines += [ "V8_HAVE_TARGET_OS" ] -+ defines += [ "V8_TARGET_OS_FREEBSD" ] -+ defines += [ "V8_TARGET_OS_BSD" ] - } +@@ -1014,6 +1014,8 @@ external_v8_defines = [ + "V8_TARGET_OS_MACOS", + "V8_TARGET_OS_WIN", + "V8_TARGET_OS_CHROMEOS", ++ "V8_TARGET_OS_OPENBSD", ++ "V8_TARGET_OS_FREEBSD", + ] + + enabled_external_v8_defines = [ +@@ -1090,6 +1092,12 @@ if (target_os == "android") { + } else if (target_os == "chromeos") { + enabled_external_v8_defines += [ "V8_HAVE_TARGET_OS" ] + enabled_external_v8_defines += [ "V8_TARGET_OS_CHROMEOS" ] ++} else if (target_os == "openbsd") { ++ enabled_external_v8_defines += [ "V8_HAVE_TARGET_OS" ] ++ enabled_external_v8_defines += [ "V8_TARGET_OS_OPENBSD" ] ++} else if (target_os == "freebsd") { ++ enabled_external_v8_defines += [ "V8_HAVE_TARGET_OS" ] ++ enabled_external_v8_defines += [ "V8_TARGET_OS_FREEBSD" ] + } - # TODO(infra): Support v8_enable_prof on Windows. -@@ -2442,6 +2450,12 @@ template("run_mksnapshot") { + disabled_external_v8_defines = external_v8_defines - enabled_external_v8_defines +@@ -2598,6 +2606,12 @@ template("run_mksnapshot") { if (!v8_enable_builtins_profiling && v8_enable_builtins_reordering) { args += [ "--reorder-builtins" ] } @@ -27,8 +34,8 @@ + } } - # This is needed to distinguish between generating code for the simulator -@@ -6448,7 +6462,7 @@ v8_component("v8_libbase") { + if (v8_enable_turboshaft_csa) { +@@ -6760,7 +6774,7 @@ v8_component("v8_libbase") { } } @@ -37,7 +44,7 @@ sources += [ "src/base/debug/stack_trace_posix.cc", "src/base/platform/platform-linux.cc", -@@ -6459,6 +6473,18 @@ v8_component("v8_libbase") { +@@ -6771,6 +6785,18 @@ v8_component("v8_libbase") { "dl", "rt", ] diff --git a/www/chromium/files/patch-v8_include_v8-internal.h b/www/chromium/files/patch-v8_include_v8-internal.h index ced45871e0d6..7dc853e0ccd9 100644 --- a/www/chromium/files/patch-v8_include_v8-internal.h +++ b/www/chromium/files/patch-v8_include_v8-internal.h @@ -1,6 +1,6 @@ ---- v8/include/v8-internal.h.orig 2024-02-23 21:04:38 UTC +--- v8/include/v8-internal.h.orig 2025-02-19 07:43:18 UTC +++ v8/include/v8-internal.h -@@ -175,7 +175,7 @@ using SandboxedPointer_t = Address; +@@ -232,7 +232,7 @@ using SandboxedPointer_t = Address; #ifdef V8_ENABLE_SANDBOX // Size of the sandbox, excluding the guard regions surrounding it. diff --git a/www/chromium/files/patch-v8_include_v8config.h b/www/chromium/files/patch-v8_include_v8config.h index ba297af314bf..cb75744698bf 100644 --- a/www/chromium/files/patch-v8_include_v8config.h +++ b/www/chromium/files/patch-v8_include_v8config.h @@ -1,6 +1,6 @@ ---- v8/include/v8config.h.orig 2024-02-23 21:04:38 UTC +--- v8/include/v8config.h.orig 2025-05-05 10:57:53 UTC +++ v8/include/v8config.h -@@ -185,6 +185,8 @@ path. Add it with -I<path> to the command line +@@ -201,6 +201,8 @@ path. Add it with -I<path> to the command line && !defined(V8_TARGET_OS_FUCHSIA) \ && !defined(V8_TARGET_OS_IOS) \ && !defined(V8_TARGET_OS_LINUX) \ @@ -9,7 +9,7 @@ && !defined(V8_TARGET_OS_MACOS) \ && !defined(V8_TARGET_OS_WIN) \ && !defined(V8_TARGET_OS_CHROMEOS) -@@ -197,6 +199,8 @@ path. Add it with -I<path> to the command line +@@ -213,6 +215,8 @@ path. Add it with -I<path> to the command line || defined(V8_TARGET_OS_FUCHSIA) \ || defined(V8_TARGET_OS_IOS) \ || defined(V8_TARGET_OS_LINUX) \ @@ -18,12 +18,10 @@ || defined(V8_TARGET_OS_MACOS) \ || defined(V8_TARGET_OS_WIN) \ || defined(V8_TARGET_OS_CHROMEOS) -@@ -218,6 +222,16 @@ path. Add it with -I<path> to the command line - - #ifdef V8_OS_LINUX +@@ -236,6 +240,16 @@ path. Add it with -I<path> to the command line # define V8_TARGET_OS_LINUX -+#endif -+ + #endif + +#ifdef V8_OS_OPENBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD @@ -32,6 +30,16 @@ +#ifdef V8_OS_FREEBSD +# define V8_TARGET_OS_OPENBSD +# define V8_TARGET_OS_BSD - #endif - ++#endif ++ #ifdef V8_OS_MACOS + # define V8_TARGET_OS_MACOS + #endif +@@ -383,6 +397,7 @@ path. Add it with -I<path> to the command line + #if (defined(_M_X64) || defined(__x86_64__) /* x64 (everywhere) */ \ + || ((defined(__AARCH64EL__) || defined(_M_ARM64)) /* arm64, but ... */ \ + && !defined(_WIN32))) /* not on windows */ \ ++ && !defined(__OpenBSD__) /* not on OpenBSD */ \ + && !defined(COMPONENT_BUILD) /* no component build */\ + && __clang_major__ >= 17 /* clang >= 17 */ + # define V8_HAS_ATTRIBUTE_PRESERVE_MOST (__has_attribute(preserve_most)) diff --git a/www/chromium/files/patch-v8_src_api_api.cc b/www/chromium/files/patch-v8_src_api_api.cc index 6b75eb042528..12ee791a6cca 100644 --- a/www/chromium/files/patch-v8_src_api_api.cc +++ b/www/chromium/files/patch-v8_src_api_api.cc @@ -1,15 +1,15 @@ ---- v8/src/api/api.cc.orig 2024-04-19 13:02:56 UTC +--- v8/src/api/api.cc.orig 2025-07-02 06:08:04 UTC +++ v8/src/api/api.cc -@@ -144,7 +144,7 @@ - #include "src/wasm/wasm-serialization.h" - #endif // V8_ENABLE_WEBASSEMBLY +@@ -158,7 +158,7 @@ + #include "src/objects/intl-objects.h" + #endif // V8_INTL_SUPPORT -#if V8_OS_LINUX || V8_OS_DARWIN || V8_OS_FREEBSD +#if V8_OS_LINUX || V8_OS_DARWIN || V8_OS_FREEBSD || V8_OS_OPENBSD #include <signal.h> #include <unistd.h> -@@ -6396,7 +6396,7 @@ bool v8::V8::Initialize(const int build_config) { +@@ -6400,7 +6400,7 @@ bool v8::V8::Initialize(const int build_config) { return true; } diff --git a/www/chromium/files/patch-v8_src_base_platform_memory.h b/www/chromium/files/patch-v8_src_base_platform_memory.h index bdc9629bc45b..dbd115bfb277 100644 --- a/www/chromium/files/patch-v8_src_base_platform_memory.h +++ b/www/chromium/files/patch-v8_src_base_platform_memory.h @@ -1,16 +1,18 @@ ---- v8/src/base/platform/memory.h.orig 2023-02-08 09:03:45 UTC +--- v8/src/base/platform/memory.h.orig 2024-10-22 08:31:56 UTC +++ v8/src/base/platform/memory.h -@@ -19,11 +19,11 @@ - - #if V8_OS_DARWIN +@@ -21,13 +21,13 @@ #include <malloc/malloc.h> --#else // !V8_OS_DARWIN -+#elif !V8_OS_BSD + #elif V8_OS_OPENBSD + #include <sys/malloc.h> +-#elif V8_OS_ZOS ++#elif (V8_OS_ZOS || V8_OS_BSD) + #include <stdlib.h> + #else #include <malloc.h> - #endif // !V8_OS_DARWIN + #endif --#if (V8_OS_POSIX && !V8_OS_AIX && !V8_OS_SOLARIS) || V8_OS_WIN -+#if (V8_OS_POSIX && !V8_OS_AIX && !V8_OS_SOLARIS && !V8_OS_BSD) || V8_OS_WIN +-#if (V8_OS_POSIX && !V8_OS_AIX && !V8_OS_SOLARIS && !V8_OS_ZOS && !V8_OS_OPENBSD) || V8_OS_WIN ++#if (V8_OS_POSIX && !V8_OS_AIX && !V8_OS_SOLARIS && !V8_OS_ZOS && !V8_OS_BSD) || V8_OS_WIN #define V8_HAS_MALLOC_USABLE_SIZE 1 - #endif // (V8_OS_POSIX && !V8_OS_AIX && !V8_OS_SOLARIS) || V8_OS_WIN + #endif diff --git a/www/chromium/files/patch-v8_src_base_platform_platform-openbsd.cc b/www/chromium/files/patch-v8_src_base_platform_platform-openbsd.cc index 74812f6dcf24..f54b27c95474 100644 --- a/www/chromium/files/patch-v8_src_base_platform_platform-openbsd.cc +++ b/www/chromium/files/patch-v8_src_base_platform_platform-openbsd.cc @@ -1,4 +1,4 @@ ---- v8/src/base/platform/platform-openbsd.cc.orig 2023-04-28 17:01:32 UTC +--- v8/src/base/platform/platform-openbsd.cc.orig 2024-07-30 11:12:21 UTC +++ v8/src/base/platform/platform-openbsd.cc @@ -6,6 +6,7 @@ // POSIX-compatible parts, the implementation is in platform-posix.cc. @@ -24,5 +24,5 @@ + return reinterpret_cast<uint8_t*>(base) + ss.ss_size; +} - std::vector<OS::MemoryRange> OS::GetFreeMemoryRangesWithin( + std::optional<OS::MemoryRange> OS::GetFirstFreeMemoryRangeWithin( OS::Address boundary_start, OS::Address boundary_end, size_t minimum_size, diff --git a/www/chromium/files/patch-v8_src_base_platform_platform-posix.cc b/www/chromium/files/patch-v8_src_base_platform_platform-posix.cc index 42359ce002dc..fc3f8c61af52 100644 --- a/www/chromium/files/patch-v8_src_base_platform_platform-posix.cc +++ b/www/chromium/files/patch-v8_src_base_platform_platform-posix.cc @@ -1,15 +1,6 @@ ---- v8/src/base/platform/platform-posix.cc.orig 2024-03-22 08:19:40 UTC +--- v8/src/base/platform/platform-posix.cc.orig 2025-07-02 06:08:04 UTC +++ v8/src/base/platform/platform-posix.cc -@@ -54,7 +54,7 @@ - #if V8_OS_DARWIN - #include <mach/mach.h> - #include <malloc/malloc.h> --#else -+#elif !V8_OS_BSD - #include <malloc.h> - #endif - -@@ -72,7 +72,7 @@ +@@ -76,7 +76,7 @@ #include <sys/syscall.h> #endif @@ -18,7 +9,7 @@ #define MAP_ANONYMOUS MAP_ANON #endif -@@ -303,8 +303,15 @@ void OS::SetRandomMmapSeed(int64_t seed) { +@@ -313,8 +313,15 @@ void OS::SetRandomMmapSeed(int64_t seed) { } } @@ -34,7 +25,7 @@ uintptr_t raw_addr; { MutexGuard guard(rng_mutex.Pointer()); -@@ -399,6 +406,7 @@ void* OS::GetRandomMmapAddr() { +@@ -411,6 +418,7 @@ void* OS::GetRandomMmapAddr() { #endif return reinterpret_cast<void*>(raw_addr); } @@ -42,8 +33,8 @@ // TODO(bbudge) Move Cygwin and Fuchsia stuff into platform-specific files. #if !V8_OS_CYGWIN && !V8_OS_FUCHSIA -@@ -672,7 +680,7 @@ void OS::DestroySharedMemoryHandle(PlatformSharedMemor - +@@ -699,7 +707,7 @@ void OS::DestroySharedMemoryHandle(PlatformSharedMemor + #if !V8_OS_ZOS // static bool OS::HasLazyCommits() { -#if V8_OS_AIX || V8_OS_LINUX || V8_OS_DARWIN @@ -51,7 +42,7 @@ return true; #else // TODO(bbudge) Return true for all POSIX platforms. -@@ -1304,7 +1312,7 @@ void Thread::SetThreadLocal(LocalStorageKey key, void* +@@ -1344,7 +1352,7 @@ void Thread::SetThreadLocal(LocalStorageKey key, void* // keep this version in POSIX as most Linux-compatible derivatives will // support it. MacOS and FreeBSD are different here. #if !defined(V8_OS_FREEBSD) && !defined(V8_OS_DARWIN) && !defined(_AIX) && \ diff --git a/www/chromium/files/patch-v8_src_base_small-vector.h b/www/chromium/files/patch-v8_src_base_small-vector.h deleted file mode 100644 index 4472541804e6..000000000000 --- a/www/chromium/files/patch-v8_src_base_small-vector.h +++ /dev/null @@ -1,11 +0,0 @@ ---- v8/src/base/small-vector.h.orig 2022-10-25 08:25:05 UTC -+++ v8/src/base/small-vector.h -@@ -22,7 +22,7 @@ template <typename T, size_t kSize, typename Allocator - class SmallVector { - // Currently only support trivially copyable and trivially destructible data - // types, as it uses memcpy to copy elements and never calls destructors. -- ASSERT_TRIVIALLY_COPYABLE(T); -+ // XXX FREEBSD ASSERT_TRIVIALLY_COPYABLE(T); - static_assert(std::is_trivially_destructible<T>::value); - - public: diff --git a/www/chromium/files/patch-v8_src_base_sys-info.cc b/www/chromium/files/patch-v8_src_base_sys-info.cc index d3c532c9289f..f7429f1ac8f0 100644 --- a/www/chromium/files/patch-v8_src_base_sys-info.cc +++ b/www/chromium/files/patch-v8_src_base_sys-info.cc @@ -1,6 +1,6 @@ ---- v8/src/base/sys-info.cc.orig 2022-02-07 13:39:41 UTC +--- v8/src/base/sys-info.cc.orig 2024-10-22 08:31:56 UTC +++ v8/src/base/sys-info.cc -@@ -38,7 +38,7 @@ namespace base { +@@ -36,7 +36,7 @@ namespace base { // static int SysInfo::NumberOfProcessors() { #if V8_OS_OPENBSD diff --git a/www/chromium/files/patch-v8_src_diagnostics_perf-jit.cc b/www/chromium/files/patch-v8_src_diagnostics_perf-jit.cc index 3c55690e02aa..023d7715ea56 100644 --- a/www/chromium/files/patch-v8_src_diagnostics_perf-jit.cc +++ b/www/chromium/files/patch-v8_src_diagnostics_perf-jit.cc @@ -1,11 +1,11 @@ ---- v8/src/diagnostics/perf-jit.cc.orig 2023-10-11 18:22:24 UTC +--- v8/src/diagnostics/perf-jit.cc.orig 2025-05-28 14:55:43 UTC +++ v8/src/diagnostics/perf-jit.cc @@ -31,7 +31,7 @@ #include "src/flags/flags.h" - // Only compile the {LinuxPerfJitLogger} on Linux. --#if V8_OS_LINUX -+#if defined(V8_OS_LINUX) || defined(V8_OS_BSD) + // Only compile the {PerfJitLogger} on Linux & Darwin. +-#if V8_OS_LINUX || V8_OS_DARWIN ++#if V8_OS_LINUX || V8_OS_DARWIN || V8_OS_BSD #include <fcntl.h> #include <sys/mman.h> diff --git a/www/chromium/files/patch-v8_src_diagnostics_perf-jit.h b/www/chromium/files/patch-v8_src_diagnostics_perf-jit.h index b5c06ad88b32..e58534f8fd5f 100644 --- a/www/chromium/files/patch-v8_src_diagnostics_perf-jit.h +++ b/www/chromium/files/patch-v8_src_diagnostics_perf-jit.h @@ -1,11 +1,11 @@ ---- v8/src/diagnostics/perf-jit.h.orig 2022-06-17 14:20:10 UTC +--- v8/src/diagnostics/perf-jit.h.orig 2025-05-28 14:55:43 UTC +++ v8/src/diagnostics/perf-jit.h @@ -31,7 +31,7 @@ #include "include/v8config.h" - // {LinuxPerfJitLogger} is only implemented on Linux. --#if V8_OS_LINUX -+#if defined(V8_OS_LINUX) || defined(V8_OS_BSD) + // {PerfJitLogger} is only implemented on Linux & Darwin. +-#if V8_OS_LINUX || V8_OS_DARWIN ++#if V8_OS_LINUX || V8_OS_DARWIN || V8_OS_BSD #include "src/logging/log.h" diff --git a/www/chromium/files/patch-v8_src_execution_isolate.cc b/www/chromium/files/patch-v8_src_execution_isolate.cc index 281fb94c55ea..6e4a73698048 100644 --- a/www/chromium/files/patch-v8_src_execution_isolate.cc +++ b/www/chromium/files/patch-v8_src_execution_isolate.cc @@ -1,6 +1,6 @@ ---- v8/src/execution/isolate.cc.orig 2024-04-19 13:02:56 UTC +--- v8/src/execution/isolate.cc.orig 2025-07-02 06:08:04 UTC +++ v8/src/execution/isolate.cc -@@ -153,6 +153,10 @@ +@@ -173,6 +173,10 @@ #include "src/execution/simulator-base.h" #endif @@ -11,7 +11,7 @@ extern "C" const uint8_t v8_Default_embedded_blob_code_[]; extern "C" uint32_t v8_Default_embedded_blob_code_size_; extern "C" const uint8_t v8_Default_embedded_blob_data_[]; -@@ -4232,6 +4236,13 @@ void Isolate::InitializeDefaultEmbeddedBlob() { +@@ -5171,6 +5175,13 @@ void Isolate::InitializeDefaultEmbeddedBlob() { uint32_t code_size = DefaultEmbeddedBlobCodeSize(); const uint8_t* data = DefaultEmbeddedBlobData(); uint32_t data_size = DefaultEmbeddedBlobDataSize(); diff --git a/www/chromium/files/patch-v8_src_flags_flags.cc b/www/chromium/files/patch-v8_src_flags_flags.cc index 9dbc8dda71fd..16ee51dd6b20 100644 --- a/www/chromium/files/patch-v8_src_flags_flags.cc +++ b/www/chromium/files/patch-v8_src_flags_flags.cc @@ -1,6 +1,6 @@ ---- v8/src/flags/flags.cc.orig 2024-04-19 13:02:56 UTC +--- v8/src/flags/flags.cc.orig 2025-03-05 08:14:56 UTC +++ v8/src/flags/flags.cc -@@ -15,6 +15,10 @@ +@@ -16,6 +16,10 @@ #include <set> #include <sstream> @@ -8,22 +8,10 @@ +#include <sys/mman.h> +#endif + - #include "src/base/functional.h" + #include "src/base/hashing.h" #include "src/base/lazy-instance.h" #include "src/base/platform/platform.h" -@@ -34,7 +38,11 @@ - namespace v8::internal { - - // Define {v8_flags}, declared in flags.h. -+#if V8_OS_OPENBSD -+FlagValues v8_flags __attribute__((section(".openbsd.mutable"))); -+#else - FlagValues v8_flags; -+#endif - - // {v8_flags} needs to be aligned to a memory page, and the size needs to be a - // multiple of a page size. This is required for memory-protection of the memory -@@ -789,6 +797,10 @@ void FlagList::FreezeFlags() { +@@ -823,6 +827,10 @@ void FlagList::FreezeFlags() { // Note that for string flags we only protect the pointer itself, but not the // string storage. TODO(12887): Fix this. base::OS::SetDataReadOnly(&v8_flags, sizeof(v8_flags)); diff --git a/www/chromium/files/patch-v8_src_libsampler_sampler.cc b/www/chromium/files/patch-v8_src_libsampler_sampler.cc new file mode 100644 index 000000000000..4533ba3fe003 --- /dev/null +++ b/www/chromium/files/patch-v8_src_libsampler_sampler.cc @@ -0,0 +1,19 @@ +--- v8/src/libsampler/sampler.cc.orig 2025-07-02 06:08:04 UTC ++++ v8/src/libsampler/sampler.cc +@@ -527,6 +527,16 @@ void SignalHandler::FillRegisterState(void* context, R + state->pc = reinterpret_cast<void*>(mcontext.__gregs[_REG_PC]); + state->sp = reinterpret_cast<void*>(mcontext.__gregs[_REG_SP]); + state->fp = reinterpret_cast<void*>(mcontext.__gregs[_REG_FP]); ++#elif V8_HOST_ARCH_ARM64 ++#ifdef __CHERI_PURE_CAPABILITY__ ++ state->pc = reinterpret_cast<void*>(mcontext.mc_capregs.cap_elr); ++ state->sp = reinterpret_cast<void*>(mcontext.mc_capregs.cap_sp); ++ state->fp = reinterpret_cast<void*>(mcontext.mc_capregs.cap_x[29]); ++#else // !__CHERI_PURE_CAPABILITY__ ++ state->pc = reinterpret_cast<void*>(mcontext.mc_gpregs.gp_elr); ++ state->sp = reinterpret_cast<void*>(mcontext.mc_gpregs.gp_sp); ++ state->fp = reinterpret_cast<void*>(mcontext.mc_gpregs.gp_x[29]); ++#endif // __CHERI_PURE_CAPABILITY__ + #endif // V8_HOST_ARCH_* + #elif V8_OS_NETBSD + #if V8_HOST_ARCH_IA32 diff --git a/www/chromium/files/patch-v8_src_sandbox_sandbox.cc b/www/chromium/files/patch-v8_src_sandbox_sandbox.cc index 860e5afb8cd8..8ea9f08c3823 100644 --- a/www/chromium/files/patch-v8_src_sandbox_sandbox.cc +++ b/www/chromium/files/patch-v8_src_sandbox_sandbox.cc @@ -1,6 +1,6 @@ ---- v8/src/sandbox/sandbox.cc.orig 2023-02-08 09:03:45 UTC +--- v8/src/sandbox/sandbox.cc.orig 2025-03-05 08:14:56 UTC +++ v8/src/sandbox/sandbox.cc -@@ -46,7 +46,7 @@ static Address DetermineAddressSpaceLimit() { +@@ -59,7 +59,7 @@ static Address DetermineAddressSpaceLimit() { } #endif // V8_TARGET_ARCH_X64 diff --git a/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.cc b/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.cc index 149980d51c9a..b54eae551d58 100644 --- a/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.cc +++ b/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.cc @@ -1,9 +1,9 @@ ---- v8/src/snapshot/embedded/platform-embedded-file-writer-base.cc.orig 2023-11-03 10:09:45 UTC +--- v8/src/snapshot/embedded/platform-embedded-file-writer-base.cc.orig 2024-08-26 12:06:38 UTC +++ v8/src/snapshot/embedded/platform-embedded-file-writer-base.cc -@@ -143,6 +143,8 @@ EmbeddedTargetOs ToEmbeddedTargetOs(const char* s) { - return EmbeddedTargetOs::kWin; - } else if (string == "starboard") { +@@ -148,6 +148,8 @@ EmbeddedTargetOs ToEmbeddedTargetOs(const char* s) { return EmbeddedTargetOs::kStarboard; + } else if (string == "zos") { + return EmbeddedTargetOs::kZOS; + } else if (string == "openbsd") { + return EmbeddedTargetOs::kOpenBSD; } else { diff --git a/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.h b/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.h index ca28e2aa9551..e5b8cbf5bee0 100644 --- a/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.h +++ b/www/chromium/files/patch-v8_src_snapshot_embedded_platform-embedded-file-writer-base.h @@ -1,9 +1,9 @@ ---- v8/src/snapshot/embedded/platform-embedded-file-writer-base.h.orig 2023-02-08 09:03:45 UTC +--- v8/src/snapshot/embedded/platform-embedded-file-writer-base.h.orig 2024-09-30 07:45:04 UTC +++ v8/src/snapshot/embedded/platform-embedded-file-writer-base.h -@@ -31,6 +31,7 @@ enum class EmbeddedTargetOs { - kMac, +@@ -36,6 +36,7 @@ enum class EmbeddedTargetOs { kWin, kStarboard, + kZOS, + kOpenBSD, kGeneric, // Everything not covered above falls in here. }; diff --git a/www/chromium/files/patch-v8_src_trap-handler_handler-inside-posix.cc b/www/chromium/files/patch-v8_src_trap-handler_handler-inside-posix.cc index 1356ada33686..693ca8b38b32 100644 --- a/www/chromium/files/patch-v8_src_trap-handler_handler-inside-posix.cc +++ b/www/chromium/files/patch-v8_src_trap-handler_handler-inside-posix.cc @@ -1,6 +1,6 @@ ---- v8/src/trap-handler/handler-inside-posix.cc.orig 2024-04-19 13:02:56 UTC +--- v8/src/trap-handler/handler-inside-posix.cc.orig 2025-07-02 06:08:04 UTC +++ v8/src/trap-handler/handler-inside-posix.cc -@@ -61,6 +61,8 @@ namespace trap_handler { +@@ -62,6 +62,8 @@ namespace trap_handler { #define CONTEXT_REG(reg, REG) &uc->uc_mcontext->__ss.__##reg #elif V8_OS_FREEBSD #define CONTEXT_REG(reg, REG) &uc->uc_mcontext.mc_##reg @@ -9,7 +9,7 @@ #else #error "Unsupported platform." #endif -@@ -80,8 +82,12 @@ bool IsKernelGeneratedSignal(siginfo_t* info) { +@@ -81,8 +83,12 @@ bool IsKernelGeneratedSignal(siginfo_t* info) { // si_code at its default of 0 for signals that don’t originate in hardware. // The other conditions are only relevant for Linux. return info->si_code > 0 && info->si_code != SI_USER && diff --git a/www/chromium/files/patch-v8_src_trap-handler_trap-handler.h b/www/chromium/files/patch-v8_src_trap-handler_trap-handler.h index 176500e103bd..11de58618a02 100644 --- a/www/chromium/files/patch-v8_src_trap-handler_trap-handler.h +++ b/www/chromium/files/patch-v8_src_trap-handler_trap-handler.h @@ -1,11 +1,11 @@ ---- v8/src/trap-handler/trap-handler.h.orig 2023-05-31 08:12:17 UTC +--- v8/src/trap-handler/trap-handler.h.orig 2025-05-28 14:55:43 UTC +++ v8/src/trap-handler/trap-handler.h -@@ -20,7 +20,7 @@ namespace trap_handler { +@@ -18,7 +18,7 @@ namespace v8::internal::trap_handler { // X64 on Linux, Windows, MacOS, FreeBSD. #if V8_HOST_ARCH_X64 && V8_TARGET_ARCH_X64 && \ ((V8_OS_LINUX && !V8_OS_ANDROID) || V8_OS_WIN || V8_OS_DARWIN || \ - V8_OS_FREEBSD) + V8_OS_FREEBSD || V8_OS_OPENBSD) #define V8_TRAP_HANDLER_SUPPORTED true - // Arm64 (non-simulator) on Mac and Linux. + // Arm64 native on Linux, Windows, MacOS. #elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_ARM64 && \ diff --git a/www/chromium/files/patch-v8_src_wasm_baseline_ia32_liftoff-assembler-ia32-inl.h b/www/chromium/files/patch-v8_src_wasm_baseline_ia32_liftoff-assembler-ia32-inl.h index 19a96c42378d..f983f11336b3 100644 --- a/www/chromium/files/patch-v8_src_wasm_baseline_ia32_liftoff-assembler-ia32-inl.h +++ b/www/chromium/files/patch-v8_src_wasm_baseline_ia32_liftoff-assembler-ia32-inl.h @@ -1,6 +1,6 @@ ---- v8/src/wasm/baseline/ia32/liftoff-assembler-ia32-inl.h.orig 2024-04-19 13:02:56 UTC +--- v8/src/wasm/baseline/ia32/liftoff-assembler-ia32-inl.h.orig 2025-07-02 06:08:04 UTC +++ v8/src/wasm/baseline/ia32/liftoff-assembler-ia32-inl.h -@@ -510,7 +510,7 @@ void LiftoffAssembler::StoreTaggedPointer(Register dst +@@ -597,7 +597,7 @@ void LiftoffAssembler::AtomicStoreTaggedPointer( } void LiftoffAssembler::Load(LiftoffRegister dst, Register src_addr, @@ -9,7 +9,7 @@ LoadType type, uint32_t* protected_load_pc, bool /* is_load_mem */, bool /* i64_offset */, bool needs_shift) { -@@ -587,7 +587,7 @@ void LiftoffAssembler::Load(LiftoffRegister dst, Regis +@@ -677,7 +677,7 @@ void LiftoffAssembler::Load(LiftoffRegister dst, Regis } void LiftoffAssembler::Store(Register dst_addr, Register offset_reg, @@ -18,7 +18,7 @@ StoreType type, LiftoffRegList pinned, uint32_t* protected_store_pc, bool /* is_store_mem */, bool /* i64_offset */) { -@@ -663,7 +663,7 @@ void LiftoffAssembler::Store(Register dst_addr, Regist +@@ -756,7 +756,7 @@ void LiftoffAssembler::Store(Register dst_addr, Regist } void LiftoffAssembler::AtomicLoad(LiftoffRegister dst, Register src_addr, @@ -27,7 +27,7 @@ LoadType type, LiftoffRegList /* pinned */, bool /* i64_offset */) { if (type.value() != LoadType::kI64Load) { -@@ -681,7 +681,7 @@ void LiftoffAssembler::AtomicLoad(LiftoffRegister dst, +@@ -774,7 +774,7 @@ void LiftoffAssembler::AtomicLoad(LiftoffRegister dst, } void LiftoffAssembler::AtomicStore(Register dst_addr, Register offset_reg, @@ -36,7 +36,7 @@ StoreType type, LiftoffRegList pinned, bool /* i64_offset */) { DCHECK_LE(offset_imm, std::numeric_limits<int32_t>::max()); -@@ -751,7 +751,7 @@ enum Binop { kAdd, kSub, kAnd, kOr, kXor, kExchange }; +@@ -844,7 +844,7 @@ enum Binop { kAdd, kSub, kAnd, kOr, kXor, kExchange }; inline void AtomicAddOrSubOrExchange32(LiftoffAssembler* lasm, Binop binop, Register dst_addr, Register offset_reg, @@ -45,7 +45,7 @@ LiftoffRegister value, LiftoffRegister result, StoreType type) { DCHECK_EQ(value, result); -@@ -819,7 +819,7 @@ inline void AtomicAddOrSubOrExchange32(LiftoffAssemble +@@ -912,7 +912,7 @@ inline void AtomicAddOrSubOrExchange32(LiftoffAssemble } inline void AtomicBinop32(LiftoffAssembler* lasm, Binop op, Register dst_addr, @@ -54,7 +54,7 @@ LiftoffRegister value, LiftoffRegister result, StoreType type) { DCHECK_EQ(value, result); -@@ -934,7 +934,7 @@ inline void AtomicBinop32(LiftoffAssembler* lasm, Bino +@@ -1027,7 +1027,7 @@ inline void AtomicBinop32(LiftoffAssembler* lasm, Bino } inline void AtomicBinop64(LiftoffAssembler* lasm, Binop op, Register dst_addr, @@ -63,7 +63,7 @@ LiftoffRegister value, LiftoffRegister result) { // We need {ebx} here, which is the root register. As the root register it // needs special treatment. As we use {ebx} directly in the code below, we -@@ -1030,7 +1030,7 @@ inline void AtomicBinop64(LiftoffAssembler* lasm, Bino +@@ -1123,7 +1123,7 @@ inline void AtomicBinop64(LiftoffAssembler* lasm, Bino } // namespace liftoff void LiftoffAssembler::AtomicAdd(Register dst_addr, Register offset_reg, @@ -72,7 +72,7 @@ LiftoffRegister result, StoreType type, bool /* i64_offset */) { if (type.value() == StoreType::kI64Store) { -@@ -1044,7 +1044,7 @@ void LiftoffAssembler::AtomicAdd(Register dst_addr, Re +@@ -1137,7 +1137,7 @@ void LiftoffAssembler::AtomicAdd(Register dst_addr, Re } void LiftoffAssembler::AtomicSub(Register dst_addr, Register offset_reg, @@ -81,7 +81,7 @@ LiftoffRegister result, StoreType type, bool /* i64_offset */) { if (type.value() == StoreType::kI64Store) { -@@ -1057,7 +1057,7 @@ void LiftoffAssembler::AtomicSub(Register dst_addr, Re +@@ -1150,7 +1150,7 @@ void LiftoffAssembler::AtomicSub(Register dst_addr, Re } void LiftoffAssembler::AtomicAnd(Register dst_addr, Register offset_reg, @@ -90,7 +90,7 @@ LiftoffRegister result, StoreType type, bool /* i64_offset */) { if (type.value() == StoreType::kI64Store) { -@@ -1071,7 +1071,7 @@ void LiftoffAssembler::AtomicAnd(Register dst_addr, Re +@@ -1164,7 +1164,7 @@ void LiftoffAssembler::AtomicAnd(Register dst_addr, Re } void LiftoffAssembler::AtomicOr(Register dst_addr, Register offset_reg, @@ -99,7 +99,7 @@ LiftoffRegister result, StoreType type, bool /* i64_offset */) { if (type.value() == StoreType::kI64Store) { -@@ -1085,7 +1085,7 @@ void LiftoffAssembler::AtomicOr(Register dst_addr, Reg +@@ -1178,7 +1178,7 @@ void LiftoffAssembler::AtomicOr(Register dst_addr, Reg } void LiftoffAssembler::AtomicXor(Register dst_addr, Register offset_reg, @@ -108,7 +108,7 @@ LiftoffRegister result, StoreType type, bool /* i64_offset */) { if (type.value() == StoreType::kI64Store) { -@@ -1099,7 +1099,7 @@ void LiftoffAssembler::AtomicXor(Register dst_addr, Re +@@ -1192,7 +1192,7 @@ void LiftoffAssembler::AtomicXor(Register dst_addr, Re } void LiftoffAssembler::AtomicExchange(Register dst_addr, Register offset_reg, @@ -117,7 +117,7 @@ LiftoffRegister value, LiftoffRegister result, StoreType type, bool /* i64_offset */) { -@@ -1114,7 +1114,7 @@ void LiftoffAssembler::AtomicExchange(Register dst_add +@@ -1207,7 +1207,7 @@ void LiftoffAssembler::AtomicExchange(Register dst_add } void LiftoffAssembler::AtomicCompareExchange( diff --git a/www/chromium/files/patch-v8_tools_run.py b/www/chromium/files/patch-v8_tools_run.py index 194cc4ae7c4c..5606a90b788e 100644 --- a/www/chromium/files/patch-v8_tools_run.py +++ b/www/chromium/files/patch-v8_tools_run.py @@ -1,11 +1,11 @@ ---- v8/tools/run.py.orig 2022-05-19 14:06:27 UTC +--- v8/tools/run.py.orig 2024-10-22 08:31:56 UTC +++ v8/tools/run.py -@@ -9,7 +9,7 @@ scripts.""" - import subprocess - import sys +@@ -21,7 +21,7 @@ if cmd and cmd[0] == '--redirect-stdout': + kwargs = dict(stdout=subprocess.PIPE) + cmd = cmd[2:] --result = subprocess.call(sys.argv[1:]) -+sys.exit(subprocess.call(sys.argv[1:], env={"LD_LIBRARY_PATH":"${WRKSRC}/out/Release"})) - if result != 0: - # Windows error codes such as 0xC0000005 and 0xC0000409 are much easier - # to recognize and differentiate in hex. +-process = subprocess.Popen(cmd, **kwargs) ++process = subprocess.Popen(cmd, env={"LD_LIBRARY_PATH":"${WRKSRC}/out/Release"}, **kwargs) + stdout, _ = process.communicate() + if stdout_file: + with stdout_file.open('w') as f: |