Email or username:

Password:

Forgot your password?
Sebastian Dröge 🍵

Over the Easter holidays I experimented a bit with building Rust code with meson instead of cargo.

Specifically I tried building a GStreamer plugin with a few dozen Rust dependencies, but the same applies in a similar way to GTK/GNOME applications or literally anything else.

A write-up of the results with a lot of details can be found here: coaxion.net/blog/2023/04/build

5 comments
matze :unarist:

@slomo mesa's rusticl is doing this for quite some time now. There I also found the rust-project.json thing a bit … annyoing.

Sebastian Dröge 🍵

@matze It's not using any external Rust dependencies though as that complicates everything a lot. That was the main part that I was interested in here. How much effort that is, what problems there are, and if we can really fully automate that (yes).

Building standalone Rust code is easily possible with meson since 2015 or so 🙂​ See also that Python module I linked to, which is built from C, C++, Fortran and Rust code and was last touched in 2017.

Sebastian Dröge 🍵

@matze OOC, why was rust-project.json annoying for you?

matze :unarist:

@slomo AFAIR the referenced paths where relative to the build directory or something similar and RA did not find the file if it is not in the root. So there was some manual required that had to be repeated once I re-ran meson.

Sebastian Dröge 🍵

@matze Ah yes, I fixed that in meson a while ago so it puts absolute paths in there. Before that it was kind of useless for me too 😅​

github.com/mesonbuild/meson/pu

Go Up