public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Kalev Lember <klember@redhat.com>
To: git-commits@fedoraproject.org
Subject: [flatpaks/flatpak-runtime] f45: container.yaml: Hook up libegl and vulkan extensions
Date: Fri, 11 Sep 2026 14:41:53 GMT	[thread overview]
Message-ID: <178913771325.1.3259915887147643753.flatpaks-flatpak-runtime-b7e47ff416c0@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : flatpaks/flatpak-runtime
            Branch : f45
            Commit : b7e47ff416c0e4b3ab46d7c5e8d2e7876565c17f
            Author : Kalev Lember <klember@redhat.com>
            Date   : 2021-12-08T10:47:48+01:00
            Stats  : +7/-0 in 1 file(s)
            URL    : https://src.fedoraproject.org/flatpaks/flatpak-runtime/c/b7e47ff416c0e4b3ab46d7c5e8d2e7876565c17f?branch=f45

            Log:
            container.yaml: Hook up libegl and vulkan extensions

This copies the merge-dirs setup from org.freedesktop.Platform//21.08
and adds symlinks to hook into /etc/glvnd and /etc/vulkan.

Mesa and other rpm-packaged drivers install into /usr/share/glvnd and
/usr/share/vulkan, leaving /etc/glvnd and /etc/vulkan for sysadmin
overrides. Since there are no sysadmin overrides in flatpak we can use
this by making /etc/glvnd and /etc/vulkan symlinks to /usr/lib/GL/glvnd
and /usr/lib/GL/vulkan, which will then be filled in by the extensions.

See https://bugzilla.redhat.com/show_bug.cgi?id=1785251 for the discussion
of this setup.

We sadly can't use the same setup for OpenCL as there doesn't appear to
be a similar /etc/OpenCL and /usr/share/OpenCL split. It's probably
necessary to split mesa extension out of org.fedoraproject.Platform in
the future to get OpenCL correctly hooked up.

---
diff --git a/container.yaml b/container.yaml
index 02dc3de..bc44f0e 100644
--- a/container.yaml
+++ b/container.yaml
@@ -17,6 +17,7 @@ flatpak:
         --extension=org.freedesktop.Platform.GL=no-autodownload=true
         --extension=org.freedesktop.Platform.GL=autodelete=false
         --extension=org.freedesktop.Platform.GL=add-ld-path=lib
+        --extension=org.freedesktop.Platform.GL=merge-dirs=vulkan/icd.d;glvnd/egl_vendor.d;OpenCL/vendors;lib/dri;lib/d3d;vulkan/explicit_layer.d;vulkan/implicit_layer.d
         --extension=org.freedesktop.Platform.GL=download-if=active-gl-driver
         --extension=org.freedesktop.Platform.GL=enable-if=active-gl-driver
         --extension=org.freedesktop.Platform.GL=autoprune-unless=active-gl-driver
@@ -40,5 +41,11 @@ flatpak:
         # Create a directory for mounting org.freedesktop.Platform.GL extension point
         mkdir -p /usr/lib64/GL
 
+        rm -r /etc/glvnd
+        ln -s ../lib64/GL/glvnd /etc/glvnd
+
+        rm -r /etc/vulkan
+        ln -s ../lib64/GL/vulkan /etc/vulkan
+
         touch -d @0 /usr/share/fonts /usr/share/fonts/*
         fc-cache -rs

                 reply	other threads:[~2026-09-11 14:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178913771325.1.3259915887147643753.flatpaks-flatpak-runtime-b7e47ff416c0@fedoraproject.org \
    --to=klember@redhat.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox