mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-31 06:13:53 -06:00
rust: add PL011 device model
This commit adds a re-implementation of hw/char/pl011.c in Rust. How to build: 1. Configure a QEMU build with: --enable-system --target-list=aarch64-softmmu --enable-rust 2. Launching a VM with qemu-system-aarch64 should use the Rust version of the pl011 device Co-authored-by: Junjie Mao <junjie.mao@intel.com> Co-authored-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Junjie Mao <junjie.mao@intel.com> Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Link: https://lore.kernel.org/r/20241024-rust-round-2-v1-2-051e7a25b978@linaro.org
This commit is contained in:
parent
ca5aa28e24
commit
37fdb2f56a
37 changed files with 1906 additions and 12 deletions
40
subprojects/packagefiles/proc-macro-error-1-rs/meson.build
Normal file
40
subprojects/packagefiles/proc-macro-error-1-rs/meson.build
Normal file
|
@ -0,0 +1,40 @@
|
|||
project('proc-macro-error-1-rs', 'rust',
|
||||
version: '1.0.4',
|
||||
license: 'MIT OR Apache-2.0',
|
||||
default_options: [])
|
||||
|
||||
subproject('proc-macro-error-attr-1-rs', required: true)
|
||||
subproject('quote-1-rs', required: true)
|
||||
subproject('syn-2-rs', required: true)
|
||||
subproject('proc-macro2-1-rs', required: true)
|
||||
|
||||
proc_macro_error_attr_dep = dependency('proc-macro-error-attr-1-rs', native: true)
|
||||
proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
|
||||
quote_dep = dependency('quote-1-rs', native: true)
|
||||
syn_dep = dependency('syn-2-rs', native: true)
|
||||
|
||||
_proc_macro_error_rs = static_library(
|
||||
'proc_macro_error',
|
||||
files('src/lib.rs'),
|
||||
override_options: ['rust_std=2018', 'build.rust_std=2018'],
|
||||
rust_abi: 'rust',
|
||||
rust_args: [
|
||||
'--cfg', 'use_fallback',
|
||||
'--cfg', 'feature="syn-error"',
|
||||
'--cfg', 'feature="proc-macro"',
|
||||
'-A', 'non_fmt_panics'
|
||||
],
|
||||
dependencies: [
|
||||
proc_macro_error_attr_dep,
|
||||
proc_macro2_dep,
|
||||
quote_dep,
|
||||
syn_dep,
|
||||
],
|
||||
native: true,
|
||||
)
|
||||
|
||||
proc_macro_error_dep = declare_dependency(
|
||||
link_with: _proc_macro_error_rs,
|
||||
)
|
||||
|
||||
meson.override_dependency('proc-macro-error-1-rs', proc_macro_error_dep, native: true)
|
Loading…
Add table
Add a link
Reference in a new issue