Browse Source

Update to 94.0.4606.54-1

tags/94.0.4606.71-1
wchen342 1 month ago
parent
commit
527246853c
Signed by: wchen342 GPG Key ID: 9C19365D69B04CEC
44 changed files with 359 additions and 391 deletions
  1. +2
    -2
      .build_config
  2. +3
    -0
      CHANGELOG.md
  3. +4
    -2
      android_flags.debug.gn
  4. +1
    -0
      android_flags.gn
  5. +4
    -4
      patches/Bromite/AImageReader-CFI-crash-mitigations.patch
  6. +7
    -7
      patches/Bromite/Add-an-always-incognito-mode.patch
  7. +6
    -6
      patches/Bromite/Add-exit-menu-item.patch
  8. +3
    -3
      patches/Bromite/Add-flag-to-disable-WebGL.patch
  9. +7
    -7
      patches/Bromite/Add-option-to-not-persist-tabs-across-sessions.patch
  10. +1
    -1
      patches/Bromite/Disable-DRM-media-origin-IDs-preprovisioning.patch
  11. +3
    -3
      patches/Bromite/Inject-scripts-for-AMP-tracking-ads-and-video.patch
  12. +2
    -2
      patches/Bromite/Remove-account-permissions-from-manifest.patch
  13. +4
    -4
      patches/Bromite/Revert-flags-remove-disable-pull-to-refresh-effect.patch
  14. +6
    -6
      patches/Other/debug-fix.patch
  15. +2
    -2
      patches/Other/ungoogled-main-repo-fix.patch
  16. +5
    -5
      patches/Unobtainium/kill-GCM.patch
  17. +1
    -1
      patches/Vanadium/0016-disable-seed-based-field-trials.patch
  18. +2
    -2
      patches/Vanadium/0034-disable-media-router-by-default.patch
  19. +1
    -3
      patches/series
  20. +43
    -0
      patches/src-fix/fix-clang-options.patch
  21. +2
    -2
      patches/src-fix/fix-prefs.patch
  22. +62
    -50
      patches/src-fix/fix-safe-browsing.patch
  23. +0
    -37
      patches/src-fix/fix-unkown-warning-clang.patch
  24. +9
    -9
      patches/ungoogled-chromium-android/Add-always-desktop-option.patch
  25. +1
    -1
      patches/ungoogled-chromium-android/Add-folder-button-bookmark.patch
  26. +10
    -10
      patches/ungoogled-chromium-android/Add-force-tablet-ui-option.patch
  27. +1
    -1
      patches/ungoogled-chromium-android/Add-more-search-engines.patch
  28. +3
    -3
      patches/ungoogled-chromium-android/Add-save-data-flag.patch
  29. +6
    -6
      patches/ungoogled-chromium-android/Add_trichrome_apk.patch
  30. +4
    -4
      patches/ungoogled-chromium-android/Change-package-name-chromium.patch
  31. +0
    -17
      patches/ungoogled-chromium-android/Disable-tflite.patch
  32. +1
    -1
      patches/ungoogled-chromium-android/Enable-ProactivelySwapBrowsingInstance.patch
  33. +5
    -5
      patches/ungoogled-chromium-android/Enable-update-notification.patch
  34. +17
    -17
      patches/ungoogled-chromium-android/Remove-UI-elements.patch
  35. +2
    -2
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.auth.patch
  36. +6
    -6
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.cast.patch
  37. +14
    -14
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.common-auth-signin-dynamic-com.google.android.gms.tasks.patch
  38. +21
    -21
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.fido-com.google.android.gms.iid-com.google.android.gms.instantapps-com.google.android.gms.location.patch
  39. +3
    -3
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.gcm.patch
  40. +2
    -2
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.vision-com.google.android.gms.clearcut-com.google.android.gms.phenotype.patch
  41. +58
    -42
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.play.core.splitcompat-com.google.android.play.core.splitinstall.patch
  42. +24
    -9
      patches/ungoogled-chromium-android/Remove-dependency-on-com.google.android.play.patch
  43. +1
    -1
      patches/ungoogled-chromium-android/Remove-dependency-on-firebase.patch
  44. +0
    -68
      patches/ungoogled-chromium-android/Tricrhome-webview-64.patch

+ 2
- 2
.build_config View File

@ -10,7 +10,7 @@ trichrome_webview_target=trichrome_webview_apk
trichrome_webview_64_target=trichrome_webview_64_apk
all=all
chromium_version=93.0.4577.82
ungoogled_chromium_version=93.0.4577.82
chromium_version=94.0.4606.54
ungoogled_chromium_version=94.0.4606.54
ungoogled_chromium_revision=1
ungoogled_chromium_android_revision=1

+ 3
- 0
CHANGELOG.md View File

@ -1,3 +1,6 @@
# 94.0.4606.54-1
* Upstream update
# 93.0.4577.82-1
* Proxy settings and bookmark import-export are temporarily disabled


+ 4
- 2
android_flags.debug.gn View File

@ -1,7 +1,10 @@
blink_symbol_level=1
build_with_tflite_lib=false
chrome_pgo_phase=0
clang_use_chrome_plugins=false
enable_js_type_check=false
disable_fieldtrial_testing_config=true
enable_hangout_services_extension=false
enable_js_type_check=false
enable_iterator_debugging=false
enable_mdns=false
enable_mse_mpeg2ts_stream_parser=true
@ -14,7 +17,6 @@ enable_reporting=false
enable_service_discovery=false
enable_widevine=true
fatal_linker_warnings=false
fieldtrial_testing_like_official_build=true
google_api_key=""
google_default_client_id=""
google_default_client_secret=""


+ 1
- 0
android_flags.gn View File

@ -14,6 +14,7 @@ enable_gvr_services=false
enable_swiftshader=false
exclude_unwind_tables=false
ffmpeg_branding="Chrome"
limit_android_deps = false
is_chromecast=false
is_clang=true
proprietary_codecs=true


+ 4
- 4
patches/Bromite/AImageReader-CFI-crash-mitigations.patch View File

@ -79,7 +79,7 @@ See discussions at:
AndroidImageReader();
--- a/chrome/browser/flag-metadata.json
+++ b/chrome/browser/flag-metadata.json
@@ -2039,7 +2039,7 @@
@@ -2017,7 +2017,7 @@
{
"name": "enable-image-reader",
"owners": [ "vikassoni", "liberato" ],
@ -173,7 +173,7 @@ See discussions at:
disable_accelerated_vp8_decode
--- a/gpu/ipc/service/gpu_init.cc
+++ b/gpu/ipc/service/gpu_init.cc
@@ -503,6 +503,11 @@ bool GpuInit::InitializeAndStartSandbox(
@@ -517,6 +517,11 @@ bool GpuInit::InitializeAndStartSandbox(
}
}
@ -214,7 +214,7 @@ See discussions at:
}
--- a/media/base/media_switches.cc
+++ b/media/base/media_switches.cc
@@ -640,6 +640,10 @@ const base::Feature kMediaDrmPreprovisio
@@ -673,6 +673,10 @@ const base::Feature kMediaDrmPreprovisio
const base::Feature kMediaDrmPreprovisioningAtStartup{
"MediaDrmPreprovisioningAtStartup", base::FEATURE_ENABLED_BY_DEFAULT};
@ -227,7 +227,7 @@ See discussions at:
base::FEATURE_DISABLED_BY_DEFAULT};
--- a/media/base/media_switches.h
+++ b/media/base/media_switches.h
@@ -210,6 +210,7 @@ MEDIA_EXPORT extern const base::Feature
@@ -221,6 +221,7 @@ MEDIA_EXPORT extern const base::Feature
MEDIA_EXPORT extern const base::Feature kMediaDrmPersistentLicense;
MEDIA_EXPORT extern const base::Feature kMediaDrmPreprovisioning;
MEDIA_EXPORT extern const base::Feature kMediaDrmPreprovisioningAtStartup;


+ 7
- 7
patches/Bromite/Add-an-always-incognito-mode.patch View File

