Adds a --container option to build in a podman container
So this adds a --container
option that builds a Gentoo podman container and then launches kde-builder inside of it and passes the remaining options.
It is functional: for instance, if you enable vlc in the Dockerfile you can build and run a functional Dragon Player. The only known issues is that it should only be used with rootless podman and also that building a Gentoo container is really slow. I think it'd be fine to merge it as an undocumented feature.
But this is mostly a starting point, to discuss where we would want to take a feature like this. The two main clients of this feature are people who want to jump into KDE development without wrestling with their package manager and KDE Linux - these new-fangled image-based distributions all have some sort of containerized tool for development.
Some of the open questions then:
- Straight podman isn't the right choice, it should be a tool like Toolbox or Distrobox, that solves a lot of problems like running GUI apps. (I was able to run applications built in the container on my openSUSE 15.6 host system, but that's some luck probably.)
- The container should be pre-built. The job of building a container that can build KDE is a subset of what KDE Linux has to do in its build process, so ideally we could just publish that Arch Linux-based subset somehow.
- If it should actually be a option of kde-builder proper, or just a separate script that installs kde-builder in a container.