android_multiviewwer/app/build.gradle.kts

258 lines
9.7 KiB
Plaintext
Raw Permalink Normal View History

2024-11-06 16:47:13 +09:00
import java.text.SimpleDateFormat
import java.util.Date
2024-08-23 11:39:16 +09:00
2024-08-12 17:02:52 +09:00
plugins {
id ("com.android.application")
id ("kotlin-android")
2024-08-23 16:03:43 +09:00
id ("io.realm.kotlin")
id ("kotlin-kapt")
2024-08-12 17:02:52 +09:00
}
android {
2026-03-05 18:11:08 +09:00
namespace = "bums.lunatic.launcher"
2024-11-13 17:41:40 +09:00
compileSdk = 35
2024-08-12 17:02:52 +09:00
defaultConfig {
2024-10-18 16:16:41 +09:00
applicationId = "bums.lunatic.launcher"
2024-08-12 17:02:52 +09:00
minSdk = 26
versionCode = 38
versionName = "2.8.2"
2024-12-20 18:06:54 +09:00
multiDexEnabled = true
2025-08-27 18:19:26 +09:00
ndk {
abiFilters += listOf("arm64-v8a") // 필요한 ABI만 빌드하도록 필터링
}
2025-08-26 13:32:53 +09:00
externalNativeBuild {
cmake {
2025-08-26 18:24:06 +09:00
cppFlags += "-std=c++17"
2025-08-27 18:19:26 +09:00
arguments += "-DANDROID_STL=c++_shared"
2025-08-26 13:32:53 +09:00
}
}
2025-08-27 18:19:26 +09:00
// 이 부분을 추가하여 prefab 기능을 활성화합니다.
buildFeatures {
prefab = true
}
2024-08-12 17:02:52 +09:00
}
2025-08-26 13:32:53 +09:00
2024-08-12 17:02:52 +09:00
buildTypes {
getByName("debug") {
isMinifyEnabled = false
isShrinkResources = false
isDebuggable = true
2024-11-20 15:51:13 +09:00
// applicationIdSuffix = ".debug"
// versionNameSuffix = "-debug"
2025-08-26 13:32:53 +09:00
buildConfigField("Long","BuildDateTime", "${getDateTime()}L")
2024-08-23 11:39:16 +09:00
resValue ("string", "app_name", "Bums Launcher Debug")
2024-08-12 17:02:52 +09:00
}
getByName("release") {
isMinifyEnabled = true
isShrinkResources = true
2025-08-26 13:32:53 +09:00
buildConfigField("Long","BuildDateTime", "${getDateTime()}L")
2024-08-12 17:02:52 +09:00
proguardFiles (getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro")
2024-08-23 11:39:16 +09:00
resValue ("string", "app_name", "Bums Launcher")
2024-08-12 17:02:52 +09:00
}
}
2025-08-26 13:32:53 +09:00
externalNativeBuild {
cmake {
path = file("src/main/cpp/CMakeLists.txt")
2025-08-27 15:09:05 +09:00
version = "3.22.1"
2025-08-26 13:32:53 +09:00
}
}
2024-08-23 11:39:16 +09:00
signingConfigs {
getByName("debug") {
storeFile = file("./bs_debug.keystore")
storePassword = "android"
keyAlias = "androiddebugkey"
keyPassword = "android"
}
}
2025-08-26 18:24:06 +09:00
android {
sourceSets["main"].jniLibs.srcDirs("src/main/jniLibs")
2026-02-24 18:04:59 +09:00
2025-08-26 18:24:06 +09:00
}
2024-08-23 11:39:16 +09:00
2024-08-12 17:02:52 +09:00
applicationVariants.all {
if (buildType.name == "release") {
outputs.all {
val output = this as? com.android.build.gradle.internal.api.BaseVariantOutputImpl
if (output?.outputFileName?.endsWith(".apk") == true) {
output.outputFileName = "${defaultConfig.applicationId}_v${defaultConfig.versionName}.apk"
}
}
}
}
buildFeatures {
viewBinding = true
2024-10-11 09:34:04 +09:00
dataBinding = true
2025-03-27 11:50:45 +09:00
buildConfig = true
resValues = true
2024-08-12 17:02:52 +09:00
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
2026-02-24 18:04:59 +09:00
2024-12-20 18:06:54 +09:00
packagingOptions.resources.excludes.add("META-INF/*")
packagingOptions.resources.excludes.add("mozilla/*")
packagingOptions.resources.excludes.add("META-INF/*/*")
2026-01-26 15:32:30 +09:00
packagingOptions {
jniLibs {
useLegacyPackaging = true
}
}
2024-08-12 17:02:52 +09:00
kotlinOptions {
jvmTarget = "1.8"
}
2025-08-26 18:24:06 +09:00
ndkVersion = "29.0.13846066 rc3"
2025-09-07 23:14:03 +09:00
// buildToolsVersion = "35.0.1"
packaging {
doNotStrip("**/libaria2c.zip.so")
doNotStrip("**/libffmpeg.zip.so")
doNotStrip("**/libpython.zip.so")
2026-03-05 18:11:08 +09:00
jniLibs {
pickFirsts.add("lib/**/libc++_shared.so")
pickFirsts.add("lib/**/libavcodec.so")
pickFirsts.add("lib/**/libavfilter.so")
pickFirsts.add("lib/**/libavformat.so")
pickFirsts.add("lib/**/libavutil.so")
pickFirsts.add("lib/**/libswresample.so")
pickFirsts.add("lib/**/libswscale.so")
}
2025-09-07 23:14:03 +09:00
}
2026-02-24 18:04:59 +09:00
2024-08-12 17:02:52 +09:00
}
2026-02-24 18:04:59 +09:00
2024-08-12 17:02:52 +09:00
dependencies {
2026-02-24 18:04:59 +09:00
implementation(fileTree(mapOf(
"dir" to "libs",
"include" to listOf("*.aar", "*.jar"),
)))
2026-03-05 18:11:08 +09:00
implementation(project(":gdrive"))
2026-03-16 15:22:49 +09:00
implementation("com.google.android.gms:play-services-wearable:19.0.0")
2024-08-12 17:02:52 +09:00
val kotlinVersion: String? by extra
2025-09-07 23:14:03 +09:00
val realmVersion = "2.0.0"
implementation ("androidx.appcompat:appcompat:1.7.1")
2024-08-12 17:02:52 +09:00
implementation ("androidx.biometric:biometric-ktx:1.2.0-alpha05")
implementation ("androidx.browser:browser:1.8.0")
2024-11-13 17:41:40 +09:00
implementation ("androidx.core:core-ktx:1.15.0")
2024-08-12 17:02:52 +09:00
implementation ("androidx.core:core-splashscreen:1.0.1")
2024-11-13 17:41:40 +09:00
implementation ("androidx.lifecycle:lifecycle-runtime-ktx:2.8.7")
2024-08-23 11:39:16 +09:00
implementation ("com.google.android.material:material:1.12.0")
2025-09-07 23:14:03 +09:00
implementation ("com.ibm.icu:icu4j:77.1")
implementation (kotlin("stdlib", version = "2.0.10"))
2024-08-12 17:02:52 +09:00
implementation ("com.github.cachapa:ExpandableLayout:2.9.2")
2025-08-25 09:45:58 +09:00
2024-11-13 17:41:40 +09:00
implementation ("androidx.work:work-runtime:2.10.0")
2025-09-07 23:14:03 +09:00
implementation ("com.google.code.gson:gson:2.13.1")
implementation ("io.realm.kotlin:library-base:${realmVersion}")
implementation ("org.jsoup:jsoup:1.21.2")
implementation ("org.apache.commons:commons-text:1.14.0")
2024-09-06 01:04:53 +09:00
implementation("com.squareup.okhttp:okhttp:2.7.5")
2024-11-13 17:41:40 +09:00
implementation("com.google.android.gms:play-services-location:21.3.0")
2025-09-07 23:14:03 +09:00
implementation("com.google.android.gms:play-services-tasks:18.3.2")
implementation("com.squareup.retrofit2:retrofit:3.0.0")
implementation("com.squareup.retrofit2:converter-gson:3.0.0")
implementation("com.squareup.retrofit2:converter-scalars:3.0.0")
2024-11-15 16:06:08 +09:00
implementation("androidx.viewpager2:viewpager2:1.1.0")
2024-10-15 18:16:32 +09:00
implementation("com.squareup.picasso:picasso:2.71828")
2024-11-11 18:12:06 +09:00
implementation("com.github.delight-im:Android-AdvancedWebView:v3.2.1")
2025-09-07 23:14:03 +09:00
// implementation(project(":library"))
// implementation(project(":utils"))
implementation( "com.github.bumptech.glide:glide:4.11.0")
2025-09-07 23:14:03 +09:00
implementation ("com.github.bumptech.glide:okhttp3-integration:4.11.0")
2026-04-20 17:10:15 +09:00
implementation ("com.github.chrisbanes:PhotoView:2.3.0")
implementation ("androidx.exifinterface:exifinterface:1.3.6")
2025-07-16 12:56:56 +09:00
// https://mvnrepository.com/artifact/org.mozilla.geckoview/geckoview
implementation("org.mozilla.geckoview:geckoview:139.0.20250523173407")
2025-09-07 23:14:03 +09:00
implementation("com.vladsch.flexmark:flexmark-all:0.64.8")
2025-08-01 18:36:16 +09:00
// implementation 'com.vladsch.flexmark:flexmark-all:0.64.8'
2025-03-27 11:50:45 +09:00
// implementation("org.opencv:opencv-android:4.11.0")
2025-08-14 16:48:48 +09:00
// build.gradle에 추가
2026-01-30 16:52:36 +09:00
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.3")
2025-08-17 16:17:52 +09:00
// implementation ("com.github.aeonSolutions:FloatingActionButtonMenuDrag:1.1")
2025-08-20 17:08:17 +09:00
implementation("io.github.junkfood02.youtubedl-android:library:0.17.4")
implementation("io.github.junkfood02.youtubedl-android:ffmpeg:0.17.4")
implementation("io.github.junkfood02.youtubedl-android:aria2c:0.17.4")
2025-09-19 18:08:03 +09:00
implementation("io.coil-kt:coil:2.5.0")
2025-09-23 15:37:38 +09:00
implementation("io.coil-kt:coil-gif:2.5.0")
2025-08-31 13:07:04 +09:00
implementation ("com.squareup.okhttp3:logging-interceptor:4.11.0")
2025-09-19 18:08:03 +09:00
implementation("androidx.lifecycle:lifecycle-viewmodel-ktx:2.8.3")
// Fragment KTX: Fragment에서 by viewModels() 델리게이트를 사용하기 위해 필수
implementation("androidx.fragment:fragment-ktx:1.8.1")
// Lifecycle KTX: viewLifecycleOwner.lifecycleScope 등을 사용하기 위해 필요
implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.8.3")
2026-02-24 18:04:59 +09:00
2025-08-26 18:24:06 +09:00
// implementation ("com.arthenica:ffmpeg-kit-full:4.5.LTS")
2025-08-27 18:19:26 +09:00
// implementation ("com.arthenica:ffmpeg-kit-full:6.0-2")
// implementation(files("libs/ffmpeg-kit-full-6.0-2.LTS.aar"))
// implementation("com.arthenica:ffmpeg-kit-full-gpl:5.1")
2025-03-27 11:50:45 +09:00
2026-02-24 18:04:59 +09:00
2024-11-18 17:35:40 +09:00
implementation ("androidx.media:media:1.7.0")
2025-07-15 11:22:07 +09:00
// implementation(project(":sdk"))
2024-10-08 17:58:37 +09:00
// implementation ("me.everything:providers-android:1.0.1")
// implementation ("me.everything:providers-core:1.0.1")
2024-09-11 18:09:16 +09:00
// implementation ("androidx.window:window:1.0.0")
// implementation("io.github.vaneproject:hanguleditor:1.0.0")
2026-03-05 18:11:08 +09:00
// implementation ("androidx.concurrent:concurrent-listenablefuture-ktx:1.1.0")
implementation ("com.google.guava:guava:33.2.1-jre")
val camerax_version = "1.3.0" // 안정적인 최신 버전 사용
// CameraX 코어 라이브러리
implementation("androidx.camera:camera-core:$camerax_version")
implementation("androidx.camera:camera-camera2:$camerax_version")
// CameraX Lifecycle 라이브러리 (Fragment/Activity 생명주기 연결)
implementation("androidx.camera:camera-lifecycle:$camerax_version")
// CameraX View 라이브러리 (PreviewView 등 UI 구성 요소)
implementation("androidx.camera:camera-view:$camerax_version")
// (선택) CameraX 비디오 라이브러리
implementation("androidx.camera:camera-video:$camerax_version")
// (선택) CameraX 확장 라이브러리 (보케, HDR 등)
implementation("androidx.camera:camera-extensions:$camerax_version")
2026-04-10 15:31:07 +09:00
implementation("com.google.mlkit:translate:17.0.3") // 버전 살짝 업그레이드 권장
implementation("com.google.mlkit:language-id:17.0.5")
implementation("com.google.android.gms:play-services-base:18.5.0")
implementation("com.google.mlkit:common:18.11.0")
2025-09-07 23:14:03 +09:00
constraints {
// ⚠️ 이 버전을 프로젝트 루트의 build.gradle.kts에 정의된 kotlinVersion 값과 정확히 일치시키세요.
val targetKotlinVersion = "2.0.20"
implementation("org.jetbrains.kotlin:kotlin-stdlib") {
version { strictly(targetKotlinVersion) }
// reason = "Align all Kotlin stdlib versions with the compiler plugin version"
}
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8") {
version { strictly(targetKotlinVersion) }
// reason = "Align all Kotlin stdlib versions with the compiler plugin version"
}
implementation("org.jetbrains.kotlin:kotlin-stdlib-common") {
version { strictly(targetKotlinVersion) }
// reason = "Align all Kotlin stdlib versions with the compiler plugin version"
}
}
2024-08-12 17:02:52 +09:00
}
2024-11-06 16:47:13 +09:00
fun getDateTime() = SimpleDateFormat("yyyyMMddHHmm").format(Date()).toLong()