rust: switch to autogenerated meson rules
Meson can automatically generate most of the build rules for subprojects, based on the contents of their Cargo.toml. Handwritten snippets can be placed in meson/meson.build to replace build.rs. Disable Meson's use of the nightly-only option "--env-set". It is buggy and anyway it should not be there in future version. Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Paolo Bonzini committed
May 25, 2026 at 17:35 UTC
530a9eb2c6aeae6c3b48820b47436389705a8cb1
40 files changed
+44
-563
meson.build
+2
-1
@@ -4,7 +4,8 @@ project('qemu', ['c'], meson_version: '>=1.5.0',
4
5
# build.rust_std breaks with older meson, but Rust does not
6
# support old meson anyway
7
- (meson.version().version_compare('>= 1.9') ? ['rust_std=2021', 'build.rust_std=2021'] : []),
7
+ (meson.version().version_compare('>= 1.9') ? ['rust_std=2021', 'build.rust_std=2021',
8
+ 'rust_nightly=disabled'] : []),
9
10
version: files('VERSION'))
11
scripts/get-wraps-from-cargo-registry.py
-6
@@ -116,12 +116,6 @@ class UpdateSubprojects:
116
patch_dir = config["wrap-file"]["patch_directory"]
117
patch_dir = os.path.join("packagefiles", patch_dir)
118
_, ver = registry_namever.rsplit("-", 1)
119
- subprocess.run(
120
- ["meson", "rewrite", "kwargs", "set", "project", "/", "version", ver],
121
- cwd=patch_dir,
122
- env=env,
123
- check=True,
124
- )
119
120
subprocess.run(
121
["meson", "subprojects", "download", wrap_name],
subprojects/anyhow-1-rs.wrap
+3
@@ -5,3 +5,6 @@ source_filename = anyhow-1.0.98.tar.gz
5
source_hash = e16d2d3311acee920a9eb8d33b8cbc1787ce4a264e85f964c2404b969bdcd487
6
method = cargo
7
patch_directory = anyhow-1-rs
8
+
9
+# bump this version number on every change to meson.build or the patches:
10
+# v1
subprojects/arbitrary-int-1-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/arbitrary-int/1.2.7/download
4
source_filename = arbitrary-int-1.2.7.tar.gz
5
source_hash = c84fc003e338a6f69fbd4f7fe9f92b535ff13e9af8997f3b14b6ddff8b1df46d
6
method = cargo
7
-patch_directory = arbitrary-int-1-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/attrs-0.2-rs.wrap
-1
@@ -4,4 +4,3 @@ source_url = https://crates.io/api/v1/crates/attrs/0.2.9/download
4
source_filename = attrs-0.2.9.tar.gz
5
source_hash = 2a207d40f43de65285f3de0509bb6cb16bc46098864fce957122bbacce327e5f
6
method = cargo
7
-patch_directory = attrs-0.2-rs
subprojects/bilge-0.2-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/bilge/0.2.0/download
4
source_filename = bilge-0.2.0.tar.gz
5
source_hash = dc707ed8ebf81de5cd6c7f48f54b4c8621760926cdf35a57000747c512e67b57
6
method = cargo
7
-patch_directory = bilge-0.2-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/bilge-impl-0.2-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/bilge-impl/0.2.0/download
4
source_filename = bilge-impl-0.2.0.tar.gz
5
source_hash = feb11e002038ad243af39c2068c8a72bcf147acf05025dcdb916fcc000adb2d8
6
method = cargo
7
-patch_directory = bilge-impl-0.2-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/either-1-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/either/1.12.0/download
4
source_filename = either-1.12.0.tar.gz
5
source_hash = 3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b
6
method = cargo
7
-patch_directory = either-1-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/foreign-0.3-rs.wrap
-1
@@ -4,4 +4,3 @@ source_url = https://crates.io/api/v1/crates/foreign/0.3.1/download
4
source_filename = foreign-0.3.1.tar.gz
5
source_hash = 17ca1b5be8c9d320daf386f1809c7acc0cb09accbae795c2001953fa50585846
6
method = cargo
7
-patch_directory = foreign-0.3-rs
subprojects/glib-sys-0.21-rs.wrap
-1
@@ -4,4 +4,3 @@ source_url = https://crates.io/api/v1/crates/glib-sys/0.21.2/download
4
source_filename = glib-sys-0.21.2.tar.gz
5
source_hash = d09d3d0fddf7239521674e57b0465dfbd844632fec54f059f7f56112e3f927e1
6
method = cargo
7
-patch_directory = glib-sys-0.21-rs
subprojects/itertools-0.11-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/itertools/0.11.0/download
4
source_filename = itertools-0.11.0.tar.gz
5
source_hash = b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57
6
method = cargo
7
-patch_directory = itertools-0.11-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/libc-0.2-rs.wrap
+3
@@ -5,3 +5,6 @@ source_filename = libc-0.2.162.tar.gz
5
source_hash = 18d287de67fe55fd7e1581fe933d965a5a9477b38e949cfa9f8574ef01506398
6
method = cargo
7
patch_directory = libc-0.2-rs
8
+
9
+# bump this version number on every change to meson.build or the patches:
10
+# v1
subprojects/packagefiles/anyhow-1-rs/meson.build
deleted
-33
@@ -1,33 +0,0 @@
1
-project('anyhow-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.0.98',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-rustc = meson.get_compiler('rust')
8
-
9
-rust_args = ['--cap-lints', 'allow']
10
-rust_args += ['--cfg', 'feature="std"']
11
-if rustc.version().version_compare('<1.65.0')
12
- error('rustc version ' + rustc.version() + ' is unsupported. Please upgrade to at least 1.65.0')
13
-endif
14
-rust_args += [ '--cfg', 'std_backtrace' ] # >= 1.65.0
15
-if rustc.version().version_compare('<1.81.0')
16
- rust_args += [ '--cfg', 'anyhow_no_core_error' ]
17
-endif
18
-
19
-_anyhow_rs = static_library(
20
- 'anyhow',
21
- files('src/lib.rs'),
22
- gnu_symbol_visibility: 'hidden',
23
- override_options: ['rust_std=2018', 'build.rust_std=2018'],
24
- rust_abi: 'rust',
25
- rust_args: rust_args,
26
- dependencies: [],
27
-)
28
-
29
-anyhow_dep = declare_dependency(
30
- link_with: _anyhow_rs,
31
-)
32
-
33
-meson.override_dependency('anyhow-1-rs', anyhow_dep)
subprojects/packagefiles/anyhow-1-rs/meson/meson.build
new
+9
@@ -0,0 +1,9 @@
1
+rustc = meson.get_compiler('rust')
2
+
3
+if rustc.version().version_compare('<1.65.0')
4
+ error('rustc version ' + rustc.version() + ' is unsupported. Please upgrade to at least 1.65.0')
5
+endif
6
+extra_args += [ '--cfg', 'std_backtrace' ] # >= 1.65.0
7
+if rustc.version().version_compare('<1.81.0')
8
+ extra_args += [ '--cfg', 'anyhow_no_core_error' ]
9
+endif
subprojects/packagefiles/arbitrary-int-1-rs/meson.build
deleted
-21
@@ -1,21 +0,0 @@
1
-project('arbitrary-int-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.2.7',
4
- license: 'MIT',
5
- default_options: [])
6
-
7
-_arbitrary_int_rs = static_library(
8
- 'arbitrary_int',
9
- files('src/lib.rs'),
10
- gnu_symbol_visibility: 'hidden',
11
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
12
- rust_args: ['--cap-lints', 'allow'],
13
- rust_abi: 'rust',
14
- dependencies: [],
15
-)
16
-
17
-arbitrary_int_dep = declare_dependency(
18
- link_with: _arbitrary_int_rs,
19
-)
20
-
21
-meson.override_dependency('arbitrary-int-1-rs', arbitrary_int_dep)
subprojects/packagefiles/attrs-0.2-rs/meson.build
deleted
-33
@@ -1,33 +0,0 @@
1
-project('attrs-0.2-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.2.9',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('proc-macro2-1-rs', required: true)
8
-subproject('syn-2-rs', required: true)
9
-
10
-proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
11
-syn_dep = dependency('syn-2-rs', native: true)
12
-
13
-_attrs_rs = static_library(
14
- 'attrs',
15
- files('src/lib.rs'),
16
- gnu_symbol_visibility: 'hidden',
17
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
18
- rust_abi: 'rust',
19
- rust_args: [
20
- '--cap-lints', 'allow',
21
- ],
22
- dependencies: [
23
- proc_macro2_dep,
24
- syn_dep,
25
- ],
26
- native: true,
27
-)
28
-
29
-attrs_dep = declare_dependency(
30
- link_with: _attrs_rs,
31
-)
32
-
33
-meson.override_dependency('attrs-0.2-rs', attrs_dep, native: true)
subprojects/packagefiles/bilge-0.2-rs/meson.build
deleted
-31
@@ -1,31 +0,0 @@
1
-project(
2
- 'bilge-0.2-rs',
3
- 'rust',
4
- meson_version: '>=1.5.0',
5
- version : '0.2.0',
6
- license : 'MIT or Apache-2.0',
7
-)
8
-
9
-subproject('arbitrary-int-1-rs', required: true)
10
-subproject('bilge-impl-0.2-rs', required: true)
11
-
12
-arbitrary_int_dep = dependency('arbitrary-int-1-rs')
13
-bilge_impl_dep = dependency('bilge-impl-0.2-rs')
14
-
15
-lib = static_library(
16
- 'bilge',
17
- 'src/lib.rs',
18
- override_options : ['rust_std=2021', 'build.rust_std=2021'],
19
- rust_abi : 'rust',
20
- rust_args: ['--cap-lints', 'allow'],
21
- dependencies: [
22
- arbitrary_int_dep,
23
- bilge_impl_dep,
24
- ],
25
-)
26
-
27
-bilge_dep = declare_dependency(
28
- link_with : [lib],
29
-)
30
-
31
-meson.override_dependency('bilge-0.2-rs', bilge_dep)
subprojects/packagefiles/bilge-impl-0.2-rs/meson.build
deleted
-44
@@ -1,44 +0,0 @@
1
-project('bilge-impl-0.2-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.2.0',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('itertools-0.11-rs', required: true)
8
-subproject('proc-macro-error-attr-1-rs', required: true)
9
-subproject('proc-macro-error-1-rs', required: true)
10
-subproject('quote-1-rs', required: true)
11
-subproject('syn-2-rs', required: true)
12
-subproject('proc-macro2-1-rs', required: true)
13
-
14
-itertools_dep = dependency('itertools-0.11-rs', native: true)
15
-proc_macro_error_attr_dep = dependency('proc-macro-error-attr-1-rs', native: true)
16
-proc_macro_error_dep = dependency('proc-macro-error-1-rs', native: true)
17
-quote_dep = dependency('quote-1-rs', native: true)
18
-syn_dep = dependency('syn-2-rs', native: true)
19
-proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
20
-
21
-rust = import('rust')
22
-
23
-_bilge_impl_rs = rust.proc_macro(
24
- 'bilge_impl',
25
- files('src/lib.rs'),
26
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
27
- rust_args: [
28
- '--cap-lints', 'allow',
29
- ],
30
- dependencies: [
31
- itertools_dep,
32
- proc_macro_error_attr_dep,
33
- proc_macro_error_dep,
34
- quote_dep,
35
- syn_dep,
36
- proc_macro2_dep,
37
- ],
38
-)
39
-
40
-bilge_impl_dep = declare_dependency(
41
- link_with: _bilge_impl_rs,
42
-)
43
-
44
-meson.override_dependency('bilge-impl-0.2-rs', bilge_impl_dep)
subprojects/packagefiles/either-1-rs/meson.build
deleted
-26
@@ -1,26 +0,0 @@
1
-project('either-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.12.0',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-_either_rs = static_library(
8
- 'either',
9
- files('src/lib.rs'),
10
- gnu_symbol_visibility: 'hidden',
11
- override_options: ['rust_std=2018', 'build.rust_std=2018'],
12
- rust_abi: 'rust',
13
- rust_args: [
14
- '--cap-lints', 'allow',
15
- '--cfg', 'feature="use_std"',
16
- '--cfg', 'feature="use_alloc"',
17
- ],
18
- dependencies: [],
19
- native: true,
20
-)
21
-
22
-either_dep = declare_dependency(
23
- link_with: _either_rs,
24
-)
25
-
26
-meson.override_dependency('either-1-rs', either_dep, native: true)
subprojects/packagefiles/foreign-0.3-rs/meson.build
deleted
-26
@@ -1,26 +0,0 @@
1
-project('foreign-0.3-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.2.0',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('libc-0.2-rs', required: true)
8
-libc_rs = dependency('libc-0.2-rs')
9
-
10
-_foreign_rs = static_library(
11
- 'foreign',
12
- files('src/lib.rs'),
13
- gnu_symbol_visibility: 'hidden',
14
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
15
- rust_abi: 'rust',
16
- rust_args: [
17
- '--cap-lints', 'allow',
18
- ],
19
- dependencies: [libc_rs],
20
-)
21
-
22
-foreign_dep = declare_dependency(
23
- link_with: _foreign_rs,
24
-)
25
-
26
-meson.override_dependency('foreign-0.3-rs', foreign_dep)
subprojects/packagefiles/glib-sys-0.21-rs/meson.build
deleted
-33
@@ -1,33 +0,0 @@
1
-project('glib-sys-0.21-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.21.2',
4
- license: 'MIT',
5
- default_options: [])
6
-
7
-subproject('libc-0.2-rs', required: true)
8
-libc_rs = dependency('libc-0.2-rs')
9
-
10
-_glib_sys_rs = static_library(
11
- 'glib_sys',
12
- files('src/lib.rs'),
13
- gnu_symbol_visibility: 'hidden',
14
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
15
- rust_abi: 'rust',
16
- rust_args: [
17
- '--cap-lints', 'allow',
18
- '--cfg', 'feature="v2_66"',
19
- '--cfg', 'feature="v2_64"',
20
- '--cfg', 'feature="v2_62"',
21
- '--cfg', 'feature="v2_60"',
22
- '--cfg', 'feature="v2_58"',
23
- ],
24
- # should also link with glib; don't bother doing it here since all
25
- # QEMU targets have it
26
- dependencies: [libc_rs],
27
-)
28
-
29
-glib_sys_dep = declare_dependency(
30
- link_with: _glib_sys_rs,
31
-)
32
-
33
-meson.override_dependency('glib-sys-0.21-rs', glib_sys_dep)
subprojects/packagefiles/itertools-0.11-rs/meson.build
deleted
-32
@@ -1,32 +0,0 @@
1
-project('itertools-0.11-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.11.0',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('either-1-rs', required: true)
8
-
9
-either_dep = dependency('either-1-rs', native: true)
10
-
11
-_itertools_rs = static_library(
12
- 'itertools',
13
- files('src/lib.rs'),
14
- gnu_symbol_visibility: 'hidden',
15
- override_options: ['rust_std=2018', 'build.rust_std=2018'],
16
- rust_abi: 'rust',
17
- rust_args: [
18
- '--cap-lints', 'allow',
19
- '--cfg', 'feature="use_std"',
20
- '--cfg', 'feature="use_alloc"',
21
- ],
22
- dependencies: [
23
- either_dep,
24
- ],
25
- native: true,
26
-)
27
-
28
-itertools_dep = declare_dependency(
29
- link_with: _itertools_rs,
30
-)
31
-
32
-meson.override_dependency('itertools-0.11-rs', itertools_dep, native: true)
subprojects/packagefiles/libc-0.2-rs/meson.build
deleted
-37
@@ -1,37 +0,0 @@
1
-project('libc-0.2-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.2.162',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-_libc_rs = static_library(
8
- 'libc',
9
- files('src/lib.rs'),
10
- gnu_symbol_visibility: 'hidden',
11
- override_options: ['rust_std=2015', 'build.rust_std=2015'],
12
- rust_abi: 'rust',
13
- rust_args: [
14
- '--cap-lints', 'allow',
15
- '--cfg', 'freebsd11',
16
- '--cfg', 'libc_priv_mod_use',
17
- '--cfg', 'libc_union',
18
- '--cfg', 'libc_const_size_of',
19
- '--cfg', 'libc_align',
20
- '--cfg', 'libc_int128',
21
- '--cfg', 'libc_core_cvoid',
22
- '--cfg', 'libc_packedN',
23
- '--cfg', 'libc_cfg_target_vendor',
24
- '--cfg', 'libc_non_exhaustive',
25
- '--cfg', 'libc_long_array',
26
- '--cfg', 'libc_ptr_addr_of',
27
- '--cfg', 'libc_underscore_const_names',
28
- '--cfg', 'libc_const_extern_fn',
29
- ],
30
- dependencies: [],
31
-)
32
-
33
-libc_dep = declare_dependency(
34
- link_with: _libc_rs,
35
-)
36
-
37
-meson.override_dependency('libc-0.2-rs', libc_dep)
subprojects/packagefiles/libc-0.2-rs/meson/meson.build
new
+16
@@ -0,0 +1,16 @@
1
+extra_args += [
2
+ '--cfg', 'freebsd11',
3
+ '--cfg', 'libc_priv_mod_use',
4
+ '--cfg', 'libc_union',
5
+ '--cfg', 'libc_const_size_of',
6
+ '--cfg', 'libc_align',
7
+ '--cfg', 'libc_int128',
8
+ '--cfg', 'libc_core_cvoid',
9
+ '--cfg', 'libc_packedN',
10
+ '--cfg', 'libc_cfg_target_vendor',
11
+ '--cfg', 'libc_non_exhaustive',
12
+ '--cfg', 'libc_long_array',
13
+ '--cfg', 'libc_ptr_addr_of',
14
+ '--cfg', 'libc_underscore_const_names',
15
+ '--cfg', 'libc_const_extern_fn',
16
+]
subprojects/packagefiles/probe-0.5-rs/meson.build
deleted
-22
@@ -1,22 +0,0 @@
1
-project('probe-0.5-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '0.5.2',
4
- license: 'Apache-2.0 OR MIT',
5
- default_options: [])
6
-
7
-_probe_rs = static_library(
8
- 'probe',
9
- files('src/lib.rs'),
10
- gnu_symbol_visibility: 'hidden',
11
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
12
- rust_abi: 'rust',
13
- rust_args: [
14
- '--cap-lints', 'allow',
15
- ],
16
-)
17
-
18
-probe_deps = declare_dependency(
19
- link_with: _probe_rs,
20
-)
21
-
22
-meson.override_dependency('probe-0.5-rs', probe_deps)
subprojects/packagefiles/proc-macro-error-1-rs/meson.build
deleted
-41
@@ -1,41 +0,0 @@
1
-project('proc-macro-error-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.0.4',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('proc-macro-error-attr-1-rs', required: true)
8
-subproject('quote-1-rs', required: true)
9
-subproject('syn-2-rs', required: true)
10
-subproject('proc-macro2-1-rs', required: true)
11
-
12
-proc_macro_error_attr_dep = dependency('proc-macro-error-attr-1-rs', native: true)
13
-proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
14
-quote_dep = dependency('quote-1-rs', native: true)
15
-syn_dep = dependency('syn-2-rs', native: true)
16
-
17
-_proc_macro_error_rs = static_library(
18
- 'proc_macro_error',
19
- files('src/lib.rs'),
20
- override_options: ['rust_std=2018', 'build.rust_std=2018'],
21
- rust_abi: 'rust',
22
- rust_args: [
23
- '--cap-lints', 'allow',
24
- '--cfg', 'use_fallback',
25
- '--cfg', 'feature="syn-error"',
26
- '-A', 'non_fmt_panics'
27
- ],
28
- dependencies: [
29
- proc_macro_error_attr_dep,
30
- proc_macro2_dep,
31
- quote_dep,
32
- syn_dep,
33
- ],
34
- native: true,
35
-)
36
-
37
-proc_macro_error_dep = declare_dependency(
38
- link_with: _proc_macro_error_rs,
39
-)
40
-
41
-meson.override_dependency('proc-macro-error-1-rs', proc_macro_error_dep, native: true)
subprojects/packagefiles/proc-macro-error-1-rs/meson/meson.build
new
+3
@@ -0,0 +1,3 @@
1
+extra_args = [
2
+ '--cfg', 'use_fallback',
3
+]
subprojects/packagefiles/proc-macro-error-attr-1-rs/meson.build
deleted
-31
@@ -1,31 +0,0 @@
1
-project('proc-macro-error-attr-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.12.0',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('proc-macro2-1-rs', required: true)
8
-subproject('quote-1-rs', required: true)
9
-
10
-proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
11
-quote_dep = dependency('quote-1-rs', native: true)
12
-
13
-rust = import('rust')
14
-_proc_macro_error_attr_rs = rust.proc_macro(
15
- 'proc_macro_error_attr',
16
- files('src/lib.rs'),
17
- override_options: ['rust_std=2018', 'build.rust_std=2018'],
18
- rust_args: [
19
- '--cap-lints', 'allow',
20
- ],
21
- dependencies: [
22
- proc_macro2_dep,
23
- quote_dep,
24
- ],
25
-)
26
-
27
-proc_macro_error_attr_dep = declare_dependency(
28
- link_with: _proc_macro_error_attr_rs,
29
-)
30
-
31
-meson.override_dependency('proc-macro-error-attr-1-rs', proc_macro_error_attr_dep, native: true)
subprojects/packagefiles/proc-macro2-1-rs/meson.build
deleted
-35
@@ -1,35 +0,0 @@
1
-project('proc-macro2-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.0.95',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('unicode-ident-1-rs', required: true)
8
-
9
-unicode_ident_dep = dependency('unicode-ident-1-rs', native: true)
10
-
11
-_proc_macro2_rs = static_library(
12
- 'proc_macro2',
13
- files('src/lib.rs'),
14
- gnu_symbol_visibility: 'hidden',
15
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
16
- rust_abi: 'rust',
17
- rust_args: [
18
- '--cap-lints', 'allow',
19
- '--cfg', 'feature="proc-macro"',
20
- '--cfg', 'no_literal_byte_character',
21
- '--cfg', 'no_literal_c_string',
22
- '--cfg', 'no_source_text',
23
- '--cfg', 'wrap_proc_macro',
24
- ],
25
- dependencies: [
26
- unicode_ident_dep,
27
- ],
28
- native: true,
29
-)
30
-
31
-proc_macro2_dep = declare_dependency(
32
- link_with: _proc_macro2_rs,
33
-)
34
-
35
-meson.override_dependency('proc-macro2-1-rs', proc_macro2_dep, native: true)
subprojects/packagefiles/proc-macro2-1-rs/meson/meson.build
new
+6
@@ -0,0 +1,6 @@
1
+extra_args = [
2
+ '--cfg', 'no_literal_byte_character',
3
+ '--cfg', 'no_literal_c_string',
4
+ '--cfg', 'no_source_text',
5
+ '--cfg', 'wrap_proc_macro',
6
+]
subprojects/packagefiles/quote-1-rs/meson.build
deleted
-31
@@ -1,31 +0,0 @@
1
-project('quote-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.12.0',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('proc-macro2-1-rs', required: true)
8
-
9
-proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
10
-
11
-_quote_rs = static_library(
12
- 'quote',
13
- files('src/lib.rs'),
14
- gnu_symbol_visibility: 'hidden',
15
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
16
- rust_abi: 'rust',
17
- rust_args: [
18
- '--cap-lints', 'allow',
19
- '--cfg', 'feature="proc-macro"',
20
- ],
21
- dependencies: [
22
- proc_macro2_dep,
23
- ],
24
- native: true,
25
-)
26
-
27
-quote_dep = declare_dependency(
28
- link_with: _quote_rs,
29
-)
30
-
31
-meson.override_dependency('quote-1-rs', quote_dep, native: true)
subprojects/packagefiles/syn-2-rs/meson.build
deleted
-43
@@ -1,43 +0,0 @@
1
-project('syn-2-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '2.0.104',
4
- license: 'MIT OR Apache-2.0',
5
- default_options: [])
6
-
7
-subproject('proc-macro2-1-rs', required: true)
8
-subproject('quote-1-rs', required: true)
9
-subproject('unicode-ident-1-rs', required: true)
10
-
11
-proc_macro2_dep = dependency('proc-macro2-1-rs', native: true)
12
-quote_dep = dependency('quote-1-rs', native: true)
13
-unicode_ident_dep = dependency('unicode-ident-1-rs', native: true)
14
-
15
-_syn_rs = static_library(
16
- 'syn',
17
- files('src/lib.rs'),
18
- gnu_symbol_visibility: 'hidden',
19
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
20
- rust_abi: 'rust',
21
- rust_args: [
22
- '--cap-lints', 'allow',
23
- '--cfg', 'feature="full"',
24
- '--cfg', 'feature="derive"',
25
- '--cfg', 'feature="parsing"',
26
- '--cfg', 'feature="printing"',
27
- '--cfg', 'feature="clone-impls"',
28
- '--cfg', 'feature="proc-macro"',
29
- '--cfg', 'feature="extra-traits"',
30
- ],
31
- dependencies: [
32
- quote_dep,
33
- proc_macro2_dep,
34
- unicode_ident_dep,
35
- ],
36
- native: true,
37
-)
38
-
39
-syn_dep = declare_dependency(
40
- link_with: _syn_rs,
41
-)
42
-
43
-meson.override_dependency('syn-2-rs', syn_dep, native: true)
subprojects/packagefiles/unicode-ident-1-rs/meson.build
deleted
-22
@@ -1,22 +0,0 @@
1
-project('unicode-ident-1-rs', 'rust',
2
- meson_version: '>=1.5.0',
3
- version: '1.0.12',
4
- license: '(MIT OR Apache-2.0) AND Unicode-DFS-2016',
5
- default_options: [])
6
-
7
-_unicode_ident_rs = static_library(
8
- 'unicode_ident',
9
- files('src/lib.rs'),
10
- gnu_symbol_visibility: 'hidden',
11
- override_options: ['rust_std=2021', 'build.rust_std=2021'],
12
- rust_abi: 'rust',
13
- rust_args: ['--cap-lints', 'allow'],
14
- dependencies: [],
15
- native: true,
16
-)
17
-
18
-unicode_ident_dep = declare_dependency(
19
- link_with: _unicode_ident_rs,
20
-)
21
-
22
-meson.override_dependency('unicode-ident-1-rs', unicode_ident_dep, native: true)
subprojects/probe-0.5-rs.wrap
-1
@@ -4,4 +4,3 @@ source_url = https://crates.io/api/v1/crates/probe/0.5.2/download
4
source_filename = probe-0.5.2.tar.gz
5
source_hash = 136558b6e1ebaecc92755d0ffaf9421f519531bed30cc2ad23b22cb00965cc5e
6
method = cargo
7
-patch_directory = probe-0.5-rs
subprojects/proc-macro-error-1-rs.wrap
+1
-1
@@ -7,4 +7,4 @@ method = cargo
7
patch_directory = proc-macro-error-1-rs
8
9
# bump this version number on every change to meson.build or the patches:
10
-# v2
10
+# v3
subprojects/proc-macro-error-attr-1-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/proc-macro-error-attr/1.0.4/downloa
4
source_filename = proc-macro-error-attr-1.0.4.tar.gz
5
source_hash = a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869
6
method = cargo
7
-patch_directory = proc-macro-error-attr-1-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/proc-macro2-1-rs.wrap
+1
-1
@@ -7,4 +7,4 @@ method = cargo
7
patch_directory = proc-macro2-1-rs
8
9
# bump this version number on every change to meson.build or the patches:
10
-# v2
10
+# v3
subprojects/quote-1-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/quote/1.0.36/download
4
source_filename = quote-1.0.36.0.tar.gz
5
source_hash = 0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7
6
method = cargo
7
-patch_directory = quote-1-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/syn-2-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/syn/2.0.104/download
4
source_filename = syn-2.0.104.0.tar.gz
5
source_hash = 17b6f705963418cdb9927482fa304bc562ece2fdd4f616084c50b7023b435a40
6
method = cargo
7
-patch_directory = syn-2-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2
subprojects/unicode-ident-1-rs.wrap
-1
@@ -4,7 +4,6 @@ source_url = https://crates.io/api/v1/crates/unicode-ident/1.0.12/download
4
source_filename = unicode-ident-1.0.12.tar.gz
5
source_hash = 3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b
6
method = cargo
7
-patch_directory = unicode-ident-1-rs
7
8
# bump this version number on every change to meson.build or the patches:
9
# v2