Closed ktoso closed 1 week ago
Before weekend snapshot:
public func swiftjava_getType_JExtractPluginSampleLib_MyCoolSwiftClass() -> Any /* Any.Type */
generated thunksBasically this means you "just" write some swift sources, add the extract plugin to the given target. Add a small task in gradle to trigger swiftpm and this way gradle/java immediately see the wrappers. Upon changing swift -> gradle triggers swift build again and it's all very seamless 🥳
🚧 early work in progress 🚧
This is first steps to make an jextract-swift plugin.
If we're able to pull this off as a swiftpm plugin we would basically have a way to "make me a jar that exposes this swift module, that would be super simple to consume from Java.
Need to figure out how to actually make this work -- it can't be a build plugin, but preBuild also isn't quite enough.
We may have to make it a command plugin, since we need compilation OUTPUT of the module to then act on the swift interfaces.