aboutsummaryrefslogtreecommitdiff
path: root/projects/grub/grub-helper
Commit message (Collapse)AuthorAgeFilesLines
* Copy correct number of bytes for floppy BPBAndrew Robbins2018-12-291-1/+1
| | | | | | | | The Bios Parameter Block (BPB) is 51 bytes, not 52. As-is, the first byte of executable code from the floppy image boot record is copied along with the BPB to boot.img; this extra byte isn't harmful to leave in since execution begins at offset 0x63+2 rather than 0x3C+2, but is a little messy.
* Trim some less useful comments in grub-helperAndrew Robbins2018-12-281-4/+0
|
* Remove extraneous radix specifier in grub_bo_dump()Andrew Robbins2018-12-281-1/+1
|
* Use tabs for indentation in grub_bo functionsAndrew Robbins2018-12-281-13/+13
|
* Automate updating SeaGRUB floppy image blocklistsAndrew Robbins2018-12-251-1/+95
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Related issue #553 Determining the byte offset of core.img on the SeaGRUB floppy is accomplished using grub_bo(), though it is memory bound as it requires reading hex dumps for the pattern and comparand into memory. The blocklists that are stored in the boot record and core.img are sector numbers. Of particular note is the blocklist written to core.img is always the location of its *second* sector--not the first. Blocklists are used because floppy disks DO NOT have an MBR or MBR gap as the filesystem spans the entire disk. Consequently, the core.img cannot be stored in the usual ~1MiB gap. Unfortunately, using blocklists means they will have to be updated whenever core.img is moved. New functions added to grub-helper: * grub_bo * grub_bo_dump * grub_bo_search * grub_blocklist_format * grub_blocklist_generate * grub_floppy_image_make_bootable * grub_floppy_image_update_blocklists
* Refactor SeaGRUB floppy creation codeAndrew Robbins2018-12-251-28/+44
| | | | | | | | | | | | | | | | | | | Related issue #553 Previously, the GRUB boot image and core image were concatenated together and padding added to create a (pseudo) floppy image. However, testing revealed that GRUB has issues dynamically loading modules from $prefix if $prefix is not located on the same device from which GRUB booted. In order to get around this issue, a proper 2.88MiB floppy image is created using mkfs.fat with GRUB modules copied to directories on the filesystem (i.e, /boot/grub/i386-pc). The 2.88MiB filesystem size is necessary to be able to fit all modules onto the image. New functions added to grub-helper: * grub_floppy_image_mmd (create directories on image using mtools mmd) * grub_floppy_image_mcopy (copy files to image using mtools mcopy)
* Be specific about size limit for floppy GRUB imageAndrew Robbins2018-04-071-1/+1
|
* Include modules from modules-minimal in GRUB imageAndrew Robbins2018-04-071-2/+8
|
* Remove braces from parameter expansionsAndrew Robbins2017-09-211-78/+78
| | | | | | | * projects/grub/grub * projects/grub/grub-helper ditto
* Make a few minor tweaks to the grub-helper scriptAndrew Robbins2017-09-141-2/+9
| | | | | | The check for an existing, non-directory file as $keymap_out_path was added to prevent the (unlikely) scenario of attempting writing a file to a file as if it were a directory.
* Create grub-helper function grub_build_fontAndrew Robbins2017-09-061-0/+26
| | | | | | The idea is to build a font from source and then make a PF2 format file from it using grub-mkfont. This cuts down on the number of binary files committed to history in the repository.
* Conditionally create dir to store compiled keymapsAndrew Robbins2017-09-021-1/+6
|
* Use grub-mklayout instead of grub-kbdcompAndrew Robbins2017-09-021-2/+2
| | | | | | grub-mklayout was the intended program to use for generating compiled GRUB keylayouts. Somewhere along the way grub-kbdcomp was erroneously substituted in its place.
* Add grub-helper scriptAndrew Robbins2017-08-291-0/+174