1
0
mirror of https://github.com/rcore-os/rCore.git synced 2024-11-22 16:16:16 +04:00

add travis for macOS

This commit is contained in:
WangRunji 2018-12-01 18:21:15 +08:00
parent 1f305a883c
commit 210854971d
2 changed files with 24 additions and 8 deletions

View File

@ -1,16 +1,25 @@
sudo: required
sudo: false
language: rust
rust: nightly
os:
- linux
- osx
cache:
cargo: true
directories:
- $HOME/Library/Caches/Homebrew
addons:
apt:
packages:
- qemu
homebrew:
packages:
- qemu
env:
matrix:
@ -21,15 +30,21 @@ env:
install:
- if [ $ARCH = riscv32 ]; then
export FILE="riscv64-unknown-elf-gcc-20181030-x86_64-linux-ubuntu14";
[ $TRAVIS_OS_NAME = linux ] && export FILE="riscv64-unknown-elf-gcc-20181127-x86_64-linux-ubuntu14";
[ $TRAVIS_OS_NAME = osx ] && export FILE="riscv64-unknown-elf-gcc-20181127-x86_64-apple-darwin";
wget https://static.dev.sifive.com/dev-tools/$FILE.tar.gz;
tar xf $FILE.tar.gz;
export PATH=$PATH:$PWD/$FILE/bin;
fi
- if [ $ARCH = aarch64 ]; then
if [ $TRAVIS_OS_NAME = linux ]; then
wget https://web.stanford.edu/class/cs140e/files/aarch64-none-elf-linux-x64.tar.gz;
tar -xzvf aarch64-none-elf-linux-x64.tar.gz;
export PATH=$PATH:$PWD/aarch64-none-elf/bin;
elif [ $TRAVIS_OS_NAME = osx ]; then
brew tap SergioBenitez/osxct;
brew install aarch64-none-elf;
fi;
fi

View File

@ -7,6 +7,7 @@
"target-c-int-width": "32",
"os": "none",
"executables": true,
"linker": "rust-lld",
"linker-flavor": "ld.lld",
"panic-strategy": "abort",
"disable-redzone": true,