diff options
| -rw-r--r-- | meta/recipes-bsp/grub/grub-efi_2.06.bb | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/meta/recipes-bsp/grub/grub-efi_2.06.bb b/meta/recipes-bsp/grub/grub-efi_2.06.bb index df5f23e22e..9857e8e036 100644 --- a/meta/recipes-bsp/grub/grub-efi_2.06.bb +++ b/meta/recipes-bsp/grub/grub-efi_2.06.bb | |||
| @@ -46,11 +46,21 @@ EXTRA_OECONF += "--enable-efiemu=no" | |||
| 46 | 46 | ||
| 47 | do_mkimage() { | 47 | do_mkimage() { |
| 48 | cd ${B} | 48 | cd ${B} |
| 49 | |||
| 50 | GRUB_MKIMAGE_MODULES="${GRUB_BUILDIN}" | ||
| 51 | |||
| 52 | # If 'all' is included in GRUB_BUILDIN we will include all available grub2 modules | ||
| 53 | if [ "${@ bb.utils.contains('GRUB_BUILDIN', 'all', 'True', 'False', d)}" = "True" ]; then | ||
| 54 | bbdebug 1 "Including all available modules" | ||
| 55 | # Get the list of all .mod files in grub-core build directory | ||
| 56 | GRUB_MKIMAGE_MODULES=$(find ${B}/grub-core/ -type f -name "*.mod" -exec basename {} .mod \;) | ||
| 57 | fi | ||
| 58 | |||
| 49 | # Search for the grub.cfg on the local boot media by using the | 59 | # Search for the grub.cfg on the local boot media by using the |
| 50 | # built in cfg file provided via this recipe | 60 | # built in cfg file provided via this recipe |
| 51 | grub-mkimage -c ../cfg -p ${EFIDIR} -d ./grub-core/ \ | 61 | grub-mkimage -v -c ../cfg -p ${EFIDIR} -d ./grub-core/ \ |
| 52 | -O ${GRUB_TARGET}-efi -o ./${GRUB_IMAGE_PREFIX}${GRUB_IMAGE} \ | 62 | -O ${GRUB_TARGET}-efi -o ./${GRUB_IMAGE_PREFIX}${GRUB_IMAGE} \ |
| 53 | ${GRUB_BUILDIN} | 63 | ${GRUB_MKIMAGE_MODULES} |
| 54 | } | 64 | } |
| 55 | 65 | ||
| 56 | addtask mkimage before do_install after do_compile | 66 | addtask mkimage before do_install after do_compile |
| @@ -70,6 +80,7 @@ do_install() { | |||
| 70 | install -m 644 ${B}/${GRUB_IMAGE_PREFIX}${GRUB_IMAGE} ${D}${EFI_FILES_PATH}/${GRUB_IMAGE} | 80 | install -m 644 ${B}/${GRUB_IMAGE_PREFIX}${GRUB_IMAGE} ${D}${EFI_FILES_PATH}/${GRUB_IMAGE} |
| 71 | } | 81 | } |
| 72 | 82 | ||
| 83 | # To include all available modules, add 'all' to GRUB_BUILDIN | ||
| 73 | GRUB_BUILDIN ?= "boot linux ext2 fat serial part_msdos part_gpt normal \ | 84 | GRUB_BUILDIN ?= "boot linux ext2 fat serial part_msdos part_gpt normal \ |
| 74 | efi_gop iso9660 configfile search loadenv test" | 85 | efi_gop iso9660 configfile search loadenv test" |
| 75 | 86 | ||
