-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathmake.cmd
30 lines (26 loc) · 800 Bytes
/
make.cmd
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
@echo off
set args=%1
goto main
:help
echo usage: ./make.cmd [option]
echo Options:
echo - run: Compile with docker and launch QEMU.
echo - compile: Compile with docker.
echo - clean: Clean project with wsl
echo - qemu: Only launch QEMU
exit
:main
if "%~1"=="" (
goto help
) else (
if "%1" == "run" (
docker-compose up
qemu-system-i386 -device e1000,netdev=net0 -serial stdio -netdev user,id=net0 -object filter-dump,id=net0,netdev=net0,file=dump.dat -d cpu_reset -D ./log.txt boot.img
) else if "%1" == "compile" (
docker-compose up
) else if "%1" == "clean" (
wsl sudo make clean
) else if "%1" == "qemu" (
qemu-system-i386 -device e1000,netdev=net0 -serial stdio -netdev user,id=net0 -object filter-dump,id=net0,netdev=net0,file=dump.dat -d cpu_reset -D ./log.txt boot.img
)
)