Commit 54c21058 by asaarnak Committed by GitHub

Add compatibility with Android Gradle Plugin 8.0 (#1039)

* Adds Android namespace

Adds a namespace attribute to the Android build.gradle, for compatibility with Android Gradle Plugin 8.0.

* Adds Android namespace

Adds a namespace attribute to the Android build.gradle, for compatibility with Android Gradle Plugin 8.0.

* Conditionalize the namespace
parent 2e47f05a
...@@ -27,6 +27,10 @@ project.getTasks().withType(JavaCompile){ ...@@ -27,6 +27,10 @@ project.getTasks().withType(JavaCompile){
apply plugin: 'com.android.library' apply plugin: 'com.android.library'
android { android {
// Conditional for compatibility with AGP <4.2.
if (project.android.hasProperty("namespace")) {
namespace 'com.baseflow.permissionhandler'
}
compileSdkVersion 33 compileSdkVersion 33
compileOptions { compileOptions {
......
...@@ -25,6 +25,7 @@ apply plugin: 'com.android.application' ...@@ -25,6 +25,7 @@ apply plugin: 'com.android.application'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
android { android {
namespace 'com.baseflow.permissionhandler.example'
compileSdkVersion 33 compileSdkVersion 33
compileOptions { compileOptions {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment