torizon / meta-toradex-torizon

Torizon OS OpenEmbedded Distro Layer
MIT License
6 stars 14 forks source link

initramfs-ostree-torizon-image is too big with unnecessary plymouth dependencies installed #16

Closed MingliuYan closed 7 months ago

MingliuYan commented 7 months ago

Currently in kirkstone-6.x.y branch, plymouth has a dependent chain like: plymouth -> pango -> cairo -> virtual/egl, virtual/egl2.

When PACKAGECONFIG 'pango' enabled in plymouth recipe, it leads to all the above packages installed to initramfs-ostree-torizon-image, as a result, the initramfs size is 32M for apalis-imx8 machines, see:

$ du -sh tmp/work/apalis_imx8-tdx-linux/initramfs-ostree-torizon-image/1.0-r0/rootfs/
32M tmp/work/apalis_imx8-tdx-linux/initramfs-ostree-torizon-image/1.0-r0/rootfs/

that's too much, can slow down the boot time.

While PACKAGECONFIG 'pango' is needed only for text rendering of user prompts (allowing user to input passwd and so on), we dont really need it.

Also currently all plymouth themes are being installed to initramfs, but we only use spinner theme, we shall consider drop the others to save some space.

I have done some tests, by dropping 'pango' PACKAGECONFIG and also the unneeded themes, the initramfs size turns to 16M for apalis-imx8 machines, that is saying 16M cut off.