icerockdev / moko-kswift

Swift-friendly api generator for Kotlin/Native frameworks
https://moko.icerock.dev
Apache License 2.0
351 stars 22 forks source link

Code generation not working on new kotlinArtifacts DSL Module #72

Open DevSrSouza opened 1 year ago

DevSrSouza commented 1 year ago

Our project does not use cocoapods, we consume KMM modules with XCFramework, the module that put all kotlin modules together for publishing does not have any dependency beside the implementation of kotlinArtifacts DSL.

plugins {
   kotlin("multiplatform")
    id("dev.icerock.moko.kswift") version "0.6.1"
}

kotlin {
    ios()
}

// New format https://kotlinlang.org/docs/multiplatform-native-artifacts.html#xcframeworks
kotlinArtifacts {
    Native.XCFramework("kmm") {
        targets(iosSimulatorArm64, iosArm64, iosX64)
        setModules(
            projects.X,
            projects.Y,
            projects.Z,
        )
    }
}

kswift {
    install(dev.icerock.moko.kswift.plugin.feature.SealedToSwiftEnumFeature)
}

When running :kmm:assembleKmmXCFramework no Swift files are generated from the sealed class from modules X Y Z