update README, Travis, Makefile

master
WangRunji 6 years ago
parent 2303a8099b
commit 2766f49986

@ -4,7 +4,7 @@ dist: xenial
language: rust
rust: nightly-2019-01-01
rust: nightly-2019-02-15
os:
- linux
@ -25,6 +25,7 @@ env:
matrix:
- ARCH="riscv64"
- ARCH="riscv64" OPTS="board=k210"
- ARCH="riscv64" OPTS="board=u540"
- ARCH="riscv32"
- ARCH="riscv32" OPTS="m_mode=1"
- ARCH="x86_64"
@ -32,17 +33,18 @@ env:
install:
- if [ $ARCH = riscv32 ] || [ $ARCH = riscv64 ]; then
[ $TRAVIS_OS_NAME = linux ] && export FILE="riscv64-unknown-elf-gcc-8.1.0-2018.12.0-x86_64-linux-ubuntu14";
[ $TRAVIS_OS_NAME = osx ] && export FILE="riscv64-unknown-elf-gcc-8.1.0-2018.12.0-x86_64-apple-darwin";
[ $TRAVIS_OS_NAME = linux ] && export FILE="riscv64-unknown-elf-gcc-8.1.0-2019.01.0-x86_64-linux-ubuntu14";
[ $TRAVIS_OS_NAME = osx ] && export FILE="riscv64-unknown-elf-gcc-8.1.0-2019.01.0-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://developer.arm.com/-/media/Files/downloads/gnu-a/8.2-2018.11/gcc-arm-8.2-2018.11-x86_64-aarch64-elf.tar.xz;
tar -xvf gcc-arm-8.2-2018.11-x86_64-aarch64-elf.tar.xz;
export PATH=$PATH:$PWD/gcc-arm-8.2-2018.11-x86_64-aarch64-elf/bin;
export FILE="gcc-arm-8.2-2018.11-x86_64-aarch64-elf";
wget https://developer.arm.com/-/media/Files/downloads/gnu-a/8.2-2018.11/$FILE.tar.xz;
tar -xvf $FILE.tar.xz;
export PATH=$PATH:$PWD/$FILE/bin;
elif [ $TRAVIS_OS_NAME = osx ]; then
brew tap SergioBenitez/osxct;
brew install aarch64-none-elf;

@ -1,6 +1,6 @@
# rCore Plus
[![Build Status](https://travis-ci.org/wangrunji0408/RustOS.svg?branch=master)](https://travis-ci.org/oscourse-tsinghua/RustOS)
[![Build Status](https://travis-ci.org/oscourse-tsinghua/rcore_plus.svg?branch=master)](https://travis-ci.org/oscourse-tsinghua/rcore_plus)
Rust version of THU [uCore OS Plus](https://github.com/chyyuu/ucore_os_plus).
@ -8,7 +8,7 @@ Its former repo name is https://github.com/oscourse-tsinghua/RustOS .
Going to be the next generation teaching operating system.
Supported architectures: x86_64, RISCV32/64, AArch64 MIPS(future)
Supported architectures: x86_64, RISCV32/64, AArch64, MIPS(future)
Tested boards: QEMU, labeled-RISCV, K210, Raspberry Pi 3B+
@ -20,12 +20,14 @@ Tested boards: QEMU, labeled-RISCV, K210, Raspberry Pi 3B+
### Environment
* [Rust](https://www.rust-lang.org) toolchain at nightly-2019-01-01
* [Rust](https://www.rust-lang.org) toolchain at nightly-2019-02-15
* Cargo tools: [cargo-xbuild](https://github.com/rust-osdev/cargo-xbuild)
* [QEMU](https://www.qemu.org) >= 3.1.0
* [bootimage](https://github.com/rust-osdev/bootimage) (for x86_64)
* [RISCV64 GNU toolchain](https://www.sifive.com/boards) (for riscv32/64)
* [AArch64 GNU toolchain](https://web.stanford.edu/class/cs140e/assignments/0-blinky/) (for aarch64)
* [AArch64 GNU toolchain](https://cs140e.sergio.bz/assignments/0-blinky/) (for aarch64)
See [Travis script](./.travis.yml) for details.
### How to run
@ -35,9 +37,9 @@ cargo install cargo-xbuild bootimage
```
```bash
git clone https://github.com//oscourse-tsinghua/rcore_plus.git --recursive
git clone https://github.com/oscourse-tsinghua/rcore_plus.git --recursive
cd rcore_plus/kernel
rustup override set nightly-2019-01-01
rustup override set nightly-2019-02-15
make run arch={riscv32,riscv64,x86_64,aarch64}
```

@ -18,6 +18,7 @@
# graphic = on | off enable/disable qemu graphical output
# board = none Running on QEMU
# | k210 Only available on riscv64, build without bbl, run on K210
# | u540 Only available on riscv64, run on HiFive U540, use Sv39
# | raspi3 Only available on aarch64, run on Raspberry Pi 3 Model B/B+
# m_mode Only available on riscv32, build for M-Mode, without MMU
@ -90,14 +91,10 @@ endif
else ifeq ($(arch), aarch64)
qemu_opts += \
-machine $(board) \
-serial null -serial mon:stdio \
-serial null \
-kernel $(bin)
endif
ifneq ($(graphic), on)
qemu_opts += -nographic
endif
ifdef d
qemu_opts += -d $(d)
endif

Loading…
Cancel
Save