Use current shims in service-connectivity
Instead of NetworkStackApiStableShims, use NetworkStackApiCurrentShims
as this is a development branch.
Use java_defaults in the "merge conflicts expected" section, so that
module release branches can use the same defaults, but set it to
NetworkStackApiStableShims.
The shims are removed from FrameworksNetIntegrationTests, as they are
already available there through service-connectivity-pre-jarjar. Keeping
them as a dependency would make FrameworksNetIntegrationTests use both
Stable shims (directly) and Current shims
(through service-connectivity-pre-jarjar).
Bug: 266205506
Test: m
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:921290b49d109360aae5dc39effaa3b0e691f65a)
Merged-In: I88228152834a1c06830fb51e868fb8e3d8c47519
Change-Id: I88228152834a1c06830fb51e868fb8e3d8c47519
diff --git a/service/Android.bp b/service/Android.bp
index 1523af9..e1376a1 100644
--- a/service/Android.bp
+++ b/service/Android.bp
@@ -138,6 +138,14 @@
name: "service-connectivity-pre-jarjar",
sdk_version: "system_server_current",
min_sdk_version: "30",
+ // NetworkStackApiShimSettingsForCurrentBranch provides the latest available shims depending on
+ // the branch to "service-connectivity".
+ // There are Tethering.apk and TetheringNext.apk variants for the tethering APEX,
+ // which use NetworkStackApiStableShims and NetworkStackApiCurrentShims respectively.
+ // Note that there can be no service-connectivity-next because it would need to be configured in
+ // default_art_config.mk which doesn't support conditionals, hence this scheme of using a
+ // variable here.
+ defaults: ["NetworkStackApiShimSettingsForCurrentBranch"],
srcs: [
"src/**/*.java",
":framework-connectivity-shared-srcs",
@@ -183,7 +191,6 @@
"PlatformProperties",
"service-connectivity-protos",
"service-connectivity-stats-protos",
- "NetworkStackApiStableShims",
],
apex_available: [
"com.android.tethering",