Don't generate FFI for glib, rely on glib-sys crate.  This makes it
possible to limit Rust to the same minimum version as C code.

The disadvantage is that each bindings module needs to import from
glib explicitly.

The extra lines in Cargo.lock are all build dependencies that are not
used by Meson.  They are only used for glib-sys's build.rs rules,
when running e.g. "cargo check".

Marc-André Lureau (1):
  rust: use glib-sys
  subprojects: add glib-sys-rs

 meson.build                                   |   1 +
 include/hw/core/cpu.h                         |   2 +-
 rust/Cargo.lock                               | 182 ++++++++++++++++++
 rust/Cargo.toml                               |   1 +
 rust/bql/Cargo.toml                           |   3 +
 rust/bql/meson.build                          |   1 +
 rust/bql/src/bindings.rs                      |   4 +
 rust/chardev/Cargo.toml                       |   1 +
 rust/chardev/meson.build                      |   2 +-
 rust/chardev/src/bindings.rs                  |   4 +
 rust/hw/char/pl011/Cargo.toml                 |   1 +
 rust/hw/char/pl011/meson.build                |   1 +
 rust/hw/char/pl011/src/bindings.rs            |   5 +
 rust/hw/core/Cargo.toml                       |   1 +
 rust/hw/core/meson.build                      |   2 +-
 rust/hw/core/src/bindings.rs                  |   3 +
 rust/meson.build                              |   2 +
 rust/migration/Cargo.toml                     |   1 +
 rust/migration/meson.build                    |   2 +-
 rust/migration/src/bindings.rs                |   1 +
 rust/qom/Cargo.toml                           |   1 +
 rust/qom/meson.build                          |   2 +-
 rust/qom/src/bindings.rs                      |   2 +
 rust/system/Cargo.toml                        |   1 +
 rust/system/meson.build                       |   2 +-
 rust/system/src/bindings.rs                   |   4 +
 rust/util/Cargo.toml                          |   1 +
 rust/util/meson.build                         |   2 +-
 rust/util/src/bindings.rs                     |   2 +
 scripts/archive-source.sh                     |   1 +
 subprojects/.gitignore                        |   1 +
 subprojects/glib-sys-0.21-rs.wrap             |   7 +
 .../packagefiles/glib-sys-0.21-rs/meson.build |  33 ++++
 33 files changed, 272 insertions(+), 7 deletions(-)
 create mode 100644 subprojects/glib-sys-0.21-rs.wrap
 create mode 100644 subprojects/packagefiles/glib-sys-0.21-rs/meson.build

-- 
2.51.0


Reply via email to