aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexandru Ardelean <ardeleanalex@gmail.com>2016-11-23 10:27:55 +0200
committerFelix Fietkau <nbd@nbd.name>2016-12-20 16:24:21 +0100
commit81a2f9d6f8612e5f0f440a9690a711d1c2d3fbc5 (patch)
tree33359e445674868c4daec6fcbda5dabb5967535f
parent65c8f2890ca4f41f5b933b5bc1e43de86cc1bd54 (diff)
downloadupstream-81a2f9d6f8612e5f0f440a9690a711d1c2d3fbc5.tar.gz
upstream-81a2f9d6f8612e5f0f440a9690a711d1c2d3fbc5.tar.bz2
upstream-81a2f9d6f8612e5f0f440a9690a711d1c2d3fbc5.zip
target/linux/x86/image: add explicit prefix to grub-mkimage command
In the latest version of grub-mkimage, the prefix option is mandatory. Not supplying it fails with: ``` Prefix not specified (use the -p option). ``` In grub-2.02-beta2 a DEFAULT_DIRECTORY was defined in `include/grub/osdep/hostfile_unix.h` as: ``` #if defined (__NetBSD__) /* NetBSD uses /boot for its boot block. */ # define DEFAULT_DIRECTORY "/"GRUB_DIR_NAME #else # define DEFAULT_DIRECTORY "/"GRUB_BOOT_DIR_NAME"/"GRUB_DIR_NAME #endif ``` Where: * GRUB_BOOT_DIR_NAME == boot * GRUB_DIR_NAME == grub This was used if the -p option was omitted. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
-rw-r--r--target/linux/x86/image/Makefile2
1 files changed, 2 insertions, 0 deletions
diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile
index 99887cb32b..965737ac63 100644
--- a/target/linux/x86/image/Makefile
+++ b/target/linux/x86/image/Makefile
@@ -68,6 +68,7 @@ ifneq ($(CONFIG_GRUB_IMAGES),)
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
grub-mkimage \
+ -p /boot/grub \
-d $(STAGING_DIR_HOST)/lib/grub/i386-pc \
-o $(KDIR)/grub2/core.img \
-O i386-pc \
@@ -106,6 +107,7 @@ define Image/Build/iso
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
grub-mkimage \
+ -p /boot/grub \
-d $(STAGING_DIR_HOST)/lib/grub/i386-pc \
-o $(KDIR)/grub2/eltorito.img \
-O i386-pc \