* Fixed a whitespace issue
* Removed deprecated '-q' from depmod
* Changed naming scheme on x86 from vmlinuz_ to vmlinux- to allow grub-mkconfig to pick it up * If the directory $root/boot/grub exists, update grub.cfg using grub-mkconfig, instead of yolo'ing it

The last change *may* break things if grub was not installed using the industry-standard grub-install (i.e. the default mess STONE creates) To fix this (to make sure grub is installed correctly, with all the modules):

For MBR-systems:

grub-install --target=i386-pc /dev/<rootdrive> (e.g. /dev/sda)

For EFI-systems

grub-install --efi-directory=/boot --bootloader-id="T2 Linux" (or wherever the EFI system partition is mounted)

Index: package/base/linux/linux.conf
===================================================================
--- package/base/linux/linux.conf	(revision 51429)
+++ package/base/linux/linux.conf	(working copy)
@@ -91,7 +91,7 @@
 	cp -vf vmlinux $root/boot/vmlinux_${lx_kernelrelease}
 	case "$lx_cpu" in
 	  i386|x86_64|x86)
-		cp -vf arch/${lx_cpu}/boot/bzImage $root/boot/vmlinuz_${lx_kernelrelease}
+		cp -vf arch/${lx_cpu}/boot/bzImage $root/boot/vmlinuz-${lx_kernelrelease}
 		;;
 	  avr32)
 		cp -vf arch/${lx_cpu}/boot/images/uImage $root/boot/uImage_${lx_kernelrelease}
@@ -128,7 +128,7 @@
 	if grep -q "CONFIG_MODULES=y" .config; then
 		module_error=0
 		echo "Building registered 3rd party module packages ..."
-	  	for x in $lx_3rd_party_modules; do
+		for x in $lx_3rd_party_modules; do
 		  echo "Sub-building 3rd party module package $x ..."
 		  pushd $builddir
 		  # ugly, bash does not abort properly when we have this in a if
@@ -153,7 +153,7 @@
 		local depmod="depmod"
 		atstage native || depmod="${archprefix}depmod"
 		echo "Running $depmod -a -b $root/ ..."
-		$depmod -a -b $root/ -q -F $root/boot/System.map_${lx_kernelrelease} ${lx_kernelrelease}
+		$depmod -a -b $root/ -F $root/boot/System.map_${lx_kernelrelease} ${lx_kernelrelease}
 
 		# due "mostly" static depmod :-(
 		for x in $moduledir/modules.*
@@ -187,4 +187,13 @@
 	 done
 	)
 }
+
+update_bootloader() {
+	echo "Updating bootloader..."
+        if [ -d $root/boot/grub ]; then
+                grub-mkconfig -o $root/boot/grub/grub.cfg
+        fi
+}
+
 hook_add postmake 5 linux_install
+hook_add postmake 5 update_bootloader
----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
li...@t2-project.org with a subject of: unsubscribe t2

Reply via email to