Closed Chr1s-T closed 3 years ago
It seems like you're using cargo's own build-std
feature. Then you aren't using the cargo-xbuild
crate at all (and you shouldn't need it). I've never seen this error, but you can try comparing your code with the post-02
branch of the phil-opp/blog_os
repo, which is the repository of the "Writing an OS in Rust" blog. This branch should contain exactly the code for the "Minimal Rust Kernel" post. It is tested daily with the latest Rust nightly by our CI, so it should always work.
It seems like you're using cargo's own
build-std
feature. Then you aren't using thecargo-xbuild
crate at all (and you shouldn't need it). I've never seen this error, but you can try comparing your code with thepost-02
branch of thephil-opp/blog_os
repo, which is the repository of the "Writing an OS in Rust" blog. This branch should contain exactly the code for the "Minimal Rust Kernel" post. It is tested daily with the latest Rust nightly by our CI, so it should always work.
It works! Thank you very much!
Hello, I prey for some help!
I was trying to learn to build a minimal system kernel from
https://os.phil-opp.com/zh-CN/minimal-rust-kernel/
. And when the process goes tocargo build --target x86.json
, the compiler throws some errors below:error[E0660]: malformed inline assembly
error[E0599]: no associated item named 'MAX' found for type 'usize' in the current scope
error: Could not compile 'compiler_builtins'.
My
Cargo.toml
configuration is here:How to solve this problem? Please help me! Thank you very much!!!