plugins { id 'com.android.application' } android { namespace 'com.xixun.xixunplayer' compileSdk 34 defaultConfig { applicationId "com.xixun.xixunplayer" minSdk 21 targetSdk 34 versionCode 1 versionName "2.2.18-Y-lora" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } buildFeatures { aidl true } compileOptions { sourceCompatibility JavaVersion.VERSION_11 targetCompatibility JavaVersion.VERSION_11 } signingConfigs { X {//4418 keyAlias 'xixun' keyPassword '123456' storeFile file('D:/develop/xixun/signedFile/keystore/xixun-x.keystore') storePassword '123456' } Y {//210 keyAlias 'xixun' keyPassword '123456' storeFile file('D:/develop/xixun/signedFile/keystore/xixun-y.keystore') storePassword '123456' } D_3568a {//3568a 视美泰 keyAlias 'keystore' keyPassword 'android' storeFile file('D:/develop/xixun/signedFile/keystore/keystore.jks') storePassword 'android' } D_3568N {//3568 恩泰世 keyAlias 'systemkey' keyPassword '123456' storeFile file('D:/_docs/comp/android/keystore/3568D恩泰世 123456.jks') storePassword '123456' } D_YF {//3566 YF keyAlias 'platform' keyPassword 'youngfeel' storeFile file('D:/_docs/comp/android/keystore/yf356x_android11_system.jks') storePassword 'youngfeel' } } buildTypes { release { lintOptions { checkReleaseBuilds false abortOnError false } minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' signingConfig signingConfigs.D_3568N } debug { signingConfig signingConfigs.D_3568N } } } dependencies { implementation 'androidx.appcompat:appcompat:1.6.1' implementation 'pl.droidsonroids.gif:android-gif-drawable:1.2.25' implementation 'com.aliyun:imageaudit20191230:2.0.6' implementation 'com.github.wseemann:FFmpegMediaMetadataRetriever-core:1.0.19' implementation 'com.github.wseemann:FFmpegMediaMetadataRetriever-native-armeabi-v7a:1.0.19' implementation 'com.github.wseemann:FFmpegMediaMetadataRetriever-native-arm64-v8a:1.0.19' implementation files('libs/gnph.jar') implementation files('libs/zip4j-2.10.0.jar') implementation files('libs/xixun_card_settings_1.2.4.jar') implementation files('libs/ijkplayer-java-0.8.8.aar') implementation files('libs/ijkplayer-armv7a-0.8.8.aar') implementation files('libs/ijkplayer-arm64-0.8.8.aar') implementation files('libs/connService2.jar') } def getAppName() { def stringsFile = android.sourceSets.main.res.sourceFiles.find { it.name.equals 'strings.xml' } String s = new XmlParser().parse(stringsFile).string.find { it.@name.equals 'app_name' }.text(); return s.replaceAll("\"", ""); } // 修改 Apk 名 android.applicationVariants.configureEach { variant -> variant.outputs.configureEach { def fileName = "${getAppName()}-${versionName}.apk" outputFileName = fileName } }