home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2003 July
/
Chip_2003-07_cd1.bin
/
tema
/
aos
/
download
/
SKY397.ZIP
/
tools
/
mkboot.bat
next >
Wrap
DOS Batch File
|
2003-04-19
|
1KB
|
68 lines
@echo off
if "%1" == "" goto usage
if "%2" == "" goto usage
echo Warning! You are about to install the bootcode %1 to drive %2:
echo Continue? (CRTL+BREAK to cancel)
pause > NUL
:ok
if "%1" == "FAT12" goto FAT12
if "%1" == "FAT16" goto FAT16
if "%1" == "SKYFS" goto SKYFS
if "%1" == "GRUB" goto GRUB
goto usage
:FAT12
call partcopy \skyos\system\bootcode.f12 0 3 -a%2
call partcopy \skyos\system\bootcode.f12 3e 1c2 -a%2 3e
goto end
:FAT16
call partcopy \skyos\system\bootcode.f16 0 3 -a%2
call partcopy \skyos\system\bootcode.f16 3e 1c2 -a%2 3e
goto end
:SKYFS
call partcopy \skyos\system\bootcode.sfs 0 512 -a%2
goto end
:GRUB
if "%2" == "a" goto grub_floppy
if "%2" == "b" goto grub_floppy
if "%2" == "A" goto grub_floppy
if "%2" == "B" goto grub_floppy
:grub_harddisk
echo.
echo.
echo GRUB harddisk installation not supported
echo.
echo.
goto end
:grub_floppy
echo.
echo Creating bootdisk image....
call partcopy ..\system\bootimg\floppy\grub\floppy.img 0 168000 -a%2
echo Done.
goto end
:usage
echo Use:
echo mkboot.bat [Type] [drive]
echo.
echo Where Type is one of the following filesystems:
echo FAT16
echo SKYFS
echo.
echo Drive is something like: A,B,C,D,....Z
echo.
goto done
:end
echo.
echo Bootloader installed successfully.
echo.
:done