You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem I'm having is that when I use the vga crate, which uses bitflags, it contains the std feature as bootloader also uses this crate in std env.
Leading to this error:
Compiling kernel v0.0.0 (REDACTED)
error[E0152]: found duplicate lang item `panic_impl`
--> kernel/src/main.rs:31:1
|
31 | / pub fn panic(_info: &PanicInfo) -> ! {
32 | | loop {}
33 | | }
| |_^
|
= note: the lang item is first defined in crate `std` (which `bitflags` depends on)
= note: first definition in `std` loaded from /home/aaron/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-d65a5ac20318153f.so, /home/aaron/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-d65a5ac20318153f.rlib
= note: second definition in the local crate (`kernel`)
Is there any way to get around this? I was hoping artifact dependencies would be completely seperate but that doesn't seem to be the case. Am I doing something wrong in my setup?
I've tried explicit using bitflags with default-features=false and using the v2 resolver to no avail
The text was updated successfully, but these errors were encountered:
Try moving the kernel into a separate workspace. You can exclude it from your main workspace by setting workspace.exclude.
Out of curiosity: Can you reproduce this issue using the latest nightly compiler? I know that we've also had this problem recently and solved it by moving our test kernels to a different workspace, but for some reason, I can't reproduce the issue right now.
I've been following the guide on setting up the workspace such that the kernel is in a separate crate and is brought in as an artifact dependency:
The problem I'm having is that when I use the
vga
crate, which usesbitflags
, it contains thestd
feature as bootloader also uses this crate instd
env.Leading to this error:
Is there any way to get around this? I was hoping artifact dependencies would be completely seperate but that doesn't seem to be the case. Am I doing something wrong in my setup?
I've tried explicit using
bitflags
withdefault-features=false
and using the v2 resolver to no availThe text was updated successfully, but these errors were encountered: