forked from hcchengithub/eforth-x86-64bits
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build26.bat
44 lines (37 loc) · 1.57 KB
/
build26.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
@rem This program merge MBR, eforth64 binary, and high level forth source code into a floppy image
@rem hcchen5600 2011/08/13 21:52:26
@rem mbr.bin is compiled from mbr.asm by NASM
@rem eforth64.bin is compiled from eforth64.asm by NASM
@rem Track1complement.bin is constant also generated by NASM
@rem All following forth code source is up to you
@rem
if not exist MBR.bin echo MBR.bin not found && goto :abort
if not exist eforth64.bin echo eforth64.bin not found && goto :abort
if not exist floppyfill.bat echo floppyfill.bat not found && goto :abort
if not exist Track1complement.bin echo Track1complement.bin not found && goto :abort
set source=00_constants.f
set source=%source%+01_basics_p1.f
set source=%source%+015_disasm_p1.f
set source=%source%+02_assembler.f
set source=%source%+025_disasm_p2.f
set source=%source%+03_codewords.f
set source=%source%+04_console.f
set source=%source%+05_basics_p2.f
set source=%source%+06_isr.f
set source=%source%+07_basics_p3.f
set source=%source%+08_debug_registers.f
set source=%source%+eforth64.f560026
copy /b /y MBR.bin+Track1complement.bin !track1.img
copy /b /y !track1.img+eforth64.bin !kernel.img
copy /b /y !kernel.img+%source% eforth64.img
rem Auto generate floppyfill.bin to complete the floppy image
del floppyfill.bin
del floppyfill.asm
call floppyfill.bat eforth64.img > floppyfill.asm
nasm floppyfill.asm -o floppyfill.bin
if not exist floppyfill.bin echo floppyfill.bin not found compiling floppyfill.asm was failed && goto :abort
copy /b /y eforth64.img+floppyfill.bin floppy.img
goto bye
:abort
echo !!!!! A B O R T E D !!!!!!!!
:bye