#996934 install failure without /etc/flash-kernel/machine pre-existing

#996934#5
Date:
2021-10-21 01:21:36 UTC
From:
To:
I have some image building scripts that installed flash-kernel in a chroot
(on unrelated hardware; user mode qemu), then configured
/etc/flash-kernel/machine, then ran flash-kernel.
That used to work (in 2018), and now fails:

Creating config file /etc/default/flash-kernel with new version
Setting up flash-kernel (3.104) ...
Processing triggers for libc-bin (2.32-4) ...
Processing triggers for initramfs-tools (0.140) ...
Warning: root device  does not exist
Unsupported platform ''.
run-parts: /etc/initramfs/post-update.d//flash-kernel exited with return code 1
dpkg: error processing package initramfs-tools (--configure):
 installed initramfs-tools package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
 initramfs-tools

This left initramfs-tools half-configured, and apt-get install flash-kernel
exited nonzero.

It seems unreasonable for installing the flash-kernel package to leave the
system in this state when a file that is only documented in that package does
not exist before the package is installed.

Also "Unsupported platform ''" is not the best error message.