1 { config, pkgs, lib, ... }:
4 configfile = builtins.storePath (builtins.toFile "config" (lib.concatStringsSep "\n"
5 (map (builtins.getAttr "configLine") config.system.requiredKernelConfig))
8 origKernel = pkgs.buildLinux {
9 inherit (pkgs.linux) src version stdenv;
11 allowImportFromDerivation = true;
12 kernelPatches = [ pkgs.kernelPatches.cifs_timeout_2_6_38 ];
15 kernel = origKernel // (derivation (origKernel.drvAttrs // {
19 make $makeFlags "''${makeFlagsArray[@]}" mrproper
20 make $makeFlags "''${makeFlagsArray[@]}" KCONFIG_ALLCONFIG=${configfile} allnoconfig
25 kernelPackages = pkgs.linuxPackagesFor kernel;
27 boot.kernelPackages = kernelPackages;