mirror of
https://github.com/CHN-beta/nixos.git
synced 2026-01-12 01:29:24 +08:00
Revert "lib.buildNixpkgsConfig: limit rocm to only specific target"
This reverts commit 45c523bdaa.
This commit is contained in:
@@ -32,7 +32,7 @@ inputs:
|
||||
# SAHF FXSR XSAVE RDRND LZCNT HLE PREFETCHW SGX PCONFIG
|
||||
"icelake-server"
|
||||
];
|
||||
nixpkgs = { march = "znver5"; rocm = [ "gfx1151" ]; };
|
||||
nixpkgs = { march = "znver5"; rocm = true; };
|
||||
sysctl.laptop-mode = 5;
|
||||
kernel = { variant = "cachyos"; patches = [ "btusb" ]; };
|
||||
};
|
||||
|
||||
@@ -16,7 +16,7 @@ let
|
||||
// (inputs.lib.optionalAttrs (nixpkgs.cuda.forwardCompat != null)
|
||||
{ cudaForwardCompat = nixpkgs.cuda.forwardCompat; })
|
||||
);
|
||||
rocmConfig = inputs.lib.optionalAttrs (nixpkgs.rocm or null != null) { rocmSupport = true; };
|
||||
rocmConfig = inputs.lib.optionalAttrs (nixpkgs.rocm or false) { rocmSupport = true; };
|
||||
allowInsecurePredicate = p: inputs.lib.warn "Allowing insecure package ${p.name or "${p.pname}-${p.version}"}" true;
|
||||
config = cudaConfig // rocmConfig
|
||||
// {
|
||||
@@ -173,12 +173,5 @@ in platformConfig //
|
||||
# // (inputs.lib.optionalAttrs (nixpkgs.march == "silvermont")
|
||||
# { c-blosc = prev.c-blosc.overrideAttrs { doCheck = false; }; })
|
||||
# // (inputs.lib.optionalAttrs (nixpkgs.arch or null == "aarch64") { nix = final.nixVersions.nix_2_29; })
|
||||
|
||||
# pick from https://github.com/nix-community/nur-combined/blob/e60d2cac468d38a97874108c1601de2ce0ca23b8/repos/slaier/outputs/_hosts/local/hardware-configuration.nix#L45
|
||||
// (inputs.lib.optionalAttrs (nixpkgs.rocm or null != null)
|
||||
{
|
||||
rocmPackages = prev.rocmPackages.overrideScope (final: prev:
|
||||
{ clr = prev.clr.override { localGpuTargets = nixpkgs.rocm; }; });
|
||||
})
|
||||
)];
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ inputs:
|
||||
};});
|
||||
default = null;
|
||||
};
|
||||
rocm = mkOption { type = types.nullOr (types.listOf types.str); default = null; };
|
||||
rocm = mkOption { type = types.bool; default = false; };
|
||||
};
|
||||
config = let inherit (inputs.config.nixos.system) nixpkgs; in
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user