User talk:Asyring
Jump to navigation
Jump to search
Grub on u-boot on Cubietruck
Using mainline u-boot (2015-04)
Installing grub-uboot
Getting source
apt-get source grub-uboot
Changing load address
--- grub2-2.02~beta2.orig/grub-core/Makefile.core.def +++ grub2-2.02~beta2/grub-core/Makefile.core.def @@ -95,5 +95,5 @@ kernel = { i386_qemu_cppflags = '-DGRUB_BOOT_MACHINE_LINK_ADDR=$(GRUB_BOOT_MACHINE_LINK_ADDR)'; emu_cflags = '$(CFLAGS_GNULIB)'; emu_cppflags = '$(CPPFLAGS_GNULIB)'; - arm_uboot_ldflags = '-Wl,-Ttext=0x08000000'; + arm_uboot_ldflags = '-Wl,-Ttext=0x40008000'; arm_uboot_stripflags = '--strip-unneeded -K start -R .note -R .comment -R .note.gnu.gold-version';
--- grub2-2.02~beta2.orig/include/grub/offsets.h +++ grub2-2.02~beta2/include/grub/offsets.h @@ -121,3 +121,3 @@ #define GRUB_KERNEL_ARM_UBOOT_MOD_ALIGN 0x8 #define GRUB_KERNEL_ARM_UBOOT_TOTAL_MODULE_SIZE 0x4 -#define GRUB_KERNEL_ARM_UBOOT_LINK_ADDR 0x08000000 +#define GRUB_KERNEL_ARM_UBOOT_LINK_ADDR 0x40008000
make changes to source
cd grub2-2.02~beta2 dpkg-source --commit cd ..
build package
apt-get -b source grub-uboot