diff --git a/README.md b/README.md index e453605..25b0548 100644 --- a/README.md +++ b/README.md @@ -6,13 +6,13 @@ - Assembles with FASM - We'll probably use ext2 filesystem - ## GRUB disk creation +## GRUB disk creation 1. Format disk. Create ext2 partition 2. Create directory mnt and mount your partition to it ``` mkdir mnt - sudo mount /dev/sdX mnt + sudo mount /dev/sdX1 mnt ``` 3. Intall grub using `sudo grub-install --target=i386-pc --removable --boot-dir=mnt/boot /dev/sdX` 4. Create config @@ -22,10 +22,36 @@ boot } ``` -5. Copy assembled kernel to `mnt/boot/roska.bin` - + 5. Copy assembled kernel to `mnt/boot/roska.bin` +## extlinux disk creation + 1. Format disk. Create ext2 partition and mark it active boot partition. + 2. Add syslinux to bootloader + `sudo dd if=/usr/lib/syslinux/bios/mbr.bin of=/dev/sdX` + 3. Create directory mnt and mount your partition to it. Add boot directory to it. + ``` + mkdir mnt + sudo mount /dev/sdX1 mnt + sudo mkdir mnt/boot + ``` + 4. Install extlinux(syslinux) + ``` + sudo extlinux --install --device /dev/sdX1 mnt/boot + sudo cp /usr/lib/syslinux/bios/libcom32.c32 mnt/boot/ + sudo cp /usr/lib/syslinux/bios/mboot.c32 mnt/boot/ + ``` + 5. Create config + ``` mnt/boot/syslinux.cfg + DEFAULT rOSka + LABEL rOSka + SAY extlinux is booting rOSka... + KERNEL /boot/mboot.c32 + APPEND /boot/roska.bin + ``` + 6. Copy assembled kernel to `mnt/boot/roska.bin` + 7. Have no video because naughty implementation doesn't tell + us the framebuffer address :(