Blame SOURCES/0149-Add-version-field-to-BLS-generated-by-grub2-switch-t.patch

d9d99f
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
d9d99f
From: Javier Martinez Canillas <javierm@redhat.com>
d9d99f
Date: Thu, 10 May 2018 10:52:11 +0200
d9d99f
Subject: [PATCH] Add version field to BLS generated by grub2-switch-to-blscfg
d9d99f
d9d99f
The version field is present in the BLS fragments that are shipped in the
d9d99f
kernel packages, so add it to the BLS generated by grub2-switch-to-blscfg
d9d99f
for consistency.
d9d99f
d9d99f
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
d9d99f
---
d9d99f
 util/grub-switch-to-blscfg.in | 3 +++
d9d99f
 1 file changed, 3 insertions(+)
d9d99f
d9d99f
diff --git a/util/grub-switch-to-blscfg.in b/util/grub-switch-to-blscfg.in
b71686
index bc28053cd..89487ad61 100644
d9d99f
--- a/util/grub-switch-to-blscfg.in
d9d99f
+++ b/util/grub-switch-to-blscfg.in
d9d99f
@@ -190,12 +190,14 @@ mkbls() {
d9d99f
     local datetime=$1 && shift
d9d99f
 
d9d99f
     local debugname=""
d9d99f
+    local debugid=""
d9d99f
     local flavor=""
d9d99f
 
d9d99f
     if [[ "$kernelver" == *\+* ]] ; then
d9d99f
         local flavor=-"${kernelver##*+}"
d9d99f
         if [[ "${flavor}" == "-debug" ]]; then
d9d99f
             local debugname=" with debugging"
d9d99f
+            local debugid="-debug"
d9d99f
         fi
d9d99f
     fi
d9d99f
     (
d9d99f
@@ -203,6 +205,7 @@ mkbls() {
d9d99f
 
d9d99f
         cat <
d9d99f
 title ${NAME} (${kernelver}) ${VERSION}${debugname}
d9d99f
+version ${kernelver}${debugid}
d9d99f
 linux /vmlinuz-${kernelver}
d9d99f
 initrd /initramfs-${kernelver}.img
d9d99f
 options \$kernelopts