-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path0008-Revert-Allow-uses-library-android.ext.adservices.patch
More file actions
186 lines (183 loc) · 11.3 KB
/
0008-Revert-Allow-uses-library-android.ext.adservices.patch
File metadata and controls
186 lines (183 loc) · 11.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
From c7b9fffad10808afe3125f5cf30fda4ed028fc02 Mon Sep 17 00:00:00 2001
From: "Kevin F. Haggerty" <haggertk@lineageos.org>
Date: Sat, 2 Mar 2024 08:55:45 -0700
Subject: [PATCH 08/13] Revert "Allow uses-library android.ext.adservices"
This reverts commit 0c3ae92dd16b763625a4d8c3f05012d9813dee2d.
---
...view_32_64_bundle.AndroidManifest.expected | 1 -
...webview_32_bundle.AndroidManifest.expected | 1 -
...view_64_32_bundle.AndroidManifest.expected | 1 -
...webview_64_bundle.AndroidManifest.expected | 1 -
...em_webview_bundle.AndroidManifest.expected | 1 -
...view_32_64_bundle.AndroidManifest.expected | 1 -
...webview_32_bundle.AndroidManifest.expected | 1 -
...view_64_32_bundle.AndroidManifest.expected | 1 -
...webview_64_bundle.AndroidManifest.expected | 1 -
...me_webview_bundle.AndroidManifest.expected | 1 -
.../0_privacysandbox_AndroidManifest.xml | 19 +++++++++++++++++++
third_party/androidx/customizations.gni | 6 ++++++
12 files changed, 25 insertions(+), 10 deletions(-)
create mode 100644 third_party/androidx/0_privacysandbox_AndroidManifest.xml
diff --git a/android_webview/expectations/system_webview_32_64_bundle.AndroidManifest.expected b/android_webview/expectations/system_webview_32_64_bundle.AndroidManifest.expected
index 3b120e85952f5..aba553799b91c 100644
--- a/android_webview/expectations/system_webview_32_64_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/system_webview_32_64_bundle.AndroidManifest.expected
@@ -521,7 +521,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="android.test.base" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
</application>
diff --git a/android_webview/expectations/system_webview_32_bundle.AndroidManifest.expected b/android_webview/expectations/system_webview_32_bundle.AndroidManifest.expected
index f8c2b3b5747ca..5a048b2abea50 100644
--- a/android_webview/expectations/system_webview_32_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/system_webview_32_bundle.AndroidManifest.expected
@@ -520,7 +520,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="android.test.base" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
</application>
diff --git a/android_webview/expectations/system_webview_64_32_bundle.AndroidManifest.expected b/android_webview/expectations/system_webview_64_32_bundle.AndroidManifest.expected
index 41eaf9e7c24ef..08c18ae23cfbd 100644
--- a/android_webview/expectations/system_webview_64_32_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/system_webview_64_32_bundle.AndroidManifest.expected
@@ -520,7 +520,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="android.test.base" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
</application>
diff --git a/android_webview/expectations/system_webview_64_bundle.AndroidManifest.expected b/android_webview/expectations/system_webview_64_bundle.AndroidManifest.expected
index 26bd7c26c2ffe..4f98a2473c9ff 100644
--- a/android_webview/expectations/system_webview_64_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/system_webview_64_bundle.AndroidManifest.expected
@@ -520,7 +520,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="android.test.base" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
</application>
diff --git a/android_webview/expectations/system_webview_bundle.AndroidManifest.expected b/android_webview/expectations/system_webview_bundle.AndroidManifest.expected
index 41a26c8ba9e66..39261ba5fc662 100644
--- a/android_webview/expectations/system_webview_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/system_webview_bundle.AndroidManifest.expected
@@ -497,6 +497,5 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
</application>
</manifest>
diff --git a/android_webview/expectations/trichrome_webview_32_64_bundle.AndroidManifest.expected b/android_webview/expectations/trichrome_webview_32_64_bundle.AndroidManifest.expected
index 66a117556f3d6..e1a00e6f99aee 100644
--- a/android_webview/expectations/trichrome_webview_32_64_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/trichrome_webview_32_64_bundle.AndroidManifest.expected
@@ -520,7 +520,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
<uses-static-library android:name="org.chromium.trichromelibrary" android:certDigest="32a2fc74d731105859e5a85df16d95f102d85b22099b8064c5d8915c61dad1e0" android:version="OFFSET=31"/>
</application>
diff --git a/android_webview/expectations/trichrome_webview_32_bundle.AndroidManifest.expected b/android_webview/expectations/trichrome_webview_32_bundle.AndroidManifest.expected
index 9dc7197a52704..b3e695a448837 100644
--- a/android_webview/expectations/trichrome_webview_32_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/trichrome_webview_32_bundle.AndroidManifest.expected
@@ -519,7 +519,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
<uses-static-library android:name="org.chromium.trichromelibrary" android:certDigest="32a2fc74d731105859e5a85df16d95f102d85b22099b8064c5d8915c61dad1e0" android:version="OFFSET=30"/>
</application>
diff --git a/android_webview/expectations/trichrome_webview_64_32_bundle.AndroidManifest.expected b/android_webview/expectations/trichrome_webview_64_32_bundle.AndroidManifest.expected
index e5a12aca76a6a..425bb7726fd51 100644
--- a/android_webview/expectations/trichrome_webview_64_32_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/trichrome_webview_64_32_bundle.AndroidManifest.expected
@@ -519,7 +519,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
<uses-static-library android:name="org.chromium.trichromelibrary" android:certDigest="32a2fc74d731105859e5a85df16d95f102d85b22099b8064c5d8915c61dad1e0" android:version="OFFSET=33"/>
</application>
diff --git a/android_webview/expectations/trichrome_webview_64_bundle.AndroidManifest.expected b/android_webview/expectations/trichrome_webview_64_bundle.AndroidManifest.expected
index 24004b6a41aae..5f533ee16ac5c 100644
--- a/android_webview/expectations/trichrome_webview_64_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/trichrome_webview_64_bundle.AndroidManifest.expected
@@ -519,7 +519,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-library android:name="androidx.window.extensions" android:required="false"/>
<uses-static-library android:name="org.chromium.trichromelibrary" android:certDigest="32a2fc74d731105859e5a85df16d95f102d85b22099b8064c5d8915c61dad1e0" android:version="OFFSET=34"/>
</application>
diff --git a/android_webview/expectations/trichrome_webview_bundle.AndroidManifest.expected b/android_webview/expectations/trichrome_webview_bundle.AndroidManifest.expected
index d873ece60663a..bcd903033aaa5 100644
--- a/android_webview/expectations/trichrome_webview_bundle.AndroidManifest.expected
+++ b/android_webview/expectations/trichrome_webview_bundle.AndroidManifest.expected
@@ -497,7 +497,6 @@
android:process=":sandboxed_process9"
android:visibleToInstantApps="true">
</service> # DIFF-ANCHOR: e2f3bbbd
- <uses-library android:name="android.ext.adservices" android:required="false"/>
<uses-static-library android:name="org.chromium.trichromelibrary" android:certDigest="32a2fc74d731105859e5a85df16d95f102d85b22099b8064c5d8915c61dad1e0" android:version="OFFSET=31"/>
</application>
</manifest>
diff --git a/third_party/androidx/0_privacysandbox_AndroidManifest.xml b/third_party/androidx/0_privacysandbox_AndroidManifest.xml
new file mode 100644
index 0000000000000..da6c78ff7b0cc
--- /dev/null
+++ b/third_party/androidx/0_privacysandbox_AndroidManifest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+Copyright 2023 The Chromium Authors
+Use of this source code is governed by a BSD-style license that can be
+found in the LICENSE file.
+-->
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:tools="http://schemas.android.com/tools"
+ package="org.chromium.privacysandbox.overrides">
+
+ <!-- Library needed for androidx.privacysandbox.ads:ads-adservices to work on Android R & S,
+ which we do not currently support. Removing out of caution to prevent the library from
+ slowing down renderer process start-up.
+ https://crbug.com/1448095
+ -->
+ <application>
+ <uses-library android:name="android.ext.adservices" tools:node="remove" />
+ </application>
+</manifest>
diff --git a/third_party/androidx/customizations.gni b/third_party/androidx/customizations.gni
index 334001bfedf8b..cebd24d1c4330 100644
--- a/third_party/androidx/customizations.gni
+++ b/third_party/androidx/customizations.gni
@@ -85,6 +85,12 @@ template("_androidx_prebuilt") {
# Replace broad library -keep rules with a more limited set in
# chrome/android/java/proguard.flags instead.
ignore_proguard_configs = true
+ } else if (target_name ==
+ "androidx_privacysandbox_ads_ads_adservices_java") {
+ if (!is_high_end_android) {
+ # https://crbug.com/1448095
+ mergeable_android_manifests = [ "0_privacysandbox_AndroidManifest.xml" ]
+ }
} else if (target_name == "androidx_startup_startup_runtime_java") {
# Keeps emoji2 code. See http://crbug.com/1205141
ignore_proguard_configs = true
--
2.53.0