add some test parts for alpine linux x86_64

master
chyyuu 6 years ago
parent 7049fce31f
commit 05f0efd3fd

@ -111,7 +111,13 @@ ifeq ($(arch), $(filter $(arch), x86_64 aarch64))
@cd $(out_dir) && tar xvf ../../$(alpine)
endif
#build: rust ucore biscuit $(busybox) nginx redis iperf3
test:
@echo setup test DIR
@mkdir -p $(out_dir)
@cp -r testsuits_alpine $(out_dir)/
@mv $(out_dir)/testsuits_alpine $(out_dir)/test
#build: rust ucore biscuit $(busybox) nginx redis iperf3 test
build: rust alpine
sfsimg: $(out_qcow2)

@ -44,6 +44,7 @@ Then, build userspace programs for rCore:
```bash
$ make {ucore,biscuit,rust,nginx,redis,all} arch={x86_64,aarch64,riscv32,riscv64,mipsel}
$ make alpine arch={x86_64,aarch64} # if you want to use alpine rootfs
$ make test arch={x86_64} # test alpine real apps, e.g. python, gcc, rust, go, lua, etc.(need rootfs with these real apps)
$ make sfsimg arch={x86_64,aarch64,riscv32,riscv64,mipsel}
```
@ -61,7 +62,7 @@ A rootfs is created at `build/$(arch)` and converted to `qcow2`.
| busybox | ✅ | ✅ | ✅ | ✅ | ✅ |
| alpine rootfs | ✅ | ✅ | ❌ | ❌ | ❌ |
| iperf3 | ✅ | ❌ | ❌ | ❌ | ❌ |
| test | ✅ | ❌ | ❌ | ❌ | ❌ |
Note: ❗ means workarounds are used so that they may not work properly. ❌ means failure in compiling or not existed on such platform.
@ -158,4 +159,22 @@ $ printf
Built within rCore
```
Note: the long linker args can be replaced by invoking gcc instead later when we fix the problem. If you encountered `rcore-fs-fuse` panicking, consider upgrading it to latest version.
Note: the long linker args can be replaced by invoking gcc instead later when we fix the problem. If you encountered `rcore-fs-fuse` panicking, consider upgrading it to latest version.
### How to test real alpine apps
#### simple test for alpine minifs with little apps
```bash
1. make alpine arch=x86_64
2. make test arch=x86_64
3. make sfsimg arch=x86_64
4. cd $(RCORE_ROOT)/kernel; make run arch=x86_64 mode=release
```
#### test gcc/go/python2/python3/ruby/lua/java/rust
```bash
1. download x86_64.qcow2.realapps.xz from cloud tsinghua
2. xz -d x86_64.qcow2.realapps.xz; mv x86_64.qcow2.realapps x86_64.qcow2
3. mv x86_64.qcow2 $(RCORE_ROOT)/user/build
4. cd $(RCORE_ROOT)/kernel; make run arch=x86_64 mode=release
```

Loading…
Cancel
Save