mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-02-16 23:57:11 +00:00
extra/chromium to 43.0.2357.125-2
This commit is contained in:
parent
8e4c2cef0b
commit
9fb17adbbf
2 changed files with 131 additions and 2 deletions
|
@ -22,7 +22,7 @@ buildarch=4
|
|||
|
||||
pkgname=chromium
|
||||
pkgver=43.0.2357.125
|
||||
pkgrel=1
|
||||
pkgrel=2
|
||||
_launcher_ver=2
|
||||
pkgdesc="The open-source project behind Google Chrome, an attempt at creating a safer, faster, and more stable browser"
|
||||
arch=('armv6h' 'armv7h')
|
||||
|
@ -43,6 +43,7 @@ install=chromium.install
|
|||
source=(https://commondatastorage.googleapis.com/chromium-browser-official/$pkgname-$pkgver.tar.xz
|
||||
chromium-launcher-$_launcher_ver.tar.gz::https://github.com/foutrelis/chromium-launcher/archive/v$_launcher_ver.tar.gz
|
||||
chromium.desktop
|
||||
add-build-flag-to-disable-hotwording.patch
|
||||
arm-webrtc-fix.patch
|
||||
chromium-arm-r0.patch
|
||||
v6-ffmpeg.patch
|
||||
|
@ -50,6 +51,7 @@ source=(https://commondatastorage.googleapis.com/chromium-browser-official/$pkgn
|
|||
sha256sums=('af1774d093f90f9ccfd7def3b2b3a8caa109274ac28d4bec0285e50f8a5a5405'
|
||||
'7f91c81721092d707d7b94e6555a48bc7fd0bc0e1174df4649bdcd745930e52f'
|
||||
'028a748a5c275de9b8f776f97909f999a8583a4b77fd1cd600b4fc5c0c3e91e9'
|
||||
'3a1c589aa90c0597776d945d34638d43e2d40d93bc1962148815831a5122ac4e'
|
||||
'9db0f01517c52e3236ff52e8a664840542a19144a54923ae6aabea3dcfa92c52'
|
||||
'df4be49770d508b772f98eda9fc5f37fa71d4c0459437e12f7f3db5892aa1611'
|
||||
'3fbabcbd512494b529e0a0e17560735887acf2291a74653750f9b29f5d45774d'
|
||||
|
@ -67,6 +69,12 @@ _google_default_client_secret=0ZChLK6AxeA3Isu96MkwqDR4
|
|||
prepare() {
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
|
||||
# Add build flag to disable 'Ok Google' hotwording feature
|
||||
# The issue with this functionality is that it downloads a binary blob
|
||||
# and that this behavior cannot be disabled if a user wishes to do so.
|
||||
# https://code.google.com/p/chromium/issues/detail?id=491435
|
||||
patch -Np1 -i ../add-build-flag-to-disable-hotwording.patch
|
||||
|
||||
# Enable support for the Widevine CDM plugin
|
||||
# The actual libraries are not included, but can be copied over from Chrome:
|
||||
# libwidevinecdmadapter.so
|
||||
|
@ -82,7 +90,7 @@ prepare() {
|
|||
patch -Np0 -i ../chromium-arm-r0.patch
|
||||
|
||||
# Remove bundled ICU; its header files appear to get picked up instead of
|
||||
# the system ones, leading to errors during the final link stage
|
||||
# the system ones, leading to errors during the final link stage.
|
||||
# https://groups.google.com/a/chromium.org/d/topic/chromium-packagers/BNGvJc08B6Q
|
||||
find third_party/icu -type f \! -regex '.*\.\(gyp\|gypi\|isolate\)' -delete
|
||||
|
||||
|
@ -166,6 +174,7 @@ fi
|
|||
-Duse_system_zlib=0
|
||||
-Dusb_ids_path=/usr/share/hwdata/usb.ids
|
||||
-Duse_gconf=0
|
||||
-Denable_hotwording=0
|
||||
-Ddisable_fatal_linker_warnings=1
|
||||
-Ddisable_glibc=1
|
||||
-Ddisable_sse2=1
|
||||
|
|
120
extra/chromium/add-build-flag-to-disable-hotwording.patch
Normal file
120
extra/chromium/add-build-flag-to-disable-hotwording.patch
Normal file
|
@ -0,0 +1,120 @@
|
|||
Index: build/common.gypi
|
||||
diff --git a/build/common.gypi b/build/common.gypi
|
||||
index b26d0e1aaf3baa8c0bea2aa21795051e0767bb39..bac0544541b1ffbd4c9a072e86425476f01fa3d9 100644
|
||||
--- a/build/common.gypi
|
||||
+++ b/build/common.gypi
|
||||
@@ -391,6 +391,9 @@
|
||||
# Web speech is enabled by default. Set to 0 to disable.
|
||||
'enable_web_speech%': 1,
|
||||
|
||||
+ # 'Ok Google' hotwording is enabled by default. Set to 0 to disable.
|
||||
+ 'enable_hotwording%': 1,
|
||||
+
|
||||
# Notifications are compiled in by default. Set to 0 to disable.
|
||||
'notifications%' : 1,
|
||||
|
||||
@@ -1136,6 +1139,7 @@
|
||||
'configuration_policy%': '<(configuration_policy)',
|
||||
'safe_browsing%': '<(safe_browsing)',
|
||||
'enable_web_speech%': '<(enable_web_speech)',
|
||||
+ 'enable_hotwording%': '<(enable_hotwording)',
|
||||
'notifications%': '<(notifications)',
|
||||
'clang_use_chrome_plugins%': '<(clang_use_chrome_plugins)',
|
||||
'mac_want_real_dsym%': '<(mac_want_real_dsym)',
|
||||
Index: chrome/browser/BUILD.gn
|
||||
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
|
||||
index 30127a3a2ee6836ffb108fd2859707b765d42cb8..867dc390d0b7f623423ed64bfbbe5f938fbc0659 100644
|
||||
--- a/chrome/browser/BUILD.gn
|
||||
+++ b/chrome/browser/BUILD.gn
|
||||
@@ -19,6 +19,11 @@ if (is_desktop_linux) {
|
||||
import("//build/config/linux/pkg_config.gni")
|
||||
}
|
||||
|
||||
+declare_args() {
|
||||
+ # 'Ok Google' hotwording is enabled.
|
||||
+ enable_hotwording = true
|
||||
+}
|
||||
+
|
||||
about_credits_file = "$target_gen_dir/about_credits.html"
|
||||
additional_modules_list_file =
|
||||
"$root_gen_dir/chrome/browser/internal/additional_modules_list.txt"
|
||||
@@ -452,6 +457,10 @@ source_set("browser") {
|
||||
}
|
||||
}
|
||||
|
||||
+ if (enable_hotwording) {
|
||||
+ defines += [ "ENABLE_HOTWORDING" ]
|
||||
+ }
|
||||
+
|
||||
if (is_linux) {
|
||||
deps += [
|
||||
"//device/media_transfer_protocol",
|
||||
Index: chrome/browser/search/hotword_service.cc
|
||||
diff --git a/chrome/browser/search/hotword_service.cc b/chrome/browser/search/hotword_service.cc
|
||||
index d222b150fbae877fe74598681e956e6e624890fa..5b08027ef4c198480f703a9420a55068e88aa435 100644
|
||||
--- a/chrome/browser/search/hotword_service.cc
|
||||
+++ b/chrome/browser/search/hotword_service.cc
|
||||
@@ -639,7 +639,11 @@ bool HotwordService::IsServiceAvailable() {
|
||||
if (group == hotword_internal::kHotwordFieldTrialDisabledGroupName)
|
||||
return false;
|
||||
|
||||
+#if defined(ENABLE_HOTWORDING)
|
||||
return DoesHotwordSupportLanguage(profile_);
|
||||
+#else
|
||||
+ return false;
|
||||
+#endif
|
||||
}
|
||||
|
||||
bool HotwordService::IsOptedIntoAudioLogging() {
|
||||
Index: chrome/browser/search/hotword_service_unittest.cc
|
||||
diff --git a/chrome/browser/search/hotword_service_unittest.cc b/chrome/browser/search/hotword_service_unittest.cc
|
||||
index 588706c1c186e7f410230b12f649a6b8853da2fb..84444468e2f7634ad895d0752355303babf0c7d7 100644
|
||||
--- a/chrome/browser/search/hotword_service_unittest.cc
|
||||
+++ b/chrome/browser/search/hotword_service_unittest.cc
|
||||
@@ -157,6 +157,7 @@ INSTANTIATE_TEST_CASE_P(HotwordServiceTests,
|
||||
extension_misc::kHotwordSharedModuleId));
|
||||
|
||||
TEST_P(HotwordServiceTest, IsHotwordAllowedLocale) {
|
||||
+#if defined(ENABLE_HOTWORDING)
|
||||
TestingProfile::Builder profile_builder;
|
||||
scoped_ptr<TestingProfile> profile = profile_builder.Build();
|
||||
|
||||
@@ -187,6 +188,7 @@ TEST_P(HotwordServiceTest, IsHotwordAllowedLocale) {
|
||||
Profile* otr_profile = profile->GetOffTheRecordProfile();
|
||||
SetApplicationLocale(otr_profile, "en");
|
||||
EXPECT_FALSE(HotwordServiceFactory::IsHotwordAllowed(otr_profile));
|
||||
+#endif // defined(ENABLE_HOTWORDING)
|
||||
}
|
||||
|
||||
TEST_P(HotwordServiceTest, ShouldReinstallExtension) {
|
||||
@@ -243,6 +245,7 @@ TEST_P(HotwordServiceTest, PreviousLanguageSetOnInstall) {
|
||||
}
|
||||
|
||||
TEST_P(HotwordServiceTest, UninstallReinstallTriggeredCorrectly) {
|
||||
+#if defined(ENABLE_HOTWORDING)
|
||||
InitializeEmptyExtensionService();
|
||||
service_->Init();
|
||||
|
||||
@@ -313,6 +316,7 @@ TEST_P(HotwordServiceTest, UninstallReinstallTriggeredCorrectly) {
|
||||
EXPECT_TRUE(HotwordServiceFactory::IsHotwordAllowed(profile()));
|
||||
EXPECT_FALSE(hotword_service->MaybeReinstallHotwordExtension());
|
||||
EXPECT_EQ(1, hotword_service->uninstall_count()); // no change
|
||||
+#endif // defined(ENABLE_HOTWORDING)
|
||||
}
|
||||
|
||||
TEST_P(HotwordServiceTest, DisableAlwaysOnOnLanguageChange) {
|
||||
Index: chrome/chrome_browser.gypi
|
||||
diff --git a/chrome/chrome_browser.gypi b/chrome/chrome_browser.gypi
|
||||
index 4070c8c38867d2394d3a2a60b1cd17361ccea1c3..b589e9a52e0ca183da7bee5a644c0de8f61a0d89 100644
|
||||
--- a/chrome/chrome_browser.gypi
|
||||
+++ b/chrome/chrome_browser.gypi
|
||||
@@ -3573,6 +3573,9 @@
|
||||
['enable_session_service==1', {
|
||||
'sources': [ '<@(chrome_browser_session_service_sources)' ],
|
||||
}],
|
||||
+ ['enable_hotwording==1', {
|
||||
+ 'defines': [ 'ENABLE_HOTWORDING' ],
|
||||
+ }],
|
||||
['OS!="android" and OS!="ios" and chromeos==0', {
|
||||
'sources': [ '<@(chrome_browser_desktop_sources)' ],
|
||||
}],
|
Loading…
Reference in a new issue