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

Check build target supports std when building with -Zbuild-std=std #14183

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Commits on Jul 3, 2024

  1. Check build target supports std when building with -Zbuild-std=std

    Running cargo with "-Zbuild-std=std" should check whether the build
    target supports building the standard library. This information can be
    obtained from rustc with the target-spec-json "--print" option. When
    'std' is false for the build target, cargo should not attempt to build
    the standard library.
    
    This avoids the "use of unstable library" errors, as this check is
    performed before Cargo starts trying to build restricted_std code.
    harmou01 committed Jul 3, 2024
    Configuration menu
    Copy the full SHA
    a60fb6c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    0ab14a6 View commit details
    Browse the repository at this point in the history
  3. Add new test case 'test_std_on_unsupported_target'

    Add a new test case to check cargo handles building a target which
    doesn't support the standard library properly.
    harmou01 committed Jul 3, 2024
    Configuration menu
    Copy the full SHA
    d79de0d View commit details
    Browse the repository at this point in the history