[TetheringGoogle] Remove explicit targetSdkVersion
Going forward targetSdkVersion would be set by build system.
It would be by default set to 10000 before SDK finalization,
and updated to the new API level after finalization.
Effectively it would mean:
1. '10000' in aosp and internal master
2. Finalized number in development branches like "33" in "tm-dev"
3. As sdk hasn't been finalised in "udc-dev", it would be "10000"
which would be automatically updated to finalized version after sdk finalization.
Removing the target sdk version declaration from the blueprint and manifest files.
More details can be found here go/mainline-modules-target-sdk-version-fix
Bug: b/242296003
Test: croot; sdks=`find ./out -name 'TetheringGoogle.apk' | grep -v .intermediates`; echo $sdks; for sdk in $sdks;do aapt2 dump badging `echo $sdk` | grep targetSdkVersion:; done
1. outputs 33 in tm-mainline-prod
2. outputs 10000 in master
Change-Id: I2657901f066a5220ae0f807846b32b9c41afcce9
diff --git a/Tethering/Android.bp b/Tethering/Android.bp
index 3ab1ec2..f203191 100644
--- a/Tethering/Android.bp
+++ b/Tethering/Android.bp
@@ -21,11 +21,15 @@
java_defaults {
name: "TetheringApiLevel",
sdk_version: "module_current",
- target_sdk_version: "33",
min_sdk_version: "30",
}
java_defaults {
+ name: "TetheringReleaseTargetSdk",
+ target_sdk_version: "33",
+}
+
+java_defaults {
name: "TetheringExternalLibs",
// Libraries not including Tethering's own framework-tethering (different flavors of that one
// are needed depending on the build rule)
@@ -81,7 +85,8 @@
defaults: [
"ConnectivityNextEnableDefaults",
"TetheringAndroidLibraryDefaults",
- "TetheringApiLevel"
+ "TetheringApiLevel",
+ "TetheringReleaseTargetSdk"
],
static_libs: [
"NetworkStackApiCurrentShims",
@@ -94,7 +99,8 @@
name: "TetheringApiStableLib",
defaults: [
"TetheringAndroidLibraryDefaults",
- "TetheringApiLevel"
+ "TetheringApiLevel",
+ "TetheringReleaseTargetSdk"
],
static_libs: [
"NetworkStackApiStableShims",
@@ -180,7 +186,12 @@
// Non-updatable tethering running in the system server process for devices not using the module
android_app {
name: "InProcessTethering",
- defaults: ["TetheringAppDefaults", "TetheringApiLevel", "ConnectivityNextEnableDefaults"],
+ defaults: [
+ "TetheringAppDefaults",
+ "TetheringApiLevel",
+ "ConnectivityNextEnableDefaults",
+ "TetheringReleaseTargetSdk"
+ ],
static_libs: ["TetheringApiCurrentLib"],
certificate: "platform",
manifest: "AndroidManifest_InProcess.xml",