2013-10-25 15:19:00 +00:00
|
|
|
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
2015-06-29 17:12:11 +00:00
|
|
|
buildscript {
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
2018-08-27 08:33:11 +00:00
|
|
|
google()
|
2020-06-24 16:15:30 +00:00
|
|
|
maven { url "https://plugins.gradle.org/m2/" }
|
2015-06-29 17:12:11 +00:00
|
|
|
}
|
|
|
|
dependencies {
|
2022-08-17 09:09:53 +00:00
|
|
|
classpath 'com.android.tools.build:gradle:7.0.4'
|
2021-09-21 00:21:16 +00:00
|
|
|
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.30'
|
2022-08-17 09:09:53 +00:00
|
|
|
classpath 'com.google.gms:google-services:4.3.13'
|
|
|
|
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.9.1'
|
2021-11-15 18:04:57 +00:00
|
|
|
classpath 'gradle.plugin.org.mozilla.rust-android-gradle:plugin:0.9.0'
|
2021-05-18 10:21:26 +00:00
|
|
|
//noinspection GradleDependency
|
2021-11-17 15:33:25 +00:00
|
|
|
classpath "com.github.triplet.gradle:play-publisher:3.6.0"
|
2021-09-21 00:21:16 +00:00
|
|
|
classpath 'cn.hutool:hutool-core:5.7.13'
|
2015-06-29 17:12:11 +00:00
|
|
|
}
|
2018-08-27 08:33:11 +00:00
|
|
|
}
|
2020-06-24 16:15:30 +00:00
|
|
|
|
2021-02-18 02:32:07 +00:00
|
|
|
static String detectNdkVersion() {
|
2020-06-24 16:15:30 +00:00
|
|
|
|
2021-03-26 02:01:53 +00:00
|
|
|
def version = "21.4.7075529"
|
2020-06-24 16:15:30 +00:00
|
|
|
|
|
|
|
def androidHome = System.getenv("ANDROID_HOME")
|
|
|
|
|
|
|
|
if (androidHome == null) return version
|
2021-02-18 02:32:07 +00:00
|
|
|
if (new File(androidHome, "ndk/$version").isDirectory()) return version
|
2020-06-24 16:15:30 +00:00
|
|
|
|
2021-09-21 00:21:16 +00:00
|
|
|
def versionFile = new File(androidHome, "ndk-bundle/source.properties")
|
2020-06-24 16:15:30 +00:00
|
|
|
|
|
|
|
if (!versionFile.isFile()) return version
|
|
|
|
|
|
|
|
def versionProperties = new Properties()
|
|
|
|
|
|
|
|
versionProperties.load(versionFile.newDataInputStream())
|
|
|
|
|
2021-09-21 00:21:16 +00:00
|
|
|
return versionProperties.getProperty("Pkg.Revision", version)
|
2020-06-24 16:15:30 +00:00
|
|
|
|
2019-07-18 13:01:39 +00:00
|
|
|
}
|
2020-06-24 16:15:30 +00:00
|
|
|
|
|
|
|
ext {
|
|
|
|
|
|
|
|
ndkVersion = detectNdkVersion()
|
|
|
|
|
2021-02-18 02:32:07 +00:00
|
|
|
}
|
2020-06-24 16:15:30 +00:00
|
|
|
|
|
|
|
allprojects {
|
|
|
|
repositories {
|
|
|
|
// The order in which you list these repositories matter.
|
|
|
|
mavenCentral()
|
|
|
|
google()
|
|
|
|
}
|
|
|
|
}
|