Using flatpak runtimes

Say I want to build gnome-builder from buildstream. Seems buildstream takes the same approach like jhbuild (building all needed deps) but without relying on host for anything.

That is not a problem at all, but as there's flatpak runtimes out there, would be great to avoid build from scratch several things, like webkit (which takes hours to build).

https://gitlab.gnome.org/GNOME/gnome-build-meta/blob/master/elements/core-deps/WebKitGTK+.bst

One option could be flatpak GNOME runtime:

http://docs.flatpak.org/en/latest/available-runtimes.html#gnome

As far as I know there's no metadata in flatpak runtimes so you can know what packages/version it provides. Our best shot is to interrogate runtime with pkg-config.

Ignoring future designs or implementations: Is it possible right know to reuse flatpak runtimes to build anything from buildstream?

I can try whichever WIP around to give feedback