-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuildwin.bat
More file actions
44 lines (34 loc) · 944 Bytes
/
buildwin.bat
File metadata and controls
44 lines (34 loc) · 944 Bytes
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
@echo off
echo Build script for Windows
echo.
echo Assembling bootloader...
cd source\bootload
nasm -O0 -f bin -o bootload.bin bootload.asm
cd ..
echo Assembling the kernel...
nasm -O0 -f bin -o kernel.bin kernel.asm
echo Assembling programs...
cd ..\programs
for %%i in (*.asm) do nasm -O0 -f bin %%i
for %%i in (*.bin) do del %%i
for %%i in (*.) do ren %%i %%i.bin
cd ..
echo Adding bootsector to disk image...
cd disk_images
..\btools\dd.exe count=2 seek=0 bs=512 if=..\source\bootload\bootload.bin of=.\QroOS.flp
cd ..
echo Mounting disk image...
imdisk -a -f disk_images\QroOS.flp -s 1440K -m B:
echo Copying kernel and applications to disk image...
copy source\kernel.bin b:\
copy programs\*.bin b:\
copy programs\*.bas b:\
echo Copying precompiled programs
copy precompiled\*.bin b:\
echo Dismounting disk image...
imdisk -D -m B:
echo Clearing build leftovers...
cd programs
for %%i in (*.bin) do del %%i
cd ..
echo Done!