From 8c2a66eca9ed2fedb057a374f06cb82bf2af7476 Mon Sep 17 00:00:00 2001 From: David Allison <62114487+david-allison@users.noreply.github.com> Date: Fri, 18 Aug 2023 19:26:01 +0100 Subject: [PATCH] build: update `targetSdkVersion` to 32 Android 12L (API level 32) is a minor release that makes Android 12 even better on large screens. There are no breaking changes. Since we have removed support for TVs, this is primarily relevant for foldable phones and Chromebooks Since Google has imposed a hard deadline in a couple of weeks, only tested on: * Large Desktop API 32 Changes: https://developer.android.com/about/versions/12/12L/summary Issue 14129 --- AnkiDroid/build.gradle | 7 +++++-- AnkiDroid/robolectricDownloader.gradle | 4 ++-- api/build.gradle | 2 +- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/AnkiDroid/build.gradle b/AnkiDroid/build.gradle index cb110e79d3d0..e3e3d3fe7008 100644 --- a/AnkiDroid/build.gradle +++ b/AnkiDroid/build.gradle @@ -69,8 +69,11 @@ android { versionCode=21603300 versionName="2.16.3" minSdkVersion 21 - //noinspection OldTargetApi - also performed in api/build.fradle - targetSdkVersion 31 // change .tests_emulator.yml + // change api/build.gradle + // change robolectricDownloader.gradle + // After #13695: change .tests_emulator.yml + // noinspection OldTargetApi + targetSdkVersion 32 testApplicationId "com.ichi2.anki.tests" vectorDrawables.useSupportLibrary = true testInstrumentationRunner 'com.ichi2.testutils.NewCollectionPathTestRunner' diff --git a/AnkiDroid/robolectricDownloader.gradle b/AnkiDroid/robolectricDownloader.gradle index 0ef1a0283ba4..c12933ca2c6d 100644 --- a/AnkiDroid/robolectricDownloader.gradle +++ b/AnkiDroid/robolectricDownloader.gradle @@ -24,8 +24,8 @@ def robolectricAndroidSdkVersions = [ // [androidVersion: "9", frameworkSdkBuildVersion: "4913185-2"], [androidVersion: "10", frameworkSdkBuildVersion: "5803371"], // [androidVersion: "11", frameworkSdkBuildVersion: "6757853"], - [androidVersion: "12", frameworkSdkBuildVersion: "7732740"], -// [androidVersion: "12.1", frameworkSdkBuildVersion: "8229987"], +// [androidVersion: "12", frameworkSdkBuildVersion: "7732740"], + [androidVersion: "12.1", frameworkSdkBuildVersion: "8229987"], // [androidVersion: "13", frameworkSdkBuildVersion: "9030017"], ] diff --git a/api/build.gradle b/api/build.gradle index f46d770de42e..92558d68f424 100644 --- a/api/build.gradle +++ b/api/build.gradle @@ -23,7 +23,7 @@ android { defaultConfig { minSdkVersion 16 //noinspection OldTargetApi - targetSdkVersion 31 + targetSdkVersion 32 buildConfigField "String", "READ_WRITE_PERMISSION", '"com.ichi2.anki.permission.READ_WRITE_DATABASE"' buildConfigField "String", "AUTHORITY", '"com.ichi2.anki.flashcards"' }