Skip to content

Commit c6769e6

Browse files
build: update Android build configurations
- Bump compile SDK version to 35 and build tools version to "35.0.0" - Update target SDK version to 35 - Add namespace 'com.optimizely.optimizely_flutter_sdk' - Enable buildConfig feature - Update kotlin-stdlib-jdk7 to version 2.1.0 - Update jackson-databind to version 2.17.2 - Set minSdkVersion and targetSdkVersion to 35 for example app - Update distributionUrl in gradle-wrapper.properties to Gradle 8.10.2 - Update android plugin version to 8.7.0 and kotlin-android version to 2.1.0
1 parent bbb4790 commit c6769e6

File tree

4 files changed

+17
-12
lines changed

4 files changed

+17
-12
lines changed

android/build.gradle

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,21 @@ rootProject.allprojects {
2424

2525

2626
ext {
27-
compile_sdk_version = 32
28-
build_tools_version = "30.0.3"
27+
compile_sdk_version = 35
28+
build_tools_version = "35.0.0"
2929
min_sdk_version = 21
30-
target_sdk_version = 29
30+
target_sdk_version = 35
3131
}
3232

3333
android {
34+
namespace 'com.optimizely.optimizely_flutter_sdk'
3435
compileSdkVersion compile_sdk_version
3536
buildToolsVersion build_tools_version
3637

38+
buildFeatures {
39+
buildConfig true
40+
}
41+
3742
defaultConfig {
3843
minSdkVersion min_sdk_version
3944
targetSdkVersion target_sdk_version
@@ -73,9 +78,9 @@ dependencies {
7378
implementation 'com.github.tony19:logback-android:3.0.0'
7479
implementation 'org.slf4j:slf4j-api:2.0.7'
7580

76-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.6.10"
81+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:2.1.0"
7782
implementation "com.optimizely.ab:android-sdk:5.0.1"
78-
implementation 'com.fasterxml.jackson.core:jackson-databind:2.13.4'
83+
implementation 'com.fasterxml.jackson.core:jackson-databind:2.17.2'
7984
implementation ('com.google.guava:guava:19.0') {
8085
exclude group:'com.google.guava', module:'listenablefuture'
8186
}

example/android/app/build.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ if (flutterVersionName == null) {
2424
}
2525

2626
android {
27-
compileSdkVersion 32
28-
ndkVersion flutter.ndkVersion
27+
namespace "com.optimizely.optimizely_flutter_sdk_example"
28+
compileSdkVersion 35
2929

3030
compileOptions {
3131
sourceCompatibility JavaVersion.VERSION_1_8
@@ -37,8 +37,8 @@ android {
3737
applicationId "com.optimizely.optimizely_flutter_sdk_example"
3838
// You can update the following values to match your application needs.
3939
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-build-configuration.
40-
minSdkVersion 21
41-
targetSdkVersion 32
40+
minSdkVersion flutter.minSdkVersion
41+
targetSdkVersion 35
4242
versionCode flutterVersionCode.toInteger()
4343
versionName flutterVersionName
4444
}

example/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-all.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip

example/android/settings.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ pluginManagement {
2626

2727
plugins {
2828
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
29-
id "com.android.application" version "7.2.1" apply false
30-
id "org.jetbrains.kotlin.android" version "1.6.10" apply false
29+
id "com.android.application" version "8.7.0" apply false
30+
id "org.jetbrains.kotlin.android" version "2.1.0" apply false
3131
}
3232

3333
include ":app"

0 commit comments

Comments
 (0)