-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.bat
58 lines (41 loc) · 1.04 KB
/
build.bat
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
@echo off
mkdir bin\
cd source
echo * Building bootload *
nasm bootload.asm -f bin -o ..\bin\bootload.bin
if %errorlevel% neq 0 goto fail
echo * Building kernel *
nasm kernel.asm -f bin -o ..\bin\kernel.bin
if %errorlevel% neq 0 goto fail
cd ..\programs
echo * Building 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 ..
del bin\felipos.flp
echo * Adding bootload to disk image *
copy bin\bootload.bin bin\felipos.flp
echo * Mounting image *
imdisk -a -f bin\felipos.flp -s 1440K -m B:
echo * Copying kernel.bin *
copy bin\kernel.bin b:\
echo * Copying programs *
copy programs\*.bin b:\
echo test > b:\test.txt
copy ..\mikeos\edit.bin b:\
copy ..\mikeos\fileman.bin b:\
copy ..\mikeos\fisher.bin b:\
copy ..\mikeos\forth.bin b:\
copy ..\mikeos\hangman.bin b:\
copy ..\mikeos\keyboard.bin b:\
copy ..\mikeos\monitor.bin b:\
copy ..\mikeos\serial.bin b:\
copy ..\mikeos\viewer.bin b:\
dir b:
echo * Dismounting image *
imdisk -D -m B:
goto end
:fail
echo Failed to build
:end