Skip to content

Commit

Permalink
Add more Linux-based syscall tables
Browse files Browse the repository at this point in the history
* Add syscall tables to most remaining arches in `src/unix/notbsd`
* Add aarch64/arm musl to CI
* Update dependencies
  • Loading branch information
alexcrichton committed Oct 18, 2017
1 parent 84da91c commit 9029cfb
Show file tree
Hide file tree
Showing 20 changed files with 4,078 additions and 195 deletions.
5 changes: 4 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ matrix:
# 1.0.0 compat
- env: TARGET=x86_64-unknown-linux-gnu NO_ADD=1
rust: 1.0.0
script: cargo build
script: rm -f Cargo.lock && cargo build
install:

# build documentation
Expand All @@ -49,7 +49,10 @@ matrix:
- env: TARGET=x86_64-unknown-linux-musl
- env: TARGET=i686-unknown-linux-musl
- env: TARGET=arm-unknown-linux-gnueabihf
- env: TARGET=arm-unknown-linux-musleabihf
- env: TARGET=aarch64-unknown-linux-gnu
- env: TARGET=aarch64-unknown-linux-musl
rust: beta
- os: osx
osx_image: xcode8.2
env: TARGET=i386-apple-ios
Expand Down
94 changes: 39 additions & 55 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions ci/docker/aarch64-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ RUN curl https://www.musl-libc.org/releases/musl-1.1.16.tar.gz | \
make ARCH=arm64 prefix=/musl-aarch64 install -j4 && \
cd .. && \
rm -rf kernel-headers-3.12.6-5

# FIXME: shouldn't need the `-lgcc` here, shouldn't that be in libstd?
ENV PATH=$PATH:/musl-aarch64/bin:/rust/bin \
CC_aarch64_unknown_linux_musl=musl-gcc \
RUSTFLAGS='-Clink-args=-lgcc' \
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER=musl-gcc \
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_RUNNER="qemu-aarch64 -L /musl-aarch64"
25 changes: 25 additions & 0 deletions ci/docker/arm-unknown-linux-musleabihf/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
FROM ubuntu:17.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc make libc6-dev git curl ca-certificates \
gcc-arm-linux-gnueabihf qemu-user

RUN curl https://www.musl-libc.org/releases/musl-1.1.16.tar.gz | tar xzf -
WORKDIR /musl-1.1.16
RUN CC=arm-linux-gnueabihf-gcc \
CFLAGS="-march=armv6 -marm" \
./configure --prefix=/musl-arm --enable-wrapper=yes
RUN make install -j4

# Install linux kernel headers sanitized for use with musl
RUN \
curl -L https://github.com/sabotage-linux/kernel-headers/archive/v3.12.6-5.tar.gz | \
tar xzf - && \
cd kernel-headers-3.12.6-5 && \
make ARCH=arm prefix=/musl-arm install -j4 && \
cd .. && \
rm -rf kernel-headers-3.12.6-5
ENV PATH=$PATH:/musl-arm/bin:/rust/bin \
CC_arm_unknown_linux_musleabihf=musl-gcc \
CARGO_TARGET_ARM_UNKNOWN_LINUX_MUSLEABIHF_LINKER=musl-gcc \
CARGO_TARGET_ARM_UNKNOWN_LINUX_MUSLEABIHF_RUNNER="qemu-arm -L /musl-arm"
2 changes: 1 addition & 1 deletion libc-test/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ build = "build.rs"
libc = { path = ".." }

[build-dependencies]
ctest = { git = 'https://github.com/alexcrichton/ctest', branch = 'long' }
ctest = "0.1.6"

[[test]]
name = "main"
Expand Down
Loading

2 comments on commit 9029cfb

@asomers
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know whether it was intended, but this commit changed libc's ABI. The symbols SYS_memfd_create, SYS_gettid, SYS_perf_event_open and SYS_pivot_root all changed from signed to unsigned.

@alexcrichton
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No that was not intended

Please sign in to comment.