diff --git a/buildSrc/src/main/kotlin/multiplatform-config.gradle.kts b/buildSrc/src/main/kotlin/multiplatform-config.gradle.kts index 0008a72eb..dddb51730 100644 --- a/buildSrc/src/main/kotlin/multiplatform-config.gradle.kts +++ b/buildSrc/src/main/kotlin/multiplatform-config.gradle.kts @@ -1,10 +1,4 @@ -import com.moowork.gradle.node.NodeExtension -import com.moowork.gradle.node.npm.NpmTask -import com.moowork.gradle.node.task.NodeTask import org.gradle.kotlin.dsl.* -import org.jetbrains.kotlin.gradle.dsl.KotlinMultiplatformExtension -import org.jetbrains.kotlin.gradle.tasks.Kotlin2JsCompile -import org.jetbrains.kotlin.gradle.tasks.KotlinCompile plugins { kotlin("multiplatform") diff --git a/kmath-core/build.gradle.kts b/kmath-core/build.gradle.kts index 93f4a1af6..6faba5a1b 100644 --- a/kmath-core/build.gradle.kts +++ b/kmath-core/build.gradle.kts @@ -6,9 +6,6 @@ val ioVersion: String by rootProject.extra kotlin { - jvm() - js() - sourceSets { commonMain { dependencies { diff --git a/kmath-coroutines/build.gradle.kts b/kmath-coroutines/build.gradle.kts index d249e1c48..627b475d5 100644 --- a/kmath-coroutines/build.gradle.kts +++ b/kmath-coroutines/build.gradle.kts @@ -3,10 +3,7 @@ plugins { } kotlin { - jvm() - js() - - sourceSets.invoke { + sourceSets { commonMain { dependencies { api(project(":kmath-core")) @@ -19,23 +16,23 @@ kotlin { implementation(kotlin("test-annotations-common")) } } - "jvmMain" { + jvmMain { dependencies { api("org.jetbrains.kotlinx:kotlinx-coroutines-core:${Ver.coroutinesVersion}") } } - "jvmTest" { + jvmTest { dependencies { implementation(kotlin("test")) implementation(kotlin("test-junit")) } } - "jsMain" { + jsMain { dependencies { api("org.jetbrains.kotlinx:kotlinx-coroutines-core-js:${Ver.coroutinesVersion}") } } - "jsTest" { + jsTest { dependencies { implementation(kotlin("test-js")) } diff --git a/kmath-histograms/build.gradle.kts b/kmath-histograms/build.gradle.kts index 069c11bc9..61eb61a43 100644 --- a/kmath-histograms/build.gradle.kts +++ b/kmath-histograms/build.gradle.kts @@ -3,10 +3,7 @@ plugins { } kotlin { - jvm() - js() - - sourceSets.invoke { + sourceSets { commonMain { dependencies { api(project(":kmath-core")) @@ -18,13 +15,13 @@ kotlin { implementation(kotlin("test-annotations-common")) } } - "jvmTest" { + jvmTest { dependencies { implementation(kotlin("test")) implementation(kotlin("test-junit")) } } - "jsTest" { + jsTest { dependencies { implementation(kotlin("test-js")) } diff --git a/kmath-koma/build.gradle.kts b/kmath-koma/build.gradle.kts index 5d8e10cb1..4270ab7d5 100644 --- a/kmath-koma/build.gradle.kts +++ b/kmath-koma/build.gradle.kts @@ -14,10 +14,8 @@ kotlin { } } } - js() - - sourceSets.invoke { + sourceSets { commonMain { dependencies { api(project(":kmath-core")) @@ -30,24 +28,24 @@ kotlin { implementation(kotlin("test-annotations-common")) } } - "jvmMain" { + jvmMain { dependencies { api("com.kyonifer:koma-core-api-jvm:0.12") } } - "jvmTest" { + jvmTest { dependencies { implementation(kotlin("test")) implementation(kotlin("test-junit")) implementation("com.kyonifer:koma-core-ejml:0.12") } } - "jsMain" { + jsMain { dependencies { api("com.kyonifer:koma-core-api-js:0.12") } } - "jsTest" { + jsTest { dependencies { implementation(kotlin("test-js")) } diff --git a/kmath-memory/build.gradle.kts b/kmath-memory/build.gradle.kts index 12cce0bbb..e23030fba 100644 --- a/kmath-memory/build.gradle.kts +++ b/kmath-memory/build.gradle.kts @@ -1,9 +1,3 @@ plugins { id("multiplatform-config") } - -// We actually don't need this, we define jvm and js targets in multiplatform-config -kotlin { - jvm() - js() -} diff --git a/kmath-sequential/build.gradle.kts b/kmath-sequential/build.gradle.kts index 6309d97d0..8d24f8cc9 100644 --- a/kmath-sequential/build.gradle.kts +++ b/kmath-sequential/build.gradle.kts @@ -4,10 +4,7 @@ plugins { } kotlin { - jvm() - js() - - sourceSets.invoke { + sourceSets { commonMain { dependencies { api(project(":kmath-core")) @@ -15,12 +12,12 @@ kotlin { compileOnly("org.jetbrains.kotlinx:atomicfu-common:${Ver.atomicfuVersion}") } } - "jvmMain" { + jvmMain { dependencies { compileOnly("org.jetbrains.kotlinx:atomicfu:${Ver.atomicfuVersion}") } } - "jsMain" { + jsMain { dependencies { compileOnly("org.jetbrains.kotlinx:atomicfu-js:${Ver.atomicfuVersion}") }