rust-lang / rust-lang/rust

error[E0463]: can't find crate for `core`- with: `--prefix=/usr --libdir=/usr/lib/amd64`

Open
#141,887 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

C-bug regression-from-stable-to-stable T-bootstrap
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

Rust build fails when using for bootstrap Rust 1.87.0 built with --prefix=/usr --libdir=/usr/lib/amd64 (On Solaris 64 bit libraries need to be placed into /usr/lib/amd64):

Building compiler artifacts (stage0 -> stage1, x86_64-pc-solaris)
warning: `/builds/psumbera/userland-test/components/rust/rustc/build/.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
   Compiling proc-macro2 v1.0.93
   Compiling unicode-ident v1.0.14
   Compiling libc v0.2.169
   Compiling cfg-if v1.0.0
error[E0463]: can't find crate for `core`
  |
  = note: the `x86_64-pc-solaris` target may not be installed
  = help: consider downloading the target with `rustup target add x86_64-pc-solaris`
  = 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 `cfg-if` (lib) due to 1 previous error

This used to work with Rust 1.78.0.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the bootstrap failure for Rust 1.87.0 on x86_64-pc-solaris with --prefix=/usr and --libdir=/usr/lib/amd64, then compare it with the working Rust 1.78.0 setup. Start from the bootstrap build and target-library lookup involved in the reported error[E0463]; done means the stage0-to-stage1 build finds core and completes successfully with Solaris's 64-bit library layout.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system, compilers, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.