From 94d5b9b0a4fe421f2fc6fed567887982060879d0 Mon Sep 17 00:00:00 2001 From: Ben Grande Date: Thu, 20 Jun 2024 10:22:41 +0200 Subject: [PATCH] Force software rendering by default For: https://github.com/QubesOS/qubes-issues/issues/9268 For: https://github.com/QubesOS/qubes-gui-agent-linux/pull/214 --- rpm_spec/core-dom0-linux.spec.in | 2 ++ system-config/disable-gpu-accel.sh | 4 ++++ 2 files changed, 6 insertions(+) create mode 100644 system-config/disable-gpu-accel.sh diff --git a/rpm_spec/core-dom0-linux.spec.in b/rpm_spec/core-dom0-linux.spec.in index ab0a749..530ce6c 100644 --- a/rpm_spec/core-dom0-linux.spec.in +++ b/rpm_spec/core-dom0-linux.spec.in @@ -153,6 +153,7 @@ install -m 644 system-config/12-qubes-ignore-lvm-devices.rules $RPM_BUILD_ROOT%_ install -m 644 system-config/11-qubes-ignore-zvol-devices.rules $RPM_BUILD_ROOT%_udevrulesdir install -m 644 system-config/99z-qubes-mark-ready.rules $RPM_BUILD_ROOT%_udevrulesdir install -m 644 -D system-config/disable-lesspipe.sh $RPM_BUILD_ROOT/etc/profile.d/zz-disable-lesspipe.sh +install -m 644 -D system-config/disable-gpu-accel.sh $RPM_BUILD_ROOT/etc/profile.d/zz-disable-gpu-accel.sh install -m 755 -D system-config/kernel-grub2.install $RPM_BUILD_ROOT/usr/lib/kernel/install.d/80-grub2.install install -m 755 -D system-config/kernel-xen-efi.install $RPM_BUILD_ROOT/usr/lib/kernel/install.d/90-xen-efi.install install -m 755 -D system-config/kernel-remove-bls.install $RPM_BUILD_ROOT/usr/lib/kernel/install.d/99-remove-bls.install @@ -315,6 +316,7 @@ chmod -x /etc/grub.d/10_linux %attr(0644,root,root) /etc/cron.d/qubes-sync-clock.cron /etc/cron.daily/lvm-cleanup %config(noreplace) /etc/profile.d/zz-disable-lesspipe.sh +%config(noreplace) /etc/profile.d/zz-disable-gpu-accel.sh %config(noreplace) /etc/dnf/protected.d/qubes-core-dom0.conf %_presetdir/75-qubes-dom0.preset %_presetdir/99-qubes-default-disable.preset diff --git a/system-config/disable-gpu-accel.sh b/system-config/disable-gpu-accel.sh new file mode 100644 index 0000000..3dd129d --- /dev/null +++ b/system-config/disable-gpu-accel.sh @@ -0,0 +1,4 @@ +if ! test -f /var/run/qubes-service/gpu-accel; then + export GSK_RENDERER="cairo" GDK_DEBUG="gl-disable vulkan-disable" \ + LIBGL_ALWAYS_SOFTWARE=1 +fi