public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
From: Randy MacLeod <randy.macleod@windriver.com>
To: Alexander Kanavin <alex.kanavin@gmail.com>,
	Francesco Pham <pham.francesco@gmail.com>
Cc: OE-core <openembedded-core@lists.openembedded.org>
Subject: Re: [OE-core] [rust] error: the crate panic_abort does not have the panic strategy abort
Date: Wed, 23 Mar 2022 11:57:00 -0400	[thread overview]
Message-ID: <bb61d16a-ffb8-3543-17fc-82a72c8155e6@windriver.com> (raw)
In-Reply-To: <CANNYZj_z2RsfGLaAaJHEBb+P5JT3CNikobgrq00FW9fkGH6UgQ@mail.gmail.com>

On 2022-01-14 09:42, Alexander Kanavin wrote:
> Perhaps you could look at how this is handled in mozjs recipe in 
> meta-oe, I vaguely remember it forces panic strategy to something 
> incompatible and I patched it to match..
> 
> Alex

Francesco,

Did looking at the mozjs recipe help?

Maybe you can summarize here for anyone who has a similar issue and
finds this thread.

../Randy

> 
> On Fri, 14 Jan 2022 at 15:21, Francesco Pham <pham.francesco@gmail.com 
> <mailto:pham.francesco@gmail.com>> wrote:
> 
>     Hi,
>     the following error appears when trying to build a simple rust hello
>     world that uses panic set to abort mode.
> 
>      > | DEBUG: Executing shell function do_compile
>      > | NOTE: cargo =
>     /home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/recipe-sysroot-native/usr/bin/cargo
>      > | NOTE: rustc =
>      > | NOTE: cargo build -v --target x86_64-poky-linux --release
>     --manifest-path=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/git//Cargo.toml
>      > |    Compiling rust-hello-world v0.0.1
>     (/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/git)
>      > |     Building [                             ] 0/1:
>     rust-hello-world(bin)
>      > |      Running `rustc --crate-name rust_hello_world
>     --edition=2018 src/main.rs
>     <http://main.rs>
>     --error-format=json --json=diagnostic-rendered-ansi --crate-type bin
>     --emit=dep-info,link -C opt-level=3 -C panic=abort -C lto -C
>     metadata=38cc6f415494c65c -C extra-filename=-38cc6f415494c65c
>     --out-dir
>     /home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/build/target/x86_64-poky-linux/release/deps
>     --target x86_64-poky-linux -C
>     linker=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/wrapper/target-rust-ccld
>     -L
>     dependency=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/build/target/x86_64-poky-linux/release/deps
>     -L
>     dependency=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/build/target/release/deps
>     -L
>     /home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/recipe-sysroot/usr/lib/rust
>     --remap-path-prefix=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0=/usr/src/debug/rust-panic-test/git-r0`
>      > | error: the crate `panic_abort` does not have the panic strategy
>     `abort`
>      > |
>      > | error: aborting due to previous error
>      > |
>      > | error: could not compile `rust-hello-world`
>      > |
>      > | Caused by:
>      > |   process didn't exit successfully: `rustc --crate-name
>     rust_hello_world --edition=2018 src/main.rs
>     <http://main.rs>
>     --error-format=json --json=diagnostic-rendered-ansi --crate-type bin
>     --emit=dep-info,link -C opt-level=3 -C panic=abort -C lto -C
>     metadata=38cc6f415494c65c -C extra-filename=-38cc6f415494c65c
>     --out-dir
>     /home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/build/target/x86_64-poky-linux/release/deps
>     --target x86_64-poky-linux -C
>     linker=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/wrapper/target-rust-ccld
>     -L
>     dependency=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/build/target/x86_64-poky-linux/release/deps
>     -L
>     dependency=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/build/target/release/deps
>     -L
>     /home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0/recipe-sysroot/usr/lib/rust
>     --remap-path-prefix=/home/francesco/Desktop/poky/build/tmp/work/core2-64-poky-linux/rust-panic-test/git-r0=/usr/src/debug/rust-panic-test/git-r0`
>     (exit status: 1)
>      > | WARNING: exit code 101 from a shell command.
> 
>     A similar error also appears when the panic strategy is set to unwind
>     The recipe, generated using cargo bitbake, is as follows:
> 
>      > inherit cargo
>      > SRC_URI +=
>     "git://git@github.com/frankplus/rust-hello-world.git;protocol=https;branch=master
>     <https://urldefense.com/v3/__http://git@github.com/frankplus/rust-hello-world.git;protocol=https;branch=master__;!!AjveYdw8EvQ!O6m7kT4SKIB2etM325d3xV_J7Qj-NTnCCEFkV6LpAdckc3pCtFlvYTiGn6SXpv9qX_W32g$>"
>      > SRCREV = "68b7f7ee7df6e08a0411ba7157761145c43baf5d"
>      > S = "${WORKDIR}/git"
>      > SUMMARY = "rust-hello-world"
>      > HOMEPAGE = "https://github.com/frankplus/rust-hello-world
>     <https://urldefense.com/v3/__https://github.com/frankplus/rust-hello-world__;!!AjveYdw8EvQ!O6m7kT4SKIB2etM325d3xV_J7Qj-NTnCCEFkV6LpAdckc3pCtFlvYTiGn6SXpv_KuXxrfQ$>"
>      > LICENSE = "MIT | Apache-2.0"
>      > LIC_FILES_CHKSUM =
>     "file://COPYRIGHT;md5=e6b2207ac3740d2d01141c49208c2147"
> 
>     Version: honister @ f286eef, master @ f9f3e1
>     Component: meta/recipes-devtools/rust
>     Relate-to: https://github.com/meta-rust/meta-rust/issues/343
>     <https://urldefense.com/v3/__https://github.com/meta-rust/meta-rust/issues/343__;!!AjveYdw8EvQ!O6m7kT4SKIB2etM325d3xV_J7Qj-NTnCCEFkV6LpAdckc3pCtFlvYTiGn6SXpv-aGWv17w$>
> 
> 
> 
> 
> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#160570): https://lists.openembedded.org/g/openembedded-core/message/160570
> Mute This Topic: https://lists.openembedded.org/mt/88421290/3616765
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [randy.macleod@windriver.com]
> -=-=-=-=-=-=-=-=-=-=-=-
> 


-- 
# Randy MacLeod
# Wind River Linux



      reply	other threads:[~2022-03-23 15:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-14 14:21 [rust] error: the crate panic_abort does not have the panic strategy abort Francesco Pham
2022-01-14 14:42 ` [OE-core] " Alexander Kanavin
2022-03-23 15:57   ` Randy MacLeod [this message]

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=bb61d16a-ffb8-3543-17fc-82a72c8155e6@windriver.com \
    --to=randy.macleod@windriver.com \
    --cc=alex.kanavin@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=pham.francesco@gmail.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