feat: add explicit ROCm and Vulkan support for compilation
Co-authored-by: aider (openrouter/mistralai/devstral-2512:free) <aider@aider.chat>
This commit is contained in:
@@ -44,13 +44,18 @@
|
||||
|
||||
environment.variables = {
|
||||
HSA_OVERRIDE_GFX_VERSION = "10.3.0";
|
||||
|
||||
};
|
||||
|
||||
#hardware.opengl.extraPackages32 = with pkgs; [
|
||||
# driversi686Linux.amdvlk
|
||||
#];
|
||||
# Enable Vulkan support
|
||||
hardware.opengl.enable = true;
|
||||
hardware.opengl.driSupport32 = true;
|
||||
hardware.opengl.extraPackages = with pkgs; [
|
||||
vulkan-loader
|
||||
vulkan-tools
|
||||
vulkan-headers
|
||||
];
|
||||
|
||||
# Explicitly include ROCm packages for compilation
|
||||
environment.systemPackages = with pkgs; [
|
||||
lact
|
||||
rocmPackages.rocminfo
|
||||
@@ -62,7 +67,16 @@
|
||||
rocmPackages.rocgdb
|
||||
rocmPackages.rocblas
|
||||
rocmPackages.rccl
|
||||
rocmPackages.hipcc
|
||||
rocmPackages.rocm-opencl-runtime
|
||||
];
|
||||
|
||||
# Ensure ROCm is available in the environment for compilation
|
||||
environment.sessionVariables = {
|
||||
ROCM_PATH = "${pkgs.rocmPackages.rocm-core}/opt/rocm";
|
||||
HIP_PATH = "${pkgs.rocmPackages.rocm-core}/opt/rocm/hip";
|
||||
};
|
||||
|
||||
systemd.packages = with pkgs; [ lact ];
|
||||
systemd.services.lactd.wantedBy = [ "multi-user.target" ];
|
||||
|
||||
@@ -88,14 +102,7 @@
|
||||
{ device = "/dev/disk/by-uuid/c7cdfab4-2c92-42de-b951-ccc6fcd7b7d7"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp10s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp7s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user