From a9a70856845625bd6b9f988d07553774f88d18d4 Mon Sep 17 00:00:00 2001 From: Shea Levy Date: Sun, 29 Jul 2012 04:31:40 -0400 Subject: [PATCH] linux/kernel/manual-config: Allow manually specifying features, cleanup --- .../linux/kernel/manual-config.nix | 24 +++++++++++++------ 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/pkgs/os-specific/linux/kernel/manual-config.nix b/pkgs/os-specific/linux/kernel/manual-config.nix index d6cf3bf7612..730983d895f 100644 --- a/pkgs/os-specific/linux/kernel/manual-config.nix +++ b/pkgs/os-specific/linux/kernel/manual-config.nix @@ -1,7 +1,5 @@ { stdenv, runCommand, nettools, perl, kmod }: -{ version, modDirVersion ? version, src, patches ? [], config }: - with stdenv.lib; let @@ -39,13 +37,25 @@ let modular = isYes "MODULES"; }; - features = readFeatures config; - - commonMakeFlags = [ - "O=../build" - ]; in +{ + # The kernel version + version, + # The version of the kernel module directory + modDirVersion ? version, + # The kernel source (tarball, git checkout, etc.) + src, + # Any patches + patches ? [], + # The kernel .config file + config, + # Manually specified features the kernel supports + features ? readFeatures config +}: + +let commonMakeFlags = [ "O=../build" ]; in + stdenv.mkDerivation ({ name = "linux-${version}";