summaryrefslogtreecommitdiff
path: root/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc
diff options
context:
space:
mode:
Diffstat (limited to 'www/chromium/files/patch-chrome_app_chrome__main__delegate.cc')
-rw-r--r--www/chromium/files/patch-chrome_app_chrome__main__delegate.cc56
1 files changed, 33 insertions, 23 deletions
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..1888fd850cef 100644
--- a/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc
+++ b/www/chromium/files/patch-chrome_app_chrome__main__delegate.cc
@@ -1,6 +1,6 @@
---- chrome/app/chrome_main_delegate.cc.orig 2024-04-19 13:02:56 UTC
+--- chrome/app/chrome_main_delegate.cc.orig 2024-05-21 18:07:39 UTC
+++ chrome/app/chrome_main_delegate.cc
-@@ -146,7 +146,7 @@
+@@ -137,7 +137,7 @@
#include "components/about_ui/credit_utils.h"
#endif
@@ -9,7 +9,7 @@
#include "components/nacl/common/nacl_paths.h"
#include "components/nacl/zygote/nacl_fork_delegate_linux.h"
#endif
-@@ -189,20 +189,20 @@
+@@ -180,21 +180,21 @@
#include "v8/include/v8.h"
#endif
@@ -21,6 +21,7 @@
-#if BUILDFLAG(IS_LINUX)
+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)
#include "base/nix/scoped_xdg_activation_token_injector.h"
+ #include "ui/linux/display_server_utils.h"
#endif
-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_ANDROID)
@@ -34,7 +35,16 @@
#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
+@@ -241,7 +241,7 @@
+ #include "base/scoped_add_feature_flags.h"
+ #include "ui/base/ui_base_features.h"
+ #include "ui/ozone/public/ozone_platform.h"
+-#if BUILDFLAG(IS_LINUX)
++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)
+ #include "chrome/browser/chrome_browser_main_extra_parts_linux.h"
+ #endif
+ #endif // BUILDFLAG(IS_OZONE)
+@@ -341,7 +341,7 @@ void AdjustLinuxOOMScore(const std::string& process_ty
// and resources loaded.
bool SubprocessNeedsResourceBundle(const std::string& process_type) {
return
@@ -43,7 +53,7 @@
// The zygote process opens the resources for the renderers.
process_type == switches::kZygoteProcess ||
#endif
-@@ -431,7 +431,7 @@ bool HandleVersionSwitches(const base::CommandLine& co
+@@ -426,7 +426,7 @@ bool HandleVersionSwitches(const base::CommandLine& co
// TODO(crbug.com/1052397): Revisit the macro expression once build flag switch
// of lacros-chrome is complete.
@@ -52,7 +62,7 @@
// 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() {
+@@ -472,7 +472,7 @@ void SetCrashpadUploadConsentPostLogin() {
}
#endif // BUILDFLAG(IS_CHROMEOS_LACROS)
@@ -61,7 +71,7 @@
void SIGTERMProfilingShutdown(int signal) {
content::Profiling::Stop();
struct sigaction sigact;
-@@ -559,7 +559,7 @@ std::optional<int> AcquireProcessSingleton(
+@@ -554,7 +554,7 @@ std::optional<int> AcquireProcessSingleton(
// process can be exited.
ChromeProcessSingleton::CreateInstance(user_data_dir);
@@ -70,7 +80,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_
+@@ -638,7 +638,7 @@ void InitializeUserDataDir(base::CommandLine* command_
std::string process_type =
command_line->GetSwitchValueASCII(switches::kProcessType);
@@ -79,7 +89,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
+@@ -765,7 +765,7 @@ void RecordMainStartupMetrics(base::TimeTicks applicat
#endif
#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || \
@@ -88,8 +98,17 @@
// Record the startup process creation time on supported platforms. On Android
// this is recorded in ChromeMainDelegateAndroid.
startup_metric_utils::GetCommon().RecordStartupProcessCreationTime(
+@@ -962,7 +962,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();
@@ -1155,7 +1155,7 @@ void ChromeMainDelegate::CommonEarlyInitialization(Inv
- chrome::GetChannel() == version_info::Channel::DEV;
+ const bool is_canary_dev = IsCanaryDev();
const bool emit_crashes =
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_MAC) || \
- BUILDFLAG(IS_WIN)
@@ -97,16 +116,7 @@
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
+@@ -1310,7 +1310,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom
// TODO(crbug.com/1052397): Revisit the macro expression once build flag
// switch of lacros-chrome is complete.
@@ -115,7 +125,7 @@
// This will directly exit if the user asked for help.
HandleHelpSwitches(command_line);
#endif
-@@ -1353,7 +1353,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom
+@@ -1340,7 +1340,7 @@ std::optional<int> ChromeMainDelegate::BasicStartupCom
#if BUILDFLAG(IS_CHROMEOS)
chromeos::dbus_paths::RegisterPathProvider();
#endif
@@ -124,7 +134,7 @@
nacl::RegisterPathProvider();
#endif
-@@ -1750,7 +1750,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
+@@ -1735,7 +1735,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
CHECK(!loaded_locale.empty()) << "Locale could not be found for " << locale;
}
@@ -133,7 +143,7 @@
// 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
+@@ -1836,7 +1836,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.