Was freeCompilerArg `-include binary <PATH>`...
# kotlin-native
b
Was freeCompilerArg
-include binary <PATH>
removed with 1.3.70?
d
No, but something else change with how the args are handled.
The args are now escaped properly.
b
This snippet no longer works in 1.3.70. Any suggestions?
Copy code
kotlin {
    sourceSets {
        val wasm32Main by getting {
            wasm32().compilations["main"].apply {
              kotlinOptions.freeCompilerArgs = resources.files.map {
                "-include-binary '${it.invariantSeparatorsPath}'"
              }
            }
        }
    }
}
d
So you'll have to do
listOf("-include-binary", "<PATH>")
instead of
listOf("-include-binary <PATH>")
I guess you could do,
Copy code
kotlin {
    sourceSets {
        val wasm32Main by getting {
            wasm32().compilations["main"].apply {
              kotlinOptions.freeCompilerArgs = resources.files.flatMap {
                listOf("-include-binary", " '${it.invariantSeparatorsPath}'")
              }
            }
        }
    }
}
👍 1