Hi,
My application requires gst-plugin-rs gstreamer plugins bundled into the Flatpak. I’m using the org.gnome.Sdk
runtime, which does not contain those plugins by default, so I need to build and install them myself.
I can build the plugins just fine, but I am unable to install the libraries into /usr/lib/x86_64-linux-gnu/gstreamer-1.0
directory, because that directory is read-only. Installing those plugins in /app
directory does not make them discoverable by gstreamer.
Is there some proper way to bundle the gstreamer plugins?
Below is the fragment of the manifest that I am using to build the plugins. generated-sources.json
was generated with the flatpak-cargo-generator.py
tool.
{
"app-id": "io.github.e_rk.hscam",
"runtime": "org.gnome.Platform",
"runtime-version": "46",
"sdk": "org.gnome.Sdk",
"sdk-extensions": ["org.freedesktop.Sdk.Extension.rust-stable"],
"command": "hscam",
"finish-args": [
"--share=network",
"--filesystem=xdg-config/hscam:create",
"--socket=wayland",
"--socket=fallback-x11",
"--device=dri"
],
"build-options": {
"append-path": "/usr/lib/sdk/rust-stable/bin",
"env": {
"CARGO_HOME": "/run/build/gst-plugin-rs/cargo"
}
},
"modules": [
{
"name": "gst-plugin-rs",
"buildsystem": "simple",
"build-options": {
"env": {
"CARGO_HOME": "/run/build/gst-plugin-rs/cargo"
}
},
"build-commands": [
"cargo cbuild --offline --release -p gst-plugin-gtk4 --prefix=/usr --libdir lib/x86_64-linux-gnu",
"cargo cinstall --offline --release -p gst-plugin-gtk4 --prefix=/usr --libdir lib/x86_64-linux-gnu"
],
"sources": [
{
"type": "git",
"url": "https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git",
"commit": "19cb695ce0e83a636aa5781788bb1b4640a5d75a"
},
"generated-sources.json"
]
}
]
}