xen-tools commit
83c37b476a75 ("Start all Debian releases since
Stretch (9) with pygrub by default") started to use pygrub by default.
Revert this.
With "pygrub" setting, xen-create-guest fails on armhf, the
80-install-kernel hook fails because it doesn't know about "armhf".
https://github.com/xen-tools/xen-tools/commit/
83c37b476a7534c432ecc9941817aeb989677da6
There's "--nopygrub" but that doesn't work due to several issues, so
removing "pygrub" from "distributions.conf" is the only way.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Acked-by: Roger Pau Monné <roger.pau@citrix.com>
fi
END
}
+
+ if ($ho->{Suite} =~ m/bookworm/) {
+ # remove "pygrub" from /etc/xen-tools/distributions.conf
+ # The "--nopygrub" option doesn't work.
+ # https://github.com/xen-tools/xen-tools/issues/67
+ # https://github.com/xen-tools/xen-tools/issues/68
+ target_editfile_root($ho, "/etc/xen-tools/distributions.conf", sub {
+ while (<::EI>) {
+ unless (m/^#/) {
+ s/ pygrub\b//;
+ }
+ print ::EO or die $!;
+ }
+ });
+ }
my $cmd = '';
my $useproxy = $c{DebianMirrorProxy} // $c{HttpProxy};
$cmd .= <<END if defined $useproxy;