cargo-bitbake icon indicating copy to clipboard operation
cargo-bitbake copied to clipboard

Edition 2021 not supported

Open ghost opened this issue 3 years ago • 6 comments

cargo-bitbake doesn't support edition 2021 in Cargo.toml

$ cargo bitbake
error: failed to parse manifest at `/home/snke/git/xxx/Cargo.toml`

Caused by:
  failed to parse the `edition` key

Caused by:
  this version of Cargo is older than the `2021` edition, and only supports `2015` and `2018` editions.
$ cargo bitbake --version
cargo-bitbake 0.3.15

ghost avatar Feb 03 '22 07:02 ghost

I'm running into the same problem.. Is there a workaround?

ghost avatar Feb 04 '22 20:02 ghost

Yeah, me too. This actually is a show stopper for my rust project

acz2022 avatar Mar 29 '22 16:03 acz2022

@cardoe Could you please take a look at this?

GiorgioBertolotti avatar Apr 08 '22 11:04 GiorgioBertolotti

@snke @Pan5ky @acz2022 as a workaround you can install the version with updated dependencies from PR #45. To do so you can run cargo install --locked --git https://github.com/otavio/cargo-bitbake. Please note that if you've previously installed the original version you should run cargo uninstall cargo-bitbake to remove it.

GiorgioBertolotti avatar Apr 08 '22 12:04 GiorgioBertolotti

@GiorgioBertolotti worked for me. Hoping this can get merged and published soon.

cletustboone avatar Apr 19 '22 19:04 cletustboone

@GiorgioBertolotti Thanks for the reply. There is unfortunately more to that. At the moment cargo-bitbake is not able to produce correct recipe (it creates almost correct) for rust app that uses gtk3. What needed to be added to my recipe after generating it via cargo bitbake:

  1. inherit pkgconfig
  2. DEPENDS = "glibc cairo gtk+3 gdk-pixbuf atk pango"

But I still think it is a great work and I'm sure it will only get better. Cheers

acz2022 avatar Apr 20 '22 16:04 acz2022