Skip to content

Commit 4307277

Browse files
committed
fix: patch away warnings for build
1 parent 79d7331 commit 4307277

File tree

3 files changed

+58
-0
lines changed

3 files changed

+58
-0
lines changed

PATCH_CONFIG_OPTIONS

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
diff --git a/pkgs/stdenv/default.nix b/pkgs/stdenv/default.nix
2+
index 3bc88f59c4bb..37d480116299 100644
3+
--- a/pkgs/stdenv/default.nix
4+
+++ b/pkgs/stdenv/default.nix
5+
@@ -43,7 +43,7 @@ in
6+
# Select the appropriate stages for the platform `system'.
7+
if crossSystem != localSystem || crossOverlays != [ ] then
8+
stagesCross
9+
-else if config ? replaceStdenv then
10+
+else if config.replaceStdenv or null != null then
11+
stagesCustom
12+
else if localSystem.isLinux then
13+
stagesLinux
14+
diff --git a/pkgs/top-level/config.nix b/pkgs/top-level/config.nix
15+
index c8e8a3f58590..cc3aa6fc0242 100644
16+
--- a/pkgs/top-level/config.nix
17+
+++ b/pkgs/top-level/config.nix
18+
@@ -266,6 +266,32 @@ let
19+
feature = "build packages with CUDA support by default";
20+
};
21+
22+
+ cudaCapabilities = mkMassRebuild {
23+
+ type = types.listOf types.str;
24+
+ default = [ ];
25+
+ description = ''
26+
+ List of CUDA capabilities to build for (e.g., `["8.9"]` for RTX 4090).
27+
+ If empty, uses the default capabilities for the CUDA version.
28+
+ See https://developer.nvidia.com/cuda-gpus for capability values.
29+
+ '';
30+
+ };
31+
+
32+
+ cudaForwardCompat = mkMassRebuild {
33+
+ default = true;
34+
+ feature = "build CUDA packages with forward compatibility (PTX)";
35+
+ };
36+
+
37+
+ replaceStdenv = mkOption {
38+
+ type = types.nullOr (types.functionTo types.raw);
39+
+ default = null;
40+
+ description = ''
41+
+ A function to replace the default stdenv.
42+
+ Takes `{ pkgs }` as argument and returns a custom stdenv.
43+
+ When set, nixpkgs will use this stdenv instead of the default.
44+
+ '';
45+
+ example = literalExpression "{ pkgs }: pkgs.ccacheStdenv";
46+
+ };
47+
+
48+
replaceBootstrapFiles = mkMassRebuild {
49+
type = types.functionTo (types.attrsOf types.package);
50+
default = lib.id;

custom_modules/core_services.nix

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -519,6 +519,13 @@ in
519519
};
520520
};
521521
}
522+
{
523+
"IP KVM" = {
524+
icon = "mdi-remote-desktop";
525+
href = "https://glkvm.tail5ca7.ts.net/#/";
526+
description = "Remote KVM Access";
527+
};
528+
}
522529
];
523530
}
524531
];

flake.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@
5151
src = nixpkgs-unpatched;
5252
patches = [
5353
./PATCH_SUNSHINE
54+
./PATCH_CONFIG_OPTIONS
5455
(tmp_pkgs.fetchpatch {
5556
url = "https://github.com/DieracDelta/nixpkgs/commit/a1d2240eebf50667a42b18c577c6a6f221e23e83.patch";
5657
hash = "sha256-mnBr3SXqfU4LekbX8v0Pqg2RsUHVijKbokPkUbArW2k=";

0 commit comments

Comments
 (0)