| 7 | } |
| 8 | dependencies { |
| 9 | classpath 'com.android.tools.build:gradle:8.6.1' |
| 10 | classpath 'com.google.gms:google-services:4.3.15' |
| 11 | // classpath 'com.huawei.agconnect:agcp:1.9.1.301' |
| 12 | classpath 'com.google.firebase:firebase-crashlytics-gradle:2.9.0' |
| 13 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:2.1.0" |
| 14 |
| 15 | //noinspection GradleDependency |
| 16 | classpath "io.sentry:sentry-android-gradle-plugin:5.12.2" |
| 17 | // db |
| 18 | classpath "io.objectbox:objectbox-gradle-plugin:5.0.1" |
| 19 | } |
| 20 | } |
| 21 |
| 22 | static String detectNdkVersion() { |
| 23 |
| 24 | def version = "21.4.7075529" |
| 25 |
| 26 | def androidHome = System.getenv("ANDROID_HOME") |
| 27 |
| 28 | if (androidHome == null) return version |
| 29 | if (new File(androidHome, "ndk/$version").isDirectory()) return version |
| 30 |
| 31 | def versionFile = new File(androidHome, "ndk-bundle/source.properties") |
| 32 |
| 33 | if (!versionFile.isFile()) return version |
| 34 |
| 35 | def versionProperties = new Properties() |
| 36 |
| 37 | versionProperties.load(versionFile.newDataInputStream()) |
| 38 |
| 39 | return versionProperties.getProperty("Pkg.Revision", version) |
| 40 |
| 41 | } |
| 42 |
| 43 | ext { |
| 44 |
| 45 | ndkVersion = detectNdkVersion() |
| 46 |
| 47 | } |
| 48 |
| 49 | allprojects { |
| 50 | repositories { |
| 51 | // The order in which you list these repositories matter. |
| 52 | mavenCentral() |
| 53 | google() |
| 54 | } |
| 55 | } |