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

cargo xbuild fails to build for riscv64gc-unknown-linux-musl #107

Open
walksanatora opened this issue Feb 1, 2023 · 1 comment
Open

Comments

@walksanatora
Copy link

error[E0464]: multiple candidates for `rmeta` dependency `core` found
 --> /home/walksanator/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core/lib.rs:4:9
  |
4 | pub use core::*;
  |         ^^^^
  |
  = note: candidate #1: /tmp/cargo-xbuildui1JMz/target/riscv64gc-unknown-linux-musl/release/deps/libcore-5e0758bd9f6fbbc9.rmeta
  = note: candidate #2: /tmp/cargo-xbuildui1JMz/target/riscv64gc-unknown-linux-musl/release/deps/libcore-48461cb5a681c214.rmeta

For more information about this error, try `rustc --explain E0464`.
error: could not compile `rustc-std-workspace-core` due to previous error
warning: build failed, waiting for other jobs to finish...
error: `CARGO_TARGET_DIR="/tmp/cargo-xbuildui1JMz/target" RUSTFLAGS="-Cembed-bitcode=yes" __CARGO_DEFAULT_LIB_METADATA="XARGO" "/home/walksanator/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo" "rustc" "-p" "alloc" "--release" "--manifest-path" "/tmp/cargo-xbuildui1JMz/Cargo.toml" "--target" "riscv64gc-unknown-linux-musl" "--" "-Z" "force-unstable-if-unmarked"` failed with exit code: Some(101)
@walksanatora
Copy link
Author

then after commenting out the linker lines in the project i was trying
  = note: /usr/bin/ld: cannot find crt1.o: No such file or directory
          /usr/bin/ld: cannot find crti.o: No such file or directory
          /usr/bin/ld: cannot find crtbegin.o: No such file or directory
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: Relocations in generic ELF (EM: 243)
          /usr/bin/ld: /home/walksanator/git/rust/oc2/project/target/riscv64gc-unknown-linux-musl/debug/deps/nothing-6c7ab86a021fff73.20qhkt0gnc0472m2.rcgu.o: error adding symbols: file in wrong format
          collect2: error: ld returned 1 exit status

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

No branches or pull requests

1 participant