[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: syslinux vesamenu



I've finished and tested the debian-cd patch for using vesamenu. Did
notice one problem. When the vesamenu is used, "default64" does not
behave the same as it normally does in syslinux. Rather than setting the
default that's used then enter is pressed, it makes syslinux
*immediately* start booting the amd64 installer with no chance for
interaction.

So unless it gets fixed[1], default64 can't be used on vesamenu images,
and I've disabled it. Instead, you need to manually pick amd64 off the
menu when booting a multiarch image.

Is this a big problem? At least there is a menu, with "AMD64 install"
visible on it. (Maybe that would be better named "64 bit install" to
avoid the amd/ia64/x86_64 confusion..)

I've created 3 test CD images that use vesamenu:

http://kitenet.net/~joey/tmp/vesamenu/

My feeling is that this is basically ready to go and is quite unlikely
to break anything in the beta2 timeframe if applied soon.


PS, the win32-loader.ini file on the multi-arch CDs lists kernel/initrd
images for amd64, but not for i386. Seems wrong.

-- 
see shy jo

[1] IIRC I reported this upstream last fall..
Index: tools/boot/lenny/boot-x86
===================================================================
--- tools/boot/lenny/boot-x86	(revision 1585)
+++ tools/boot/lenny/boot-x86	(working copy)
@@ -180,17 +180,33 @@
 		extra_image gtk/initrd.gz
 		mv boot$N/$ISOLINUXDIR/f3.txt.withgtk boot$N/$ISOLINUXDIR/f3.txt
 		mv boot$N/$ISOLINUXDIR/f4.txt.withgtk boot$N/$ISOLINUXDIR/f4.txt
-		mv boot$N/$ISOLINUXDIR/isolinux.cfg.withgtk boot$N/$ISOLINUXDIR/isolinux.cfg
+		if [ -e boot$N/$ISOLINUXDIR/isolinux.cfg.withgtk ]; then
+			mv boot$N/$ISOLINUXDIR/isolinux.cfg.withgtk boot$N/$ISOLINUXDIR/isolinux.cfg
+		fi
+	else
+		# Remove gtk isolinux config files.
+		rm -f boot$N/$ISOLINUXDIR/gtk.cfg
+		rm -f boot$N/$ISOLINUXDIR/amdgtk.cfg
 	fi
 	rm -f boot$N/$ISOLINUXDIR/isolinux.cfg.with* 2>/dev/null || true
 
-	sed -i "s|/install/|/$INSTALLDIR/|" boot$N/$ISOLINUXDIR/isolinux.cfg
+	for f in isolinux.cfg text.cfg gtk.cfg; do
+		if [ -e boot$N/$ISOLINUXDIR/$f ]; then
+			sed -i "s|/install/|/$INSTALLDIR/|" boot$N/$ISOLINUXDIR/$f
+		fi
+	done
+	for f in amd.cfg amdgtk.cfg; do
+		if [ -e boot$N/$ISOLINUXDIR/$f ]; then
+			sed -i "s|/install/|/$INSTALLDIR_amd64/|" boot$N/$ISOLINUXDIR/$f
+		fi
+	done
 
 	if [ -e boot$N/win32-loader.ini ] ; then
 	    sed -i "s|install/|$INSTALLDIR/|" boot$N/win32-loader.ini
 	fi
 
 	cp -f $BASEDIR/data/$DI_CODENAME/isolinux.bin boot$N/$ISOLINUXDIR/
+	cp -f $BASEDIR/data/$DI_CODENAME/vesamenu.c32 boot$N/$ISOLINUXDIR/
 
 	if [ -n "$KERNEL_PARAMS" ]; then
 		# Substitute custom kernel params into the isolinux config
@@ -213,11 +229,20 @@
 			mv $file.tmp $file
 		done
 
-		cat boot$N/isolinux-amd64/isolinux.cfg | awk '
-			/^[Ll][Aa][Bb][Ee][Ll]/ { printf("label amd64-%s\n", $2) }
-			/^[Dd][Ee][Ff][Aa][Uu][Ll][Tt]/ { printf("default64 amd64-%s\n", $2) }
-			/[Kk][Ee][Rr][Nn][Ee][Ll]/ { print $0 }
-			/[Aa][Pp][Pp][Ee][Nn][Dd]/ { print $0 }' >> boot$N/isolinux/isolinux.cfg
+		if [ -e boot$N/isolinux/amd.cfg ]; then
+			# Split isolinux configs exist, so the amd.cfg will
+			# be loaded and set things up for amd64. No munging
+			# needed.
+			:
+		else 
+			# This is compatability code for old versions of d-i that
+			# do not use split isolinux configs.
+			cat boot$N/isolinux-amd64/isolinux.cfg | awk '
+				/^[Ll][Aa][Bb][Ee][Ll]/ { printf("label amd64-%s\n", $2) }
+				/^[Dd][Ee][Ff][Aa][Uu][Ll][Tt]/ { printf("default64 amd64-%s\n", $2) }
+				/[Kk][Ee][Rr][Nn][Ee][Ll]/ { print $0 }
+				/[Aa][Pp][Pp][Ee][Nn][Dd]/ { print $0 }' >> boot$N/isolinux/isolinux.cfg
+		fi
 
 		sed -i -e "/^arch=/d ; /^i386\//p; s/^i386\//amd64\//; s/=$INSTALLDIR_i386\//=$INSTALLDIR_amd64\//g" \
 			boot$N/win32-loader.ini
@@ -227,8 +252,16 @@
 		        mkdir -p boot$N/isolinux
 			mv -f boot$N/isolinux-amd64/* boot$N/isolinux
 		fi
-		rm -rf boot$N/isolinux-amd64
+
+		if [ -e boot$N/isolinux/amd.cfg ]; then
+			# Split isolinux configs exist. Remove the amd.cfg
+			# to avoid it being loaded on a disc that does not
+			# have both amd64 and i386 dirs.
+			rm -f boot$N/isolinux/amd.cfg
+			rm -f boot$N/isolinux/amdgtk.cfg
+		fi
 	fi
+	rm -rf boot$N/isolinux-amd64
 	
 	if [ "$SPLASHPNG" ] ; then
 		# Insert our own splash screen.  Color index 0 is
Index: data/lenny/isolinux.bin
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Index: data/lenny/vesamenu.c32
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: data/lenny/vesamenu.c32
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream

Attachment: signature.asc
Description: Digital signature


Reply to: