diff mbox series

[1/3] rust: Fix crossbeam-utils for arches without atomics

Message ID 20220825104851.3258387-1-richard.purdie@linuxfoundation.org
State Accepted, archived
Commit 5d8c01dfed4c82fcc5d504c728a51fb98a262300
Headers show
Series [1/3] rust: Fix crossbeam-utils for arches without atomics | expand

Commit Message

Richard Purdie Aug. 25, 2022, 10:48 a.m. UTC
crossbeam-utils tries to use the triplet to look up whether the target
supports various forms of atomics. We use TARGET_VENDOR and not "-unknown"
in the target case which means this fails and breaks platforms like mips
and powerpc 32 bit. Add a patch to handle TARGET_VENDOR in this case.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-devtools/rust/rust-source.inc    |  1 +
 .../rust/rust/crossbeam_atomic.patch          | 33 +++++++++++++++++++
 meta/recipes-devtools/rust/rust_1.63.0.bb     |  3 ++
 3 files changed, 37 insertions(+)
 create mode 100644 meta/recipes-devtools/rust/rust/crossbeam_atomic.patch

Comments

Alexander Kanavin Aug. 25, 2022, 10:52 a.m. UTC | #1
This will complicate version updates unfortunately, as updating
.cargo-checksum.json is a pain :(
Can we try to arrive at something upstreamable?

Alex

On Thu, 25 Aug 2022 at 12:49, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
>
> crossbeam-utils tries to use the triplet to look up whether the target
> supports various forms of atomics. We use TARGET_VENDOR and not "-unknown"
> in the target case which means this fails and breaks platforms like mips
> and powerpc 32 bit. Add a patch to handle TARGET_VENDOR in this case.
>
> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> ---
>  meta/recipes-devtools/rust/rust-source.inc    |  1 +
>  .../rust/rust/crossbeam_atomic.patch          | 33 +++++++++++++++++++
>  meta/recipes-devtools/rust/rust_1.63.0.bb     |  3 ++
>  3 files changed, 37 insertions(+)
>  create mode 100644 meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
>
> diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc
> index d8be2701367..ce6c983fc0b 100644
> --- a/meta/recipes-devtools/rust/rust-source.inc
> +++ b/meta/recipes-devtools/rust/rust-source.inc
> @@ -3,6 +3,7 @@ SRC_URI[rust.sha256sum] = "8f44af6dc44cc4146634a4dd5e4cc5470b3052a2337019b870c0e
>
>  SRC_URI:append:class-target:pn-rust = " \
>      file://hardcodepaths.patch \
> +    file://crossbeam_atomic.patch \
>      file://0001-Add-ENOTSUP-constant-for-riscv32-musl.patch"
>  SRC_URI:append:class-nativesdk:pn-nativesdk-rust = " file://hardcodepaths.patch"
>
> diff --git a/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch b/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
> new file mode 100644
> index 00000000000..64c73810a89
> --- /dev/null
> +++ b/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
> @@ -0,0 +1,33 @@
> +Upstream-Status: Inappropriate [OE Specific tweak]
> +
> +Index: rustc-1.63.0-src/vendor/crossbeam-utils/build.rs
> +===================================================================
> +--- rustc-1.63.0-src.orig/vendor/crossbeam-utils/build.rs
> ++++ rustc-1.63.0-src/vendor/crossbeam-utils/build.rs
> +@@ -29,7 +29,7 @@ use std::env;
> + include!("no_atomic.rs");
> +
> + fn main() {
> +-    let target = match env::var("TARGET") {
> ++    let mut target = match env::var("TARGET") {
> +         Ok(target) => target,
> +         Err(e) => {
> +             println!(
> +@@ -40,6 +40,8 @@ fn main() {
> +             return;
> +         }
> +     };
> ++    let vendor = env::var("TARGET_VENDOR").unwrap();
> ++    target = target.replace(&vendor, "-unknown");
> +
> +     // Note that this is `no_*`, not `has_*`. This allows treating
> +     // `cfg(target_has_atomic = "ptr")` as true when the build script doesn't
> +Index: rustc-1.63.0-src/vendor/crossbeam-utils/.cargo-checksum.json
> +===================================================================
> +--- rustc-1.63.0-src.orig/vendor/crossbeam-utils/.cargo-checksum.json
> ++++ rustc-1.63.0-src/vendor/crossbeam-utils/.cargo-checksum.json
> +@@ -1 +1 @@
> +-{"files":{"CHANGELOG.md":"665a9f2c5fd37c98bef7c1b6eda753b58bb925d87e5b42d7298df973d7590631","Cargo.toml":"fe22292acd6a868e65baf225f90d5678678971642814d2d8e92a03954b8bdb40","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"5734ed989dfca1f625b40281ee9f4530f91b2411ec01cb748223e7eb87e201ab","README.md":"dfa9fbed47c344c134a63c84b7c0e4651baeac1554b7b3266d0e38643743fc33","benches/atomic_cell.rs":"c927eb3cd1e5ecc4b91adbc3bde98af15ffab4086190792ba64d5cde0e24df3d","build.rs":"7e74dc72343ff57e83d0a84a9fbdd9ff1645894165909999b4c3d2fba94bc96c","no_atomic.rs":"71b5f78fd701ce604aa766dd3d825fa5bed774282aae4d6c31d7acb01b1b242f","src/atomic/atomic_cell.rs":"01185588e0e16ba81425677966d0c11887dedc4ac0d4a65991a34057c418adc4","src/atomic/consume.rs":"7a7736fcd64f6473dfea7653559ffc5e1a2a234df43835f8aa8734862145ac15","src/atomic/mod.rs":"94193895fa03cece415e8d7be700b73a9a8a7015774ca821253438607f9b0736","src/atomic/seq_lock.rs":"27182e6b87a9db73c5f6831759f8625f9fcdec3c2828204c444aef04f427735a","src/atomic/seq_lock_wide.rs":"9888dd03116bb89ca36d4ab8d5a0b5032107a2983a7eb8024454263b09080088","src/backoff.rs":"7cc7754e15f69b52e92a70d4f49d1bc274693455a0933a2d7eb0605806566af3","src/cache_padded.rs":"6a512698115ad0d5a5b163dbd7a83247e1f1c146c4a30f3fc74b952e3b767b59","src/lib.rs":"6f1bcf157abe06ad8458a53e865bf8efab9fad4a9424790147cee8fefb3795d8","src/sync/mod.rs":"59986f559a8f170a4b3247ab2eea2460b09809d87c8110ed88e4e7103d3519dc","src/sync/parker.rs":"3f997f5b41fec286ccedcf3d36f801d741387badb574820b8e3456117ecd9154","src/sync/sharded_lock.rs":"14be659744918d0b27db24c56b41c618b0f0484b6761da46561023d96c4c120f","src/sync/wait_group.rs":"32e946a7581c55f8aa9904527b92b177c538fa0cf7cbcfa1d1f25990582cb6ea","src/thread.rs":"6a7676fd4e50af63aec6f655121a10cd6e8c704f4677125388186ba58dc5842d","tests/atomic_cell.rs":"d64faa1ca8896373468308031220940d988aa3a1679ea25d2291a7a7d22bc51a","tests/cache_padded.rs":"1bfaff8354c8184e1ee1f902881ca9400b60effb273b0d3f752801a483d2b66d","tests/parker.rs":"6def4721287d9d70b1cfd63ebb34e1c83fbb3376edbad2bc8aac6ef69dd99d20","tests/sharded_lock.rs":"eb6c5b59f007e0d290dd0f58758e8ccb5cacd38af34e3341368ced815f0c41be","tests/thread.rs":"9a7d7d3028c552fd834c68598b04a1cc252a816bc20ab62cec060d6cd09cab10","tests/wait_group.rs":"ad8f0cdfed31f9594a2e0737234d418f8b924d784a4db8d7e469deab8c95f5f8"},"package":"0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"}
> +\ No newline at end of file
> ++{"files":{"CHANGELOG.md":"665a9f2c5fd37c98bef7c1b6eda753b58bb925d87e5b42d7298df973d7590631","Cargo.toml":"fe22292acd6a868e65baf225f90d5678678971642814d2d8e92a03954b8bdb40","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"5734ed989dfca1f625b40281ee9f4530f91b2411ec01cb748223e7eb87e201ab","README.md":"dfa9fbed47c344c134a63c84b7c0e4651baeac1554b7b3266d0e38643743fc33","benches/atomic_cell.rs":"c927eb3cd1e5ecc4b91adbc3bde98af15ffab4086190792ba64d5cde0e24df3d","build.rs":"d983d511c89607ce89473779d1ee195e3eb509cc4d3043b9efe6aa2f94c98158","no_atomic.rs":"71b5f78fd701ce604aa766dd3d825fa5bed774282aae4d6c31d7acb01b1b242f","src/atomic/atomic_cell.rs":"01185588e0e16ba81425677966d0c11887dedc4ac0d4a65991a34057c418adc4","src/atomic/consume.rs":"7a7736fcd64f6473dfea7653559ffc5e1a2a234df43835f8aa8734862145ac15","src/atomic/mod.rs":"94193895fa03cece415e8d7be700b73a9a8a7015774ca821253438607f9b0736","src/atomic/seq_lock.rs":"27182e6b87a9db73c5f6831759f8625f9fcdec3c2828204c444aef04f427735a","src/atomic/seq_lock_wide.rs":"9888dd03116bb89ca36d4ab8d5a0b5032107a2983a7eb8024454263b09080088","src/backoff.rs":"7cc7754e15f69b52e92a70d4f49d1bc274693455a0933a2d7eb0605806566af3","src/cache_padded.rs":"6a512698115ad0d5a5b163dbd7a83247e1f1c146c4a30f3fc74b952e3b767b59","src/lib.rs":"6f1bcf157abe06ad8458a53e865bf8efab9fad4a9424790147cee8fefb3795d8","src/sync/mod.rs":"59986f559a8f170a4b3247ab2eea2460b09809d87c8110ed88e4e7103d3519dc","src/sync/parker.rs":"3f997f5b41fec286ccedcf3d36f801d741387badb574820b8e3456117ecd9154","src/sync/sharded_lock.rs":"14be659744918d0b27db24c56b41c618b0f0484b6761da46561023d96c4c120f","src/sync/wait_group.rs":"32e946a7581c55f8aa9904527b92b177c538fa0cf7cbcfa1d1f25990582cb6ea","src/thread.rs":"6a7676fd4e50af63aec6f655121a10cd6e8c704f4677125388186ba58dc5842d","tests/atomic_cell.rs":"d64faa1ca8896373468308031220940d988aa3a1679ea25d2291a7a7d22bc51a","tests/cache_padded.rs":"1bfaff8354c8184e1ee1f902881ca9400b60effb273b0d3f752801a483d2b66d","tests/parker.rs":"6def4721287d9d70b1cfd63ebb34e1c83fbb3376edbad2bc8aac6ef69dd99d20","tests/sharded_lock.rs":"eb6c5b59f007e0d290dd0f58758e8ccb5cacd38af34e3341368ced815f0c41be","tests/thread.rs":"9a7d7d3028c552fd834c68598b04a1cc252a816bc20ab62cec060d6cd09cab10","tests/wait_group.rs":"ad8f0cdfed31f9594a2e0737234d418f8b924d784a4db8d7e469deab8c95f5f8"},"package":"0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"}
> +\ No newline at end of file
> diff --git a/meta/recipes-devtools/rust/rust_1.63.0.bb b/meta/recipes-devtools/rust/rust_1.63.0.bb
> index 050f398794f..db797146b09 100644
> --- a/meta/recipes-devtools/rust/rust_1.63.0.bb
> +++ b/meta/recipes-devtools/rust/rust_1.63.0.bb
> @@ -7,6 +7,9 @@ FILES:${PN} += "${libdir}/rustlib"
>  FILES:${PN} += "${libdir}/*.so"
>  FILES:${PN}-dev = ""
>
> +# Used by crossbeam_atomic.patch
> +export TARGET_VENDOR
> +
>  do_compile () {
>      rust_runx build --stage 2
>  }
> --
> 2.34.1
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#169844): https://lists.openembedded.org/g/openembedded-core/message/169844
> Mute This Topic: https://lists.openembedded.org/mt/93245408/1686489
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [alex.kanavin@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
Alexander Kanavin Aug. 25, 2022, 10:53 a.m. UTC | #2
What would be much preferred is an explicit switch to disable atomics
on the platforms where we know they don't work.

Alex

On Thu, 25 Aug 2022 at 12:52, Alexander Kanavin <alex.kanavin@gmail.com> wrote:
>
> This will complicate version updates unfortunately, as updating
> .cargo-checksum.json is a pain :(
> Can we try to arrive at something upstreamable?
>
> Alex
>
> On Thu, 25 Aug 2022 at 12:49, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> >
> > crossbeam-utils tries to use the triplet to look up whether the target
> > supports various forms of atomics. We use TARGET_VENDOR and not "-unknown"
> > in the target case which means this fails and breaks platforms like mips
> > and powerpc 32 bit. Add a patch to handle TARGET_VENDOR in this case.
> >
> > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> > ---
> >  meta/recipes-devtools/rust/rust-source.inc    |  1 +
> >  .../rust/rust/crossbeam_atomic.patch          | 33 +++++++++++++++++++
> >  meta/recipes-devtools/rust/rust_1.63.0.bb     |  3 ++
> >  3 files changed, 37 insertions(+)
> >  create mode 100644 meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
> >
> > diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc
> > index d8be2701367..ce6c983fc0b 100644
> > --- a/meta/recipes-devtools/rust/rust-source.inc
> > +++ b/meta/recipes-devtools/rust/rust-source.inc
> > @@ -3,6 +3,7 @@ SRC_URI[rust.sha256sum] = "8f44af6dc44cc4146634a4dd5e4cc5470b3052a2337019b870c0e
> >
> >  SRC_URI:append:class-target:pn-rust = " \
> >      file://hardcodepaths.patch \
> > +    file://crossbeam_atomic.patch \
> >      file://0001-Add-ENOTSUP-constant-for-riscv32-musl.patch"
> >  SRC_URI:append:class-nativesdk:pn-nativesdk-rust = " file://hardcodepaths.patch"
> >
> > diff --git a/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch b/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
> > new file mode 100644
> > index 00000000000..64c73810a89
> > --- /dev/null
> > +++ b/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
> > @@ -0,0 +1,33 @@
> > +Upstream-Status: Inappropriate [OE Specific tweak]
> > +
> > +Index: rustc-1.63.0-src/vendor/crossbeam-utils/build.rs
> > +===================================================================
> > +--- rustc-1.63.0-src.orig/vendor/crossbeam-utils/build.rs
> > ++++ rustc-1.63.0-src/vendor/crossbeam-utils/build.rs
> > +@@ -29,7 +29,7 @@ use std::env;
> > + include!("no_atomic.rs");
> > +
> > + fn main() {
> > +-    let target = match env::var("TARGET") {
> > ++    let mut target = match env::var("TARGET") {
> > +         Ok(target) => target,
> > +         Err(e) => {
> > +             println!(
> > +@@ -40,6 +40,8 @@ fn main() {
> > +             return;
> > +         }
> > +     };
> > ++    let vendor = env::var("TARGET_VENDOR").unwrap();
> > ++    target = target.replace(&vendor, "-unknown");
> > +
> > +     // Note that this is `no_*`, not `has_*`. This allows treating
> > +     // `cfg(target_has_atomic = "ptr")` as true when the build script doesn't
> > +Index: rustc-1.63.0-src/vendor/crossbeam-utils/.cargo-checksum.json
> > +===================================================================
> > +--- rustc-1.63.0-src.orig/vendor/crossbeam-utils/.cargo-checksum.json
> > ++++ rustc-1.63.0-src/vendor/crossbeam-utils/.cargo-checksum.json
> > +@@ -1 +1 @@
> > +-{"files":{"CHANGELOG.md":"665a9f2c5fd37c98bef7c1b6eda753b58bb925d87e5b42d7298df973d7590631","Cargo.toml":"fe22292acd6a868e65baf225f90d5678678971642814d2d8e92a03954b8bdb40","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"5734ed989dfca1f625b40281ee9f4530f91b2411ec01cb748223e7eb87e201ab","README.md":"dfa9fbed47c344c134a63c84b7c0e4651baeac1554b7b3266d0e38643743fc33","benches/atomic_cell.rs":"c927eb3cd1e5ecc4b91adbc3bde98af15ffab4086190792ba64d5cde0e24df3d","build.rs":"7e74dc72343ff57e83d0a84a9fbdd9ff1645894165909999b4c3d2fba94bc96c","no_atomic.rs":"71b5f78fd701ce604aa766dd3d825fa5bed774282aae4d6c31d7acb01b1b242f","src/atomic/atomic_cell.rs":"01185588e0e16ba81425677966d0c11887dedc4ac0d4a65991a34057c418adc4","src/atomic/consume.rs":"7a7736fcd64f6473dfea7653559ffc5e1a2a234df43835f8aa8734862145ac15","src/atomic/mod.rs":"94193895fa03cece415e8d7be700b73a9a8a7015774ca821253438607f9b0736","src/atomic/seq_lock.rs":"27182e6b87a9db73c5f6831759f8625f9fcdec3c2828204c444aef04f427735a","src/atomic/seq_lock_wide.rs":"9888dd03116bb89ca36d4ab8d5a0b5032107a2983a7eb8024454263b09080088","src/backoff.rs":"7cc7754e15f69b52e92a70d4f49d1bc274693455a0933a2d7eb0605806566af3","src/cache_padded.rs":"6a512698115ad0d5a5b163dbd7a83247e1f1c146c4a30f3fc74b952e3b767b59","src/lib.rs":"6f1bcf157abe06ad8458a53e865bf8efab9fad4a9424790147cee8fefb3795d8","src/sync/mod.rs":"59986f559a8f170a4b3247ab2eea2460b09809d87c8110ed88e4e7103d3519dc","src/sync/parker.rs":"3f997f5b41fec286ccedcf3d36f801d741387badb574820b8e3456117ecd9154","src/sync/sharded_lock.rs":"14be659744918d0b27db24c56b41c618b0f0484b6761da46561023d96c4c120f","src/sync/wait_group.rs":"32e946a7581c55f8aa9904527b92b177c538fa0cf7cbcfa1d1f25990582cb6ea","src/thread.rs":"6a7676fd4e50af63aec6f655121a10cd6e8c704f4677125388186ba58dc5842d","tests/atomic_cell.rs":"d64faa1ca8896373468308031220940d988aa3a1679ea25d2291a7a7d22bc51a","tests/cache_padded.rs":"1bfaff8354c8184e1ee1f902881ca9400b60effb273b0d3f752801a483d2b66d","tests/parker.rs":"6def4721287d9d70b1cfd63ebb34e1c83fbb3376edbad2bc8aac6ef69dd99d20","tests/sharded_lock.rs":"eb6c5b59f007e0d290dd0f58758e8ccb5cacd38af34e3341368ced815f0c41be","tests/thread.rs":"9a7d7d3028c552fd834c68598b04a1cc252a816bc20ab62cec060d6cd09cab10","tests/wait_group.rs":"ad8f0cdfed31f9594a2e0737234d418f8b924d784a4db8d7e469deab8c95f5f8"},"package":"0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"}
> > +\ No newline at end of file
> > ++{"files":{"CHANGELOG.md":"665a9f2c5fd37c98bef7c1b6eda753b58bb925d87e5b42d7298df973d7590631","Cargo.toml":"fe22292acd6a868e65baf225f90d5678678971642814d2d8e92a03954b8bdb40","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"5734ed989dfca1f625b40281ee9f4530f91b2411ec01cb748223e7eb87e201ab","README.md":"dfa9fbed47c344c134a63c84b7c0e4651baeac1554b7b3266d0e38643743fc33","benches/atomic_cell.rs":"c927eb3cd1e5ecc4b91adbc3bde98af15ffab4086190792ba64d5cde0e24df3d","build.rs":"d983d511c89607ce89473779d1ee195e3eb509cc4d3043b9efe6aa2f94c98158","no_atomic.rs":"71b5f78fd701ce604aa766dd3d825fa5bed774282aae4d6c31d7acb01b1b242f","src/atomic/atomic_cell.rs":"01185588e0e16ba81425677966d0c11887dedc4ac0d4a65991a34057c418adc4","src/atomic/consume.rs":"7a7736fcd64f6473dfea7653559ffc5e1a2a234df43835f8aa8734862145ac15","src/atomic/mod.rs":"94193895fa03cece415e8d7be700b73a9a8a7015774ca821253438607f9b0736","src/atomic/seq_lock.rs":"27182e6b87a9db73c5f6831759f8625f9fcdec3c2828204c444aef04f427735a","src/atomic/seq_lock_wide.rs":"9888dd03116bb89ca36d4ab8d5a0b5032107a2983a7eb8024454263b09080088","src/backoff.rs":"7cc7754e15f69b52e92a70d4f49d1bc274693455a0933a2d7eb0605806566af3","src/cache_padded.rs":"6a512698115ad0d5a5b163dbd7a83247e1f1c146c4a30f3fc74b952e3b767b59","src/lib.rs":"6f1bcf157abe06ad8458a53e865bf8efab9fad4a9424790147cee8fefb3795d8","src/sync/mod.rs":"59986f559a8f170a4b3247ab2eea2460b09809d87c8110ed88e4e7103d3519dc","src/sync/parker.rs":"3f997f5b41fec286ccedcf3d36f801d741387badb574820b8e3456117ecd9154","src/sync/sharded_lock.rs":"14be659744918d0b27db24c56b41c618b0f0484b6761da46561023d96c4c120f","src/sync/wait_group.rs":"32e946a7581c55f8aa9904527b92b177c538fa0cf7cbcfa1d1f25990582cb6ea","src/thread.rs":"6a7676fd4e50af63aec6f655121a10cd6e8c704f4677125388186ba58dc5842d","tests/atomic_cell.rs":"d64faa1ca8896373468308031220940d988aa3a1679ea25d2291a7a7d22bc51a","tests/cache_padded.rs":"1bfaff8354c8184e1ee1f902881ca9400b60effb273b0d3f752801a483d2b66d","tests/parker.rs":"6def4721287d9d70b1cfd63ebb34e1c83fbb3376edbad2bc8aac6ef69dd99d20","tests/sharded_lock.rs":"eb6c5b59f007e0d290dd0f58758e8ccb5cacd38af34e3341368ced815f0c41be","tests/thread.rs":"9a7d7d3028c552fd834c68598b04a1cc252a816bc20ab62cec060d6cd09cab10","tests/wait_group.rs":"ad8f0cdfed31f9594a2e0737234d418f8b924d784a4db8d7e469deab8c95f5f8"},"package":"0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"}
> > +\ No newline at end of file
> > diff --git a/meta/recipes-devtools/rust/rust_1.63.0.bb b/meta/recipes-devtools/rust/rust_1.63.0.bb
> > index 050f398794f..db797146b09 100644
> > --- a/meta/recipes-devtools/rust/rust_1.63.0.bb
> > +++ b/meta/recipes-devtools/rust/rust_1.63.0.bb
> > @@ -7,6 +7,9 @@ FILES:${PN} += "${libdir}/rustlib"
> >  FILES:${PN} += "${libdir}/*.so"
> >  FILES:${PN}-dev = ""
> >
> > +# Used by crossbeam_atomic.patch
> > +export TARGET_VENDOR
> > +
> >  do_compile () {
> >      rust_runx build --stage 2
> >  }
> > --
> > 2.34.1
> >
> >
> > -=-=-=-=-=-=-=-=-=-=-=-
> > Links: You receive all messages sent to this group.
> > View/Reply Online (#169844): https://lists.openembedded.org/g/openembedded-core/message/169844
> > Mute This Topic: https://lists.openembedded.org/mt/93245408/1686489
> > Group Owner: openembedded-core+owner@lists.openembedded.org
> > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [alex.kanavin@gmail.com]
> > -=-=-=-=-=-=-=-=-=-=-=-
> >
Richard Purdie Aug. 25, 2022, 10:55 a.m. UTC | #3
On Thu, 2022-08-25 at 12:53 +0200, Alexander Kanavin wrote:
> What would be much preferred is an explicit switch to disable atomics
> on the platforms where we know they don't work.

There is a list of such platforms in no_atomics.rs. This patch means we
don't have to add the switch for every platform by fixing the detection
code.

Cheers,

Richard
Richard Purdie Aug. 25, 2022, 10:59 a.m. UTC | #4
On Thu, 2022-08-25 at 12:52 +0200, Alexander Kanavin wrote:
> This will complicate version updates unfortunately, as updating
> .cargo-checksum.json is a pain :(
> Can we try to arrive at something upstreamable?

The usptreamable version of the patch would probably be something which
splits the target names in no_atomics up into components and matched on
subsections of it rather than the whole string. My rust isn't really up
to doing that though.

I didn't really want us to maintain a separate list of targets which
have atomics issues given it and the list in no_atomics would get out
of sync very easily too.

Cheers,

Richard
Alexander Kanavin Aug. 25, 2022, 11:04 a.m. UTC | #5
On Thu, 25 Aug 2022 at 12:59, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
> The usptreamable version of the patch would probably be something which
> splits the target names in no_atomics up into components and matched on
> subsections of it rather than the whole string. My rust isn't really up
> to doing that though.
>
> I didn't really want us to maintain a separate list of targets which
> have atomics issues given it and the list in no_atomics would get out
> of sync very easily too.

But then the same patch needs to be applied to (and maintained
separately in) librsvg - and everything else that includes a copy of
crossbeam. Perhaps it's worth to at least make the above suggestion
about making it upstreamable in the patch commit message?

Alex
Richard Purdie Aug. 25, 2022, 11:53 a.m. UTC | #6
On Thu, 2022-08-25 at 13:04 +0200, Alexander Kanavin wrote:
> On Thu, 25 Aug 2022 at 12:59, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > The usptreamable version of the patch would probably be something which
> > splits the target names in no_atomics up into components and matched on
> > subsections of it rather than the whole string. My rust isn't really up
> > to doing that though.
> > 
> > I didn't really want us to maintain a separate list of targets which
> > have atomics issues given it and the list in no_atomics would get out
> > of sync very easily too.
> 
> But then the same patch needs to be applied to (and maintained
> separately in) librsvg - and everything else that includes a copy of
> crossbeam. Perhaps it's worth to at least make the above suggestion
> about making it upstreamable in the patch commit message?

Yes, I can improve the patch header. I do understand the patch isn't
ideal.

The alternatives are:

* we take my patch
* we break powerpc, mips, armv5, riscv32 and others
* we drop the rust upgrades (the latent problem still exists)
* we rewrite the patch

For me to rewrite the patch, I'll need to learn more rust. I'm sure I
can do that but it will take time and that time is time I can't use for
other things.

I'm hoping that by explaining the issue and documenting it, *someone*
would step up and work out the upstreamable patch. This hasn't worked
well for the rust recipes so far as I've had to do a lot of work to get
them more into shape. I'm hoping the problem was just the shear scale
and now issues are in easier smaller pieces others can/will help. It
will certainly be time before someone else can schedule that in, we
don't have anyone who can do it now.

I will say that I'm really really tired.

I have a ton of autobuilder failures and in order to resolve them I'm
rewriting patches many times over, first to get them to work, then
taking review feedback and people complaining they're not perfect or
don't fix other issues. I have a pile of other problems like this.

I appreciate the desire not to have patches, particularly when they're
as painful as the rust ones are. I appreciate the patch can be improved
and should go upstream. I was hoping to take some time off tomorrow but
it looks like I have other things to do (in reality probably on the
weekend, I need to rework the llvm patches too and both sets take hours
in rebuild time even to test).

Cheers,

Richard
Randy MacLeod Aug. 25, 2022, 7:11 p.m. UTC | #7
On 2022-08-25 07:53, Richard Purdie wrote:
> On Thu, 2022-08-25 at 13:04 +0200, Alexander Kanavin wrote:
>> On Thu, 25 Aug 2022 at 12:59, Richard Purdie
>> <richard.purdie@linuxfoundation.org> wrote:
>>> The usptreamable version of the patch would probably be something which
>>> splits the target names in no_atomics up into components and matched on
>>> subsections of it rather than the whole string. My rust isn't really up
>>> to doing that though.
>>>
>>> I didn't really want us to maintain a separate list of targets which
>>> have atomics issues given it and the list in no_atomics would get out
>>> of sync very easily too.
>> But then the same patch needs to be applied to (and maintained
>> separately in) librsvg - and everything else that includes a copy of
>> crossbeam. Perhaps it's worth to at least make the above suggestion
>> about making it upstreamable in the patch commit message?
> Yes, I can improve the patch header. I do understand the patch isn't
> ideal.
>
> The alternatives are:
>
> * we take my patch
> * we break powerpc, mips, armv5, riscv32 and others
> * we drop the rust upgrades (the latent problem still exists)
> * we rewrite the patch
>
> For me to rewrite the patch, I'll need to learn more rust. I'm sure I
> can do that but it will take time and that time is time I can't use for
> other things.
>
> I'm hoping that by explaining the issue and documenting it, *someone*
> would step up and work out the upstreamable patch. This hasn't worked
> well for the rust recipes so far as I've had to do a lot of work to get
> them more into shape. I'm hoping the problem was just the shear scale
> and now issues are in easier smaller pieces others can/will help. It
> will certainly be time before someone else can schedule that in, we
> don't have anyone who can do it now.

Yes, with the range of things I have had going on, re-writing the
rust classes/recipes was too big a task to consider. However, I can
and will work to get this patch into a form that is upstreamable.

I've created a bug to track that:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=14904

and at least started to look at some of the code!

../Randy


>
> I will say that I'm really really tired.
>
> I have a ton of autobuilder failures and in order to resolve them I'm
> rewriting patches many times over, first to get them to work, then
> taking review feedback and people complaining they're not perfect or
> don't fix other issues. I have a pile of other problems like this.
>
> I appreciate the desire not to have patches, particularly when they're
> as painful as the rust ones are. I appreciate the patch can be improved
> and should go upstream. I was hoping to take some time off tomorrow but
> it looks like I have other things to do (in reality probably on the
> weekend, I need to rework the llvm patches too and both sets take hours
> in rebuild time even to test).
>
> Cheers,
>
> Richard
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#169852): https://lists.openembedded.org/g/openembedded-core/message/169852
> Mute This Topic: https://lists.openembedded.org/mt/93245408/3616765
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [randy.macleod@windriver.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
Khem Raj Aug. 25, 2022, 11:24 p.m. UTC | #8
On Thu, Aug 25, 2022 at 12:11 PM Randy MacLeod
<randy.macleod@windriver.com> wrote:
>
> On 2022-08-25 07:53, Richard Purdie wrote:
> > On Thu, 2022-08-25 at 13:04 +0200, Alexander Kanavin wrote:
> >> On Thu, 25 Aug 2022 at 12:59, Richard Purdie
> >> <richard.purdie@linuxfoundation.org> wrote:
> >>> The usptreamable version of the patch would probably be something which
> >>> splits the target names in no_atomics up into components and matched on
> >>> subsections of it rather than the whole string. My rust isn't really up
> >>> to doing that though.
> >>>
> >>> I didn't really want us to maintain a separate list of targets which
> >>> have atomics issues given it and the list in no_atomics would get out
> >>> of sync very easily too.
> >> But then the same patch needs to be applied to (and maintained
> >> separately in) librsvg - and everything else that includes a copy of
> >> crossbeam. Perhaps it's worth to at least make the above suggestion
> >> about making it upstreamable in the patch commit message?
> > Yes, I can improve the patch header. I do understand the patch isn't
> > ideal.
> >
> > The alternatives are:
> >
> > * we take my patch
> > * we break powerpc, mips, armv5, riscv32 and others
> > * we drop the rust upgrades (the latent problem still exists)
> > * we rewrite the patch
> >
> > For me to rewrite the patch, I'll need to learn more rust. I'm sure I
> > can do that but it will take time and that time is time I can't use for
> > other things.
> >
> > I'm hoping that by explaining the issue and documenting it, *someone*
> > would step up and work out the upstreamable patch. This hasn't worked
> > well for the rust recipes so far as I've had to do a lot of work to get
> > them more into shape. I'm hoping the problem was just the shear scale
> > and now issues are in easier smaller pieces others can/will help. It
> > will certainly be time before someone else can schedule that in, we
> > don't have anyone who can do it now.
>
> Yes, with the range of things I have had going on, re-writing the
> rust classes/recipes was too big a task to consider. However, I can
> and will work to get this patch into a form that is upstreamable.
>
> I've created a bug to track that:
>
> https://bugzilla.yoctoproject.org/show_bug.cgi?id=14904
>
> and at least started to look at some of the code!
>


Also opening an issue upstream at
https://github.com/crossbeam-rs/crossbeam

would be a good thing. crossbeam is vendored by many rust packages and
we will end up spewing
the all such recipes with the tweak in addition to regenerating the
checksums in toml files with every
upgrade.

> ../Randy
>
>
> >
> > I will say that I'm really really tired.
> >
> > I have a ton of autobuilder failures and in order to resolve them I'm
> > rewriting patches many times over, first to get them to work, then
> > taking review feedback and people complaining they're not perfect or
> > don't fix other issues. I have a pile of other problems like this.
> >
> > I appreciate the desire not to have patches, particularly when they're
> > as painful as the rust ones are. I appreciate the patch can be improved
> > and should go upstream. I was hoping to take some time off tomorrow but
> > it looks like I have other things to do (in reality probably on the
> > weekend, I need to rework the llvm patches too and both sets take hours
> > in rebuild time even to test).
> >
> > Cheers,
> >
> > Richard
> >
> >
> >
>
> --
> # Randy MacLeod
> # Wind River Linux
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#169885): https://lists.openembedded.org/g/openembedded-core/message/169885
> Mute This Topic: https://lists.openembedded.org/mt/93245408/1997914
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
Randy MacLeod Aug. 26, 2022, 1:17 a.m. UTC | #9
On 2022-08-25 19:24, Khem Raj wrote:
> On Thu, Aug 25, 2022 at 12:11 PM Randy MacLeod
> <randy.macleod@windriver.com> wrote:
>> On 2022-08-25 07:53, Richard Purdie wrote:
>>> On Thu, 2022-08-25 at 13:04 +0200, Alexander Kanavin wrote:
>>>> On Thu, 25 Aug 2022 at 12:59, Richard Purdie
>>>> <richard.purdie@linuxfoundation.org> wrote:
>>>>> The usptreamable version of the patch would probably be something which
>>>>> splits the target names in no_atomics up into components and matched on
>>>>> subsections of it rather than the whole string. My rust isn't really up
>>>>> to doing that though.
>>>>>
>>>>> I didn't really want us to maintain a separate list of targets which
>>>>> have atomics issues given it and the list in no_atomics would get out
>>>>> of sync very easily too.
>>>> But then the same patch needs to be applied to (and maintained
>>>> separately in) librsvg - and everything else that includes a copy of
>>>> crossbeam. Perhaps it's worth to at least make the above suggestion
>>>> about making it upstreamable in the patch commit message?
>>> Yes, I can improve the patch header. I do understand the patch isn't
>>> ideal.
>>>
>>> The alternatives are:
>>>
>>> * we take my patch
>>> * we break powerpc, mips, armv5, riscv32 and others
>>> * we drop the rust upgrades (the latent problem still exists)
>>> * we rewrite the patch
>>>
>>> For me to rewrite the patch, I'll need to learn more rust. I'm sure I
>>> can do that but it will take time and that time is time I can't use for
>>> other things.
>>>
>>> I'm hoping that by explaining the issue and documenting it, *someone*
>>> would step up and work out the upstreamable patch. This hasn't worked
>>> well for the rust recipes so far as I've had to do a lot of work to get
>>> them more into shape. I'm hoping the problem was just the shear scale
>>> and now issues are in easier smaller pieces others can/will help. It
>>> will certainly be time before someone else can schedule that in, we
>>> don't have anyone who can do it now.
>> Yes, with the range of things I have had going on, re-writing the
>> rust classes/recipes was too big a task to consider. However, I can
>> and will work to get this patch into a form that is upstreamable.
>>
>> I've created a bug to track that:
>>
>> https://bugzilla.yoctoproject.org/show_bug.cgi?id=14904
>>
>> and at least started to look at some of the code!
>>
> Also opening an issue upstream at
> https://github.com/crossbeam-rs/crossbeam
>
> would be a good thing. crossbeam is vendored by many rust packages and
> we will end up spewing
> the all such recipes with the tweak in addition to regenerating the
> checksums in toml files with every
> upgrade.

Agreed and noted in the YP bug.

../Randy


>
>> ../Randy
>>
>>
>>> I will say that I'm really really tired.
>>>
>>> I have a ton of autobuilder failures and in order to resolve them I'm
>>> rewriting patches many times over, first to get them to work, then
>>> taking review feedback and people complaining they're not perfect or
>>> don't fix other issues. I have a pile of other problems like this.
>>>
>>> I appreciate the desire not to have patches, particularly when they're
>>> as painful as the rust ones are. I appreciate the patch can be improved
>>> and should go upstream. I was hoping to take some time off tomorrow but
>>> it looks like I have other things to do (in reality probably on the
>>> weekend, I need to rework the llvm patches too and both sets take hours
>>> in rebuild time even to test).
>>>
>>> Cheers,
>>>
>>> Richard
>>>
>>>
>>>
>> --
>> # Randy MacLeod
>> # Wind River Linux
>>
>>
>> -=-=-=-=-=-=-=-=-=-=-=-
>> Links: You receive all messages sent to this group.
>> View/Reply Online (#169885): https://lists.openembedded.org/g/openembedded-core/message/169885
>> Mute This Topic: https://lists.openembedded.org/mt/93245408/1997914
>> Group Owner: openembedded-core+owner@lists.openembedded.org
>> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [raj.khem@gmail.com]
>> -=-=-=-=-=-=-=-=-=-=-=-
>>
diff mbox series

Patch

diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc
index d8be2701367..ce6c983fc0b 100644
--- a/meta/recipes-devtools/rust/rust-source.inc
+++ b/meta/recipes-devtools/rust/rust-source.inc
@@ -3,6 +3,7 @@  SRC_URI[rust.sha256sum] = "8f44af6dc44cc4146634a4dd5e4cc5470b3052a2337019b870c0e
 
 SRC_URI:append:class-target:pn-rust = " \
     file://hardcodepaths.patch \
+    file://crossbeam_atomic.patch \
     file://0001-Add-ENOTSUP-constant-for-riscv32-musl.patch"
 SRC_URI:append:class-nativesdk:pn-nativesdk-rust = " file://hardcodepaths.patch"
 
diff --git a/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch b/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
new file mode 100644
index 00000000000..64c73810a89
--- /dev/null
+++ b/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch
@@ -0,0 +1,33 @@ 
+Upstream-Status: Inappropriate [OE Specific tweak]
+
+Index: rustc-1.63.0-src/vendor/crossbeam-utils/build.rs
+===================================================================
+--- rustc-1.63.0-src.orig/vendor/crossbeam-utils/build.rs
++++ rustc-1.63.0-src/vendor/crossbeam-utils/build.rs
+@@ -29,7 +29,7 @@ use std::env;
+ include!("no_atomic.rs");
+ 
+ fn main() {
+-    let target = match env::var("TARGET") {
++    let mut target = match env::var("TARGET") {
+         Ok(target) => target,
+         Err(e) => {
+             println!(
+@@ -40,6 +40,8 @@ fn main() {
+             return;
+         }
+     };
++    let vendor = env::var("TARGET_VENDOR").unwrap();
++    target = target.replace(&vendor, "-unknown");
+ 
+     // Note that this is `no_*`, not `has_*`. This allows treating
+     // `cfg(target_has_atomic = "ptr")` as true when the build script doesn't
+Index: rustc-1.63.0-src/vendor/crossbeam-utils/.cargo-checksum.json
+===================================================================
+--- rustc-1.63.0-src.orig/vendor/crossbeam-utils/.cargo-checksum.json
++++ rustc-1.63.0-src/vendor/crossbeam-utils/.cargo-checksum.json
+@@ -1 +1 @@
+-{"files":{"CHANGELOG.md":"665a9f2c5fd37c98bef7c1b6eda753b58bb925d87e5b42d7298df973d7590631","Cargo.toml":"fe22292acd6a868e65baf225f90d5678678971642814d2d8e92a03954b8bdb40","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"5734ed989dfca1f625b40281ee9f4530f91b2411ec01cb748223e7eb87e201ab","README.md":"dfa9fbed47c344c134a63c84b7c0e4651baeac1554b7b3266d0e38643743fc33","benches/atomic_cell.rs":"c927eb3cd1e5ecc4b91adbc3bde98af15ffab4086190792ba64d5cde0e24df3d","build.rs":"7e74dc72343ff57e83d0a84a9fbdd9ff1645894165909999b4c3d2fba94bc96c","no_atomic.rs":"71b5f78fd701ce604aa766dd3d825fa5bed774282aae4d6c31d7acb01b1b242f","src/atomic/atomic_cell.rs":"01185588e0e16ba81425677966d0c11887dedc4ac0d4a65991a34057c418adc4","src/atomic/consume.rs":"7a7736fcd64f6473dfea7653559ffc5e1a2a234df43835f8aa8734862145ac15","src/atomic/mod.rs":"94193895fa03cece415e8d7be700b73a9a8a7015774ca821253438607f9b0736","src/atomic/seq_lock.rs":"27182e6b87a9db73c5f6831759f8625f9fcdec3c2828204c444aef04f427735a","src/atomic/seq_lock_wide.rs":"9888dd03116bb89ca36d4ab8d5a0b5032107a2983a7eb8024454263b09080088","src/backoff.rs":"7cc7754e15f69b52e92a70d4f49d1bc274693455a0933a2d7eb0605806566af3","src/cache_padded.rs":"6a512698115ad0d5a5b163dbd7a83247e1f1c146c4a30f3fc74b952e3b767b59","src/lib.rs":"6f1bcf157abe06ad8458a53e865bf8efab9fad4a9424790147cee8fefb3795d8","src/sync/mod.rs":"59986f559a8f170a4b3247ab2eea2460b09809d87c8110ed88e4e7103d3519dc","src/sync/parker.rs":"3f997f5b41fec286ccedcf3d36f801d741387badb574820b8e3456117ecd9154","src/sync/sharded_lock.rs":"14be659744918d0b27db24c56b41c618b0f0484b6761da46561023d96c4c120f","src/sync/wait_group.rs":"32e946a7581c55f8aa9904527b92b177c538fa0cf7cbcfa1d1f25990582cb6ea","src/thread.rs":"6a7676fd4e50af63aec6f655121a10cd6e8c704f4677125388186ba58dc5842d","tests/atomic_cell.rs":"d64faa1ca8896373468308031220940d988aa3a1679ea25d2291a7a7d22bc51a","tests/cache_padded.rs":"1bfaff8354c8184e1ee1f902881ca9400b60effb273b0d3f752801a483d2b66d","tests/parker.rs":"6def4721287d9d70b1cfd63ebb34e1c83fbb3376edbad2bc8aac6ef69dd99d20","tests/sharded_lock.rs":"eb6c5b59f007e0d290dd0f58758e8ccb5cacd38af34e3341368ced815f0c41be","tests/thread.rs":"9a7d7d3028c552fd834c68598b04a1cc252a816bc20ab62cec060d6cd09cab10","tests/wait_group.rs":"ad8f0cdfed31f9594a2e0737234d418f8b924d784a4db8d7e469deab8c95f5f8"},"package":"0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"}
+\ No newline at end of file
++{"files":{"CHANGELOG.md":"665a9f2c5fd37c98bef7c1b6eda753b58bb925d87e5b42d7298df973d7590631","Cargo.toml":"fe22292acd6a868e65baf225f90d5678678971642814d2d8e92a03954b8bdb40","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"5734ed989dfca1f625b40281ee9f4530f91b2411ec01cb748223e7eb87e201ab","README.md":"dfa9fbed47c344c134a63c84b7c0e4651baeac1554b7b3266d0e38643743fc33","benches/atomic_cell.rs":"c927eb3cd1e5ecc4b91adbc3bde98af15ffab4086190792ba64d5cde0e24df3d","build.rs":"d983d511c89607ce89473779d1ee195e3eb509cc4d3043b9efe6aa2f94c98158","no_atomic.rs":"71b5f78fd701ce604aa766dd3d825fa5bed774282aae4d6c31d7acb01b1b242f","src/atomic/atomic_cell.rs":"01185588e0e16ba81425677966d0c11887dedc4ac0d4a65991a34057c418adc4","src/atomic/consume.rs":"7a7736fcd64f6473dfea7653559ffc5e1a2a234df43835f8aa8734862145ac15","src/atomic/mod.rs":"94193895fa03cece415e8d7be700b73a9a8a7015774ca821253438607f9b0736","src/atomic/seq_lock.rs":"27182e6b87a9db73c5f6831759f8625f9fcdec3c2828204c444aef04f427735a","src/atomic/seq_lock_wide.rs":"9888dd03116bb89ca36d4ab8d5a0b5032107a2983a7eb8024454263b09080088","src/backoff.rs":"7cc7754e15f69b52e92a70d4f49d1bc274693455a0933a2d7eb0605806566af3","src/cache_padded.rs":"6a512698115ad0d5a5b163dbd7a83247e1f1c146c4a30f3fc74b952e3b767b59","src/lib.rs":"6f1bcf157abe06ad8458a53e865bf8efab9fad4a9424790147cee8fefb3795d8","src/sync/mod.rs":"59986f559a8f170a4b3247ab2eea2460b09809d87c8110ed88e4e7103d3519dc","src/sync/parker.rs":"3f997f5b41fec286ccedcf3d36f801d741387badb574820b8e3456117ecd9154","src/sync/sharded_lock.rs":"14be659744918d0b27db24c56b41c618b0f0484b6761da46561023d96c4c120f","src/sync/wait_group.rs":"32e946a7581c55f8aa9904527b92b177c538fa0cf7cbcfa1d1f25990582cb6ea","src/thread.rs":"6a7676fd4e50af63aec6f655121a10cd6e8c704f4677125388186ba58dc5842d","tests/atomic_cell.rs":"d64faa1ca8896373468308031220940d988aa3a1679ea25d2291a7a7d22bc51a","tests/cache_padded.rs":"1bfaff8354c8184e1ee1f902881ca9400b60effb273b0d3f752801a483d2b66d","tests/parker.rs":"6def4721287d9d70b1cfd63ebb34e1c83fbb3376edbad2bc8aac6ef69dd99d20","tests/sharded_lock.rs":"eb6c5b59f007e0d290dd0f58758e8ccb5cacd38af34e3341368ced815f0c41be","tests/thread.rs":"9a7d7d3028c552fd834c68598b04a1cc252a816bc20ab62cec060d6cd09cab10","tests/wait_group.rs":"ad8f0cdfed31f9594a2e0737234d418f8b924d784a4db8d7e469deab8c95f5f8"},"package":"0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"}
+\ No newline at end of file
diff --git a/meta/recipes-devtools/rust/rust_1.63.0.bb b/meta/recipes-devtools/rust/rust_1.63.0.bb
index 050f398794f..db797146b09 100644
--- a/meta/recipes-devtools/rust/rust_1.63.0.bb
+++ b/meta/recipes-devtools/rust/rust_1.63.0.bb
@@ -7,6 +7,9 @@  FILES:${PN} += "${libdir}/rustlib"
 FILES:${PN} += "${libdir}/*.so"
 FILES:${PN}-dev = ""
 
+# Used by crossbeam_atomic.patch
+export TARGET_VENDOR
+
 do_compile () {
     rust_runx build --stage 2
 }