Hello! I believe this question belongs to this channel, but forgive me if it doesn’t. I have the fol...
g
Hello! I believe this question belongs to this channel, but forgive me if it doesn’t. I have the following KMP
build.gradle.kts
configuration:
Copy code
val iosMain by creating {
    dependsOn(commonMain)
    dependencies {
        // ...
    }
}

listOf(iosX64, iosArm64, iosSimulatorArm64).forEach { target ->
    getByName("${target.targetName}Main") {
        dependsOn(iosMain)
    }

    val kspConfigName = "ksp${target.name.replaceFirstChar { it.uppercaseChar() }}"
    dependencies.add(kspConfigName, "my-ksp-lib")
}
My shared module imports a KSP library to generate code inside iOS targets. It works as expected (image in attach). However, I’m facing a strange behavior; my generated code cannot see/access what’s in
iosMain
(that generated code imports some classes from
iosMain
that I need). What am I doing wrong or missing? Thanks for your time.
turns out I can use it on iosApp. I can even debug the code and the classes effectively can see each other. Could it be an IDE problem? 🤔