Closed aelnosu closed 2 months ago
Also 'cc' lib does not build.
rustup component add rust-src --toolchain nightly-x86_64-unknown-linux-gnu
rustup target add x86_64-unknown-none cargo build --target x86_64-unknown-none
error: failed to parse manifest at /app/AnotherOSbutinrust/Cargo.toml
Caused by:
artifact = …
requires -Z bindeps
(kernel)
root@f530701681c9:/app/AnotherOSbutinrust# cargo build -Zbuild-std --target x86_64-unknown-none
Updating crates.io index
Downloaded getopts v0.2.21
Downloaded allocator-api2 v0.2.16
Downloaded adler v1.0.2
Downloaded unicode-width v0.1.11
Downloaded rustc-demangle v0.1.23
Downloaded addr2line v0.21.0
Downloaded miniz_oxide v0.7.2
Downloaded memchr v2.5.0
Downloaded compiler_builtins v0.1.109
Downloaded hashbrown v0.14.3
Downloaded object v0.32.2
Downloaded gimli v0.28.1
Downloaded libc v0.2.153
Downloaded 13 crates (1.9 MB) in 0.32s
Compiling compiler_builtins v0.1.109
Compiling core v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
Compiling autocfg v1.3.0
Compiling proc-macro2 v1.0.81
Compiling unicode-ident v1.0.12
Compiling libc v0.2.153
Compiling pin-project-lite v0.2.14
Compiling memchr v2.5.0
Compiling quote v1.0.36
Compiling std v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std)
Compiling syn v2.0.60
Compiling libc v0.2.154
Compiling crossbeam-utils v0.8.19
Compiling futures-core v0.3.30
Compiling slab v0.4.9
Compiling parking v2.2.0
Compiling cfg-if v1.0.0
Compiling futures-io v0.3.30
Compiling concurrent-queue v2.5.0
Compiling bitflags v2.5.0
Compiling memchr v2.7.2
Compiling rustix v0.38.34
Compiling linux-raw-sys v0.4.13
Compiling event-listener v4.0.3
Compiling serde v1.0.200
Compiling radium v0.7.0
Compiling io-lifetimes v1.0.11
Compiling log v0.4.21
Compiling tracing-core v0.1.32
Compiling tracing v0.1.40
Compiling event-listener-strategy v0.4.0
Compiling polling v2.8.0
Compiling bitflags v1.3.2
Compiling waker-fn v1.1.1
Compiling tap v1.0.1
Compiling futures-sink v0.3.30
Compiling fastrand v1.9.0
Compiling rustix v0.37.27
Compiling serde_derive v1.0.200
Compiling futures-macro v0.3.30
Compiling polling v3.7.0
Compiling futures-lite v1.13.0
Compiling futures-channel v0.3.30
Compiling wyz v0.5.1
Compiling async-lock v3.3.0
Compiling futures-lite v2.3.0
Compiling async-io v1.13.0
Compiling event-listener v2.5.3
Compiling pin-utils v0.1.0
Compiling funty v2.0.0
Compiling futures-task v0.3.30
Compiling linux-raw-sys v0.3.8
Compiling bitvec v1.0.1
Compiling rustc-std-workspace-core v1.99.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
Compiling futures-util v0.3.30
Compiling async-lock v2.8.0
Compiling async-io v2.3.2
Compiling alloc v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
Compiling unwind v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/unwind)
Compiling adler v1.0.2
Compiling rustc-demangle v0.1.23
Compiling pin-project-internal v1.1.5
Compiling socket2 v0.4.10
Compiling rustc-std-workspace-alloc v1.99.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-alloc)
Compiling panic_abort v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_abort)
Compiling gimli v0.28.1
Compiling hashbrown v0.14.3
Compiling miniz_oxide v0.7.2
Compiling object v0.32.2
Compiling std_detect v0.1.5 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/stdarch/crates/std_detect)
Compiling panic_unwind v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_unwind)
Compiling signal-hook-registry v1.4.2
Compiling pin-project v1.1.5
Compiling async-signal v0.2.6
Compiling futures-executor v0.3.30
Compiling event-listener v3.1.0
Compiling thiserror v1.0.59
Compiling addr2line v0.21.0
Compiling smallvec v1.13.2
Compiling rustversion v1.0.15
Compiling futures-concurrency v7.6.0
Compiling async-process v1.8.1
Compiling futures v0.3.30
Compiling thiserror-impl v1.0.59
Compiling getrandom v0.2.14
Compiling lock_api v0.4.12
Compiling serde_json v1.0.116
Compiling llvm-tools v0.1.1
Compiling anyhow v1.0.82
Compiling crc-catalog v2.4.0
Compiling crc v3.2.1
Compiling uuid v1.8.0
Compiling serde-big-array v0.4.1
Compiling bincode v1.3.3
Compiling proc_macro v0.0.0 (/root/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/proc_macro)
Compiling ryu v1.0.17
Compiling byteorder v1.5.0
Compiling bootloader v0.11.7
Compiling itoa v1.0.11
Compiling bootloader_api v0.11.7
Compiling volatile v0.4.6
Compiling scopeguard v1.2.0
Compiling bit_field v0.10.2
Compiling fastrand v2.1.0
Compiling x86_64 v0.15.1
Compiling tempfile v3.10.1
Compiling spin v0.5.2
Compiling fatfs v0.3.6
Compiling mbrman v0.5.2
Compiling gpt v3.1.0
Compiling bootloader-boot-config v0.11.7
Compiling pic8259 v0.11.0
Compiling lazy_static v1.4.0
Compiling spin v0.9.8
Compiling noto-sans-mono-bitmap v0.2.0
Compiling ovmf-prebuilt v0.1.0-alpha.1
error[E0658]: use of unstable library feature 'restricted_std': You have attempted to use a standard library built for a platform that it doesn't know how to support. Consider building it for a known environment, disabling it with #![no_std]
or overriding this warning by enabling this feature.
|
= help: add #![feature(restricted_std)]
to the crate attributes to enable
= note: this compiler was built on 2024-05-08; consider upgrading it if it is out of date
error[E0658]: use of unstable library feature 'restricted_std': You have attempted to use a standard library built for a platform that it doesn't know how to support. Consider building it for a known environment, disabling it with #![no_std] or overriding this warning by enabling this feature.
--> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ovmf-prebuilt-0.1.0-alpha.1/src/lib.rs:1:17 |
1 | use std::path::{PathBuf, Path}; | ^^^^^^^ |
---|
= help: add #![feature(restricted_std)]
to the crate attributes to enable
= note: this compiler was built on 2024-05-08; consider upgrading it if it is out of date
error[E0658]: use of unstable library feature 'restricted_std': You have attempted to use a standard library built for a platform that it doesn't know how to support. Consider building it for a known environment, disabling it with #![no_std] or overriding this warning by enabling this feature.
--> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ovmf-prebuilt-0.1.0-alpha.1/src/lib.rs:1:26 |
1 | use std::path::{PathBuf, Path}; | ^^^^ |
---|
= help: add #![feature(restricted_std)]
to the crate attributes to enable
= note: this compiler was built on 2024-05-08; consider upgrading it if it is out of date
For more information about this error, try rustc --explain E0658
.
error: could not compile ovmf-prebuilt
(lib) due to 3 previous errors
warning: build failed, waiting for other jobs to finish...
The kernel library will automatically build for x86_64-unknown-none, the main crate needs the std library, as all that it will do is launch qemu. Building the entire project for x86_64-unknown-none will never work.
ok
will test
root@6ec4052d778c:/app# cd AnotherOSbutinrust/
root@6ec4052d778c:/app/AnotherOSbutinrust# cargo build
Updating crates.io index
Downloaded async-signal v0.2.6
Downloaded autocfg v1.3.0
Downloaded async-process v1.8.1
Downloaded async-lock v3.3.0
Downloaded anyhow v1.0.82
Downloaded event-listener v3.1.0
Downloaded async-lock v2.8.0
Downloaded crc v3.2.1
Downloaded event-listener v4.0.3
Downloaded fastrand v1.9.0
Downloaded errno v0.3.8
Downloaded event-listener-strategy v0.4.0
Downloaded fastrand v2.1.0
Downloaded bincode v1.3.3
Downloaded event-listener v2.5.3
Downloaded cfg-if v1.0.0
Downloaded bootloader_api v0.11.7
Downloaded bootloader v0.11.7
Downloaded byteorder v1.5.0
Downloaded bootloader-boot-config v0.11.7
Downloaded bitvec v1.0.1
Downloaded slab v0.4.9
Downloaded wyz v0.5.1
Downloaded scopeguard v1.2.0
Downloaded thiserror v1.0.59
Downloaded smallvec v1.13.2
Downloaded tempfile v3.10.1
Downloaded uuid v1.8.0
Downloaded unicode-ident v1.0.12
Downloaded spin v0.9.8
Downloaded tracing-core v0.1.32
Downloaded tracing v0.1.40
Downloaded x86_64 v0.15.1
Downloaded futures-util v0.3.30
Downloaded serde_json v1.0.116
Downloaded syn v2.0.60
Downloaded rustix v0.37.27
Downloaded noto-sans-mono-bitmap v0.2.0
Downloaded libc v0.2.154
Downloaded linux-raw-sys v0.3.8
Downloaded rustix v0.38.34
Downloaded serde v1.0.200
Downloaded ovmf-prebuilt v0.1.0-alpha.1
Downloaded linux-raw-sys v0.4.13
Downloaded memchr v2.7.2
Downloaded ryu v1.0.17
Downloaded futures-concurrency v7.6.0
Downloaded socket2 v0.4.10
Downloaded serde_derive v1.0.200
Downloaded proc-macro2 v1.0.81
Downloaded polling v3.7.0
Downloaded pin-project-lite v0.2.14
Downloaded gpt v3.1.0
Downloaded polling v2.8.0
Downloaded fatfs v0.3.6
Downloaded pin-project-internal v1.1.5
Downloaded pin-project v1.1.5
Downloaded log v0.4.21
Downloaded futures v0.3.30
Downloaded quote v1.0.36
Downloaded getrandom v0.2.14
Downloaded futures-channel v0.3.30
Downloaded lock_api v0.4.12
Downloaded io-lifetimes v1.0.11
Downloaded futures-lite v2.3.0
Downloaded futures-lite v1.13.0
Downloaded futures-sink v0.3.30
Downloaded pin-utils v0.1.0
Downloaded waker-fn v1.1.1
Downloaded volatile v0.4.6
Downloaded thiserror-impl v1.0.59
Downloaded tap v1.0.1
Downloaded spin v0.5.2
Downloaded serde-big-array v0.4.1
Downloaded rustversion v1.0.15
Downloaded lazy_static v1.4.0
Downloaded itoa v1.0.11
Downloaded futures-task v0.3.30
Downloaded futures-macro v0.3.30
Downloaded futures-io v0.3.30
Downloaded futures-executor v0.3.30
Downloaded futures-core v0.3.30
Downloaded funty v2.0.0
Downloaded signal-hook-registry v1.4.2
Downloaded radium v0.7.0
Downloaded pic8259 v0.11.0
Downloaded parking v2.2.0
Downloaded mbrman v0.5.2
Downloaded llvm-tools v0.1.1
Downloaded crc-catalog v2.4.0
Downloaded concurrent-queue v2.5.0
Downloaded crossbeam-utils v0.8.19
Downloaded bit_field v0.10.2
Downloaded bitflags v2.5.0
Downloaded bitflags v1.3.2
Downloaded async-io v2.3.2
Downloaded async-io v1.13.0
Downloaded 97 crates (9.3 MB) in 1.35s (largest was linux-raw-sys
at 1.5 MB)
Compiling autocfg v1.3.0
Compiling proc-macro2 v1.0.81
Compiling unicode-ident v1.0.12
Compiling pin-project-lite v0.2.14
Compiling libc v0.2.154
Compiling crossbeam-utils v0.8.19
Compiling futures-core v0.3.30
Compiling slab v0.4.9
Compiling cfg-if v1.0.0
Compiling parking v2.2.0
Compiling futures-io v0.3.30
Compiling memchr v2.7.2
Compiling quote v1.0.36
Compiling syn v2.0.60
Compiling concurrent-queue v2.5.0
Compiling bitflags v2.5.0
Compiling rustix v0.38.34
Compiling linux-raw-sys v0.4.13
Compiling event-listener v4.0.3
Compiling log v0.4.21
Compiling radium v0.7.0
Compiling tracing-core v0.1.32
Compiling io-lifetimes v1.0.11
Compiling serde v1.0.200
Compiling tracing v0.1.40
Compiling event-listener-strategy v0.4.0
Compiling polling v2.8.0
Compiling futures-sink v0.3.30
Compiling waker-fn v1.1.1
Compiling rustix v0.37.27
Compiling bitflags v1.3.2
Compiling tap v1.0.1
Compiling fastrand v1.9.0
Compiling futures-lite v1.13.0
Compiling wyz v0.5.1
Compiling futures-channel v0.3.30
Compiling async-lock v3.3.0
Compiling futures-lite v2.3.0
Compiling async-io v1.13.0
Compiling futures-task v0.3.30
Compiling event-listener v2.5.3
Compiling linux-raw-sys v0.3.8
Compiling pin-utils v0.1.0
Compiling funty v2.0.0
Compiling bitvec v1.0.1
Compiling serde_derive v1.0.200
Compiling futures-macro v0.3.30
Compiling polling v3.7.0
Compiling async-io v2.3.2
Compiling pin-project-internal v1.1.5
Compiling futures-util v0.3.30
Compiling async-lock v2.8.0
Compiling socket2 v0.4.10
Compiling signal-hook-registry v1.4.2
Compiling async-signal v0.2.6
Compiling pin-project v1.1.5
Compiling event-listener v3.1.0
Compiling rustversion v1.0.15
Compiling smallvec v1.13.2
Compiling thiserror v1.0.59
Compiling futures-concurrency v7.6.0
Compiling async-process v1.8.1
Compiling futures-executor v0.3.30
Compiling futures v0.3.30
Compiling thiserror-impl v1.0.59
Compiling getrandom v0.2.14
Compiling lock_api v0.4.12
Compiling crc-catalog v2.4.0
Compiling llvm-tools v0.1.1
Compiling anyhow v1.0.82
Compiling serde_json v1.0.116
Compiling crc v3.2.1
Compiling uuid v1.8.0
Compiling serde-big-array v0.4.1
Compiling bincode v1.3.3
Compiling bootloader_api v0.11.7
Compiling scopeguard v1.2.0
error[E0463]: can't find crate for core
|
= note: the x86_64-unknown-none
target may not be installed
= help: consider downloading the target with rustup target add x86_64-unknown-none
= help: consider building the standard library from source with cargo build -Zbuild-std
For more information about this error, try rustc --explain E0463
.
error: could not compile scopeguard
(lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
I think I get it to work.
132/137
Yep i get it to work on debian, by work I mean build.
I will make a PR on documentation soon TM, probably at about 10:45
Updated readme with working commands
Also need apt install build-essential, gcc