@@ -67,8 +67,9 @@ class AndroidBuild extends JavaBuild {
6767 static public String MIN_SDK_WATCHFACE ;
6868
6969 // Versions of all required dependencies
70- static public String TARGET_SDK ;
71- static public String TARGET_PLATFORM ;
70+ static public String TARGET_SDK ;
71+ static public String TARGET_WEAR_SDK_ARM ;
72+ static public String TARGET_WEAR_SDK ;
7273 static public String GRADLE_PLUGIN_VER ;
7374 static public String APPCOMPAT_VER ;
7475 static public String V4LEGACY_VER ;
@@ -1024,8 +1025,21 @@ static public void initVersions(File file) {
10241025 TARGET_SDK = defTargetSDK ;
10251026 Preferences .set ("android.sdk.target" , TARGET_SDK );
10261027 }
1027- TARGET_PLATFORM = "android-" + TARGET_SDK ;
1028-
1028+
1029+ TARGET_WEAR_SDK_ARM = Preferences .get ("android.sdk.target.wear_arm" );
1030+ String defTargetWearSDKArm = props .getProperty ("android-platform-wear-arm" );
1031+ if (TARGET_WEAR_SDK_ARM == null || PApplet .parseInt (TARGET_WEAR_SDK_ARM ) != PApplet .parseInt (defTargetWearSDKArm )) {
1032+ TARGET_WEAR_SDK_ARM = defTargetWearSDKArm ;
1033+ Preferences .set ("android.sdk.target.wear_arm" , TARGET_WEAR_SDK_ARM );
1034+ }
1035+
1036+ TARGET_WEAR_SDK = Preferences .get ("android.sdk.target.wear" );
1037+ String defTargetWearSDK = props .getProperty ("android-platform-wear" );
1038+ if (TARGET_WEAR_SDK == null || PApplet .parseInt (TARGET_WEAR_SDK ) != PApplet .parseInt (defTargetWearSDK )) {
1039+ TARGET_WEAR_SDK = defTargetWearSDK ;
1040+ Preferences .set ("android.sdk.target.wear" , TARGET_WEAR_SDK );
1041+ }
1042+
10291043 APPCOMPAT_VER = Preferences .get ("android.sdk.appcompat" );
10301044 String defAppCompatVer = props .getProperty ("androidx.appcompat%appcompat" );
10311045 if (APPCOMPAT_VER == null || !versionCheck (APPCOMPAT_VER , defAppCompatVer )) {
0 commit comments