summaryrefslogtreecommitdiff
path: root/target/linux/x86/image/Makefile
diff options
context:
space:
mode:
authorNicolas Thill <nico@openwrt.org>2010-05-02 17:32:25 +0000
committerNicolas Thill <nico@openwrt.org>2010-05-02 17:32:25 +0000
commit3bca4b20946d11b40219db34b66ac6c59c603525 (patch)
tree032a5749d3f3683a773b36661b5204da508a5a13 /target/linux/x86/image/Makefile
parent08be2bcfd99a2bf96fb3618db3572fdabd122716 (diff)
downloadmtk-20170518-3bca4b20946d11b40219db34b66ac6c59c603525.zip
mtk-20170518-3bca4b20946d11b40219db34b66ac6c59c603525.tar.gz
mtk-20170518-3bca4b20946d11b40219db34b66ac6c59c603525.tar.bz2
package/grub: build a host grub and a target grub (#7269) - use the host grub binary for grub install, but with target stage files - disable SSP (-fno-stack-protector) & Compile Time Buffer Checks (-U_FORTIFY_SOURCE) if appropriate - create a target grub package
SVN-Revision: 21305
Diffstat (limited to 'target/linux/x86/image/Makefile')
-rw-r--r--target/linux/x86/image/Makefile15
1 files changed, 9 insertions, 6 deletions
diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile
index 912dae2..257723c 100644
--- a/target/linux/x86/image/Makefile
+++ b/target/linux/x86/image/Makefile
@@ -56,7 +56,9 @@ ifneq ($(CONFIG_X86_GRUB_IMAGES),)
# left here because the image builder doesnt need these
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub
$(CP) \
- $(KDIR)/*stage* \
+ $(KDIR)/stage1 \
+ $(KDIR)/stage2 \
+ $(KDIR)/e2fs_stage1_5 \
$(KDIR)/root.grub/boot/grub/
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
sed \
@@ -74,9 +76,10 @@ ifneq ($(CONFIG_X86_GRUB_IMAGES),)
define Image/Prepare/grub
# for the image builder
$(CP) \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-*/stage1 \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-*/stage2 \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-*/e2fs_stage1_5 \
+ $(STAGING_DIR)/usr/lib/grub/i386-openwrt/stage1 \
+ $(STAGING_DIR)/usr/lib/grub/i386-openwrt/stage2 \
+ $(STAGING_DIR)/usr/lib/grub/i386-openwrt/stage2_eltorito \
+ $(STAGING_DIR)/usr/lib/grub/i386-openwrt/e2fs_stage1_5 \
$(KDIR)/
endef
@@ -135,8 +138,8 @@ endef
define Image/Build/iso
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub
$(CP) \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-openwrt/stage2_eltorito \
- $(KDIR)/root.grub/boot/grub/stage2_eltorito
+ $(KDIR)/stage2_eltorito \
+ $(KDIR)/root.grub/boot/grub/
sed \
-e 's#@SERIAL_CONFIG@#$(strip $(GRUB_SERIAL_CONFIG))#g' \
-e 's#@TERMINAL_CONFIG@#$(strip $(GRUB_TERMINAL_CONFIG))#g' \