summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--flake.lock88
-rw-r--r--hosts/sif/default.nix4
-rw-r--r--modules/llvm_kernel.nix59
-rw-r--r--system-profiles/zfs.nix3
4 files changed, 41 insertions, 113 deletions
diff --git a/flake.lock b/flake.lock
index 5a9e4420..e4c3a97c 100644
--- a/flake.lock
+++ b/flake.lock
@@ -178,11 +178,11 @@
178 "nixpkgs-lib": "nixpkgs-lib_2" 178 "nixpkgs-lib": "nixpkgs-lib_2"
179 }, 179 },
180 "locked": { 180 "locked": {
181 "lastModified": 1733312601, 181 "lastModified": 1749398372,
182 "narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=", 182 "narHash": "sha256-tYBdgS56eXYaWVW3fsnPQ/nFlgWi/Z2Ymhyu21zVM98=",
183 "owner": "hercules-ci", 183 "owner": "hercules-ci",
184 "repo": "flake-parts", 184 "repo": "flake-parts",
185 "rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9", 185 "rev": "9305fe4e5c2a6fcf5ba6a3ff155720fbe4076569",
186 "type": "github" 186 "type": "github"
187 }, 187 },
188 "original": { 188 "original": {
@@ -386,7 +386,7 @@
386 "leapseconds": { 386 "leapseconds": {
387 "flake": false, 387 "flake": false,
388 "locked": { 388 "locked": {
389 "narHash": "sha256-5ZaoY/bScQS7EGJRHu6vj9XWhbObmxNEaGugaGU7+lg=", 389 "narHash": "sha256-FJgbafPB48+5sT+7ZB8pajSsfJoISEOoaJ0d/2Ya7o8=",
390 "type": "file", 390 "type": "file",
391 "url": "https://data.iana.org/time-zones/tzdb/leap-seconds.list" 391 "url": "https://data.iana.org/time-zones/tzdb/leap-seconds.list"
392 }, 392 },
@@ -402,16 +402,16 @@
402 "nixpkgs": [ 402 "nixpkgs": [
403 "nixpkgs" 403 "nixpkgs"
404 ], 404 ],
405 "nixpkgs-stable": "nixpkgs-stable_3", 405 "nixpkgs-stable": "nixpkgs-stable_2",
406 "xwayland-satellite-stable": "xwayland-satellite-stable", 406 "xwayland-satellite-stable": "xwayland-satellite-stable",
407 "xwayland-satellite-unstable": "xwayland-satellite-unstable" 407 "xwayland-satellite-unstable": "xwayland-satellite-unstable"
408 }, 408 },
409 "locked": { 409 "locked": {
410 "lastModified": 1750471128, 410 "lastModified": 1750735687,
411 "narHash": "sha256-oR2yjhAPXZDmfFb4UwBeVQcJBtrUNFwufovzN8sTBVc=", 411 "narHash": "sha256-pscxcZpLGcEEJGVjFAM7X77cARABc7M+zVyUN6qsEmU=",
412 "owner": "sodiboo", 412 "owner": "sodiboo",
413 "repo": "niri-flake", 413 "repo": "niri-flake",
414 "rev": "13e7a34df7aa4e7d8ec4dd9df9d5a01973f28f49", 414 "rev": "a581a91b7406a0b9039ef22e37e5166bd3b1a139",
415 "type": "github" 415 "type": "github"
416 }, 416 },
417 "original": { 417 "original": {
@@ -441,11 +441,11 @@
441 "niri-unstable": { 441 "niri-unstable": {
442 "flake": false, 442 "flake": false,
443 "locked": { 443 "locked": {
444 "lastModified": 1750334747, 444 "lastModified": 1750684365,
445 "narHash": "sha256-nsD1Z6vVP2Hhdgrd0uYHacre2+NhaH/53TFRXn6pRcs=", 445 "narHash": "sha256-BqtoSRCgmutJXnQFZs+KFMNvp3LuX6POIHjXIxWdlTE=",
446 "owner": "YaLTeR", 446 "owner": "YaLTeR",
447 "repo": "niri", 447 "repo": "niri",
448 "rev": "e0b0b04b445f7044f383e50104f861e632e1c905", 448 "rev": "4c02f3bba451747c3f337f4c131b0c7f9ef41bb7",
449 "type": "github" 449 "type": "github"
450 }, 450 },
451 "original": { 451 "original": {
@@ -599,14 +599,17 @@
599 }, 599 },
600 "nixpkgs-lib_2": { 600 "nixpkgs-lib_2": {
601 "locked": { 601 "locked": {
602 "lastModified": 1733096140, 602 "lastModified": 1748740939,
603 "narHash": "sha256-1qRH7uAUsyQI7R1Uwl4T+XvdNv778H0Nb5njNrqvylY=", 603 "narHash": "sha256-rQaysilft1aVMwF14xIdGS3sj1yHlI6oKQNBRTF40cc=",
604 "type": "tarball", 604 "owner": "nix-community",
605 "url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz" 605 "repo": "nixpkgs.lib",
606 "rev": "656a64127e9d791a334452c6b6606d17539476e2",
607 "type": "github"
606 }, 608 },
607 "original": { 609 "original": {
608 "type": "tarball", 610 "owner": "nix-community",
609 "url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz" 611 "repo": "nixpkgs.lib",
612 "type": "github"
610 } 613 }
611 }, 614 },
612 "nixpkgs-lib_3": { 615 "nixpkgs-lib_3": {
@@ -661,27 +664,11 @@
661 }, 664 },
662 "nixpkgs-stable_2": { 665 "nixpkgs-stable_2": {
663 "locked": { 666 "locked": {
664 "lastModified": 1735563628, 667 "lastModified": 1750622754,
665 "narHash": "sha256-OnSAY7XDSx7CtDoqNh8jwVwh4xNL/2HaJxGjryLWzX8=", 668 "narHash": "sha256-kMhs+YzV4vPGfuTpD3mwzibWUE6jotw5Al2wczI0Pv8=",
666 "owner": "NixOS",
667 "repo": "nixpkgs",
668 "rev": "b134951a4c9f3c995fd7be05f3243f8ecd65d798",
669 "type": "github"
670 },
671 "original": {
672 "owner": "NixOS",
673 "ref": "nixos-24.05",
674 "repo": "nixpkgs",
675 "type": "github"
676 }
677 },
678 "nixpkgs-stable_3": {
679 "locked": {
680 "lastModified": 1750400657,
681 "narHash": "sha256-3vkjFnxCOP6vm5Pm13wC/Zy6/VYgei/I/2DWgW4RFeA=",
682 "owner": "NixOS", 669 "owner": "NixOS",
683 "repo": "nixpkgs", 670 "repo": "nixpkgs",
684 "rev": "b2485d56967598da068b5a6946dadda8bfcbcd37", 671 "rev": "c7ab75210cb8cb16ddd8f290755d9558edde7ee1",
685 "type": "github" 672 "type": "github"
686 }, 673 },
687 "original": { 674 "original": {
@@ -691,7 +678,7 @@
691 "type": "github" 678 "type": "github"
692 } 679 }
693 }, 680 },
694 "nixpkgs-stable_4": { 681 "nixpkgs-stable_3": {
695 "locked": { 682 "locked": {
696 "lastModified": 1748026580, 683 "lastModified": 1748026580,
697 "narHash": "sha256-rWtXrcIzU5wm/C8F9LWvUfBGu5U5E7cFzPYT1pHIJaQ=", 684 "narHash": "sha256-rWtXrcIzU5wm/C8F9LWvUfBGu5U5E7cFzPYT1pHIJaQ=",
@@ -707,7 +694,7 @@
707 "type": "github" 694 "type": "github"
708 } 695 }
709 }, 696 },
710 "nixpkgs-stable_5": { 697 "nixpkgs-stable_4": {
711 "locked": { 698 "locked": {
712 "lastModified": 1678872516, 699 "lastModified": 1678872516,
713 "narHash": "sha256-/E1YwtMtFAu2KUQKV/1+KFuReYPANM2Rzehk84VxVoc=", 700 "narHash": "sha256-/E1YwtMtFAu2KUQKV/1+KFuReYPANM2Rzehk84VxVoc=",
@@ -725,11 +712,11 @@
725 }, 712 },
726 "nixpkgs_2": { 713 "nixpkgs_2": {
727 "locked": { 714 "locked": {
728 "lastModified": 1750365781, 715 "lastModified": 1750506804,
729 "narHash": "sha256-XE/lFNhz5lsriMm/yjXkvSZz5DfvKJLUjsS6pP8EC50=", 716 "narHash": "sha256-VLFNc4egNjovYVxDGyBYTrvVCgDYgENp5bVi9fPTDYc=",
730 "owner": "NixOS", 717 "owner": "NixOS",
731 "repo": "nixpkgs", 718 "repo": "nixpkgs",
732 "rev": "08f22084e6085d19bcfb4be30d1ca76ecb96fe54", 719 "rev": "4206c4cb56751df534751b058295ea61357bbbaa",
733 "type": "github" 720 "type": "github"
734 }, 721 },
735 "original": { 722 "original": {
@@ -837,15 +824,14 @@
837 "nixpkgs": [ 824 "nixpkgs": [
838 "ca-util", 825 "ca-util",
839 "nixpkgs" 826 "nixpkgs"
840 ], 827 ]
841 "nixpkgs-stable": "nixpkgs-stable_2"
842 }, 828 },
843 "locked": { 829 "locked": {
844 "lastModified": 1734261738, 830 "lastModified": 1749636823,
845 "narHash": "sha256-3Lzk+7QyX8v60+km26D3dln7NMSA13vW+KYTkMkds6Q=", 831 "narHash": "sha256-WUaIlOlPLyPgz9be7fqWJA5iG6rHcGRtLERSCfUDne4=",
846 "owner": "cachix", 832 "owner": "cachix",
847 "repo": "pre-commit-hooks.nix", 833 "repo": "pre-commit-hooks.nix",
848 "rev": "4c8e75efbbdcc6f9203f64b1f21f8a55d2285264", 834 "rev": "623c56286de5a3193aa38891a6991b28f9bab056",
849 "type": "github" 835 "type": "github"
850 }, 836 },
851 "original": { 837 "original": {
@@ -860,7 +846,7 @@
860 "flake-utils": "flake-utils_2", 846 "flake-utils": "flake-utils_2",
861 "gitignore": "gitignore_3", 847 "gitignore": "gitignore_3",
862 "nixpkgs": "nixpkgs_3", 848 "nixpkgs": "nixpkgs_3",
863 "nixpkgs-stable": "nixpkgs-stable_5" 849 "nixpkgs-stable": "nixpkgs-stable_4"
864 }, 850 },
865 "locked": { 851 "locked": {
866 "lastModified": 1685361114, 852 "lastModified": 1685361114,
@@ -996,7 +982,7 @@
996 "nixpkgs": "nixpkgs_2", 982 "nixpkgs": "nixpkgs_2",
997 "nixpkgs-eostre": "nixpkgs-eostre", 983 "nixpkgs-eostre": "nixpkgs-eostre",
998 "nixpkgs-pgbackrest": "nixpkgs-pgbackrest", 984 "nixpkgs-pgbackrest": "nixpkgs-pgbackrest",
999 "nixpkgs-stable": "nixpkgs-stable_4", 985 "nixpkgs-stable": "nixpkgs-stable_3",
1000 "nvfetcher": "nvfetcher", 986 "nvfetcher": "nvfetcher",
1001 "poetry2nix": "poetry2nix", 987 "poetry2nix": "poetry2nix",
1002 "prometheus-borg-exporter": "prometheus-borg-exporter", 988 "prometheus-borg-exporter": "prometheus-borg-exporter",
@@ -1146,11 +1132,11 @@
1146 "xwayland-satellite-unstable": { 1132 "xwayland-satellite-unstable": {
1147 "flake": false, 1133 "flake": false,
1148 "locked": { 1134 "locked": {
1149 "lastModified": 1750388715, 1135 "lastModified": 1750686869,
1150 "narHash": "sha256-6WMpcn3Ga/L71NiX9SdWw7ZELpNfrFnWJ0Gt2uAHjJg=", 1136 "narHash": "sha256-FS/rYXd96VBtKNJRTV2xTpTk8CgrYP+lFsFj0+VKgoY=",
1151 "owner": "Supreeeme", 1137 "owner": "Supreeeme",
1152 "repo": "xwayland-satellite", 1138 "repo": "xwayland-satellite",
1153 "rev": "03cbb2ee3a9da931bb9a39eb917674297a0b9318", 1139 "rev": "117af56a83e2d1d25016fbd504a2a040babe586a",
1154 "type": "github" 1140 "type": "github"
1155 }, 1141 },
1156 "original": { 1142 "original": {
diff --git a/hosts/sif/default.nix b/hosts/sif/default.nix
index a57c454c..467c9e99 100644
--- a/hosts/sif/default.nix
+++ b/hosts/sif/default.nix
@@ -60,7 +60,7 @@ in {
60 60
61 plymouth.enable = true; 61 plymouth.enable = true;
62 62
63 kernel.llvm.kernel = pkgs.linuxKernel.kernels.linux_latest; 63 kernelPackages = pkgs.linuxKernel.packages.linux_latest;
64 kernelPatches = [ 64 kernelPatches = [
65 { name = "edac-config"; 65 { name = "edac-config";
66 patch = null; 66 patch = null;
@@ -98,6 +98,8 @@ in {
98 server ptbtime2.ptb.de prefer iburst nts 98 server ptbtime2.ptb.de prefer iburst nts
99 server ptbtime3.ptb.de prefer iburst nts 99 server ptbtime3.ptb.de prefer iburst nts
100 server ptbtime4.ptb.de prefer iburst nts 100 server ptbtime4.ptb.de prefer iburst nts
101 pool ntppool1.time.nl prefer iburst nts
102 pool ntppool2.time.nl prefer iburst nts
101 103
102 authselectmode require 104 authselectmode require
103 minsources 3 105 minsources 3
diff --git a/modules/llvm_kernel.nix b/modules/llvm_kernel.nix
deleted file mode 100644
index 42b8bf95..00000000
--- a/modules/llvm_kernel.nix
+++ /dev/null
@@ -1,59 +0,0 @@
1{ config, pkgs, lib, ... }:
2let
3 cfg = config.boot.kernel.llvm;
4in {
5 options = {
6 boot.kernel.llvm = {
7 enable = lib.mkEnableOption "building linux kernel with clang/LLVM" // {
8 default = true;
9 };
10
11 kernel = lib.mkPackageOption pkgs [ "linuxKernel" "kernels" "linux_default" ] {};
12 };
13 };
14
15 config = lib.mkIf cfg.enable {
16 boot.kernelPackages =
17 with pkgs; # Cut down on repeated `pkgs.` declarations
18 let
19 # Choose whichever LLVM version you please. `llvmPackages` is the
20 # default version, `llvmPackages_latest` is the latest (at the time of
21 # writing, LLVM 17.0.6 and 18.1.8 respectively).
22 llvm = llvmPackages_latest;
23 # Same deal as LLVM; choose whichever kernel version you like.
24 # `linux` is the latest LTS, `linux_latest` is the latest stable.
25 inherit (cfg) kernel;
26 in
27 # Generate kernel modules for our custom kernel.
28 linuxPackagesFor (
29 # Override our chosen kernel version with our custom settings.
30 (kernel.override {
31 # Set our chosen version of LLVM as our standard environment.
32 stdenv = overrideCC llvm.stdenv (
33 # Tell our C compiler (Clang) to use LLVM bintools--normally GNU
34 # binutils are used even with Clang as the compiler.
35 llvm.stdenv.cc.override {
36 bintools = llvm.bintools;
37 }
38 );
39
40 # Tell Linux that we're compiling with Clang and LLVM.
41 extraMakeFlags = [ "LLVM=1" ];
42
43 # If you'd like to edit your kernel configuration, use
44 # `structuredExtraConfig`. For example, some options available to us
45 # when compiling with Clang and linking with LLD:
46 structuredExtraConfig = {
47 # CFI_CLANG = lib.kernel.yes;
48 # LTO_CLANG_THIN = lib.kernel.yes;
49 };
50 }
51 ).overrideAttrs
52 # Work around another NixOS specific issue where builds with WERROR=y
53 # are stopped by a benign error. See reference 1 below for details.
54 # Technically, this fix is only necessary with WERROR=y but the issue
55 # still causes a warning on builds where WERROR is unset.
56 { env.NIX_CFLAGS_COMPILE = "-Wno-unused-command-line-argument"; }
57 );
58 };
59}
diff --git a/system-profiles/zfs.nix b/system-profiles/zfs.nix
index f3147f9e..af9f1c17 100644
--- a/system-profiles/zfs.nix
+++ b/system-profiles/zfs.nix
@@ -1,8 +1,7 @@
1{ config, pkgs, lib, ... } : { 1{ config, pkgs, lib, ... } : {
2 config = { 2 config = {
3 boot = { 3 boot = {
4 kernelPackages = lib.mkIf (!config.boot.kernel.llvm.enable) pkgs.linuxPackages_6_12; 4 kernelPackages = pkgs.linuxPackages_6_12;
5 kernel.llvm.kernel = lib.mkIf config.boot.kernel.llvm.enable pkgs.linux_6_12;
6 zfs.package = pkgs.zfs_2_3; 5 zfs.package = pkgs.zfs_2_3;
7 6
8 supportedFilesystems.zfs = true; 7 supportedFilesystems.zfs = true;