GLDriver/app/build.gradle
2025-01-21 08:54:54 +08:00

204 lines
7.5 KiB
Groovy
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
}
def releaseTime() {
return new Date().format("yyyyMMddHHmm", TimeZone.getTimeZone("GMT+08:00"))
}
android {
namespace 'com.arpa.hndahesudintocctmsdriver'
signingConfigs {
// config {
// keyAlias 'key0'
// keyPassword '210419'
// storeFile file('gldriver.jks')
// storePassword '210419'
// v1SigningEnabled true
// v2SigningEnabled true
// }
config {
keyAlias 'key0'
keyPassword '123456'
storeFile file('key.jks')
storePassword '123456'
v1SigningEnabled true
v2SigningEnabled true
}
}
compileSdk rootProject.ext.android["compileSdkVersion"]
defaultConfig {
applicationId rootProject.ext.android["applicationId"]
minSdkVersion rootProject.ext.android["minSdkVersion"]
targetSdkVersion rootProject.ext.android["targetSdkVersion"]
versionCode rootProject.ext.android["versionCode"]
versionName rootProject.ext.android["versionName"]
flavorDimensions "CHANNEL_VALUE"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
ndk {
//设置支持的SO库架构开发者可以根据需要选择一个或多个平台的so
abiFilters "armeabi-v7a", "arm64-v8a"
// abiFilters "armeabi", "armeabi-v7a", "arm64-v8a", "x86","x86_64"
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.config
}
debug {
signingConfig signingConfigs.config
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
kotlinOptions {
jvmTarget = '11'
}
buildFeatures {
viewBinding = true
}
lintOptions {
checkReleaseBuilds false
abortOnError false
}
sourceSets {
main {
jniLibs.srcDir 'libs'
//说明so的路径为该libs路径关联所有地图SDK的so文件
}
}
productFlavors {
dev {
applicationId "com.arpa.hndahesudintocctmsdriver"
manifestPlaceholders = [CHANNEL_VALUE: "司机端(测试)",
// app_icon : "@drawable/head_defaut",
JPUSH_PKGNAME: applicationId,
//JPush 上注册的包名对应的 Appkey.
JPUSH_APPKEY : "fba6f55621c670d8c1fe9191",
//暂时填写默认值即可.
JPUSH_CHANNEL: "developer-n"]
buildConfigField("String", "OPEN_AL_URL", "\"https://oapi-staging.alct56.com\"")
buildConfigField("String", "BASE_URL", "\"http://192.168.1.118:8082/devApi/\"")
// buildConfigField("String", "BASE_URL", "\"http://192.168.1.118:8080/devApi/\"")
// buildConfigField("String", "BASE_URL", "\"http://platform.test.v2.dahehuoyun.com/devApi/\"")
buildConfigField "boolean", "isTest", "true"
//APP名称可以在androidMainfest中引用
resValue "string", "appName", "司机端测试"
}
prod {
applicationId "com.arpa.hndahesudintocctmsdriver"
manifestPlaceholders = [CHANNEL_VALUE: "司机端",
// app_icon : "@drawable/ysxy",
JPUSH_PKGNAME: applicationId,
//JPush 上注册的包名对应的 Appkey.
JPUSH_APPKEY : "fba6f55621c670d8c1fe9191",
//暂时填写默认值即可.
JPUSH_CHANNEL: "developer-default"]
buildConfigField("String", "OPEN_AL_URL", "\"https://oapi.alct56.com\"")
buildConfigField("String", "BASE_URL", "\"http://app.dahehuoyun.com/api/\"")
buildConfigField "boolean", "isTest", "false"
resValue "string", "appName", "司机端"
}
}
android.applicationVariants.all { variant ->
variant.outputs.all {
//获取渠道名称
def isText = variant.productFlavors[0].properties.get("buildConfigFields").getAt("isTest").properties.get("value")
def appName = null
if (isText == "true") {
appName = '司机端测试_'
} else {
appName = '司机端正式_'
}
outputFileName = appName + "${variant.buildType.name}_${defaultConfig.versionName}_${releaseTime()}.apk"
}
}
}
dependencies {
implementation 'androidx.core:core-ktx:1.7.0'
implementation 'androidx.appcompat:appcompat:1.3.0'
implementation 'com.google.android.material:material:1.4.0'
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
implementation 'androidx.annotation:annotation:1.2.0'
implementation 'androidx.lifecycle:lifecycle-livedata-ktx:2.3.1'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
//评价星星
implementation 'me.zhanghai.android.materialratingbar:library:1.4.0'
implementation project(path: ':mylibrary')
implementation project(path: ':keeplibrary')
// implementation files('libs/ocrsdk.aar')
//高德地图
// implementation 'com.amap.api:3dmap:9.8.3'
//定位功能
// implementation 'com.amap.api:location:6.4.2'//6.4.2
implementation 'com.amap.api:search:9.7.0'
implementation 'com.amap.api:navi-3dmap:latest.integration'
// implementation 'com.amap.api:navi-3dmap:9.8.3_3dmap9.8.3'
//易签宝
// implementation files('libs/EsignSDK.aar')
// implementation(name: 'EsignSDK', ext: 'aar')
//交通厅
implementation 'com.lzy.net:okgo:3.0.4'
implementation 'com.alibaba:fastjson:1.2.61'
implementation 'org.bouncycastle:bcprov-jdk15on:1.55'
implementation 'org.apache.commons:commons-lang3:3.5'
// implementation(name: 'locationgd-androidx_2.1.0', ext: 'aar')//交通厅
implementation files('libs/locationgd-androidx_2.1.0.aar')
//安联
//当引入的与之前引入的库有重复冲突部分的时候使用compileOnly
// implementation files('libs\\mdp_sdk.jar')
// implementation 'com.loopj.android:android-async-http:1.4.9'
// implementation 'com.j256.ormlite:ormlite-android:4.48'
// implementation 'com.j256.ormlite:ormlite-core:4.48'
implementation 'com.github.hotchemi:permissionsdispatcher:2.3.1'
annotationProcessor 'com.github.hotchemi:permissionsdispatcher-processor:2.3.1'
//友盟
implementation 'com.umeng.umsdk:common:9.6.3'// 必选
implementation 'com.umeng.umsdk:asms:1.8.0'// 必选
implementation 'com.umeng.umsdk:uverify:2.5.9'// 必选
implementation 'com.umeng.umsdk:uverify-main:2.1.4'// 必选
implementation 'com.umeng.umsdk:uverify-logger:2.1.4'// 必选
implementation 'com.umeng.umsdk:uverify-crashshield:2.1.4'// 必选
//推送
// implementation 'com.umeng.umsdk:push:6.6.3'// 必选
implementation 'cn.jiguang.sdk:jpush:5.3.1'
implementation files('libs/mdp-release.aar')
}