From 82a07127b7110e778131c598c57428aa1b2e1422 Mon Sep 17 00:00:00 2001 From: ItsDrike Date: Mon, 8 Jul 2024 14:58:39 +0200 Subject: [PATCH] Use hardware.graphics instead of hardware.opengl --- system/shared/hardware/gpu/amd.nix | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/system/shared/hardware/gpu/amd.nix b/system/shared/hardware/gpu/amd.nix index 0f3402e..173d886 100644 --- a/system/shared/hardware/gpu/amd.nix +++ b/system/shared/hardware/gpu/amd.nix @@ -26,14 +26,17 @@ in graphics = { enable = true; - # Enable AMDVLK (AMD's open-source Vulkan driver) - extraPackages = with pkgs; [ amdvlk ]; + extraPackages = with pkgs; [ + # Enable AMDVLK (AMD's open-source Vulkan driver) + amdvlk + + # OpenCL (Universal GPU computing API - not AMD specific) + # To check if this works, run: `nix run nixpkgs#clinfo` (after rebooting) + rocmPackages.clr.icd + ]; + # AMDVLK for 32-bit applications extraPackages32 = with pkgs; [ driversi686Linux.amdvlk ]; }; - - # OpenCL (Universal GPU computing API - not AMD specific) - # To check if this works, run: `nix run nixpkgs#clinfo` (after rebooting) - opengl.extraPackages = with pkgs; [rocmPackages.clr.icd]; }; # HIP (SDK that allows running CUDA code on AMD GPUs)