-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.toml
93 lines (75 loc) · 2.61 KB
/
Makefile.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
extend= [
{ path = "coverage_grcov.makefile.toml" },
{ path = "pai-make-targets/build.toml" },
{ path = "pai-make-targets/fix.toml" },
{ path = "pai-make-targets/test.toml" },
{ path = "pai-make-targets/enforce.toml" },
{ path = "pai-make-targets/publish.toml" },
]
[tasks.publish]
dependencies = ["update", "enforcestd", "test-all"]
[tasks.build]
args = [ "build", "--all-features", "--target-dir=output", "--target=${@}"]
[tasks.coverage]
alias="coverage_grcov"
[tasks.bench]
command = "cargo"
args = ["bench", "--all-features"]
# # Doc also expects target argument
[tasks.docpublic]
command = "cargo"
args = ["doc", "--quiet", "--all-features", "--no-deps", "--target=${@}"]
[tasks.docprivate]
command = "cargo"
args = ["doc", "--quiet", "--all-features", "--no-deps", "--target=${@}", "--document-private-items"]
[tasks.test-min]
extend = "test"
args = ["test"]
[tasks.test-plugin]
extend = "test"
args = ["test", "--features", "plugins"]
[tasks.test-syscalls]
extend = "test"
args = ["test", "--features", "syscalls"]
[tasks.test-x86]
env = { TARGET = ["i686-unknown-linux-gnu"] }
run_task = "crosstest"
[tasks.test-x86_64]
# Run tests in all possible configuration, some tests are then run multiple
# times.
dependencies = [ "test-min", "test-plugin", "test-syscalls", "test" ]
[tasks.test-armv7-gnueabihf]
env = { TARGET = ["armv7-unknown-linux-gnueabihf"] }
run_task = "crosstest"
[tasks.test-aarch64]
env = { TARGET = ["aarch64-linux-android"] }
run_task = "crosstest"
# This only builds with cargo and not cross, so no automatic testing yet.
[tasks.test-riscv64]
env = { TARGET = ["riscv64gc-unknown-linux-gnu"] }
run_task = "crosstest"
[tasks.test-mips]
env = { TARGET = ["mips-unknown-linux-gnu"] }
run_task = "crosstest"
[tasks.test-all]
dependencies = [
"test-x86_64",
"test-x86",
"test-armv7-gnueabihf",
"test-aarch64",
"test-riscv64",
"test-mips"
]
# Afterwards run with:
# "qemu-system-arm" "-nographic" "-snapshot" "-smp" "4" "-m" "1G" "-kernel" "scripts/images/arm-linux-gnueabi/zImage" "-M" "vexpress-a9" "-drive" "file=scripts/images/arm-linux-gnueabi/rootfs-ready.qcow2,if=sd" "-append" "rootwait console=ttyAMA0,115200 root=/dev/mmcblk0" "-net" "nic,model=lan9118" "-dtb" "scripts/images/arm-linux-gnueabi/vexpress-v2p-ca9.dtb" "-net" "user,hostfwd=tcp::10023-:22"
[tasks.update-rootfs-arm]
script = "./scripts/qemu-runner.rs"
args = [
"-vv", "--arch", "ArmEabi",
"--kernel", "scripts/images/arm-linux-gnueabi/zImage",
"--disk", "scripts/images/arm-linux-gnueabi/rootfs-ready.qcow2",
"--no-snapshot", "--user", "shell",
"--identity scripts/keys/qemu_id_rsa",
"--pubkey", "scripts/keys/qemu_id_rsa.pub",
"id"
]