loki: Enable 32bit graphics, add workaround for ROCm/HIP

This commit is contained in:
Erwin Boskma 2024-07-30 12:11:24 +02:00
parent 2862a8a6e5
commit 4e713b60a3
Signed by: erwin
SSH key fingerprint: SHA256:/Wk1WZdLg+vQHs3in9qq7PsIp8SMzwGSk/RLZ5zPuZk

View file

@ -103,11 +103,16 @@
# high-resolution display # high-resolution display
# hardware.video.hidpi.enable = lib.mkDefault true; # hardware.video.hidpi.enable = lib.mkDefault true;
# Enable firmware hardware = {
hardware.enableAllFirmware = true; # Enable firmware
enableAllFirmware = true;
graphics = {
enable32Bit = true;
};
# i2c support # i2c support
hardware.i2c.enable = true; i2c.enable = true;
};
boot = { boot = {
initrd.availableKernelModules = [ initrd.availableKernelModules = [
@ -505,10 +510,27 @@
]; ];
}; };
# Workaround for packages that has HIP paths hardcoded
systemd.tmpfiles.rules =
let
rocmEnv = pkgs.symlinkJoin {
name = "rocm-combined";
paths = with pkgs.rocmPackages; [
rocblas
hipblas
clr
];
};
in
[ "L+ /opt/rocm - - - - ${rocmEnv}" ];
nix.settings.post-build-hook = nix.settings.post-build-hook =
let let
inherit (attic.packages.${pkgs.system}) attic-client; inherit (attic.packages.${pkgs.system}) attic-client;
cachedPackagePatterns = builtins.concatStringsSep "|" [ "mongodb" ]; cachedPackagePatterns = builtins.concatStringsSep "|" [
"mongodb"
"qgis"
];
in in
pkgs.writeScript "upload-to-cache" '' pkgs.writeScript "upload-to-cache" ''
set -eu set -eu