From: Junjie Mao <junjie.mao@intel.com>
To: manos.pitsidianakis@linaro.org, pbonzini@redhat.com
Cc: alex.bennee@linaro.org, armbru@redhat.com, berrange@redhat.com,
gustavo.romero@linaro.org, mads@ynddal.dk,
marcandre.lureau@redhat.com, peter.maydell@linaro.org,
philmd@linaro.org, pierrick.bouvier@linaro.org,
qemu-devel@nongnu.org, richard.henderson@linaro.org,
rowan.hart@intel.com, stefanha@redhat.com, thuth@redhat.com,
zhao1.liu@intel.com
Subject: [RFC PATCH 1/2] meson: subprojects: Specify Rust edition by rust_std=20XX
Date: Wed, 14 Aug 2024 17:08:19 +0800 [thread overview]
Message-ID: <20240814090820.1251026-2-junjie.mao@intel.com> (raw)
In-Reply-To: <20240814090820.1251026-1-junjie.mao@intel.com>
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
---
subprojects/packagefiles/arbitrary-int-1-rs/meson.build | 4 +---
subprojects/packagefiles/bilge-impl-0.2-rs/meson.build | 2 +-
subprojects/packagefiles/either-1-rs/meson.build | 2 +-
subprojects/packagefiles/itertools-0.11-rs/meson.build | 2 +-
subprojects/packagefiles/proc-macro-error-1-rs/meson.build | 2 +-
.../packagefiles/proc-macro-error-attr-1-rs/meson.build | 2 +-
subprojects/packagefiles/proc-macro2-1-rs/meson.build | 2 +-
subprojects/packagefiles/quote-1-rs/meson.build | 2 +-
subprojects/packagefiles/syn-2-rs/meson.build | 2 +-
subprojects/packagefiles/unicode-ident-1-rs/meson.build | 4 +---
10 files changed, 10 insertions(+), 14 deletions(-)
diff --git a/subprojects/packagefiles/arbitrary-int-1-rs/meson.build b/subprojects/packagefiles/arbitrary-int-1-rs/meson.build
index 9cba82365f..34a189cbae 100644
--- a/subprojects/packagefiles/arbitrary-int-1-rs/meson.build
+++ b/subprojects/packagefiles/arbitrary-int-1-rs/meson.build
@@ -7,10 +7,8 @@ _arbitrary_int_rs = static_library(
'arbitrary_int',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2021', 'build.rust_std=2021'],
rust_abi: 'rust',
- rust_args: [
- '--edition', '2021',
- ],
dependencies: [],
)
diff --git a/subprojects/packagefiles/bilge-impl-0.2-rs/meson.build b/subprojects/packagefiles/bilge-impl-0.2-rs/meson.build
index e0c51c7375..80243c7024 100644
--- a/subprojects/packagefiles/bilge-impl-0.2-rs/meson.build
+++ b/subprojects/packagefiles/bilge-impl-0.2-rs/meson.build
@@ -22,8 +22,8 @@ rust = import('rust')
_bilge_impl_rs = rust.proc_macro(
'bilge_impl',
files('src/lib.rs'),
+ override_options: ['rust_std=2021', 'build.rust_std=2021'],
rust_args: [
- '--edition', '2021',
'--cfg', 'use_fallback',
'--cfg', 'feature="syn-error"',
'--cfg', 'feature="proc-macro"',
diff --git a/subprojects/packagefiles/either-1-rs/meson.build b/subprojects/packagefiles/either-1-rs/meson.build
index 07240b8708..a5842eb3a6 100644
--- a/subprojects/packagefiles/either-1-rs/meson.build
+++ b/subprojects/packagefiles/either-1-rs/meson.build
@@ -7,9 +7,9 @@ _either_rs = static_library(
'either',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2018', 'build.rust_std=2018'],
rust_abi: 'rust',
rust_args: [
- '--edition', '2018',
'--cfg', 'feature="use_std"',
'--cfg', 'feature="use_alloc"',
],
diff --git a/subprojects/packagefiles/itertools-0.11-rs/meson.build b/subprojects/packagefiles/itertools-0.11-rs/meson.build
index da731ca032..13d2d27019 100644
--- a/subprojects/packagefiles/itertools-0.11-rs/meson.build
+++ b/subprojects/packagefiles/itertools-0.11-rs/meson.build
@@ -11,9 +11,9 @@ _itertools_rs = static_library(
'itertools',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2018', 'build.rust_std=2018'],
rust_abi: 'rust',
rust_args: [
- '--edition', '2018',
'--cfg', 'feature="use_std"',
'--cfg', 'feature="use_alloc"',
],
diff --git a/subprojects/packagefiles/proc-macro-error-1-rs/meson.build b/subprojects/packagefiles/proc-macro-error-1-rs/meson.build
index 20f2e99a87..38ea7b89d3 100644
--- a/subprojects/packagefiles/proc-macro-error-1-rs/meson.build
+++ b/subprojects/packagefiles/proc-macro-error-1-rs/meson.build
@@ -16,9 +16,9 @@ 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: [
- '--edition', '2018',
'--cfg', 'use_fallback',
'--cfg', 'feature="syn-error"',
'--cfg', 'feature="proc-macro"',
diff --git a/subprojects/packagefiles/proc-macro-error-attr-1-rs/meson.build b/subprojects/packagefiles/proc-macro-error-attr-1-rs/meson.build
index 1aafd41795..d900c54cfd 100644
--- a/subprojects/packagefiles/proc-macro-error-attr-1-rs/meson.build
+++ b/subprojects/packagefiles/proc-macro-error-attr-1-rs/meson.build
@@ -13,8 +13,8 @@ rust = import('rust')
_proc_macro_error_attr_rs = rust.proc_macro(
'proc_macro_error_attr',
files('src/lib.rs'),
+ override_options: ['rust_std=2018', 'build.rust_std=2018'],
rust_args: [
- '--edition', '2018',
'--cfg', 'use_fallback',
'--cfg', 'feature="syn-error"',
'--cfg', 'feature="proc-macro"'
diff --git a/subprojects/packagefiles/proc-macro2-1-rs/meson.build b/subprojects/packagefiles/proc-macro2-1-rs/meson.build
index 6796d75295..8e601b50cc 100644
--- a/subprojects/packagefiles/proc-macro2-1-rs/meson.build
+++ b/subprojects/packagefiles/proc-macro2-1-rs/meson.build
@@ -11,9 +11,9 @@ _proc_macro2_rs = static_library(
'proc_macro2',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2021', 'build.rust_std=2021'],
rust_abi: 'rust',
rust_args: [
- '--edition', '2021',
'--cfg', 'feature="proc-macro"',
'--cfg', 'no_literal_byte_character',
'--cfg', 'no_literal_c_string',
diff --git a/subprojects/packagefiles/quote-1-rs/meson.build b/subprojects/packagefiles/quote-1-rs/meson.build
index a9c2fb9b61..d36609bd3c 100644
--- a/subprojects/packagefiles/quote-1-rs/meson.build
+++ b/subprojects/packagefiles/quote-1-rs/meson.build
@@ -11,9 +11,9 @@ _quote_rs = static_library(
'quote',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2021', 'build.rust_std=2021'],
rust_abi: 'rust',
rust_args: [
- '--edition', '2021',
'--cfg', 'feature="proc-macro"',
],
dependencies: [
diff --git a/subprojects/packagefiles/syn-2-rs/meson.build b/subprojects/packagefiles/syn-2-rs/meson.build
index b4666473fb..a53335f309 100644
--- a/subprojects/packagefiles/syn-2-rs/meson.build
+++ b/subprojects/packagefiles/syn-2-rs/meson.build
@@ -15,9 +15,9 @@ _syn_rs = static_library(
'syn',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2021', 'build.rust_std=2021'],
rust_abi: 'rust',
rust_args: [
- '--edition', '2021',
'--cfg', 'feature="full"',
'--cfg', 'feature="derive"',
'--cfg', 'feature="parsing"',
diff --git a/subprojects/packagefiles/unicode-ident-1-rs/meson.build b/subprojects/packagefiles/unicode-ident-1-rs/meson.build
index 77c581f40a..54f2376854 100644
--- a/subprojects/packagefiles/unicode-ident-1-rs/meson.build
+++ b/subprojects/packagefiles/unicode-ident-1-rs/meson.build
@@ -7,10 +7,8 @@ _unicode_ident_rs = static_library(
'unicode_ident',
files('src/lib.rs'),
gnu_symbol_visibility: 'hidden',
+ override_options: ['rust_std=2021', 'build.rust_std=2021'],
rust_abi: 'rust',
- rust_args: [
- '--edition', '2021',
- ],
dependencies: [],
native: true,
)
--
2.30.2
next prev parent reply other threads:[~2024-08-14 0:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-14 9:08 [RFC PATCH 0/2] meson: Specify Rust edition by rust_std=20XX Junjie Mao
2024-08-14 9:08 ` Junjie Mao [this message]
2024-08-14 9:08 ` [RFC PATCH 2/2] rust: " Junjie Mao
2024-08-14 11:19 ` [RFC PATCH 0/2] meson: " Manos Pitsidianakis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240814090820.1251026-2-junjie.mao@intel.com \
--to=junjie.mao@intel.com \
--cc=alex.bennee@linaro.org \
--cc=armbru@redhat.com \
--cc=berrange@redhat.com \
--cc=gustavo.romero@linaro.org \
--cc=mads@ynddal.dk \
--cc=manos.pitsidianakis@linaro.org \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=philmd@linaro.org \
--cc=pierrick.bouvier@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.org \
--cc=rowan.hart@intel.com \
--cc=stefanha@redhat.com \
--cc=thuth@redhat.com \
--cc=zhao1.liu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).