From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1X21PU-0001XG-54 for mharc-grub-devel@gnu.org; Tue, 01 Jul 2014 13:00:00 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53359) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X21PJ-0001VB-HJ for grub-devel@gnu.org; Tue, 01 Jul 2014 12:59:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X21PA-0007VL-Qk for grub-devel@gnu.org; Tue, 01 Jul 2014 12:59:49 -0400 Received: from userp1040.oracle.com ([156.151.31.81]:17137) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X21PA-0007VF-Ji for grub-devel@gnu.org; Tue, 01 Jul 2014 12:59:40 -0400 Received: from acsinet22.oracle.com (acsinet22.oracle.com [141.146.126.238]) by userp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id s61Gxb8G013492 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 1 Jul 2014 16:59:39 GMT Received: from aserz7022.oracle.com (aserz7022.oracle.com [141.146.126.231]) by acsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id s61Gxbn5006094 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 1 Jul 2014 16:59:37 GMT Received: from abhmp0008.oracle.com (abhmp0008.oracle.com [141.146.116.14]) by aserz7022.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id s61GxbpL006087 for ; Tue, 1 Jul 2014 16:59:37 GMT Received: from sheep.uk.oracle.com (/10.167.241.51) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 01 Jul 2014 09:59:37 -0700 Message-ID: <53B2E8F7.2000405@oracle.com> Date: Tue, 01 Jul 2014 17:59:35 +0100 From: John Haxby User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: The development of GNU GRUB Subject: Odd problem with submenus X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Source-IP: acsinet22.oracle.com [141.146.126.238] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 156.151.31.81 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Jul 2014 16:59:58 -0000 Hello, I have a warning generated by grub2-mkconfig that shows up on various systems that I'm not sure what to do about. Well, I know I can ignore it, but I'm not sure what do do about not getting the warning in the first place. On this machine here, I have menuentry 'Fedora, with Linux 3.14.9-200.fc20.x86_64' --class ... and grub2-set-default 'Fedora, with ...' is OK, but then and I also have GRUB_DISABLE_SUBMENU=true i /etc/default/grub, so $ grub2-mkconfig -o /boot/grub2/grub.cfg ... Warning: Please don't use old title `Fedora, with Linux 3.14.9-200.fc20.x86_64' for GRUB_DEFAULT, use `Advanced options for Fedora>Fedora, with Linux 3.14.9-200.fc20.x86_64' (for versions before 2.00) or `gnulinux-advanced-d87b5f54-5bfb-45bd-b300-f4b1db6d5dfb>gnulinux-3.14.9-200.fc20.x86_64-advanced-d87b5f54-5bfb-45bd-b300-f4b1db6d5dfb' (for 2.00 or later) Exhorting me to use a submenu default when there are no submenus is clearly wrong, so in /etc/grub.d/10_linux (and the other platform-specific files) there's: > if [ x"$title" = x"$GRUB_ACTUAL_DEFAULT" ] || [ x"Previous Linux versions>$title" = x"$GRUB_ACTUAL_DEFAULT" ]; then > replacement_title="$(echo "Advanced options for ${OS}" | sed 's,>,>>,g')>$(echo "$title" | sed 's,>,>>,g')" > quoted="$(echo "$GRUB_ACTUAL_DEFAULT" | grub_quote)" > title_correction_code="${title_correction_code}if [ \"x\$default\" = '$quoted' ]; then default='$(echo "$replacement_title" | grub_quote)'; fi;" > grub_warn "$(gettext_printf "Please don't use old title \`%s' for GRUB_DEFAULT, use \`%s' (for versions before 2.00) or \`%s' (for 2.00 or later)" "$GRUB_ACTUAL_DEFAULT" "$replacement_title" "gnulinux-advanced-$boot_device_id>gnulinux-$version-$type-$boot_device_id")" > fi It's easy enough to add a test for GRUB_DISABLE_SUBMENU here but I'm at a loss to know why this clause is needed at all. I know it means that if I have submenus enabled then I can just set the default to be the title of a submenu and not worry about the "Advanced options ..." bit, but it looks to me as though it was just a transition thing which is really no longer needed. Is this really no longer needed or am I missing something? I'm happy to submit a patch either way. jch