You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
76 lines
1.7 KiB
76 lines
1.7 KiB
11 months ago
|
import java.time.LocalDateTime
|
||
|
import java.time.Month
|
||
|
import java.time.temporal.ChronoUnit
|
||
|
|
||
|
apply plugin: 'com.android.application'
|
||
|
|
||
|
android {
|
||
|
ndkVersion '26.1.10909125'
|
||
|
namespace 'com.example.hlsdk'
|
||
|
|
||
|
packagingOptions {
|
||
|
jniLibs {
|
||
|
useLegacyPackaging = true
|
||
|
}
|
||
|
}
|
||
|
|
||
|
defaultConfig {
|
||
|
applicationId 'com.example.hlsdk'
|
||
|
versionName '1.35'
|
||
|
versionCode getBuildNum()
|
||
|
minSdkVersion 19
|
||
|
targetSdk 34
|
||
|
compileSdk 34
|
||
|
}
|
||
|
|
||
|
externalNativeBuild {
|
||
|
cmake {
|
||
|
version '3.22.1'
|
||
|
}
|
||
|
}
|
||
|
|
||
|
compileOptions {
|
||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||
|
}
|
||
|
|
||
|
buildTypes {
|
||
|
debug {
|
||
|
minifyEnabled false
|
||
|
shrinkResources false
|
||
|
debuggable true
|
||
|
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
|
||
|
}
|
||
|
release {
|
||
|
minifyEnabled false
|
||
|
shrinkResources false
|
||
|
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
|
||
|
}
|
||
|
}
|
||
|
|
||
|
externalNativeBuild {
|
||
|
cmake {
|
||
|
path file('../../CMakeLists.txt')
|
||
|
}
|
||
|
}
|
||
|
|
||
|
lint {
|
||
|
abortOnError false
|
||
|
}
|
||
|
|
||
|
androidResources {
|
||
|
noCompress += ''
|
||
|
}
|
||
|
}
|
||
|
|
||
|
dependencies {
|
||
|
implementation 'androidx.appcompat:appcompat:1.6.1'
|
||
|
}
|
||
|
|
||
|
static def getBuildNum() {
|
||
|
LocalDateTime now = LocalDateTime.now()
|
||
|
LocalDateTime releaseDate = LocalDateTime.of(2023, Month.DECEMBER, 28, 0, 0, 0)
|
||
|
int qBuildNum = releaseDate.until(now, ChronoUnit.DAYS)
|
||
|
int minuteOfDay = now.getHour() * 60 + now.getMinute()
|
||
|
return qBuildNum * 10000 + minuteOfDay
|
||
|
}
|