Upgrade Gradle and add iOS targets (#27)
Some checks failed
Publish Snapshot / test (push) Has been cancelled
Publish Snapshot / Publish Snapshot (push) Has been cancelled

- Upgraded Gradle wrapper to version 8.5.
- Updated Gradle build scripts and configurations.
- Added iOS targets (iosX64, iosArm64, iosSimulatorArm64) to the Kotlin Multiplatform setup.
- Configured shared iOS source sets.
- Bumped project version to 3.1.0.
- Updated JDK version to 21 in project settings.
- Removed kotlinScripting.xml.
- Added runConfigurations.xml and AndroidProjectSystem.xml.

(cherry picked from commit 06dc507590)
This commit is contained in:
2025-09-05 11:17:54 +02:00
committed by GitHub
parent c3a4ca5925
commit 456f889b9c
10 changed files with 87 additions and 33 deletions

View File

@@ -9,7 +9,7 @@ plugins {
val PUBLISH_GROUP_ID = "com.github.adriankuta"
val PUBLISH_ARTIFACT_ID = "tree-structure"
val PUBLISH_VERSION = "3.0.2"
val PUBLISH_VERSION = "3.1.0"
val secretFile = File(rootProject.rootDir, "local.properties")
if (secretFile.exists()) {
@@ -118,6 +118,12 @@ kotlin {
}
}
}
// Add iOS targets
iosX64()
iosArm64()
iosSimulatorArm64()
val hostOs = System.getProperty("os.name")
val isMingwX64 = hostOs.startsWith("Windows")
val nativeTarget = when {
@@ -127,7 +133,6 @@ kotlin {
else -> throw GradleException("Host OS is not supported in Kotlin/Native.")
}
sourceSets {
val commonMain by getting
val commonTest by getting {
@@ -145,5 +150,19 @@ kotlin {
val jsTest by getting
val nativeMain by getting
val nativeTest by getting
// Shared iOS source sets
val iosMain by creating {
dependsOn(commonMain)
}
val iosTest by creating {
dependsOn(commonTest)
}
val iosX64Main by getting { dependsOn(iosMain) }
val iosArm64Main by getting { dependsOn(iosMain) }
val iosSimulatorArm64Main by getting { dependsOn(iosMain) }
val iosX64Test by getting { dependsOn(iosTest) }
val iosArm64Test by getting { dependsOn(iosTest) }
val iosSimulatorArm64Test by getting { dependsOn(iosTest) }
}
}