Open NyaomiDEV opened 1 year ago
There has been a little discussion around being able to use the header-translator
(the tool icrate
uses to generate the Rust definitions from the Apple frameworks) for other frameworks. For example, see item 2 at https://github.com/madsmtm/objc2/issues/429.
So far there hasn't been a lot of work toward making this practical though. In principle, I believe it should be possible now, but it would require some modification to the icrate
configuration and potentially to some parts of header-translator
.
The situation should improve in the next few months hopefully, once there has been more progress made toward the new dependency scanning backend.
At some point after https://github.com/madsmtm/objc2/issues/345 we'll probably figure out a good way for translating headers not provided via. Xcode, then you should be able to just run header-translator
(or whatever it'll end up being named) on your header and get a Rust library that targets that.
Oops, @silvanshade beat me to it, but agree with everything they said
I wonder if it is inside the scope of this project to be able to link against private frameworks (specifically MediaRemote) and to use them in a mostly-type-safe way.