-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.toml
78 lines (66 loc) · 1.76 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
[config]
time_summary = false
default_to_workspace = false
[tasks.install-deps]
command = "cargo"
args = ["install", "cargo-deny", "--locked"]
[tasks.build-debug]
script_runner = "@duckscript"
script = '''
rm target/i686-unknown-none/glos2
exec cargo build --profile dev
cp target/i686-unknown-none/debug/glos2 target/i686-unknown-none/glos2
'''
[tasks.build-dev]
script_runner = "@duckscript"
script = '''
rm target/i686-unknown-none/glos2
exec cargo build --profile devel
cp target/i686-unknown-none/devel/glos2 target/i686-unknown-none/glos2
'''
[tasks.build-rls]
script_runner = "@duckscript"
script = '''
rm target/i686-unknown-none/glos2
exec cargo build --release
cp target/i686-unknown-none/release/glos2 target/i686-unknown-none/glos2
'''
[tasks.create-iso]
script_runner = "@duckscript"
script = '''
mkdir iso/boot/grub
cp target/i686-unknown-none/glos2 iso/boot/glos
writefile iso/boot/grub/grub.cfg "set timeout=0\nset default=0\nmenuentry \"glOS\" {\nmultiboot2 /boot/glos\nboot\n}"
exec grub-mkrescue -o glos.iso iso
rm -r iso
rm target/i686-unknown-none/glos2
'''
[tasks.clean]
command = "cargo"
args = ["clean"]
[tasks.run]
dependencies = ["create-iso"]
command = "qemu-system-i386"
args = ["-d", "int,pcall,cpu_reset", "-D", "log.txt", "-cdrom", "glos.iso", "-no-reboot", "-no-shutdown", "-M", "smm=off"]
[tasks.run-debug]
dependencies = ["create-iso"]
command = "qemu-system-i386"
args = ["-d", "int,pcall,cpu_reset", "-D", "log.txt", "-cdrom", "glos.iso", "-no-reboot", "-no-shutdown", "-M", "smm=off", "-s", "-S"]
[tasks.dev]
dependencies = [
"build-dev",
"run"
]
[tasks.debug]
dependencies = [
"build-debug",
"run-debug"
]
[tasks.release]
dependencies = [
"build-rls",
"create-iso"
]
[tasks.check]
command = "cargo"
args = ["deny", "check"]