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

crate-ify compiler-rt into compiler-builtins #35021

Merged
merged 7 commits into from
Sep 14, 2016

Commits on Sep 13, 2016

  1. crate-ify compiler-rt into compiler-builtins

    libcompiler-rt.a is dead, long live libcompiler-builtins.rlib
    
    This commit moves the logic that used to build libcompiler-rt.a into a
    compiler-builtins crate on top of the core crate and below the std crate.
    This new crate still compiles the compiler-rt instrinsics using gcc-rs
    but produces an .rlib instead of a static library.
    
    Also, with this commit rustc no longer passes -lcompiler-rt to the
    linker. This effectively makes the "no-compiler-rt" field of target
    specifications a no-op. Users of `no_std` will have to explicitly add
    the compiler-builtins crate to their crate dependency graph *if* they
    need the compiler-rt intrinsics. Users of the `std` have to do nothing
    extra as the std crate depends on compiler-builtins.
    
    Finally, this a step towards lazy compilation of std with Cargo as the
    compiler-rt intrinsics can now be built by Cargo instead of having to
    be supplied by the user by some other method.
    
    closes rust-lang#34400
    Jorge Aparicio authored and alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    3fd5fdd View commit details
    Browse the repository at this point in the history
  2. it's libcompiler-rt.lib on windows

    Jorge Aparicio authored and alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    e6da837 View commit details
    Browse the repository at this point in the history
  3. no emutls for you, windows

    Jorge Aparicio authored and alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    e5d0bb1 View commit details
    Browse the repository at this point in the history
  4. it's also compiler-rt.lib on windows-gnu

    Jorge Aparicio authored and alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    521ffe9 View commit details
    Browse the repository at this point in the history
  5. rustc: Always link compiler-builtins last

    All crates depend on compiler-builtins, so we need to always include the crate
    last.
    alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    2140c4b View commit details
    Browse the repository at this point in the history
  6. rustc: Don't pass --whole-archive for compiler-builtins

    This flag is intended for rlibs included once, not rlibs that are repeatedly
    included.
    alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    2656202 View commit details
    Browse the repository at this point in the history
  7. Link test to compiler builtins and make unstable

    This commit fixes a test which now needs to explicitly link to the
    `compiler_builtins` crate as well as makes the `compiler_builtins` crate
    unstable.
    alexcrichton committed Sep 13, 2016
    Configuration menu
    Copy the full SHA
    848cfe2 View commit details
    Browse the repository at this point in the history