Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unstable features and macros tracking issues #551

Open
3 tasks
orangecms opened this issue Feb 25, 2022 · 1 comment
Open
3 tasks

Unstable features and macros tracking issues #551

orangecms opened this issue Feb 25, 2022 · 1 comment

Comments

@orangecms
Copy link
Contributor

orangecms commented Feb 25, 2022

Same as they are doing in Rust for Linux: Rust-for-Linux/linux#2

Remarks

We cannot use a stable version as of now because we're using some -Z flags; this would be printed:

RUST_TARGET_PATH=/home/user/oreboot/src/custom_targets cargo build --target "x86_64-unknown-none-oreboot" -Z build-std=core,alloc --verbose --release
error: the `-Z` flag is only accepted on the nightly channel of Cargo, but this is the `stable` channel

Howto

Look at the stable release of the Rust unstable book to find the references and compare with the nightly release of the book.

Here's a list of unstable things we're using (TODO: complete the list!)

Compiler Features

Language Features

@bwerthmann
Copy link
Contributor

bwerthmann commented Dec 16, 2022

I spiked on this for just the nezha as far as I could get with make RUSTUP_TOOLCHAIN=1.66. See branch https://github.com/bwerthmann/oreboot/tree/551-unstable-features-and-macros-tracking-issues for patches. I only compile tested this code.

I ran out of runway here:

   Compiling oreboot-nezha-bt0 v0.1.0 (/home/ben/ofw/oreboot/src/mainboard/sunxi/nezha/bt0)
error[E0554]: `#![feature]` may not be used on the stable release channel
 --> src/mainboard/sunxi/nezha/bt0/src/main.rs:2:1
  |
2 | #![feature(naked_functions, asm_const)]
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0554]: `#![feature]` may not be used on the stable release channel
 --> src/mainboard/sunxi/nezha/bt0/src/main.rs:3:1
  |
3 | #![feature(default_alloc_error_handler)]
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

2 participants