| 7 |
| 8 | configurations { |
| 9 | compile.exclude module: 'support-v4' |
| 10 | } |
| 11 |
| 12 | configurations.all { |
| 13 | exclude group: 'com.google.firebase', module: 'firebase-core' |
| 14 | exclude group: 'androidx.recyclerview', module: 'recyclerview' |
| 15 | } |
| 16 |
| 17 | dependencies { |
| 18 | implementation project(':TMessagesProj') |
| 19 | implementation 'androidx.multidex:multidex:2.0.1' |
| 20 | coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5' |
| 21 | implementation files('../TMessagesProj/libs/libgsaverification-client.aar') |
| 22 |
| 23 | implementation "com.microsoft.appcenter:appcenter-distribute:3.3.1" |
| 24 | implementation "com.microsoft.appcenter:appcenter-crashes:3.3.1" |
| 25 | implementation "com.microsoft.appcenter:appcenter-analytics:3.3.1" |
| 26 | } |
| 27 |
| 28 | android { |
| 29 | compileSdkVersion 33 |
| 30 | buildToolsVersion '33.0.0' |
| 31 |
| 32 | defaultConfig.applicationId = APP_PACKAGE |
| 33 |
| 34 | sourceSets.main.jniLibs.srcDirs = ['../TMessagesProj/jni/'] |
| 35 |
| 36 | lintOptions { |
| 37 | disable 'MissingTranslation' |
| 38 | disable 'ExtraTranslation' |
| 39 | disable 'BlockedPrivateApi' |
| 40 | } |
| 41 |
| 42 | dexOptions { |
| 43 | jumboMode = true |
| 44 | } |
| 45 |
| 46 | compileOptions { |
| 47 | sourceCompatibility JavaVersion.VERSION_1_8 |
| 48 | targetCompatibility JavaVersion.VERSION_1_8 |
| 49 |
| 50 | coreLibraryDesugaringEnabled true |
| 51 | } |
| 52 |
| 53 | signingConfigs { |
| 54 | debug { |
| 55 | storeFile file("../TMessagesProj/config/release.keystore") |
| 56 | storePassword RELEASE_STORE_PASSWORD |
| 57 | keyAlias RELEASE_KEY_ALIAS |
| 58 | keyPassword RELEASE_KEY_PASSWORD |
| 59 | } |
| 60 |
| 61 | release { |
| 62 | storeFile file("../TMessagesProj/config/release.keystore") |
| 63 | storePassword RELEASE_STORE_PASSWORD |
| 64 | keyAlias RELEASE_KEY_ALIAS |
| 65 | keyPassword RELEASE_KEY_PASSWORD |
| 66 | } |
| 67 | } |
| 68 |
| 69 | buildTypes { |
| 70 | HA_private { |
| 71 | debuggable true |
| 72 | jniDebuggable true |
| 73 | signingConfig signingConfigs.debug |
| 74 | applicationIdSuffix ".beta" |
| 75 | minifyEnabled true |
| 76 | multiDexEnabled true |
| 77 | proguardFiles getDefaultProguardFile('proguard-android.txt'), '../TMessagesProj/proguard-rules.pro' |
| 78 | ndk.debugSymbolLevel = 'FULL' |
| 79 | } |
| 80 | HA_public { |
| 81 | debuggable false |
| 82 | jniDebuggable false |
| 83 | signingConfig signingConfigs.debug |
| 84 | applicationIdSuffix ".beta" |
| 85 | minifyEnabled true |
| 86 | multiDexEnabled true |
| 87 | proguardFiles getDefaultProguardFile('proguard-android.txt'), '../TMessagesProj/proguard-rules.pro' |
| 88 | ndk.debugSymbolLevel = 'FULL' |
| 89 | } |
| 90 | } |
| 91 |
| 92 | sourceSets.HA_private { |
| 93 | manifest.srcFile '../TMessagesProj/config/debug/AndroidManifest.xml' |
| 94 | } |
| 95 | sourceSets.HA_public { |
| 96 | manifest.srcFile '../TMessagesProj/config/debug/AndroidManifest.xml' |
| 97 | } |
| 98 |
| 99 | flavorDimensions "minApi" |
| 100 |
| 101 | productFlavors { |
| 102 | bundleAfat { |
| 103 | ndk { |
| 104 | abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64" |
| 105 | } |
| 106 | ext { |
| 107 | abiVersionCode = 1 |
| 108 | } |
| 109 | } |
| 110 | bundleAfat_SDK23 { |
| 111 | ndk { |
| 112 | abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64" |
| 113 | } |
| 114 | minSdkVersion 23 |
| 115 | ext { |
| 116 | abiVersionCode = 2 |
| 117 | } |
| 118 | } |
| 119 | afat { |
| 120 | ndk { |
| 121 | abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64" |
| 122 | } |
| 123 | ext { |
| 124 | abiVersionCode = 9 |
| 125 | } |
| 126 | } |
| 127 | } |
| 128 |
| 129 | defaultConfig.versionCode = Integer.parseInt(APP_VERSION_CODE) |
| 130 |
| 131 | applicationVariants.all { variant -> |
| 132 | variant.outputs.all { output -> |
| 133 | outputFileName = "app.apk" |
| 134 | output.versionCodeOverride = defaultConfig.versionCode * 10 + variant.productFlavors.get(0).abiVersionCode |
| 135 | } |
| 136 | } |
| 137 |
| 138 | variantFilter { variant -> |
| 139 | def names = variant.flavors*.name |
| 140 | if (variant.buildType.name != "release" && !names.contains("afat")) { |
| 141 | setIgnore(true) |
| 142 | } |
| 143 | } |
| 144 |
| 145 | defaultConfig { |
| 146 | minSdkVersion 19 |
| 147 | targetSdkVersion 33 |
| 148 | versionName APP_VERSION_NAME |
| 149 | ndkVersion "21.4.7075529" |
| 150 |
| 151 | multiDexEnabled true |
| 152 |
| 153 | vectorDrawables.generatedDensities = ['mdpi', 'hdpi', 'xhdpi', 'xxhdpi'] |
| 154 |
| 155 | externalNativeBuild { |
| 156 | cmake { |
| 157 | version '3.10.2' |
| 158 | arguments '-DANDROID_STL=c++_static', '-DANDROID_PLATFORM=android-16', "-j=16" |
| 159 | } |
| 160 | } |
| 161 | } |
| 162 |
| 163 | buildFeatures { |
| 164 | buildConfig = true |
| 165 | } |
| 166 |
| 167 | lintOptions { |
| 168 | checkReleaseBuilds false |
| 169 | } |
| 170 | } |
| 171 |
| 172 | apply plugin: 'com.google.gms.google-services' |
| 173 |