@ -128,7 +128,7 @@ Enable incognito custom tabs and fix crashes for incognito/custom tab intents (c
import org.chromium.chrome.browser.IntentHandler.IntentHandlerDelegate;
import org.chromium.chrome.browser.IntentHandler.TabOpenType;
import org.chromium.chrome.browser.accessibility_tab_switcher.OverviewListLayout;
@@ -1745,8 +1746,10 @@ public class ChromeTabbedActivity extend
@@ -1763,8 +1764,10 @@ public class ChromeTabbedActivity extend
Bundle savedInstanceState = getSavedInstanceState();
// We determine the model as soon as possible so every systems get initialized coherently.
@ -139,7 +139,7 @@ Enable incognito custom tabs and fix crashes for incognito/custom tab intents (c
+ || (savedInstanceState != null
+ && savedInstanceState.getBoolean(IS_INCOGNITO_SELECTED, false));
int index = savedInstanceState != null ? savedInstanceState.getInt(WINDOW_INDEX, 0) : 0;
mNextTabPolicySupplier = new ChromeNextTabPolicySupplier(mOverviewModeBehaviorSupplier);
--- a/chrome/android/java/src/org/chromium/chrome/browser/app/ChromeActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/app/ChromeActivity.java
@ -151,7 +151,7 @@ Enable incognito custom tabs and fix crashes for incognito/custom tab intents (c
import org.chromium.chrome.browser.dependency_injection.ChromeActivityComponent;
import org.chromium.chrome.browser.dependency_injection.ModuleFactoryOverrides;
import org.chromium.chrome.browser.device.DeviceClassManager;
@@ -1961,6 +1962,9 @@ public abstract class ChromeActivity<C e
@@ -1947,6 +1948,9 @@ public abstract class ChromeActivity<C e
throw new IllegalStateException(
"Attempting to access TabCreator before initialization");
}
@ -163,7 +163,7 @@ Enable incognito custom tabs and fix crashes for incognito/custom tab intents (c
--- a/chrome/android/java/src/org/chromium/chrome/browser/app/appmenu/AppMenuPropertiesDelegateImpl.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/app/appmenu/AppMenuPropertiesDelegateImpl.java
@@ -363,6 +363,12 @@ public class AppMenuPropertiesDelegateIm
@@ -378,6 +378,12 @@ public class AppMenuPropertiesDelegateIm
}
private void prepareCommonMenuItems(Menu menu, @MenuGroup int menuGroup, boolean isIncognito) {
@ -309,14 +309,14 @@ Enable incognito custom tabs and fix crashes for incognito/custom tab intents (c
.setWebContents(webContents)
--- a/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
@@ -47,6 +47,7 @@ import org.chromium.ui.text.SpanApplier;
@@ -48,6 +48,7 @@ import org.chromium.ui.text.SpanApplier;
*/
public class PrivacySettings
extends PreferenceFragmentCompat implements Preference.OnPreferenceChangeListener {
+ private static final String PREF_ALWAYS_INCOGNITO = "always_incognito";
private static final String PREF_CAN_MAKE_PAYMENT = "can_make_payment";
private static final String PREF_NETWORK_PREDICTIONS = "preload_pages";
private static final String PREF_SECURE_DNS = "secure_dns";
private static final String PREF_HTTPS_FIRST_MODE = "https_first_mode";
--- a/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/ChromeTabCreator.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/ChromeTabCreator.java
@@ -44,6 +44,10 @@ import org.chromium.url.GURL;
@ -463,7 +463,7 @@ Enable incognito custom tabs and fix crashes for incognito/custom tab intents (c
}
--- a/chrome/browser/flags/android/chrome_feature_list.cc
+++ b/chrome/browser/flags/android/chrome_feature_list.cc
@@ -432,7 +432,7 @@ const base::Feature kCCTIncognito{"CCTIn
@@ -446,7 +446,7 @@ const base::Feature kCCTIncognito{"CCTIn
base::FEATURE_ENABLED_BY_DEFAULT};
const base::Feature kCCTIncognitoAvailableToThirdParty{


+ 6
- 6
patches/Bromite/Add-exit-menu-item.patch View File

@ -13,7 +13,7 @@ Corrected Exit functionality
--- a/chrome/android/java/res/menu/main_menu.xml
+++ b/chrome/android/java/res/menu/main_menu.xml
@@ -118,6 +118,9 @@
@@ -121,6 +121,9 @@
android:icon="@drawable/gm_filled_cardboard_24" />
<item android:id="@+id/managed_by_menu_id"
android:title="@string/managed" />
@ -23,7 +23,7 @@ Corrected Exit functionality
</group>
<!-- Items shown only in the tab switcher -->
@@ -144,6 +147,9 @@
@@ -147,6 +150,9 @@
<item android:id="@id/preferences_id"
android:title="@string/menu_settings"
android:icon="@drawable/settings_cog" />
@ -35,7 +35,7 @@ Corrected Exit functionality
<!-- Items shown only in the tab switcher when start surface is enabled -->
--- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -202,6 +202,8 @@ import java.lang.annotation.RetentionPol
@@ -208,6 +208,8 @@ import java.util.HashSet;
import java.util.List;
import java.util.Locale;
@ -44,7 +44,7 @@ Corrected Exit functionality
/**
* This is the main activity for ChromeMobile when not running in document mode. All the tabs
* are accessible via a chrome specific tab switching UI.
@@ -1959,6 +1961,8 @@ public class ChromeTabbedActivity extend
@@ -2014,6 +2016,8 @@ public class ChromeTabbedActivity extend
} else if (id == R.id.close_tab) {
getCurrentTabModel().closeTab(currentTab, true, false, true);
RecordUserAction.record("MobileTabClosed");
@ -63,7 +63,7 @@ Corrected Exit functionality
import org.chromium.chrome.browser.ChromeActivitySessionTracker;
import org.chromium.chrome.browser.ChromeApplicationImpl;
import org.chromium.chrome.browser.ChromeKeyboardVisibilityDelegate;
@@ -2392,6 +2393,11 @@ public abstract class ChromeActivity<C e
@@ -2378,6 +2379,11 @@ public abstract class ChromeActivity<C e
return true;
}
@ -92,7 +92,7 @@ Corrected Exit functionality
@Override
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -3101,6 +3101,9 @@ To change this setting, <ph name="BEGIN_
@@ -3189,6 +3189,9 @@ To change this setting, <ph name="BEGIN_
<message name="IDS_MENU_SETTINGS" desc="Menu item for opening browser settings. [CHAR_LIMIT=27]">
Settings
</message>


+ 3
- 3
patches/Bromite/Add-flag-to-disable-WebGL.patch View File

@ -10,7 +10,7 @@ Subject: Add flag to disable WebGL
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -2764,6 +2764,9 @@ const FeatureEntry kFeatureEntries[] = {
@@ -2654,6 +2654,9 @@ const FeatureEntry kFeatureEntries[] = {
flag_descriptions::kAccelerated2dCanvasName,
flag_descriptions::kAccelerated2dCanvasDescription, kOsAll,
SINGLE_DISABLE_VALUE_TYPE(switches::kDisableAccelerated2dCanvas)},
@ -22,7 +22,7 @@ Subject: Add flag to disable WebGL
MULTI_VALUE_TYPE(kOverlayStrategiesChoices)},
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -642,6 +642,10 @@ const char kEnableAudioFocusEnforcementN
@@ -613,6 +613,10 @@ const char kEnableAudioFocusEnforcementN
const char kEnableAudioFocusEnforcementDescription[] =
"Enables enforcement of a single media session having audio focus at "
"any one time. Requires #enable-media-session-service to be enabled too.";
@ -35,7 +35,7 @@ Subject: Add flag to disable WebGL
"Enable the account data storage for autofill";
--- a/chrome/browser/flag_descriptions.h
+++ b/chrome/browser/flag_descriptions.h
@@ -388,6 +388,9 @@ extern const char kDisallowDocWrittenScr
@@ -367,6 +367,9 @@ extern const char kDisallowDocWrittenScr
extern const char kDocumentTransitionName[];
extern const char kDocumentTransitionDescription[];


+ 7
- 7
patches/Bromite/Add-option-to-not-persist-tabs-across-sessions.patch View File

@ -11,7 +11,7 @@ Subject: Add option to not persist tabs across sessions
--- a/chrome/android/java/res/xml/privacy_preferences.xml
+++ b/chrome/android/java/res/xml/privacy_preferences.xml
@@ -28,6 +28,11 @@
@@ -32,6 +32,11 @@
android:key="secure_dns"
android:title="@string/settings_secure_dns_title"
android:fragment="org.chromium.chrome.browser.privacy.secure_dns.SecureDnsSettings"/>
@ -25,7 +25,7 @@ Subject: Add option to not persist tabs across sessions
android:key="do_not_track"
--- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -1195,8 +1195,10 @@ public class ChromeTabbedActivity extend
@@ -1192,8 +1192,10 @@ public class ChromeTabbedActivity extend
boolean hadCipherData =
CipherFactory.getInstance().restoreFromBundle(getSavedInstanceState());
@ -55,8 +55,8 @@ Subject: Add option to not persist tabs across sessions
+import org.chromium.base.BuildInfo;
import org.chromium.chrome.R;
import org.chromium.chrome.browser.feedback.HelpAndFeedbackLauncherImpl;
import org.chromium.chrome.browser.preferences.Pref;
@@ -50,6 +53,7 @@ public class PrivacySettings
import org.chromium.chrome.browser.flags.ChromeFeatureList;
@@ -52,6 +55,7 @@ public class PrivacySettings
private static final String PREF_USAGE_STATS = "usage_stats_reporting";
private static final String PREF_DO_NOT_TRACK = "do_not_track";
private static final String PREF_CLEAR_BROWSING_DATA = "clear_browsing_data";
@ -64,7 +64,7 @@ Subject: Add option to not persist tabs across sessions
private static final String PREF_PRIVACY_SANDBOX = "privacy_sandbox";
private ManagedPreferenceDelegate mManagedPreferenceDelegate;
@@ -126,7 +130,11 @@ public class PrivacySettings
@@ -137,7 +141,11 @@ public class PrivacySettings
@Override
public boolean onPreferenceChange(Preference preference, Object newValue) {
String key = preference.getKey();
@ -77,7 +77,7 @@ Subject: Add option to not persist tabs across sessions
UserPrefs.get(Profile.getLastUsedRegularProfile())
.setBoolean(Pref.CAN_MAKE_PAYMENT_ENABLED, (boolean) newValue);
} else if (PREF_NETWORK_PREDICTIONS.equals(key)) {
@@ -192,6 +200,11 @@ public class PrivacySettings
@@ -206,6 +214,11 @@ public class PrivacySettings
privacySandboxPreference.setSummary(
PrivacySandboxSettingsFragment.getStatusString(getContext()));
}
@ -91,7 +91,7 @@ Subject: Add option to not persist tabs across sessions
private ChromeManagedPreferenceDelegate createManagedPreferenceDelegate() {
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -3944,6 +3944,12 @@ To change this setting, <ph name="BEGIN_
@@ -4043,6 +4043,12 @@ To change this setting, <ph name="BEGIN_
<message name="IDS_CONTEXTMENU_IMAGE_TITLE" desc="The title of a context menu tab when the item pressed contains more than one type. This indicates that all the actions are related to the image.">
IMAGE
</message>


+ 1
- 1
patches/Bromite/Disable-DRM-media-origin-IDs-preprovisioning.patch View File

@ -8,7 +8,7 @@ Subject: Disable DRM media origin IDs preprovisioning
--- a/media/base/media_switches.cc
+++ b/media/base/media_switches.cc
@@ -631,7 +631,7 @@ const base::Feature kMediaDrmPersistentL
@@ -664,7 +664,7 @@ const base::Feature kMediaDrmPersistentL
// MediaDrmBridge. If disabled, MediaDrmBridge will get unprovisioned origin IDs
// which will trigger provisioning process after MediaDrmBridge is created.
const base::Feature kMediaDrmPreprovisioning{"MediaDrmPreprovisioning",


+ 3
- 3
patches/Bromite/Inject-scripts-for-AMP-tracking-ads-and-video.patch View File

@ -48,7 +48,7 @@ Send a random key press to circumvent idle status detection
#ifndef NDEBUG
using WeakDocumentSet = blink::HeapHashSet<blink::WeakMember<blink::Document>>;
static WeakDocumentSet& liveDocumentSet();
@@ -6622,6 +6625,61 @@ void Document::setAllowDeclarativeShadow
@@ -6554,6 +6557,61 @@ void Document::setAllowDeclarativeShadow
val ? AllowState::kAllow : AllowState::kDeny;
}
@ -110,7 +110,7 @@ Send a random key press to circumvent idle status detection
void Document::FinishedParsing() {
DCHECK(!GetScriptableDocumentParser() || !parser_->IsParsing());
DCHECK(!GetScriptableDocumentParser() || ready_state_ != kLoading);
@@ -6679,6 +6737,10 @@ void Document::FinishedParsing() {
@@ -6609,6 +6667,10 @@ void Document::FinishedParsing() {
if (frame->GetFrameScheduler())
frame->GetFrameScheduler()->OnDomContentLoaded();
@ -123,7 +123,7 @@ Send a random key press to circumvent idle status detection
probe::DomContentLoadedEventFired(frame);
--- a/third_party/blink/renderer/core/dom/document.h
+++ b/third_party/blink/renderer/core/dom/document.h
@@ -1752,6 +1752,9 @@ class CORE_EXPORT Document : public Cont
@@ -1750,6 +1750,9 @@ class CORE_EXPORT Document : public Cont
void AddAXContext(AXContext*);
void RemoveAXContext(AXContext*);


+ 2
- 2
patches/Bromite/Remove-account-permissions-from-manifest.patch View File

@ -9,7 +9,7 @@ Subject: Remove all sync and account permissions/features from manifest
--- a/chrome/android/java/AndroidManifest.xml
+++ b/chrome/android/java/AndroidManifest.xml
@@ -64,24 +64,18 @@ by a child template that "extends" this
@@ -67,24 +67,18 @@ by a child template that "extends" this
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
<uses-permission android:name="android.permission.DOWNLOAD_WITHOUT_NOTIFICATION" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
@ -34,7 +34,7 @@ Subject: Remove all sync and account permissions/features from manifest
{% set enable_vr = enable_vr|default(0) %}
{% if enable_vr == "true" %}
<!-- Indicates use of Android's VR-mode, available only on Android N+. -->
@@ -116,8 +110,6 @@ by a child template that "extends" this
@@ -119,8 +113,6 @@ by a child template that "extends" this
<uses-permission android:name="com.chrome.permission.DEVICE_EXTRAS" />
<uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT"/>


+ 4
- 4
patches/Bromite/Revert-flags-remove-disable-pull-to-refresh-effect.patch View File

@ -12,7 +12,7 @@ This reverts commit 4e598f38a0e6dd3dbede009c6a99b2a520a94e1f.
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -3432,6 +3432,10 @@ const FeatureEntry kFeatureEntries[] = {
@@ -3300,6 +3300,10 @@ const FeatureEntry kFeatureEntries[] = {
SINGLE_DISABLE_VALUE_TYPE(switches::kDisableHostedAppShimCreation)},
#endif // OS_MAC
#if defined(OS_ANDROID)
@ -25,7 +25,7 @@ This reverts commit 4e598f38a0e6dd3dbede009c6a99b2a520a94e1f.
flag_descriptions::kTranslateForceTriggerOnEnglishDescription, kOsAndroid,
--- a/chrome/browser/flag-metadata.json
+++ b/chrome/browser/flag-metadata.json
@@ -1135,6 +1135,11 @@
@@ -1104,6 +1104,11 @@
"expiry_milestone": -1
},
{
@ -39,7 +39,7 @@ This reverts commit 4e598f38a0e6dd3dbede009c6a99b2a520a94e1f.
"expiry_milestone": 83
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -3427,6 +3427,10 @@ const char kReadLaterDescription[] =
@@ -3294,6 +3294,10 @@ const char kReadLaterDescription[] =
"Allow users to save tabs for later. Enables a new button and menu for "
"accessing tabs saved for later.";
@ -52,7 +52,7 @@ This reverts commit 4e598f38a0e6dd3dbede009c6a99b2a520a94e1f.
"Determines what pages the Reader Mode infobar is shown on.";
--- a/chrome/browser/flag_descriptions.h
+++ b/chrome/browser/flag_descriptions.h
@@ -1956,6 +1956,9 @@ extern const char kQueryTilesRankTilesDe
@@ -1884,6 +1884,9 @@ extern const char kQueryTilesRankTilesDe
extern const char kQueryTilesSwapTrendingName[];
extern const char kQueryTilesSwapTrendingDescription[];


+ 6
- 6
patches/Other/debug-fix.patch View File

@ -50,7 +50,7 @@ Subject: Remove DCHECK and other lines causing Debug builds to fail
defines = []
configs = []
@@ -1828,7 +1828,7 @@ config("no_rtti") {
@@ -1836,7 +1836,7 @@ config("no_rtti") {
# to heap-allocated memory are passed over shared library boundaries.
config("export_dynamic") {
# TODO(crbug.com/1052397): Revisit after target_os flip is completed.
@ -59,7 +59,7 @@ Subject: Remove DCHECK and other lines causing Debug builds to fail
ldflags = [ "-rdynamic" ]
}
}
@@ -2047,8 +2047,6 @@ if (is_win) {
@@ -2011,8 +2011,6 @@ if (is_win) {
common_optimize_on_cflags += [
# Put data and code in their own sections, so that unused symbols
# can be removed at link time with --gc-sections.
@ -68,7 +68,7 @@ Subject: Remove DCHECK and other lines causing Debug builds to fail
]
if (!is_nacl && is_clang) {
# We don't care about unique section names, this makes object files a bit
@@ -2061,7 +2059,6 @@ if (is_win) {
@@ -2025,7 +2023,6 @@ if (is_win) {
# See http://lwn.net/Articles/192624/ .
# -O2 enables string tail merge optimization in gold and lld.
"-Wl,-O2",
@ -76,7 +76,7 @@ Subject: Remove DCHECK and other lines causing Debug builds to fail
]
}
}
@@ -2421,7 +2418,7 @@ config("symbols") {
@@ -2385,7 +2382,7 @@ config("symbols") {
# sections (llvm.org/PR34820).
cflags += [ "-ggnu-pubnames" ]
}
@ -87,7 +87,7 @@ Subject: Remove DCHECK and other lines causing Debug builds to fail
--- a/components/policy/core/browser/configuration_policy_handler.cc
+++ b/components/policy/core/browser/configuration_policy_handler.cc
@@ -360,7 +360,6 @@ SchemaValidatingPolicyHandler::SchemaVal
@@ -359,7 +359,6 @@ SchemaValidatingPolicyHandler::SchemaVal
Schema schema,
SchemaOnErrorStrategy strategy)
: NamedPolicyHandler(policy_name), schema_(schema), strategy_(strategy) {
@ -107,7 +107,7 @@ Subject: Remove DCHECK and other lines causing Debug builds to fail
return std::make_unique<ProfileOAuth2TokenService>(
--- a/components/omnibox/browser/autocomplete_match.cc
+++ b/components/omnibox/browser/autocomplete_match.cc
@@ -1396,16 +1396,6 @@ bool AutocompleteMatch::IsEmptyAutocompl
@@ -1413,16 +1413,6 @@ bool AutocompleteMatch::IsEmptyAutocompl
split_autocompletion.Empty();
}


+ 2
- 2
patches/Other/ungoogled-main-repo-fix.patch View File

@ -7,14 +7,14 @@ author: Wengling Chen <[email protected]>
--- a/ungoogled-chromium/flags.gn
+++ b/ungoogled-chromium/flags.gn
@@ -12,7 +12,6 @@ enable_remoting=false
@@ -14,7 +14,6 @@ enable_remoting=false
enable_reporting=false
enable_service_discovery=false
enable_widevine=true
-exclude_unwind_tables=true
fieldtrial_testing_like_official_build=true
google_api_key=""
google_default_client_id=""
google_default_client_secret=""
--- a/ungoogled-chromium/pruning.list
+++ b/ungoogled-chromium/pruning.list
@@ -17462,7 +17462,6 @@ third_party/pyelftools/test/testfiles_for_unittests/simple_gcc.elf.arm


+ 5
- 5
patches/Unobtainium/kill-GCM.patch View File

@ -15,7 +15,7 @@ Subject: kill GCM
--- a/chrome/android/chrome_java_sources.gni
+++ b/chrome/android/chrome_java_sources.gni
@@ -16,7 +16,6 @@ chrome_java_sources = [
@@ -15,7 +15,6 @@ chrome_java_sources = [
"java/src/org/chromium/chrome/browser/ChromeActionModeHandler.java",
"java/src/org/chromium/chrome/browser/ChromeActivitySessionTracker.java",
"java/src/org/chromium/chrome/browser/ChromeApplicationImpl.java",
@ -23,7 +23,7 @@ Subject: kill GCM
"java/src/org/chromium/chrome/browser/ChromeBackupAgentImpl.java",
"java/src/org/chromium/chrome/browser/ChromeBackupWatcher.java",
"java/src/org/chromium/chrome/browser/ChromeBaseAppCompatActivity.java",
@@ -1029,10 +1028,6 @@ chrome_java_sources = [
@@ -1036,10 +1035,6 @@ chrome_java_sources = [
"java/src/org/chromium/chrome/browser/searchwidget/SearchBoxDataProvider.java",
"java/src/org/chromium/chrome/browser/searchwidget/SearchWidgetProvider.java",
"java/src/org/chromium/chrome/browser/send_tab_to_self/SendTabToSelfShareActivity.java",
@ -36,7 +36,7 @@ Subject: kill GCM
"java/src/org/chromium/chrome/browser/settings/SettingsLauncherImpl.java",
--- a/chrome/android/java/AndroidManifest.xml
+++ b/chrome/android/java/AndroidManifest.xml
@@ -104,21 +104,16 @@ by a child template that "extends" this
@@ -107,21 +107,16 @@ by a child template that "extends" this
<permission android:name="{{ manifest_package }}.permission.CHILD_SERVICE" android:protectionLevel="signature" />
<permission android:name="{{ manifest_package }}.permission.READ_WRITE_BOOKMARK_FOLDERS" android:protectionLevel="signatureOrSystem" />
<permission android:name="{{ manifest_package }}.TOS_ACKED" android:protectionLevel="signatureOrSystem" />
@ -58,7 +58,7 @@ Subject: kill GCM
<uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT"/>
<uses-permission android:name="com.google.android.apps.now.CURRENT_ACCOUNT_ACCESS" />
@@ -1005,25 +1000,6 @@ by a child template that "extends" this
@@ -1027,25 +1022,6 @@ by a child template that "extends" this
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|mcc|mnc|screenLayout|smallestScreenSize"
android:hardwareAccelerated="false" />
@ -84,7 +84,7 @@ Subject: kill GCM
<!-- Android Notification service listener -->
<service android:name="org.chromium.chrome.browser.notifications.NotificationService"
@@ -1048,28 +1024,10 @@ by a child template that "extends" this
@@ -1070,28 +1046,10 @@ by a child template that "extends" this
android:exported="false"
android:permission="android.permission.BIND_JOB_SERVICE"/>


+ 1
- 1
patches/Vanadium/0016-disable-seed-based-field-trials.patch View File

@ -9,7 +9,7 @@ Subject: [PATCH 16/73] disable seed-based field trials
--- a/components/variations/service/variations_field_trial_creator.cc
+++ b/components/variations/service/variations_field_trial_creator.cc
@@ -277,8 +277,6 @@ bool VariationsFieldTrialCreator::SetupF
@@ -274,8 +274,6 @@ bool VariationsFieldTrialCreator::SetupF
#endif // BUILDFLAG(FIELDTRIAL_TESTING_ENABLED)
bool used_seed = false;
if (!used_testing_config) {


+ 2
- 2
patches/Vanadium/0034-disable-media-router-by-default.patch View File

@ -10,7 +10,7 @@ Subject: [PATCH 34/77] disable media router by default
--- a/chrome/browser/media/router/media_router_feature.cc
+++ b/chrome/browser/media/router/media_router_feature.cc
@@ -88,7 +88,7 @@ bool MediaRouterEnabled(content::Browser
@@ -79,7 +79,7 @@ bool MediaRouterEnabled(content::Browser
pref_values.insert(std::make_pair(context, allowed));
return allowed;
}
@ -21,7 +21,7 @@ Subject: [PATCH 34/77] disable media router by default
#if !defined(OS_ANDROID)
--- a/chrome/browser/profiles/profile_impl.cc
+++ b/chrome/browser/profiles/profile_impl.cc
@@ -421,7 +421,7 @@ void ProfileImpl::RegisterProfilePrefs(
@@ -433,7 +433,7 @@ void ProfileImpl::RegisterProfilePrefs(
#endif
registry->RegisterBooleanPref(prefs::kForceEphemeralProfiles, false);


+ 1
- 3
patches/series View File

@ -1,6 +1,6 @@
src-fix/android-rlz-fix-missing-variable.patch
src-fix/fix-null-mInstanceID.patch
src-fix/fix-unkown-warning-clang.patch
src-fix/fix-clang-options.patch
src-fix/fix-safe-browsing.patch
src-fix/fix-prefs.patch
src-fix/fix-base-feature.patch
@ -21,7 +21,6 @@ Unobtainium/kill-Vision.patch
Unobtainium/kill-Translate.patch
Unobtainium/kill-TOS-and-metrics-opt-out.patch
ungoogled-chromium-android/Change-package-name-chromium.patch
ungoogled-chromium-android/Tricrhome-webview-64.patch
ungoogled-chromium-android/Add_trichrome_apk.patch
ungoogled-chromium-android/Remove-dependency-on-com.google.android.gms.gcm.patch
ungoogled-chromium-android/Remove-dependency-on-firebase.patch
@ -46,7 +45,6 @@ ungoogled-chromium-android/Remove-ntp-sites.patch
ungoogled-chromium-android/Add-save-data-flag.patch
ungoogled-chromium-android/Add-always-desktop-option.patch
ungoogled-chromium-android/Add-force-tablet-ui-option.patch
ungoogled-chromium-android/Disable-tflite.patch
Bromite/Remove-account-permissions-from-manifest.patch
Bromite/updater-disable-updater-pings.patch
Bromite/Change-default-webRTC-policy-to-not-use-any-address.patch


+ 43
- 0
patches/src-fix/fix-clang-options.patch View File

@ -0,0 +1,43 @@
description: prevent clang from printing unknown-warning warning. Also remove --rtlib=libgcc and -ffile-compilation-dir=. which won't be available until we have clang 13.
author: Wengling Chen <[email protected]>
---
build/config/android/BUILD.gn | 2 --
build/config/compiler/BUILD.gn | 5 ++++-
2 files changed, 4 insertions(+), 3 deletions(-)
--- a/build/config/compiler/BUILD.gn
+++ b/build/config/compiler/BUILD.gn
@@ -1234,7 +1234,7 @@ config("compiler_deterministic") {
} else {
# -ffile-compilation-dir is an alias for both -fdebug-compilation-dir=
# and -fcoverage-compilation-dir=.
- cflags += [ "-ffile-compilation-dir=." ]
+ cflags += [ "-fdebug-compilation-dir=." ]
}
if (!is_win) {
# We don't use clang -cc1as on Windows (yet? https://crbug.com/762167)
@@ -1616,6 +1616,9 @@ config("default_warnings") {
cflags += [
"-Wenum-compare-conditional",
+ # Ignore unknown warning warnings from clang
+ "-Wno-unknown-warning-option",
+
# An ABI compat warning we don't care about, https://crbug.com/1102157
# TODO(thakis): Push this to the (few) targets that need it,
# instead of having a global flag.
--- a/build/config/android/BUILD.gn
+++ b/build/config/android/BUILD.gn
@@ -52,11 +52,9 @@ config("compiler") {
]
# TODO(crbug.com/1184398): Move to compiler-rt when we are ready.
- ldflags += [ "--rtlib=libgcc" ]
if (current_cpu == "arm64") {
# For outline atomics on AArch64 (can't pass this unconditionally
# due to unused flag warning on other targets).
- cflags += [ "--rtlib=libgcc" ]
if (arm_control_flow_integrity == "standard") {
cflags += [ "-mbranch-protection=standard" ]
}

+ 2
- 2
patches/src-fix/fix-prefs.patch View File

@ -10,7 +10,7 @@ Subject: fix build error with prefs.h
--- a/chrome/browser/preferences/BUILD.gn
+++ b/chrome/browser/preferences/BUILD.gn
@@ -36,7 +36,6 @@ java_cpp_strings("java_pref_names_srcjar
@@ -37,7 +37,6 @@ java_cpp_strings("java_pref_names_srcjar
"//components/offline_pages/core/prefetch/prefetch_prefs.cc",
"//components/password_manager/core/common/password_manager_pref_names.cc",
"//components/payments/core/payment_prefs.cc",
@ -32,7 +32,7 @@ Subject: fix build error with prefs.h
}
--- a/chrome/android/java/src/org/chromium/chrome/browser/signin/SyncConsentFragmentBase.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/signin/SyncConsentFragmentBase.java
@@ -435,8 +435,7 @@ public abstract class SyncConsentFragmen
@@ -457,8 +457,7 @@ public abstract class SyncConsentFragmen
mConfirmSyncDataStateMachine = new ConfirmSyncDataStateMachine(
new ConfirmSyncDataStateMachineDelegate(
requireContext(), getChildFragmentManager(), mModalDialogManager),


+ 62
- 50
patches/src-fix/fix-safe-browsing.patch View File

@ -19,7 +19,7 @@ Subject: Fix build error caused by the removal of safe_browsing
chrome/browser/safe_browsing/android/BUILD.gn | 1
chrome/browser/safe_browsing/android/java/src/org/chromium/chrome/browser/safe_browsing/SafeBrowsingBridge.java | 31 -
chrome/browser/safe_browsing/android/java/src/org/chromium/chrome/browser/safe_browsing/settings/RadioButtonGroupSafeBrowsingPreference.java | 28 -
chrome/browser/safe_browsing/android/java/src/org/chromium/chrome/browser/safe_browsing/settings/SafeBrowsingSettingsFragment.java | 168 --------
chrome/browser/safe_browsing/android/java/src/org/chromium/chrome/browser/safe_browsing/settings/SafeBrowsingSettingsFragment.java | 168 -------
chrome/browser/safe_browsing/android/java/src/org/chromium/chrome/browser/safe_browsing/settings/StandardProtectionSettingsFragment.java | 8
components/safe_browsing/content/browser/client_side_detection_host.cc | 17
components/safe_browsing/content/browser/client_side_detection_host.h | 3
@ -34,15 +34,15 @@ Subject: Fix build error caused by the removal of safe_browsing
weblayer/browser/safe_browsing/client_side_detection_service_delegate.cc | 12
weblayer/browser/safe_browsing/client_side_detection_service_factory.cc | 4
weblayer/browser/safe_browsing/real_time_url_lookup_service_factory.cc | 7
weblayer/browser/safe_browsing/safe_browsing_blocking_page.cc | 8
weblayer/browser/safe_browsing/safe_browsing_service.cc | 200 ----------
weblayer/browser/safe_browsing/safe_browsing_service.cc | 213 ----------
weblayer/browser/safe_browsing/safe_browsing_tab_observer.cc | 11
weblayer/browser/safe_browsing/weblayer_safe_browsing_blocking_page_factory.cc | 6
weblayer/browser/tab_impl.cc | 2
35 files changed, 57 insertions(+), 612 deletions(-)
35 files changed, 57 insertions(+), 623 deletions(-)
--- a/chrome/android/BUILD.gn
+++ b/chrome/android/BUILD.gn
@@ -371,7 +371,6 @@ android_library("chrome_java") {
@@ -377,7 +377,6 @@ android_library("chrome_java") {
"//chrome/browser/privacy:java",
"//chrome/browser/privacy_sandbox/android:java",
"//chrome/browser/profiles/android:java",
@ -68,10 +68,10 @@ Subject: Fix build error caused by the removal of safe_browsing
#include "components/safe_browsing/content/browser/triggers/trigger_manager.h"
#include "components/safe_browsing/core/common/features.h"
-#include "components/safe_browsing/core/common/safe_browsing_prefs.h"
#include "components/safe_browsing/core/common/safebrowsing_constants.h"
#include "components/safe_browsing/core/common/utils.h"
#include "components/security_interstitials/content/security_interstitial_controller_client.h"
@@ -110,16 +109,16 @@ AwSafeBrowsingBlockingPage* AwSafeBrowsi
#include "components/security_interstitials/content/settings_page_helper.h"
@@ -104,16 +103,16 @@ AwSafeBrowsingBlockingPage* AwSafeBrowsi
BaseSafeBrowsingErrorUI::SBErrorDisplayOptions display_options =
BaseSafeBrowsingErrorUI::SBErrorDisplayOptions(
IsMainPageLoadBlocked(unsafe_resources),
@ -114,15 +114,15 @@ Subject: Fix build error caused by the removal of safe_browsing
blocked_content::SafeBrowsingTriggeredPopupBlocker::RegisterProfilePrefs(
--- a/chrome/android/java/src/org/chromium/chrome/browser/sync/settings/GoogleServicesSettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/sync/settings/GoogleServicesSettings.java
@@ -182,7 +182,6 @@ public class GoogleServicesSettings
identityManager.getPrimaryAccountInfo(ConsentLevel.SIGNIN) != null
&& !((boolean) newValue);
@@ -181,7 +181,6 @@ public class GoogleServicesSettings
boolean shouldSignUserOut =
identityManager.hasPrimaryAccount(ConsentLevel.SIGNIN) && !((boolean) newValue);
if (!shouldSignUserOut) {
- mPrefService.setBoolean(Pref.SIGNIN_ALLOWED, (boolean) newValue);
return true;
}
@@ -193,7 +192,6 @@ public class GoogleServicesSettings
@@ -192,7 +191,6 @@ public class GoogleServicesSettings
IdentityServicesProvider.get()
.getSigninManager(Profile.getLastUsedRegularProfile())
.signOut(SignoutReason.USER_CLICKED_SIGNOUT_SETTINGS, null, false);
@ -130,7 +130,7 @@ Subject: Fix build error caused by the removal of safe_browsing
return true;
}
@@ -225,7 +223,7 @@ public class GoogleServicesSettings
@@ -224,7 +222,7 @@ public class GoogleServicesSettings
}
private void updatePreferences() {
@ -139,7 +139,7 @@ Subject: Fix build error caused by the removal of safe_browsing
mSearchSuggestions.setChecked(mPrefService.getBoolean(Pref.SEARCH_SUGGEST_ENABLED));
if (mNavigationError != null) {
mNavigationError.setChecked(
@@ -253,7 +251,7 @@ public class GoogleServicesSettings
@@ -252,7 +250,7 @@ public class GoogleServicesSettings
return preference -> {
String key = preference.getKey();
if (PREF_ALLOW_SIGNIN.equals(key)) {
@ -148,7 +148,7 @@ Subject: Fix build error caused by the removal of safe_browsing
}
if (PREF_NAVIGATION_ERROR.equals(key)) {
return mPrefService.isManagedPreference(Pref.ALTERNATE_ERROR_PAGES_ENABLED);
@@ -320,7 +318,6 @@ public class GoogleServicesSettings
@@ -318,7 +316,6 @@ public class GoogleServicesSettings
}
},
forceWipeUserData);
@ -158,8 +158,8 @@ Subject: Fix build error caused by the removal of safe_browsing
}
--- a/chrome/browser/safe_browsing/BUILD.gn
+++ b/chrome/browser/safe_browsing/BUILD.gn
@@ -350,7 +350,6 @@ static_library("safe_browsing") {
deps += [ "//components/safe_browsing/android:remote_database_manager" ]
@@ -351,7 +351,6 @@ static_library("safe_browsing") {
]
}
deps += [
- "//chrome/browser/safe_browsing/android",
@ -168,7 +168,7 @@ Subject: Fix build error caused by the removal of safe_browsing
]
--- a/chrome/browser/preferences/BUILD.gn
+++ b/chrome/browser/preferences/BUILD.gn
@@ -36,7 +36,6 @@ java_cpp_strings("java_pref_names_srcjar
@@ -37,7 +37,6 @@ java_cpp_strings("java_pref_names_srcjar
"//components/offline_pages/core/prefetch/prefetch_prefs.cc",
"//components/password_manager/core/common/password_manager_pref_names.cc",
"//components/payments/core/payment_prefs.cc",
@ -192,7 +192,7 @@ Subject: Fix build error caused by the removal of safe_browsing
void TabWebContentsDelegateAndroid::RunFileChooser(
--- a/weblayer/browser/content_browser_client_impl.cc
+++ b/weblayer/browser/content_browser_client_impl.cc
@@ -509,33 +509,6 @@ ContentBrowserClientImpl::CreateURLLoade
@@ -514,33 +514,6 @@ ContentBrowserClientImpl::CreateURLLoade
int frame_tree_node_id) {
std::vector<std::unique_ptr<blink::URLLoaderThrottle>> result;
@ -226,7 +226,7 @@ Subject: Fix build error caused by the removal of safe_browsing
auto signin_throttle =
SigninURLLoaderThrottle::Create(browser_context, wc_getter);
if (signin_throttle)
@@ -847,13 +820,6 @@ ContentBrowserClientImpl::CreateThrottle
@@ -852,13 +825,6 @@ ContentBrowserClientImpl::CreateThrottle
#if defined(OS_ANDROID)
if (handle->IsInMainFrame()) {
@ -240,7 +240,7 @@ Subject: Fix build error caused by the removal of safe_browsing
std::unique_ptr<content::NavigationThrottle> intercept_navigation_throttle =
navigation_interception::InterceptNavigationDelegate::
MaybeCreateThrottleFor(
@@ -930,11 +896,6 @@ void ContentBrowserClientImpl::ExposeInt
@@ -951,11 +917,6 @@ void ContentBrowserClientImpl::ExposeInt
};
registry->AddInterface(base::BindRepeating(create_spellcheck_host),
content::GetUIThreadTaskRunner({}));
@ -252,20 +252,19 @@ Subject: Fix build error caused by the removal of safe_browsing
#endif // defined(OS_ANDROID)
}
--- a/weblayer/browser/safe_browsing/safe_browsing_blocking_page.cc
+++ b/weblayer/browser/safe_browsing/safe_browsing_blocking_page.cc
@@ -62,12 +62,8 @@ SafeBrowsingBlockingPage* SafeBrowsingBl
security_interstitials::BaseSafeBrowsingErrorUI::SBErrorDisplayOptions
display_options =
BaseBlockingPage::CreateDefaultDisplayOptions(unsafe_resources);
- display_options.is_extended_reporting_opt_in_allowed =
--- a/weblayer/browser/safe_browsing/weblayer_safe_browsing_blocking_page_factory.cc
+++ b/weblayer/browser/safe_browsing/weblayer_safe_browsing_blocking_page_factory.cc
@@ -36,11 +36,9 @@ WebLayerSafeBrowsingBlockingPageFactory:
safe_browsing::BaseBlockingPage::CreateDefaultDisplayOptions(
unsafe_resources);
display_options.is_extended_reporting_opt_in_allowed =
- safe_browsing::IsExtendedReportingOptInAllowed(
- *(browser_context->pref_service()));
- display_options.is_extended_reporting_enabled =
+ false;
display_options.is_extended_reporting_enabled =
- safe_browsing::IsExtendedReportingEnabled(
- *(browser_context->pref_service()));
+ display_options.is_extended_reporting_opt_in_allowed = false;
+ display_options.is_extended_reporting_enabled = false;
+ false;
// TODO(crbug.com/1080748): Set settings_page_helper once enhanced protection
// is supported on weblayer.
@ -280,15 +279,15 @@ Subject: Fix build error caused by the removal of safe_browsing
#include <memory>
#include "base/bind.h"
@@ -15,7 +13,6 @@
#include "components/safe_browsing/content/browser/mojo_safe_browsing_impl.h"
@@ -17,7 +15,6 @@
#include "components/safe_browsing/content/browser/safe_browsing_network_context.h"
#include "components/safe_browsing/core/browser/ping_manager.h"
#include "components/safe_browsing/core/browser/realtime/url_lookup_service.h"
-#include "components/safe_browsing/core/common/safe_browsing_prefs.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_task_traits.h"
#include "content/public/browser/browser_thread.h"
@@ -60,10 +57,7 @@ void MaybeCreateSafeBrowsing(
@@ -68,10 +65,7 @@ void MaybeCreateSafeBrowsing(
if (!render_process_host)
return;
@ -300,7 +299,7 @@ Subject: Fix build error caused by the removal of safe_browsing
if (!is_safe_browsing_enabled)
return;
@@ -77,196 +71,4 @@ void MaybeCreateSafeBrowsing(
@@ -85,209 +79,4 @@ void MaybeCreateSafeBrowsing(
} // namespace
@ -356,7 +355,7 @@ Subject: Fix build error caused by the removal of safe_browsing
-std::unique_ptr<content::NavigationThrottle>
-SafeBrowsingService::CreateSafeBrowsingNavigationThrottle(
- content::NavigationHandle* handle) {
- return std::make_unique<SafeBrowsingNavigationThrottle>(
- return std::make_unique<safe_browsing::SafeBrowsingNavigationThrottle>(
- handle, GetSafeBrowsingUIManager().get());
-}
-
@ -380,14 +379,27 @@ Subject: Fix build error caused by the removal of safe_browsing
- return safe_browsing_db_manager_;
-}
-
-scoped_refptr<SafeBrowsingUIManager>
-safe_browsing::PingManager* SafeBrowsingService::GetPingManager() {
- if (!ping_manager_) {
- ping_manager_ =
- ::safe_browsing::PingManager::Create(safe_browsing::GetV4ProtocolConfig(
- GetProtocolConfigClientName(), false /* auto_update */));
- }
-
- return ping_manager_.get();
-}
-
-scoped_refptr<safe_browsing::SafeBrowsingUIManager>
-SafeBrowsingService::GetSafeBrowsingUIManager() {
- return ui_manager_;
-}
-
-void SafeBrowsingService::CreateSafeBrowsingUIManager() {
- DCHECK(!ui_manager_);
- ui_manager_ = new SafeBrowsingUIManager(this);
- ui_manager_ = new safe_browsing::SafeBrowsingUIManager(
- std::make_unique<WebLayerSafeBrowsingUIManagerDelegate>(),
- std::make_unique<WebLayerSafeBrowsingBlockingPageFactory>(),
- GURL(url::kAboutBlankURL));
-}
-
-void SafeBrowsingService::CreateAndStartSafeBrowsingDBManager() {
@ -834,7 +846,7 @@ Subject: Fix build error caused by the removal of safe_browsing
private void onPromoSeen() {
--- a/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
@@ -23,8 +23,6 @@ import org.chromium.chrome.browser.priva
@@ -24,8 +24,6 @@ import org.chromium.chrome.browser.priva
import org.chromium.chrome.browser.privacy_sandbox.PrivacySandboxReferrer;
import org.chromium.chrome.browser.privacy_sandbox.PrivacySandboxSettingsFragment;
import org.chromium.chrome.browser.profiles.Profile;
@ -843,7 +855,7 @@ Subject: Fix build error caused by the removal of safe_browsing
import org.chromium.chrome.browser.settings.ChromeManagedPreferenceDelegate;
import org.chromium.chrome.browser.settings.SettingsLauncherImpl;
import org.chromium.chrome.browser.signin.services.IdentityServicesProvider;
@@ -83,11 +81,7 @@ public class PrivacySettings
@@ -85,11 +83,7 @@ public class PrivacySettings
}
Preference safeBrowsingPreference = findPreference(PREF_SAFE_BROWSING);
@ -855,7 +867,7 @@ Subject: Fix build error caused by the removal of safe_browsing
return false;
});
@@ -185,8 +179,6 @@ public class PrivacySettings
@@ -199,8 +193,6 @@ public class PrivacySettings
Preference safeBrowsingPreference = findPreference(PREF_SAFE_BROWSING);
if (safeBrowsingPreference != null && safeBrowsingPreference.isVisible()) {
@ -1132,7 +1144,7 @@ Subject: Fix build error caused by the removal of safe_browsing
}
--- a/chrome/browser/password_manager/chrome_password_manager_client.cc
+++ b/chrome/browser/password_manager/chrome_password_manager_client.cc
@@ -444,7 +444,9 @@ void ChromePasswordManagerClient::ShowTo
@@ -460,7 +460,9 @@ void ChromePasswordManagerClient::ShowTo
#if defined(OS_ANDROID)
void ChromePasswordManagerClient::OnPasswordSelected(
const std::u16string& text) {
@ -1155,7 +1167,7 @@ Subject: Fix build error caused by the removal of safe_browsing
safe_browsing_context = sb_service->GetNetworkContext();
--- a/components/safe_browsing/content/browser/client_side_detection_service.cc
+++ b/components/safe_browsing/content/browser/client_side_detection_service.cc
@@ -81,18 +81,7 @@ ClientSideDetectionService::ClientSideDe
@@ -83,18 +83,7 @@ ClientSideDetectionService::ClientSideDe
url_loader_factory_ = delegate_->GetSafeBrowsingURLLoaderFactory();
pref_change_registrar_.Init(delegate_->GetPrefs());
@ -1175,7 +1187,7 @@ Subject: Fix build error caused by the removal of safe_browsing
// Do an initial check of the prefs.
OnPrefsUpdated();
}
@@ -107,10 +96,9 @@ void ClientSideDetectionService::Shutdow
@@ -109,10 +98,9 @@ void ClientSideDetectionService::Shutdow
void ClientSideDetectionService::OnPrefsUpdated() {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
@ -1188,7 +1200,7 @@ Subject: Fix build error caused by the removal of safe_browsing
if (enabled == enabled_ && extended_reporting_ == extended_reporting)
return;
@@ -207,10 +195,7 @@ void ClientSideDetectionService::StartCl
@@ -209,10 +197,7 @@ void ClientSideDetectionService::StartCl
return;
}
@ -1200,7 +1212,7 @@ Subject: Fix build error caused by the removal of safe_browsing
// Fill in metadata about which model we used.
*request->mutable_population() = delegate_->GetUserPopulation();
@@ -407,7 +392,6 @@ void ClientSideDetectionService::AddPhis
@@ -409,7 +394,6 @@ void ClientSideDetectionService::AddPhis
base::ListValue time_list;
for (const base::Time& timestamp : phishing_report_times_)
time_list.Append(base::Value(timestamp.ToDoubleT()));
@ -1208,7 +1220,7 @@ Subject: Fix build error caused by the removal of safe_browsing
}
void ClientSideDetectionService::LoadPhishingReportTimesFromPrefs() {
@@ -415,13 +399,6 @@ void ClientSideDetectionService::LoadPhi
@@ -417,13 +401,6 @@ void ClientSideDetectionService::LoadPhi
return;
phishing_report_times_.clear();
@ -1242,7 +1254,7 @@ Subject: Fix build error caused by the removal of safe_browsing
}
--- a/components/safe_browsing/content/browser/client_side_detection_host.cc
+++ b/components/safe_browsing/content/browser/client_side_detection_host.cc
@@ -143,7 +143,7 @@ class ClientSideDetectionHost::ShouldCla
@@ -142,7 +142,7 @@ class ClientSideDetectionHost::ShouldCla
// Don't start classification if |url_| is allowlisted by enterprise policy.
if (host_->delegate_->GetPrefs() &&
@ -1251,7 +1263,7 @@ Subject: Fix build error caused by the removal of safe_browsing
DontClassifyForPhishing(NO_CLASSIFY_ALLOWLISTED_BY_POLICY);
}
@@ -533,19 +533,6 @@ void ClientSideDetectionHost::PhishingDe
@@ -532,19 +532,6 @@ void ClientSideDetectionHost::PhishingDe
GetDebugFeatureDirectory()));
}
@ -1271,7 +1283,7 @@ Subject: Fix build error caused by the removal of safe_browsing
base::UmaHistogramBoolean("SBClientPhishing.LocalModelDetectsPhishing",
verdict->is_phishing());
@@ -644,7 +631,7 @@ bool ClientSideDetectionHost::CanGetAcce
@@ -646,7 +633,7 @@ bool ClientSideDetectionHost::CanGetAcce
// Return true if the finch feature is enabled for an ESB user, and if the
// primary user account is signed in.
return base::FeatureList::IsEnabled(kClientSideDetectionWithToken) &&
@ -1344,7 +1356,7 @@ Subject: Fix build error caused by the removal of safe_browsing
safe_browsing::ChromeUserPopulation::UNAVAILABLE);
--- a/weblayer/browser/tab_impl.cc
+++ b/weblayer/browser/tab_impl.cc
@@ -263,7 +263,7 @@ class WebContentsTracker : public conten
@@ -264,7 +264,7 @@ class WebContentsTracker : public conten
// available. Otherwise returns nullptr.
const scoped_refptr<safe_browsing::SafeBrowsingDatabaseManager>
GetDatabaseManagerFromSafeBrowsingService() {


+ 0
- 37
patches/src-fix/fix-unkown-warning-clang.patch View File

@ -1,37 +0,0 @@
description: prevent clang from printing unknown-warning warning. Also remove --rtlib=libgcc which won't be available until we have clang 13.
author: Wengling Chen <[email protected]>
---
build/config/android/BUILD.gn | 8 --------
build/config/compiler/BUILD.gn | 3 +++
2 files changed, 3 insertions(+), 8 deletions(-)
--- a/build/config/compiler/BUILD.gn
+++ b/build/config/compiler/BUILD.gn
@@ -1600,6 +1600,9 @@ config("default_warnings") {
cflags += [
"-Wenum-compare-conditional",
+ # Ignore unknown warning warnings from clang
+ "-Wno-unknown-warning-option",
+
# An ABI compat warning we don't care about, https://crbug.com/1102157
# TODO(thakis): Push this to the (few) targets that need it,
# instead of having a global flag.
--- a/build/config/android/BUILD.gn
+++ b/build/config/android/BUILD.gn
@@ -51,14 +51,6 @@ config("compiler") {
"-Wl,--exclude-libs=libvpx_assembly_arm.a",
]
- # TODO(crbug.com/1184398): Move to compiler-rt when we are ready.
- ldflags += [ "--rtlib=libgcc" ]
- if (current_cpu == "arm64") {
- # For outline atomics on AArch64 (can't pass this unconditionally
- # due to unused flag warning on other targets).
- cflags += [ "--rtlib=libgcc" ]
- }
-
# $compile_api_level corresponds to the API level used for the sysroot path
# calculation in //build/config/android/config.gni
if (android_64bit_target_cpu) {

+ 9
- 9
patches/ungoogled-chromium-android/Add-always-desktop-option.patch View File

@ -24,9 +24,9 @@ author: Wengling Chen <[email protected]>
android:title="@string/accessibility_captions_title"/>
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -1197,6 +1197,12 @@ Your Google account may have other forms
<message name="IDS_ACCESSIBILITY_CAPTIONS_TITLE" desc="Title of the preference that allows the user to update caption settings.">
Captions
@@ -1212,6 +1212,12 @@ Your Google account may have other forms
<message name="IDS_ACCESSIBILITY_PAGE_ZOOM_FACTOR" desc="Text description of the current page zoom factor set by the user" translateable="false">
<ph name="ZOOM_FACTOR">%1$d<ex>100</ex></ph> %%
</message>
+ <message name="IDS_FORCE_DESKTOP_MODE_SUMMARY" desc="Summary of the preference that allows the user to force all pages to be opened in desktop mode.">
+ Open all pages in desktop mode
@ -39,7 +39,7 @@ author: Wengling Chen <[email protected]>
<message name="IDS_LANGUAGE_SETTINGS" desc="Title for the Languages settings screen that allows users to manage their languages preferences. [CHAR_LIMIT=32]">
--- a/chrome/browser/preferences/android/java/src/org/chromium/chrome/browser/preferences/ChromePreferenceKeys.java
+++ b/chrome/browser/preferences/android/java/src/org/chromium/chrome/browser/preferences/ChromePreferenceKeys.java
@@ -537,6 +537,8 @@ public final class ChromePreferenceKeys
@@ -533,6 +533,8 @@ public final class ChromePreferenceKeys
public static final String FONT_USER_FONT_SCALE_FACTOR = "user_font_scale_factor";
public static final String FONT_USER_SET_FORCE_ENABLE_ZOOM = "user_set_force_enable_zoom";
@ -48,7 +48,7 @@ author: Wengling Chen <[email protected]>
public static final String HISTORY_SHOW_HISTORY_INFO = "history_home_show_info";
/** Keys used to save settings related to homepage. */
@@ -1062,6 +1064,7 @@ public final class ChromePreferenceKeys
@@ -1077,6 +1079,7 @@ public final class ChromePreferenceKeys
FLAGS_CACHED_SAFE_VALUES_VERSION,
FLAGS_CRASH_STREAK_BEFORE_CACHE,
FLAGS_FIELD_TRIAL_PARAM_CACHED.pattern(),
@ -58,15 +58,15 @@ author: Wengling Chen <[email protected]>
HOMEPAGE_USE_CHROME_NTP,
--- a/chrome/android/java/src/org/chromium/chrome/browser/accessibility/settings/AccessibilitySettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/accessibility/settings/AccessibilitySettings.java
@@ -34,6 +34,7 @@ public class AccessibilitySettings
static final String PREF_READER_FOR_ACCESSIBILITY = "reader_for_accessibility";
@@ -36,6 +36,7 @@ public class AccessibilitySettings
static final String PREF_CAPTIONS = "captions";
static final String PREF_IMAGE_DESCRIPTIONS = "image_descriptions";
static final String PREF_ACCESSIBILITY_PAGE_ZOOM = "accessibility_page_zoom";
+ static final String PREF_FORCE_DESKTOP_MODE = "force_desktop_mode";
private TextScalePreference mTextScalePref;
private ChromeBaseCheckBoxPreference mForceEnableZoomPref;
@@ -80,6 +81,12 @@ public class AccessibilitySettings
@@ -82,6 +83,12 @@ public class AccessibilitySettings
.getBoolean(Pref.READER_FOR_ACCESSIBILITY));
readerForAccessibilityPref.setOnPreferenceChangeListener(this);
@ -79,7 +79,7 @@ author: Wengling Chen <[email protected]>
ChromeBaseCheckBoxPreference mAccessibilityTabSwitcherPref =
(ChromeBaseCheckBoxPreference) findPreference(
ChromePreferenceKeys.ACCESSIBILITY_TAB_SWITCHER);
@@ -134,6 +141,9 @@ public class AccessibilitySettings
@@ -140,6 +147,9 @@ public class AccessibilitySettings
} else if (PREF_READER_FOR_ACCESSIBILITY.equals(preference.getKey())) {
UserPrefs.get(Profile.getLastUsedRegularProfile())
.setBoolean(Pref.READER_FOR_ACCESSIBILITY, (Boolean) newValue);


+ 1
- 1
patches/ungoogled-chromium-android/Add-folder-button-bookmark.patch View File

@ -178,7 +178,7 @@ Subject: Add new folder button to bookmark activity
if (!mIsCreatingFolder) {
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -3162,6 +3162,9 @@ To change this setting, <ph name="BEGIN_
@@ -3250,6 +3250,9 @@ To change this setting, <ph name="BEGIN_
<message name="IDS_BOOKMARK_ACTION_BAR_EDIT_FOLDER" desc="Button text for editing current folder action on the bookmark action bar [CHAR_LIMIT=32]">
Edit folder
</message>


+ 10
- 10
patches/ungoogled-chromium-android/Add-force-tablet-ui-option.patch View File

@ -27,7 +27,7 @@ author: Wengling Chen <[email protected]>
android:title="@string/accessibility_captions_title"/>
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -1203,6 +1203,12 @@ Your Google account may have other forms
@@ -1218,6 +1218,12 @@ Your Google account may have other forms
<message name="IDS_FORCE_DESKTOP_MODE_TITLE" desc="Title of the preference that allows the user to update force desktop mode settings.">
Force Desktop Mode
</message>
@ -42,15 +42,15 @@ author: Wengling Chen <[email protected]>
<message name="IDS_LANGUAGE_SETTINGS" desc="Title for the Languages settings screen that allows users to manage their languages preferences. [CHAR_LIMIT=32]">
--- a/chrome/android/java/src/org/chromium/chrome/browser/accessibility/settings/AccessibilitySettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/accessibility/settings/AccessibilitySettings.java
@@ -35,6 +35,7 @@ public class AccessibilitySettings
static final String PREF_CAPTIONS = "captions";
@@ -37,6 +37,7 @@ public class AccessibilitySettings
static final String PREF_IMAGE_DESCRIPTIONS = "image_descriptions";
static final String PREF_ACCESSIBILITY_PAGE_ZOOM = "accessibility_page_zoom";
static final String PREF_FORCE_DESKTOP_MODE = "force_desktop_mode";
+ static final String PREF_FORCE_TABLET_UI = "force_tablet_ui";
private TextScalePreference mTextScalePref;
private ChromeBaseCheckBoxPreference mForceEnableZoomPref;
@@ -87,6 +88,12 @@ public class AccessibilitySettings
@@ -89,6 +90,12 @@ public class AccessibilitySettings
ChromePreferenceKeys.FLAGS_FORCE_DESKTOP_MODE_ENABLED, false));
forceDesktopModePref.setOnPreferenceChangeListener(this);
@ -63,7 +63,7 @@ author: Wengling Chen <[email protected]>
ChromeBaseCheckBoxPreference mAccessibilityTabSwitcherPref =
(ChromeBaseCheckBoxPreference) findPreference(
ChromePreferenceKeys.ACCESSIBILITY_TAB_SWITCHER);
@@ -144,6 +151,9 @@ public class AccessibilitySettings
@@ -150,6 +157,9 @@ public class AccessibilitySettings
} else if (PREF_FORCE_DESKTOP_MODE.equals(preference.getKey())) {
SharedPreferencesManager.getInstance().writeBoolean(
ChromePreferenceKeys.FLAGS_FORCE_DESKTOP_MODE_ENABLED, (Boolean) newValue);
@ -75,7 +75,7 @@ author: Wengling Chen <[email protected]>
}
--- a/chrome/browser/preferences/android/java/src/org/chromium/chrome/browser/preferences/ChromePreferenceKeys.java
+++ b/chrome/browser/preferences/android/java/src/org/chromium/chrome/browser/preferences/ChromePreferenceKeys.java
@@ -538,6 +538,7 @@ public final class ChromePreferenceKeys
@@ -534,6 +534,7 @@ public final class ChromePreferenceKeys
public static final String FONT_USER_SET_FORCE_ENABLE_ZOOM = "user_set_force_enable_zoom";
public static final String FLAGS_FORCE_DESKTOP_MODE_ENABLED = "Chrome.UngoogledChromium.ForceDesktopMode";
@ -83,7 +83,7 @@ author: Wengling Chen <[email protected]>
public static final String HISTORY_SHOW_HISTORY_INFO = "history_home_show_info";
@@ -1065,6 +1066,7 @@ public final class ChromePreferenceKeys
@@ -1080,6 +1081,7 @@ public final class ChromePreferenceKeys
FLAGS_CRASH_STREAK_BEFORE_CACHE,
FLAGS_FIELD_TRIAL_PARAM_CACHED.pattern(),
FLAGS_FORCE_DESKTOP_MODE_ENABLED,
@ -114,7 +114,7 @@ author: Wengling Chen <[email protected]>
--- a/ui/android/BUILD.gn
+++ b/ui/android/BUILD.gn
@@ -369,6 +369,7 @@ android_library("ui_no_recycler_view_jav
@@ -370,6 +370,7 @@ android_library("ui_no_recycler_view_jav
":ui_java_resources",
":ui_utils_java",
"//base:base_java",
@ -124,7 +124,7 @@ author: Wengling Chen <[email protected]>
"//third_party/androidx:androidx_appcompat_appcompat_java",
--- a/components/BUILD.gn
+++ b/components/BUILD.gn
@@ -539,7 +539,7 @@ test("components_unittests") {
@@ -542,7 +542,7 @@ test("components_unittests") {
# On LaCrOS, tests use ash - chrome as a window manager, thus the dependency.
# On other platforms, no components should depend on Chrome.
@ -133,7 +133,7 @@ author: Wengling Chen <[email protected]>
assert_no_deps = [ "//chrome/*" ]
}
@@ -786,7 +786,7 @@ if (!is_ios) {
@@ -789,7 +789,7 @@ if (!is_ios) {
# On LaCrOS, tests use ash - chrome as a window manager, thus the dependency.
# On other platforms, no components should depend on Chrome.


+ 1
- 1
patches/ungoogled-chromium-android/Add-more-search-engines.patch View File

@ -28,7 +28,7 @@ Subject: Add Startpage.com and Qwant.com search engines
"searx": {
"name": "Searx",
"keyword": "searx.me",
@@ -162,6 +173,7 @@
@@ -163,6 +174,7 @@
"favicon_url": "https://www.qwant.com/favicon.ico",
"search_url": "https://www.qwant.com/?q={searchTerms}&client=opensearch",
"suggest_url": "https://api.qwant.com/api/suggest/?q={searchTerms}&client=opensearch",


+ 3
- 3
patches/ungoogled-chromium-android/Add-save-data-flag.patch View File

@ -12,7 +12,7 @@ author: Wengling Chen <[email protected]>
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -4712,6 +4712,9 @@ const FeatureEntry kFeatureEntries[] = {
@@ -4595,6 +4595,9 @@ const FeatureEntry kFeatureEntries[] = {
FEATURE_WITH_PARAMS_VALUE_TYPE(features::kMBIMode,
kMBIModeVariations,
"MBIMode")},
@ -48,7 +48,7 @@ author: Wengling Chen <[email protected]>
extern const base::Feature kTrustTokens;
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -1078,6 +1078,10 @@ const char kDisableKeepaliveFetchDescrip
@@ -1026,6 +1026,10 @@ const char kDisableKeepaliveFetchDescrip
"Disable fetch with keepalive set "
"(https://fetch.spec.whatwg.org/#request-keepalive-flag).";
@ -61,7 +61,7 @@ author: Wengling Chen <[email protected]>
const char kExperimentalAccessibilityLanguageDetectionDescription[] =
--- a/chrome/browser/flag_descriptions.h
+++ b/chrome/browser/flag_descriptions.h
@@ -594,6 +594,9 @@ extern const char kDiagnosticsAppNavigat
@@ -558,6 +558,9 @@ extern const char kDiagnosticsAppNavigat
extern const char kDisableKeepaliveFetchName[];
extern const char kDisableKeepaliveFetchDescription[];


+ 6
- 6
patches/ungoogled-chromium-android/Add_trichrome_apk.patch View File

@ -7,7 +7,7 @@ author: Wengling Chen <[email protected]>
--- a/chrome/android/BUILD.gn
+++ b/chrome/android/BUILD.gn
@@ -2082,6 +2082,10 @@ if (current_toolchain == default_toolcha
@@ -2102,6 +2102,10 @@ if (current_toolchain == default_toolcha
is_monochrome = true
is_bundle_module = true
}
@ -18,7 +18,7 @@ author: Wengling Chen <[email protected]>
resource_packaging("trichrome_chrome_bundle_module_pak_assets") {
is_monochrome = false
is_trichrome = true
@@ -2669,6 +2673,23 @@ android_resources("trichrome_dummy_resou
@@ -2712,6 +2716,23 @@ android_resources("trichrome_dummy_resou
sources = [ "trichrome/res_dummy/values/strings.xml" ]
}
@ -42,7 +42,7 @@ author: Wengling Chen <[email protected]>
chrome_public_test_apk_manifest =
"$root_gen_dir/chrome_public_test_apk_manifest/AndroidManifest.xml"
chrome_public_test_vr_apk_manifest =
@@ -3216,6 +3237,8 @@ template("monochrome_or_trichrome_public
@@ -3338,6 +3359,8 @@ template("monochrome_or_trichrome_public
!defined(invoker.static_library_synchronized_proguard) ||
!invoker.static_library_synchronized_proguard) {
bundle_target = ":${invoker.target_name}"
@ -51,9 +51,9 @@ author: Wengling Chen <[email protected]>
}
}
@@ -3430,6 +3453,21 @@ if (android_64bit_target_cpu) {
use_trichrome_library = true
static_library_provider = ":trichrome_library_32_apk"
@@ -3570,6 +3593,21 @@ if (android_64bit_target_cpu) {
static_library_provider = ":trichrome_library_32_apk"
}
}
+
+ monochrome_public_apk_or_module_tmpl("trichrome_chrome_64_apk") {


+ 4
- 4
patches/ungoogled-chromium-android/Change-package-name-chromium.patch View File

@ -8,16 +8,16 @@ author: Wengling Chen <[email protected]>
--- a/chrome/android/BUILD.gn
+++ b/chrome/android/BUILD.gn
@@ -40,7 +40,7 @@ import("java_sources.gni")
import("static_initializers.gni")
import("trichrome.gni")
@@ -44,7 +44,7 @@ if (android_64bit_target_cpu && skip_sec
assert(current_toolchain != android_secondary_abi_toolchain)
}
-_default_package = "org.chromium.chrome"
+_default_package = "org.ungoogled.chromium"
if (android_channel != "default") {
# android-binary-size trybot may checks if an internal Chrome variant's
# AndroidManifest is as expected by ensuring the differences between its
@@ -61,7 +61,7 @@ declare_args() {
@@ -65,7 +65,7 @@ declare_args() {
# for details.
chrome_public_manifest_package = _default_package
}


+ 0
- 17
patches/ungoogled-chromium-android/Disable-tflite.patch View File

@ -1,17 +0,0 @@
description: Remove TFLite
author: Wengling Chen <[email protected]>
---
---
components/optimization_guide/features.gni | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/components/optimization_guide/features.gni
+++ b/components/optimization_guide/features.gni
@@ -6,5 +6,5 @@ declare_args() {
# This enables build with TFLite library.
# Currently only available for Desktop and Android.
build_with_tflite_lib =
- is_android || is_win || is_linux || is_mac || is_chromeos
+ is_win || is_linux || is_mac || is_chromeos
}

+ 1
- 1
patches/ungoogled-chromium-android/Enable-ProactivelySwapBrowsingInstance.patch View File

@ -9,7 +9,7 @@ Subject: Enable experimental ProactivelySwapBrowsingInstance feature
--- a/content/public/common/content_features.cc
+++ b/content/public/common/content_features.cc
@@ -578,7 +578,7 @@ const base::Feature kPrioritizeBootstrap
@@ -580,7 +580,7 @@ const base::Feature kPrioritizeBootstrap
// HTTP(S) navigations when the BrowsingInstance doesn't contain any other
// windows.
const base::Feature kProactivelySwapBrowsingInstance{


+ 5
- 5
patches/ungoogled-chromium-android/Enable-update-notification.patch View File

@ -260,7 +260,7 @@
+}
--- a/chrome/android/chrome_java_sources.gni
+++ b/chrome/android/chrome_java_sources.gni
@@ -883,6 +883,7 @@ chrome_java_sources = [
@@ -890,6 +890,7 @@ chrome_java_sources = [
"java/src/org/chromium/chrome/browser/omaha/inline/InlineUpdateController.java",
"java/src/org/chromium/chrome/browser/omaha/inline/InlineUpdateControllerFactory.java",
"java/src/org/chromium/chrome/browser/omaha/inline/NoopInlineUpdateController.java",
@ -459,7 +459,7 @@
constexpr int kDefaultUpdateNotificationMaxInterval = 90;
--- a/chrome/android/java/AndroidManifest.xml
+++ b/chrome/android/java/AndroidManifest.xml
@@ -1114,7 +1114,7 @@ by a child template that "extends" this
@@ -1136,7 +1136,7 @@ by a child template that "extends" this
<service android:name="org.chromium.chrome.browser.tracing.TracingNotificationService"
android:exported="false"/>
@ -470,7 +470,7 @@
<meta-data android:name="org.chromium.content.browser.SMART_CLIP_PROVIDER"
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -2024,7 +2024,7 @@ To change this setting, <ph name="BEGIN_
@@ -2086,7 +2086,7 @@ To change this setting, <ph name="BEGIN_
Update Chrome
</message>
<message name="IDS_UPDATE_NOTIFICATION_TEXT_BODY_DEFAULT" desc="Default text showing in the update notification body, kindly telling user to update to the latest version of Chrome.">
@ -481,7 +481,7 @@
Update Chrome
--- a/chrome/browser/flag-metadata.json
+++ b/chrome/browser/flag-metadata.json
@@ -2054,7 +2054,7 @@
@@ -2032,7 +2032,7 @@
{
"name": "enable-inline-update-flow",
"owners": [ "nyquist", "dtrainor" ],
@ -492,7 +492,7 @@
"name": "enable-input-event-logging",
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -3643,10 +3643,9 @@ const char kVoiceButtonInTopToolbarDescr
@@ -3520,10 +3520,9 @@ const char kVoiceButtonInTopToolbarDescr
"Enables showing the voice search button in the top toolbar. Enabling "
"Adaptive Button overrides this.";


+ 17
- 17
patches/ungoogled-chromium-android/Remove-UI-elements.patch View File

@ -14,7 +14,6 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
chrome/android/java/src/org/chromium/chrome/browser/customtabs/BaseCustomTabActivity.java | 2
chrome/android/java/src/org/chromium/chrome/browser/datareduction/settings/DataReductionPreferenceFragment.java | 4
chrome/android/java/src/org/chromium/chrome/browser/directactions/MenuDirectActionHandler.java | 2
chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunStatus.java | 8 -
chrome/android/java/src/org/chromium/chrome/browser/password_manager/settings/PasswordSettings.java | 4
chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java | 18 ---
chrome/android/java/src/org/chromium/chrome/browser/settings/MainSettings.java | 50 ----------
@ -22,6 +21,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
chrome/android/java/src/org/chromium/chrome/browser/site_settings/ChromeSiteSettingsDelegate.java | 2
chrome/android/java/src/org/chromium/chrome/browser/sync/settings/GoogleServicesSettings.java | 3
chrome/android/java/src/org/chromium/chrome/browser/sync/settings/ManageSyncSettings.java | 3
chrome/browser/first_run/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunStatus.java | 8 -
components/autofill_assistant/browser/features.cc | 10 +-
components/feed/core/shared_prefs/pref_names.cc | 4
21 files changed, 16 insertions(+), 168 deletions(-)
@ -41,7 +41,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
--- a/chrome/android/features/start_surface/public/java/src/org/chromium/chrome/features/start_surface/StartSurfaceConfiguration.java
+++ b/chrome/android/features/start_surface/public/java/src/org/chromium/chrome/features/start_surface/StartSurfaceConfiguration.java
@@ -152,7 +152,7 @@ public class StartSurfaceConfiguration {
@@ -182,7 +182,7 @@ public class StartSurfaceConfiguration {
*/
public static boolean getFeedArticlesVisibility() {
return SharedPreferencesManager.getInstance().readBoolean(
@ -52,7 +52,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
/**
--- a/chrome/android/java/src/org/chromium/chrome/browser/settings/SettingsActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/settings/SettingsActivity.java
@@ -230,11 +230,6 @@ public class SettingsActivity extends Ch
@@ -221,11 +221,6 @@ public class SettingsActivity extends Ch
@Override
public boolean onCreateOptionsMenu(Menu menu) {
super.onCreateOptionsMenu(menu);
@ -93,7 +93,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
@Override
--- a/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
@@ -49,8 +49,6 @@ public class PrivacySettings
@@ -51,8 +51,6 @@ public class PrivacySettings
private static final String PREF_SECURE_DNS = "secure_dns";
private static final String PREF_USAGE_STATS = "usage_stats_reporting";
private static final String PREF_DO_NOT_TRACK = "do_not_track";
@ -102,7 +102,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
private static final String PREF_CLEAR_BROWSING_DATA = "clear_browsing_data";
private static final String PREF_PRIVACY_SANDBOX = "privacy_sandbox";
@@ -80,11 +78,6 @@ public class PrivacySettings
@@ -82,11 +80,6 @@ public class PrivacySettings
getPreferenceScreen().removePreference(findPreference(PREF_PRIVACY_SANDBOX));
}
@ -114,7 +114,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
setHasOptionsMenu(true);
mManagedPreferenceDelegate = createManagedPreferenceDelegate();
@@ -103,9 +96,6 @@ public class PrivacySettings
@@ -114,9 +107,6 @@ public class PrivacySettings
Preference secureDnsPref = findPreference(PREF_SECURE_DNS);
secureDnsPref.setVisible(SecureDnsSettings.isUiEnabled());
@ -124,7 +124,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
updateSummaries();
}
@@ -177,10 +167,6 @@ public class PrivacySettings
@@ -191,10 +181,6 @@ public class PrivacySettings
secureDnsPref.setSummary(SecureDnsSettings.getSummary(getContext()));
}
@ -135,7 +135,7 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
Preference usageStatsPref = findPreference(PREF_USAGE_STATS);
if (usageStatsPref != null) {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q
@@ -221,10 +207,6 @@ public class PrivacySettings
@@ -238,10 +224,6 @@ public class PrivacySettings
@Override
public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
menu.clear();
@ -359,8 +359,8 @@ Subject: Remove unused UI elements. Also disables autofill assistant.
if (PREF_SEARCH_ENGINE.equals(preference.getKey())) {
return TemplateUrlServiceFactory.get().isDefaultSearchManaged();
}
--- a/chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunStatus.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunStatus.java
--- a/chrome/browser/first_run/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunStatus.java
+++ b/chrome/browser/first_run/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunStatus.java
@@ -44,7 +44,7 @@ public class FirstRunStatus {
*/
public static boolean getFirstRunFlowComplete() {