if [ -f autoexec.bat ]; then rm -rf autoexec.bat; fi
if [ -f $@ ]; then rm -rf $@; fi
+ echo @echo off >> autoexec.bat
echo set PATH=A:\\DOS >> autoexec.bat
+# echo '%PATH%\\temp.bat' >> autoexec.bat
# echo echo 123 >> temp.bat
-# echo @ echo %PATH% >> temp.bat
-# echo temp.bat >> temp.bat
+# echo echo %PATH% >> temp.bat
+# echo temp >> temp.bat
utils/dosfstools/mkdosfs --boot boot/freeldr/bootsect/fat12.bin --sectors 720 -F 12 -n "CHIMAERA OS" $@
utils/dosfstools/mmd -i $@ boot boot/freeldr
if [ -f autoexec.bat ]; then rm -rf autoexec.bat; fi
if [ -f $@ ]; then rm -rf $@; fi
+ echo @echo off >> autoexec.bat
echo set PATH=C:\\DOS >> autoexec.bat
# echo echo %PATH% >> autoexec.bat
# echo autoexec.bat >> autoexec.bat
.L5:
+ mov ax, cs:[_echo_line]
+ mov word ptr [bp - 4], ax
+
+.L119:
+
push es
push di
push cx
pop di
pop es
- jmp .L5
+ jmp .L119
.L111:
mov word ptr [_scratch_list], 0
+ mov ax, word ptr [bp - 4]
+ mov cs:[_echo_line], ax
+
pop cx
pop di
pop es
push ax
push dx
push si
-
+ push es
+ push ds
+
mov si, bx
+_handler_echo.copy:
+
+ push es
+ push ds
+ push si
+ push di
+
+ mov ax, cs
+ mov es, ax
+
+ mov di, offset _temp
+ push si
+
+ call _strlen
+ add sp, 2
+
+ mov cx, ax
+ rep movsb
+
+ xor al, al
+ stosb
+
+ pop di
+ pop si
+ pop ds
+ pop es
+
+ mov ax, cs
+ mov ds, ax
+
+ mov si, offset _temp
+
+_handler_echo.check_off:
+
+ push si
+
+ mov ax, offset _echo_off
+ push ax
+
+ call _strcmp
+ add sp, 4
+
+ and ax, ax
+ jnz _handler_echo.check_on
+
+ mov word ptr cs:[_echo_line], 0
+ jmp _handler_echo.done
+
+_handler_echo.check_on:
+
+ push si
+
+ mov ax, offset _echo_on
+ push ax
+
+ call _strcmp
+ add sp, 4
+
+ and ax, ax
+ jnz _handler_echo.check
+
+ mov word ptr cs:[_echo_line], 1
+ jmp _handler_echo.done
+
_handler_echo.check:
cmp word ptr cs:[_cbreak], 1
_handler_echo.done:
+ pop ds
+ pop es
pop si
pop dx
pop ax
_autoexec: db "AUTOEXEC.BAT", HEX (00)
_batch_flags: db "r", HEX (00)
+_echo_off: db "off", HEX (00)
+_echo_on: db "on", HEX (00)
+
_echo_line: dw HEX (0001)
_in_batch: dw HEX (0000)
_ll_scratch: dw HEX (0000)