From bf49396f8dda45990d6c366b16fe61d4aa5ff399 Mon Sep 17 00:00:00 2001 From: Tom Alexander Date: Wed, 22 Mar 2023 16:51:38 -0400 Subject: [PATCH 1/2] Enable vulkan for sway on both FreeBSD and Linux. --- ansible/roles/sway/files/launch_sway_freebsd.bash | 1 + ansible/roles/sway/files/launch_sway_linux.bash | 1 + ansible/roles/sway/tasks/common.yaml | 1 + 3 files changed, 3 insertions(+) diff --git a/ansible/roles/sway/files/launch_sway_freebsd.bash b/ansible/roles/sway/files/launch_sway_freebsd.bash index dfb1225..262a5b7 100644 --- a/ansible/roles/sway/files/launch_sway_freebsd.bash +++ b/ansible/roles/sway/files/launch_sway_freebsd.bash @@ -12,6 +12,7 @@ if [[ ! -v XDG_RUNTIME_DIR ]]; then fi export XDG_CURRENT_DESKTOP=sway +export WLR_RENDERER=vulkan # Enable wayland support for firefox export MOZ_ENABLE_WAYLAND=1 diff --git a/ansible/roles/sway/files/launch_sway_linux.bash b/ansible/roles/sway/files/launch_sway_linux.bash index d1e10a3..33beb5e 100644 --- a/ansible/roles/sway/files/launch_sway_linux.bash +++ b/ansible/roles/sway/files/launch_sway_linux.bash @@ -6,5 +6,6 @@ IFS=$'\n\t' DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" export XDG_CURRENT_DESKTOP=sway +export WLR_RENDERER=vulkan exec sway -d &> $HOME/.config/swaylog diff --git a/ansible/roles/sway/tasks/common.yaml b/ansible/roles/sway/tasks/common.yaml index 2ff7846..748442e 100644 --- a/ansible/roles/sway/tasks/common.yaml +++ b/ansible/roles/sway/tasks/common.yaml @@ -20,6 +20,7 @@ - wtype # for rofimoji to be able to insert characters - dbus # for desktop notifications - jq + - vulkan-validation-layers # For vulkan support in sway state: present - name: Install scripts From 8f84ea9adfe9104d761382bf9def8bce128579e8 Mon Sep 17 00:00:00 2001 From: Tom Alexander Date: Wed, 22 Mar 2023 18:05:33 -0400 Subject: [PATCH 2/2] Install vulkan-tools on FreeBSD. --- ansible/roles/firewall/tasks/freebsd.yaml | 1 + ansible/roles/graphics/tasks/freebsd_intel.yaml | 1 + 2 files changed, 2 insertions(+) diff --git a/ansible/roles/firewall/tasks/freebsd.yaml b/ansible/roles/firewall/tasks/freebsd.yaml index 3c1e779..038bdd6 100644 --- a/ansible/roles/firewall/tasks/freebsd.yaml +++ b/ansible/roles/firewall/tasks/freebsd.yaml @@ -26,6 +26,7 @@ shell: service pf status register: is_pf_running failed_when: is_pf_running.rc != 0 + changed_when: false ignore_errors: true - name: Enable pflog diff --git a/ansible/roles/graphics/tasks/freebsd_intel.yaml b/ansible/roles/graphics/tasks/freebsd_intel.yaml index d6bc50c..96a1c82 100644 --- a/ansible/roles/graphics/tasks/freebsd_intel.yaml +++ b/ansible/roles/graphics/tasks/freebsd_intel.yaml @@ -9,6 +9,7 @@ - vdpauinfo # for vdpauinfo - libvdpau-va-gl # vdpau support - igt-gpu-tools # for intel_gpu_top + - vulkan-tools # For vulkaninfo state: present # - name: Configure vdpau to use va-api driver