Hello, i’m wondering if someone might be able to assist with a KMM issue im experiencing since upgrading Kotlin from
1.5.21
->
1.5.30
… The issue im experiencing is specifically with
packForXcode
where Gradle is returning an error messae all of a sudden
Copy code
* What went wrong:
Could not create task ':mobile-shared:packForXcode'.
> Key releaseFramework is missing in the map.
I have had a look around online first for solutions, but really can’t see any resolutions or hints to point me in the right direction. Anyone have any ideas? I’ll post my
packForXcode
task as a thread comment.
nevardreik
01/25/2022, 4:43 AM
Copy code
val packForXcode by tasks.creating {
dependsOn(deleteXcFramework)
group = "build"
val mode = "Release"
val frameworks = arrayOf("iosArm64", "iosX64")
.map { kotlin.targets.getByName<KotlinNativeTarget>(it).binaries.getFramework(mode) }
inputs.property("mode", mode)
dependsOn(frameworks.map { it.linkTask })
doLast {
buildXcFramework(frameworks)
}
}
a
Artyom Degtyarev [JB]
01/25/2022, 6:32 AM
I’ve seen similar error here and here. Could you please check if your XCFramework’s name is set to be the same as the baseName of your single-target frameworks’.