build.gradle
3.66 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
buildscript {
// ext.kotlin_version = '1.3.50'
// ext.kotlin_version = '1.9.24'
// ext.kotlin_version = '1.5.20'
ext.kotlin_version = '1.9.0'
// ext.kotlin_version = '1.5.20'
// ext.kotlin_version = '1.4.32'
// ext{
// compileSdkVersion = 34
// }
repositories {
mavenCentral()
google()
jcenter()
maven{
url 'http://maven.aliyun.com/nexus/content/groups/public/'
allowInsecureProtocol = true
}
// maven { url 'https://maven.aliyun.com/repository/google' }
// maven { url 'https://maven.aliyun.com/repository/jcenter' }
// maven { url 'http://maven.aliyun.com/nexus/content/groups/public' }
maven {url 'https://developer.huawei.com/repo/'}
}
dependencies {
// classpath 'com.android.tools.build:gradle:4.2.0'
classpath 'com.android.tools.build:gradle:7.4.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'com.huawei.agconnect:agcp:1.0.0.300'
}
}
allprojects {
repositories {
mavenCentral()
google()
jcenter()
maven{
url 'http://maven.aliyun.com/nexus/content/groups/public/'
allowInsecureProtocol = true
}
// maven { url 'https://maven.aliyun.com/repository/google' }
// maven { url 'https://maven.aliyun.com/repository/jcenter' }
// maven { url 'http://maven.aliyun.com/nexus/content/groups/public' }
maven {url 'https://developer.huawei.com/repo/'}
maven { url 'https://jitpack.io' }
}
}
rootProject.buildDir = '../build'
// subprojects{
// project.abiFilters.android.compileSdkVersion 34
// }
subprojects {
project.buildDir = "${rootProject.buildDir}/${project.name}"
}
subprojects {
if (project.name == 'whisper_cpp_flutter_plus') {
apply plugin: 'org.jetbrains.kotlin.android'
plugins.withId('com.android.library') {
android.ndkVersion = '29.0.13113456'
}
afterEvaluate {
if (project.hasProperty('android')) {
project.android.compileSdk = 34
}
}
}
if (project.name == 'flutter_open_chinese_convert') {
plugins.withId('com.android.library') {
android.compileSdk = 34
}
afterEvaluate {
if (project.hasProperty('android')) {
project.android.compileSdk = 34
}
}
}
}
subprojects {
project.evaluationDependsOn(':app')
}
subprojects {
project.configurations.all {
resolutionStrategy.eachDependency { details ->
if (details.requested.group == 'com.android.support'
&& !details.requested.name.contains('multidex') ) {
details.useVersion "27.1.1"
}
if (project.name == 'app') {
if (details.requested.group == 'org.jetbrains.kotlin') {
details.useVersion '1.8.22'
}
if (details.requested.group == 'org.jetbrains.kotlinx'
&& details.requested.name.startsWith('kotlinx-coroutines')) {
details.useVersion '1.9.0'
}
}
if (project.name == 'flutter_open_chinese_convert') {
if (details.requested.group == 'org.jetbrains.kotlin') {
details.useVersion '1.8.22'
}
if (details.requested.group == 'org.jetbrains.kotlinx'
&& details.requested.name.startsWith('kotlinx-coroutines')) {
details.useVersion '1.6.4'
}
}
}
}
}
tasks.register("clean", Delete) {
delete rootProject.buildDir
}