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

add an opt-in cargo feature to build intrinsics from compiler-rt source #74

Merged
merged 5 commits into from
Sep 30, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 6 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ language: rust
services: docker
sudo: required
rust: nightly
cache: cargo

matrix:
include:
Expand All @@ -25,18 +24,11 @@ matrix:
- env: TARGET=mipsel-unknown-linux-gnu
- env: TARGET=powerpc-unknown-linux-gnu
- env: TARGET=powerpc64-unknown-linux-gnu
# QEMU crashes even when executing the simplest cross compiled C program:
# `int main() { return 0; }`
- env: TARGET=powerpc64le-unknown-linux-gnu NO_RUN=1
- env: TARGET=powerpc64le-unknown-linux-gnu
- env: TARGET=thumbv6m-none-eabi
install: cargo install xargo --debug -f
script: $HOME/.cargo/bin/xargo build --target $TARGET
- env: TARGET=thumbv7em-none-eabi
install: cargo install xargo --debug -f
script: $HOME/.cargo/bin/xargo build --target $TARGET
- env: TARGET=thumbv7em-none-eabihf
install: cargo install xargo --debug -f
script: $HOME/.cargo/bin/xargo build --target $TARGET
- env: TARGET=thumbv7m-none-eabi
- env: TARGET=x86_64-apple-darwin
os: osx
env: TARGET=x86_64-unknown-linux-gnu
Expand All @@ -45,8 +37,10 @@ before_install:
- test "$TRAVIS_OS_NAME" = "osx" || docker run --rm --privileged multiarch/qemu-user-static:register

install:
- curl https://static.rust-lang.org/rustup.sh |
sh -s -- --add-target=$TARGET --disable-sudo -y --prefix=`rustc --print sysroot`
- if case $TARGET in thumb*) false;; *) true;; esac; then
curl https://static.rust-lang.org/rustup.sh |
sh -s -- --add-target=$TARGET --disable-sudo -y --prefix=`rustc --print sysroot`;
fi

script:
- cargo generate-lockfile
Expand Down
6 changes: 6 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ build = "build.rs"
name = "rustc_builtins"
version = "0.1.0"

[build-dependencies]
gcc = "0.3.35"
rustc-cfg = "0.1.2"

[dependencies]

[dependencies.rlibc]
Expand All @@ -17,6 +21,8 @@ gcc_s = { path = "gcc_s" }
compiler-rt = { path = "compiler-rt" }

[features]
# Build the missing intrinsics from compiler-rt C source code
c = []
weak = ["rlibc/weak"]

[workspace]
Loading