From c13d7a535831853c618d017948a37c2328c2fff4 Mon Sep 17 00:00:00 2001 From: Romain Boisselle Date: Sat, 18 Nov 2023 15:34:04 +0100 Subject: [PATCH] Kotlin 1.9.20 / Gradle 8.4 --- build.gradle.kts | 2 +- canard/build.gradle.kts | 6 ++++-- .../kotlin/org/kodein/log/frontend/darwinFrontend.kt | 2 ++ .../kotlin/org/kodein/log/frontend/printStackTraceNative.kt | 1 - .../kotlin/org/kodein/log/frontend/defaultWasmJs.kt} | 0 .../org/kodein/log/frontend/printStackTraceWasmJs.kt} | 0 .../kotlin/org/kodein/log/kclassWasmJs.kt} | 0 .../kotlin/org/kodein/log/timestampWasmJs.kt} | 0 gradle/libs.versions.toml | 2 +- gradle/wrapper/gradle-wrapper.properties | 2 +- settings.gradle.kts | 2 +- 11 files changed, 10 insertions(+), 7 deletions(-) rename canard/src/{wasmMain/kotlin/org/kodein/log/frontend/defaultNative.kt => wasmJsMain/kotlin/org/kodein/log/frontend/defaultWasmJs.kt} (100%) rename canard/src/{wasmMain/kotlin/org/kodein/log/frontend/printStackTraceWasm.kt => wasmJsMain/kotlin/org/kodein/log/frontend/printStackTraceWasmJs.kt} (100%) rename canard/src/{wasmMain/kotlin/org/kodein/log/kclassWasm.kt => wasmJsMain/kotlin/org/kodein/log/kclassWasmJs.kt} (100%) rename canard/src/{wasmMain/kotlin/org/kodein/log/timestampJs.kt => wasmJsMain/kotlin/org/kodein/log/timestampWasmJs.kt} (100%) diff --git a/build.gradle.kts b/build.gradle.kts index 52f0592..49b0aa5 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -4,5 +4,5 @@ plugins { allprojects { group = "org.kodein.log" - version = "1.0.1" + version = "1.1.0" } \ No newline at end of file diff --git a/canard/build.gradle.kts b/canard/build.gradle.kts index 9238b12..79f4dfc 100644 --- a/canard/build.gradle.kts +++ b/canard/build.gradle.kts @@ -3,7 +3,10 @@ plugins { } kotlin.kodein { - all() + allNative() + js() + wasmJs() +// wasmWasi() jvm { target.setCompileClasspath() @@ -36,7 +39,6 @@ kotlin.kodein { dependsOn(defaultNativeMain) } } - } kodeinUpload { diff --git a/canard/src/appleMain/kotlin/org/kodein/log/frontend/darwinFrontend.kt b/canard/src/appleMain/kotlin/org/kodein/log/frontend/darwinFrontend.kt index f7817b2..515c16b 100644 --- a/canard/src/appleMain/kotlin/org/kodein/log/frontend/darwinFrontend.kt +++ b/canard/src/appleMain/kotlin/org/kodein/log/frontend/darwinFrontend.kt @@ -1,10 +1,12 @@ package org.kodein.log.frontend +import kotlinx.cinterop.ExperimentalForeignApi import org.kodein.log.LogFrontend import org.kodein.log.LogReceiver import org.kodein.log.Logger import org.kodein.log.darwin.* +@OptIn(ExperimentalForeignApi::class) public val darwinFrontend: LogFrontend = LogFrontend { tag -> val log = darwin_log_create(tag.pkg, tag.name) diff --git a/canard/src/nativeMain/kotlin/org/kodein/log/frontend/printStackTraceNative.kt b/canard/src/nativeMain/kotlin/org/kodein/log/frontend/printStackTraceNative.kt index c1f4c5d..358b461 100644 --- a/canard/src/nativeMain/kotlin/org/kodein/log/frontend/printStackTraceNative.kt +++ b/canard/src/nativeMain/kotlin/org/kodein/log/frontend/printStackTraceNative.kt @@ -5,7 +5,6 @@ import kotlinx.cinterop.cstr import platform.posix.fdopen import platform.posix.fprintf import kotlin.experimental.ExperimentalNativeApi -import kotlin.native.concurrent.SharedImmutable @OptIn(ExperimentalForeignApi::class) diff --git a/canard/src/wasmMain/kotlin/org/kodein/log/frontend/defaultNative.kt b/canard/src/wasmJsMain/kotlin/org/kodein/log/frontend/defaultWasmJs.kt similarity index 100% rename from canard/src/wasmMain/kotlin/org/kodein/log/frontend/defaultNative.kt rename to canard/src/wasmJsMain/kotlin/org/kodein/log/frontend/defaultWasmJs.kt diff --git a/canard/src/wasmMain/kotlin/org/kodein/log/frontend/printStackTraceWasm.kt b/canard/src/wasmJsMain/kotlin/org/kodein/log/frontend/printStackTraceWasmJs.kt similarity index 100% rename from canard/src/wasmMain/kotlin/org/kodein/log/frontend/printStackTraceWasm.kt rename to canard/src/wasmJsMain/kotlin/org/kodein/log/frontend/printStackTraceWasmJs.kt diff --git a/canard/src/wasmMain/kotlin/org/kodein/log/kclassWasm.kt b/canard/src/wasmJsMain/kotlin/org/kodein/log/kclassWasmJs.kt similarity index 100% rename from canard/src/wasmMain/kotlin/org/kodein/log/kclassWasm.kt rename to canard/src/wasmJsMain/kotlin/org/kodein/log/kclassWasmJs.kt diff --git a/canard/src/wasmMain/kotlin/org/kodein/log/timestampJs.kt b/canard/src/wasmJsMain/kotlin/org/kodein/log/timestampWasmJs.kt similarity index 100% rename from canard/src/wasmMain/kotlin/org/kodein/log/timestampJs.kt rename to canard/src/wasmJsMain/kotlin/org/kodein/log/timestampWasmJs.kt diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 5aecdde..08767c5 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,5 +1,5 @@ [versions] -kotlinx-datetime = "0.4.0" +kotlinx-datetime = "0.4.1" slf4j = "1.7.36" [libraries] diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 27313fb..fce403e 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-all.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/settings.gradle.kts b/settings.gradle.kts index df45e01..cd69c32 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -4,7 +4,7 @@ buildscript { maven(url = "https://raw.githubusercontent.com/kosi-libs/kodein-internal-gradle-plugin/mvn-repo") } dependencies { - classpath("org.kodein.internal.gradle:kodein-internal-gradle-settings:8.2.2") + classpath("org.kodein.internal.gradle:kodein-internal-gradle-settings:8.3.0") } }