Open kirillzh opened 2 years ago
Build workflows for production-level libraries tend to be very custom, ours included (at least at this time). A look at some of the Python and Kotlin ones from the Glean and application-services repositories tell the same story (although in even more complex form 🤣). Our plugins have also evolved quite a bit over the past year and I expect will continue to do so as uniffi-rs evolves.
At this point I'm not sure of the exact shape the plugin would need to take to be general enough to work for others, and I'm not sure I have the bandwidth to build a more generic version myself. But I am building general documentation on Rust bindings using uniffi which will tackle some of those build and publish workflows at a high level, as well as outline the particular choices we made between shell scripts, Gradle plugins, and others for our libraries (Kotlin/JVM, Kotlin/Android, Swift, Python).
Feel free to close this issue for now (@kirillzh, @mhammond), but if anyone finds their way here looking for examples of Gradle plugins to help build uniffi libraries, you can find ours here for JVM and here for Android.
Thanks!
UniFfi docs mention:
Folks at Bitcoin Dev Kit (BDK) team (@thunderbiscuit) implemented a couple of plugin scripts for generating Kotlin JVM and Android bindings, and are open on turning it into a reusable plugin and potentially host it in this repository.
We are thinking of a nice Gradle DSL interface for generating bindings, perhaps:
We are wondering:
┆Issue is synchronized with this Jira Task ┆friendlyId: UNIFFI-185