diff --git a/OsmAnd-java/build.gradle b/OsmAnd-java/build.gradle index 5964d10165..d461ea8aff 100644 --- a/OsmAnd-java/build.gradle +++ b/OsmAnd-java/build.gradle @@ -1,5 +1,6 @@ apply plugin: 'java' apply plugin: 'maven-publish' +apply plugin: 'ivy-publish' configurations { android @@ -85,11 +86,21 @@ artifacts { } publishing { + repositories { + ivy { + url = System.getenv("OSMAND_BINARIES_IVY_ROOT") ?: "./" + } + } publications { maven(MavenPublication) { artifactId "osmand-base" from components.java } + ivyJava(IvyPublication) { + artifact androidJar { + classifier 'android' + } + } } } diff --git a/build.gradle b/build.gradle index 947988ebf5..2789ee2902 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ buildscript { - ext.kotlin_version = '1.3.11' + ext.kotlin_version = '1.4.10' repositories { google() mavenCentral() @@ -10,7 +10,7 @@ buildscript { } dependencies { //classpath 'com.android.tools.build:gradle:2.+' - classpath 'com.android.tools.build:gradle:3.2.1' + classpath 'com.android.tools.build:gradle:4.1.1' classpath 'com.google.gms:google-services:3.0.0' classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" diff --git a/gradle.properties b/gradle.properties index 1a21288983..c80fef2728 100644 --- a/gradle.properties +++ b/gradle.properties @@ -18,6 +18,7 @@ # for enableD8=true min sdk must be > 22 # UPDATE: temporairly commented since gradle plugin updated to 3.1.3 and claims INSTALL_FAILED_DEXOPT is fixed # UPDATE 2: D8 causes problems on arm64 devices with Android 6.0 (API 23) -android.enableD8=false +# UPDATE 3: Turn on D8 to recover builds with new gradle 6.5 and pluigin 4.1.1 +#android.enableD8=false android.enableJetifier=true android.useAndroidX=true diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index bf3de21830..622ab64a3c 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists