Generate splash screens statically into device package
We need to generate the splash screens separately for each device, because they are specific to the device's display resolution.
At the moment we do this dynamically during the installation process. This has the advantage that there is no need to re-build all device packages when one of the splash screen is changed (or a new one is added).
In reality, however, the splash screens do not change very frequently.
On the other hand, generating the splash screens dynamically has signficant
disk usage overhead for a minimal ("none" UI) rootfs:
The Python interpreter together with the necessary libraries requires
about ~60 MB of disk space on aarch64.
The splash screens itself require about ~100 KB for 720x1280.
This is not necessary if we move the splash screen generation into devicepkg-dev, which is used to build the device package for all devices. Another advantage is that we no longer need the (rather complicated) caching mechanism for splash screens - so we actually end up with less lines than before.
rootfs size for samsung-a5ulte ("none" UI):
- Before: 450M
- After: 388M (-62M)
After this change, every(!) device package needs to be rebuilt once. No changes are necessary in device packages.
Merge request reports
Activity
added 1 commit
- 172bd761 - main/devicepkg-dev: Fix shellcheck warnings in splash screen generation
By Minecrell on 2020-01-20T15:45:49
added type::feature + 1 deleted label
Looks good to me. Great improvement, this has been an issue almost since the start of the project. I always thought, that the best solution would be replacing the python splash generator with something c based, with as few dependencies as possible... but I like this approach even more! We can keep the splash screen generator, with it's easy to maintain python code base, and all the configuration options it supports, and still have the splashes generated ahead of time. Best of all, this is a solution that works today.
Thanks a lot @Minecrell!
Whoever is merging this after second approval, should bump the pkgrels of all device packages right afterwards:
$ cd pmaports/device/ $ pmbootstrap pkgrel_bump device-*
And after pushing the pkgrel bumps, keep an eye on bpo to see if everything builds (it should, and if building the big amount of packages runs into a network error, it should even get automatically retried now).
By Oliver Smith on 2020-01-26T19:10:52
added 46 commits
-
c7f85627...a5cf21b4 - 43 commits from branch
postmarketOS:master
- 0c7bcb54 - main/osk-sdl: add missing depends on ttf-dejavu (!899 (merged))
- e3d07c83 - main/{devicepkg-dev,postmarketos-mkinitfs}: statically generate splash screens (!899 (merged))
- d4ee1230 - main/devicepkg-dev: Fix shellcheck warnings in splash screen generation (!899 (merged))
By Bart Ribbers on 2020-01-28T14:36:01
Toggle commit list-
c7f85627...a5cf21b4 - 43 commits from branch
enabled an automatic merge when the pipeline for d4ee1230 succeeds
By Bart Ribbers on 2020-01-28T14:36:08
mentioned in issue pmbootstrap#1624 (closed)
By Minecrell on 2020-02-09T23:04:30
mentioned in commit e3d07c83
By Minecrell on 2020-02-10T00:06:48
mentioned in commit d4ee1230
By Minecrell on 2020-02-10T00:06:48
mentioned in commit 0c7bcb54
By Minecrell on 2020-02-10T00:06:48