File trying-more-debug.patch of Package yast2-bootloader
Index: yast2-bootloader-3.1.101/src/clients/bootloader_finish.rb
===================================================================
--- yast2-bootloader-3.1.101.orig/src/clients/bootloader_finish.rb
+++ yast2-bootloader-3.1.101/src/clients/bootloader_finish.rb
@@ -167,6 +167,27 @@ module Yast
@retcode = Bootloader.WriteInstallation
else
@retcode = Bootloader.Update
+ # workaround for packages that forgot to update initrd(bnc#889616)
+ # do not use Initrd module as it can also change configuration, which we do not want
+ res = SCR.Execute(path(".target.bash_output"), "/sbin/mkinitrd")
+ Builtins.y2milestone("Regerate initrd with result #{res}")
+ end
+
+ # FIXME workaround grub2 need manual rerun of branding due to overwrite by
+ # pbl. see bnc#879686 and bnc#901003
+ if Bootloader.getLoaderType =~ /grub2/
+ prefix = Installation.destdir
+ branding_activator = Dir["#{prefix}/usr/share/grub2/themes/*/activate-theme"].first
+
+ if branding_activator
+ branding_activator = branding_activator[prefix.size..-1]
+ res = SCR.Execute(path(".target.bash_output"), branding_activator)
+ Builtins.y2milestone("Reactivate branding with #{branding_activator} and result #{res}")
+ res = SCR.Execute(path(".target.bash_output"), "/usr/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg")
+ Builtins.y2milestone("Grub mkconfig with result #{res}")
+ else
+ Builtins.y2milestone("No branding_activator")
+ end
end
if @retcode
@@ -197,26 +218,6 @@ module Yast
@ret = nil
end
- # FIXME workaround grub2 need manual rerun of branding due to overwrite by
- # pbl. see bnc#879686 and bnc#901003
- if Bootloader.getLoaderType =~ /grub2/
- prefix = Installation.destdir
- branding_activator = Dir["#{prefix}/usr/share/grub2/themes/*/activate-theme"].first
- if branding_activator
- branding_activator = branding_activator[prefix.size..-1]
- res = SCR.Execute(path(".target.bash_output"), branding_activator)
- res = SCR.Execute(path(".target.bash_output"), "/usr/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg")
- Builtins.y2milestone("Reactivate branding with #{branding_activator} and result #{res}")
- end
- end
- # workaround for packages that forgot to update initrd(bnc#889616)
- # do not use Initrd module as it can also change configuration, which we do not want
- if Mode.update
- res = SCR.Execute(path(".target.bash_output"), "/sbin/mkinitrd")
- Builtins.y2milestone("Regerate initrd with result #{res}")
- end
-
-
Builtins.y2debug("ret=%1", @ret)
Builtins.y2milestone("bootloader_finish finished")
deep_copy(@ret)
Index: yast2-bootloader-3.1.101/src/modules/Bootloader.rb
===================================================================
--- yast2-bootloader-3.1.101.orig/src/modules/Bootloader.rb
+++ yast2-bootloader-3.1.101/src/modules/Bootloader.rb
@@ -934,7 +934,7 @@ module Yast
WFM.Execute(path(".local.mkdir"), "/var/lib/YaST2")
cmd = Builtins.sformat(
- "/bin/cp -L %1%2 %1%3 %4",
+ "/bin/cp -L %1/%2 %1/%3 %4",
Installation.destdir,
"vmlinuz",
"initrd",