Enable tethering to perform its own hidden API processing
Previously, the hidden API encoding of the tethering boot dex jars, i.e. those dex jars that tethering contributes to the bootclasspath were done as part of the monolithic hidden API processing. This change causes the encoding to be done by the tethering's bootclasspath_fragment. This change involves the following: * Addition of the fragments property to the tethering's bootclasspath_fragment module to list all the other bootclasspath_fragment modules on which this depends. * Addition of the additional_stubs property to add stubs for APIs that are not provided by another bootclasspath_fragment. * Moving hidden API flag file entries related to tethering from the flag files in frameworks/base/boot/hiddenapi directory into the tethering directory with an appropriate OWNERS file to allow them to be managed by the Soong and compat team. * Addition of a PREUPLOAD.cfg hook script to ensure that the flag files are sorted. The build automatically checks that the hidden API flags which are computed by tethering and encoded into its boot dex jars match those that are generated by the monolithic processing so this is guaranteed to be safe. Bug: 179354495 Test: m com.android.tethering - ensure that the generated APEX is byte-for-byte identical before and after these changes. m out/soong/hiddenapi/hiddenapi-flags.csv - make sure that they are not changed by this. Change-Id: I4d9621325c7fcea5043cbca4c577ba2ac6125c0c Ignore-AOSP-First: merge conflicts
This commit is contained in:
parent
d5532eac04
commit
b28cb44e4b
5 changed files with 1260 additions and 2 deletions
|
@ -2,3 +2,5 @@
|
|||
checkstyle_hook = ${REPO_ROOT}/prebuilts/checkstyle/checkstyle.py --sha ${PREUPLOAD_COMMIT}
|
||||
|
||||
ktlint_hook = ${REPO_ROOT}/prebuilts/ktlint/ktlint.py -f ${PREUPLOAD_FILES}
|
||||
|
||||
hidden_api_txt_checksorted_hook = ${REPO_ROOT}/tools/platform-compat/hiddenapi/checksorted_sha.sh ${PREUPLOAD_COMMIT} ${REPO_ROOT}
|
||||
|
|
|
@ -31,11 +31,11 @@ apex {
|
|||
],
|
||||
multilib: {
|
||||
first: {
|
||||
jni_libs: ["libservice-connectivity"]
|
||||
jni_libs: ["libservice-connectivity"],
|
||||
},
|
||||
both: {
|
||||
jni_libs: ["libframework-connectivity-jni"],
|
||||
}
|
||||
},
|
||||
},
|
||||
bpfs: [
|
||||
"offload.o",
|
||||
|
@ -74,6 +74,27 @@ bootclasspath_fragment {
|
|||
"framework-tethering",
|
||||
],
|
||||
apex_available: ["com.android.tethering"],
|
||||
|
||||
// The bootclasspath_fragments that provide APIs on which this depends.
|
||||
fragments: [
|
||||
{
|
||||
apex: "com.android.art",
|
||||
module: "art-bootclasspath-fragment",
|
||||
},
|
||||
],
|
||||
|
||||
// Additional stubs libraries that this fragment's contents use which are
|
||||
// not provided by another bootclasspath_fragment.
|
||||
additional_stubs: [
|
||||
"android-non-updatable",
|
||||
],
|
||||
|
||||
// Additional hidden API flag files to override the defaults. This must only be
|
||||
// modified by the Soong or platform compat team.
|
||||
hidden_api: {
|
||||
max_target_o_low_priority: ["hiddenapi/hiddenapi-max-target-o-low-priority.txt"],
|
||||
unsupported: ["hiddenapi/hiddenapi-unsupported.txt"],
|
||||
},
|
||||
}
|
||||
|
||||
override_apex {
|
||||
|
|
9
Tethering/apex/hiddenapi/OWNERS
Normal file
9
Tethering/apex/hiddenapi/OWNERS
Normal file
|
@ -0,0 +1,9 @@
|
|||
# These files are only intended to be changed by platform-compat and
|
||||
# the soong teams.
|
||||
set noparent
|
||||
|
||||
# soong-team@ as the hiddenapi files are tightly coupled with Soong
|
||||
file:platform/build/soong:/OWNERS
|
||||
|
||||
# compat-team@ for changes to hiddenapi files
|
||||
file:tools/platform-compat:/OWNERS
|
1216
Tethering/apex/hiddenapi/hiddenapi-max-target-o-low-priority.txt
Normal file
1216
Tethering/apex/hiddenapi/hiddenapi-max-target-o-low-priority.txt
Normal file
File diff suppressed because it is too large
Load diff
10
Tethering/apex/hiddenapi/hiddenapi-unsupported.txt
Normal file
10
Tethering/apex/hiddenapi/hiddenapi-unsupported.txt
Normal file
|
@ -0,0 +1,10 @@
|
|||
Landroid/net/IConnectivityManager$Stub$Proxy;-><init>(Landroid/os/IBinder;)V
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getActiveLinkProperties()Landroid/net/LinkProperties;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getActiveNetworkInfo()Landroid/net/NetworkInfo;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getAllNetworkInfo()[Landroid/net/NetworkInfo;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getAllNetworks()[Landroid/net/Network;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getTetherableIfaces()[Ljava/lang/String;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getTetherableUsbRegexs()[Ljava/lang/String;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->getTetheredIfaces()[Ljava/lang/String;
|
||||
Landroid/net/IConnectivityManager$Stub$Proxy;->mRemote:Landroid/os/IBinder;
|
||||
Landroid/net/IConnectivityManager$Stub;->asInterface(Landroid/os/IBinder;)Landroid/net/IConnectivityManager;
|
Loading…
Reference in a new issue