-
Notifications
You must be signed in to change notification settings - Fork 22
/
build.gradle
184 lines (160 loc) · 7.28 KB
/
build.gradle
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
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
rootProject.ext.configPath = "../app-config.json"
apply from: "../parse_json.gradle"
android {
signingConfigs {
config {
storeFile file('../opensource_keystore.jks')
storePassword '111222'
keyAlias = 'tenextll'
keyPassword '111222'
}
}
ndkVersion "22.1.7171670"
compileSdkVersion 31
buildToolsVersion "29.0.2"
defaultConfig {
applicationId "com.tencent.iot.explorer.link.opensource"
minSdkVersion 21
targetSdkVersion 31
versionCode rootProject.ext.android.versionCode
versionName rootProject.ext.android.versionName
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
ndk {
//根据需要 自行选择添加的对应cpu类型的.so库。
abiFilters 'armeabi', 'armeabi-v7a', 'x86', 'arm64-v8a'
// 还可以添加 'x86', 'x86_64', 'mips', 'mips64'
}
manifestPlaceholders = [
XG_ACCESS_ID : '',
XG_ACCESS_KEY: '',
MAP_SDK_VALUE: getValueById('TencentMapSDKValue')
]
buildConfigField 'String', 'WXAccessAppId', "\"${getValueById('WXAccessAppId')}\""
buildConfigField 'String', 'TencentIotLinkAppkey', "\"${getValueById('TencentIotLinkAppkey')}\""
buildConfigField 'String', 'TencentIotLinkAppSecret', "\"${getValueById('TencentIotLinkAppSecret')}\""
buildConfigField 'String', 'XgAccessId', "\"${getValueById('XgAccessId')}\""
buildConfigField 'String', 'XgAccessKey', "\"${getValueById('XgAccessKey')}\""
buildConfigField 'String', 'XgUSAAccessId', "\"${getValueById('XgUSAAccessId')}\""
buildConfigField 'String', 'XgUSAAccessKey', "\"${getValueById('XgUSAAccessKey')}\""
buildConfigField 'String', 'WeatherKey', "\"${getValueById('HEweatherKey')}\""
buildConfigField 'String', 'TencentMapSDKValue', "\"${getValueById('TencentMapSDKValue')}\""
multiDexEnabled true
}
flavorDimensions "version"
productFlavors {
opensource {
applicationId "com.tencent.iot.explorer.link.opensource"
resValue("string", "app_name_zh", "腾讯连连开源版")
resValue("string", "app_name_en", "Tencent LLink (OSS)")
}
//-tencentOfficial {
//- applicationId "com.tencent.iot.explorer.link"
//- resValue("string" , "app_name_zh","腾讯连连")
//- resValue("string" , "app_name_en","Tencent LLink")
//-}
}
kotlinOptions { jvmTarget = 1.8 }
buildTypes {
debug {
signingConfig signingConfigs.config
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
release {
signingConfig signingConfigs.config
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
lintOptions {
checkReleaseBuilds false
abortOnError false
}
sourceSets { main { assets.srcDirs = ['src/main/assets', 'src/main/assets/'] } }
repositories {
flatDir { dirs 'libs' }
}
applicationVariants.all { variant ->
variant.outputs.all {
def date = new Date().format("yyyyMMddHH", TimeZone.getTimeZone("GMT+08"))
if (variant.buildType.name == 'debug') {
outputFileName = "iot-link-android-debug-${date}.apk"
}
if (variant.buildType.name == 'release') {
outputFileName = "iot-link-android-release-${date}.apk"
}
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.aar', '*.jar'])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'androidx.core:core-ktx:1.1.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'com.google.android.material:material:1.2.1'
implementation 'com.airbnb.android:lottie:3.6.1'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test:runner:1.2.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
implementation 'com.android.support:design:+'
implementation 'com.android.support:multidex:1.0.1'
//WebSocket
implementation "org.java-websocket:Java-WebSocket:1.4.0"
//EventBus
implementation 'org.greenrobot:eventbus:3.1.1'
//腾讯对象存储--文件上传
implementation('com.qcloud.cos:cos-android-lite:5.6.5') {
exclude group: 'com.tencent.qcloud', module: 'mtaUtils' //关闭 mta上报功能
}
//plist文件解析
implementation 'com.googlecode.plist:dd-plist:1.22'
//微信登录
implementation 'com.tencent.mm.opensdk:wechat-sdk-android-without-mta:+'
//banner
implementation 'com.youth.banner:banner:1.4.10'
//左滑删除
implementation 'com.github.mcxtzhang:SwipeDelMenuLayout:V1.2.1'
implementation 'androidx.cardview:cardview:1.0.0'
api 'com.android.support:recyclerview-v7:29.0.0'
//kotlin协程
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.3.4'
//刷新
implementation 'io.github.shichuanenhui:refresh-layout-kernel:1.0.0'
implementation 'io.github.shichuanenhui:refresh-header-classics:1.0.0'
implementation 'io.github.shichuanenhui:refresh-footer-classics:1.0.0'
if (findProject(':sdk:explorer-link-android') != null) {
implementation project(path: ':sdk:explorer-link-android')
} else {
implementation 'com.tencent.iot.explorer:explorer-link-android:+'
}
implementation 'com.squareup.picasso:picasso:2.71828'
implementation 'com.github.chrisbanes:PhotoView:2.3.0'
implementation 'com.squareup.retrofit2:retrofit:2.0.2'
implementation 'com.yangy:YZxing-lib:2.2'
implementation 'com.alibaba:fastjson:1.2.73'
implementation "com.tencent.iot.thirdparty.android:esptouch:0.3.7.2"
implementation "com.github.skydoves:progressview:1.1.2"
implementation 'com.belerweb:pinyin4j:2.5.1'
implementation 'cn.aigestudio.wheelpicker:WheelPicker:1.1.3'
implementation 'com.chauthai.swipereveallayout:swipe-reveal-layout:1.4.1'
implementation 'com.github.Jay-Goo:RangeSeekBar:v3.0.0'
if (findProject(':sdk:explorer-link-rtc') != null) {
implementation project(path: ':sdk:explorer-link-rtc')
} else {
implementation 'com.tencent.iot.explorer:explorer-link-rtc:+'
}
if (findProject(':sdk:video-link-android') != null) {
api project(path: ':sdk:video-link-android')
}
implementation 'com.tencent.iot.thirdparty.android:ijkplayer-java:2.0.8'
implementation 'com.tencent.iot.thirdparty.android:ijkplayer-armv7a:2.0.8'
implementation 'com.tencent.iot.thirdparty.android:ijkplayer-arm64:2.0.8'
}