Hello to everyone.
I'm trying to understand the reasons why the kernel file that I generate does not work correctly. Maybe I've understood something,but I don't have a clear picture of the problem. I want to try to explain what's wrong using my method of _expression_ because I find it easier. A more "advanced" way may be able to help you,but it will not help me and the result will be that we will not understand each other. So. I've created the folder called "kernels" like this :
mkdir -p /home/ziomario/Scrivania/PassT-Cubic/kernels/
inside of it I have copied the following kernel file :
initrd.img-5.10.0-18-amd64.gz
it is unaltered. I haven't added any logos and pictures inside of it. After this,I have created two more folders :
mkdir -p /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped
mkdir -p /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64
and then I did :
cd /home/ziomario/Scrivania/PassT-Cubic/kernels/
gunzip -k initrd.img-5.10.0-18-amd64.gz
cpio -idv < initrd.img-5.10.0-18-amd64 -D /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64
Every time I give the latest command (the cpio one),something odd happens and I don't understand the reason. Inside the folder "/usr/share/plymouth/themes/homeworld",two new files are created : debian.png and logo.png. The first one is correct. I mean,this is one of the pictures that I want to add inside the kernel file. But the second file,logo.png is wrong. It is an old picture that I used sometime ago and that I don't use anymore because I created a new logo. Let's say that the folder "/usr/share/plymouth" and "/usr/share/plymouth/themes/underworld" are two folders that I have created on my host os and inside of them I have stored the correct pictures that I want to add inside the kernel file. Later in the process,I issue the below commands to copy the correct images inside the kernel file before re-packing it.
cp /usr/share/plymouth/debian-logo.png /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64/usr/share/plymouth/
cp /usr/share/plymouth/themes/homeworld/debian.png /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64/usr/share/plymouth/themes/homeworld
cp /usr/share/plymouth/themes/homeworld/logo.png /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64/usr/share/plymouth/themes/homeworld
At the moment I haven't reached that step because the cpio command (cpio -idv < initrd.img-5.10.0-18-amd64 -D /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64) behavior is not expected.
Since I'm using unaltered kernel files,I don't know where the cpio command (cpio -idv < initrd.img-5.10.0-18-amd64 -D /home/ziomario/Scrivania/PassT-Cubic/kernels/unzipped/initrd.img-5.10.0-18-amd64) gets those images when I run it. And most of all,I don't know why those pictures are copied inside the folder "/usr/share/plymouth/themes/underworld",overwriting the already existing pictures that are already there. As I repeat,those files aren't stored inside the kernel file (initrd.img-5.10.0-18-amd64),because it is unaltered and it contains only the default debian pictures,which are different from mine. I hope that I have been clear. Sorry I don't have another way to explain what happens other than my narrative.
Mario.