[iso] add support for distros using a NONSTANDARD GRUB 2.0 prefix directory

* Looking at you, openSUSE Live and GeckoLinux!
This commit is contained in:
Pete Batard 2022-04-07 01:57:24 +01:00
parent f669f05403
commit 3528ca773d
No known key found for this signature in database
GPG key ID: 38E0CF5E69EDD671
7 changed files with 139 additions and 17 deletions

View file

@ -384,7 +384,7 @@ typedef struct {
BOOLEAN has_efi_syslinux;
BOOLEAN needs_syslinux_overwrite;
BOOLEAN has_grub4dos;
BOOLEAN has_grub2;
uint8_t has_grub2;
BOOLEAN has_compatresources_dll;
BOOLEAN has_kolibrios;
BOOLEAN uses_casper;
@ -666,6 +666,23 @@ extern void StrArrayClear(StrArray* arr);
extern void StrArrayDestroy(StrArray* arr);
#define IsStrArrayEmpty(arr) (arr.Index == 0)
/* Patch structs for GRUB */
typedef struct {
const uint32_t offset;
const uint32_t size;
const uint8_t data[];
} chunk_t;
typedef struct {
const chunk_t* src;
const chunk_t* rep;
} patch_t;
typedef struct {
const char* version;
const patch_t patch[2];
} grub_patch_t;
/*
* typedefs for the function prototypes. Use the something like:
* PF_DECL(FormatEx);