Convert :source-api and :source-local to android library module (#3636)
- There's really no plan to support other platforms on this code base - The "KMP" modules only had android target which is rather pointless - `i18n` involves more work but given it has no actual code keeping it as is
This commit is contained in:
+19
-37
@@ -1,46 +1,28 @@
|
||||
import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi
|
||||
|
||||
plugins {
|
||||
alias(mihonx.plugins.kotlin.multiplatform)
|
||||
alias(mihonx.plugins.android.library)
|
||||
alias(mihonx.plugins.spotless)
|
||||
|
||||
alias(libs.plugins.kotlin.serialization)
|
||||
}
|
||||
|
||||
kotlin {
|
||||
@Suppress("UnstableApiUsage")
|
||||
android {
|
||||
namespace = "eu.kanade.tachiyomi.source"
|
||||
optimization {
|
||||
consumerKeepRules.file("consumer-proguard.pro")
|
||||
}
|
||||
android {
|
||||
namespace = "eu.kanade.tachiyomi.source"
|
||||
|
||||
// TODO(antsy): Remove when https://youtrack.jetbrains.com/issue/KT-83319 is resolved
|
||||
withHostTest { }
|
||||
}
|
||||
|
||||
@OptIn(ExperimentalKotlinGradlePluginApi::class)
|
||||
dependencies {
|
||||
api(libs.kotlinx.serialization.json)
|
||||
api(libs.injekt)
|
||||
api(libs.rxJava)
|
||||
api(libs.jsoup)
|
||||
|
||||
implementation(platform(libs.androidx.compose.bom))
|
||||
implementation(libs.androidx.compose.runtime)
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
androidMain {
|
||||
dependencies {
|
||||
implementation(projects.core.common)
|
||||
api(libs.androidx.preference)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@OptIn(ExperimentalKotlinGradlePluginApi::class)
|
||||
compilerOptions {
|
||||
freeCompilerArgs.add("-Xexpect-actual-classes")
|
||||
defaultConfig {
|
||||
consumerProguardFiles("consumer-proguard.pro")
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(projects.core.common)
|
||||
|
||||
implementation(libs.kotlinx.serialization.json)
|
||||
implementation(libs.injekt)
|
||||
implementation(libs.rxJava)
|
||||
implementation(libs.jsoup)
|
||||
|
||||
implementation(libs.androidx.preference)
|
||||
|
||||
implementation(platform(libs.androidx.compose.bom))
|
||||
implementation(libs.androidx.compose.runtime)
|
||||
}
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
package eu.kanade.tachiyomi.source
|
||||
|
||||
actual typealias PreferenceScreen = androidx.preference.PreferenceScreen
|
||||
@@ -1,3 +0,0 @@
|
||||
package eu.kanade.tachiyomi.source
|
||||
|
||||
expect class PreferenceScreen
|
||||
@@ -1,5 +0,0 @@
|
||||
package eu.kanade.tachiyomi.util
|
||||
|
||||
import rx.Observable
|
||||
|
||||
expect suspend fun <T> Observable<T>.awaitSingle(): T
|
||||
+1
@@ -3,6 +3,7 @@ package eu.kanade.tachiyomi.source
|
||||
import android.app.Application
|
||||
import android.content.Context
|
||||
import android.content.SharedPreferences
|
||||
import androidx.preference.PreferenceScreen
|
||||
import uy.kohesive.injekt.Injekt
|
||||
import uy.kohesive.injekt.api.get
|
||||
|
||||
+1
-1
@@ -3,4 +3,4 @@ package eu.kanade.tachiyomi.util
|
||||
import rx.Observable
|
||||
import tachiyomi.core.common.util.lang.awaitSingle
|
||||
|
||||
actual suspend fun <T> Observable<T>.awaitSingle(): T = awaitSingle()
|
||||
suspend fun <T> Observable<T>.awaitSingle(): T = awaitSingle()
|
||||
Reference in New Issue
Block a user