diff options
-rw-r--r-- | pkgs/os-specific/linux/kernel/builder.sh | 11 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/generic.nix | 4 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 12 |
3 files changed, 10 insertions, 17 deletions
diff --git a/pkgs/os-specific/linux/kernel/builder.sh b/pkgs/os-specific/linux/kernel/builder.sh index 621237fa9a3f..8fb5e9f91eb4 100644 --- a/pkgs/os-specific/linux/kernel/builder.sh +++ b/pkgs/os-specific/linux/kernel/builder.sh @@ -23,8 +23,6 @@ configurePhase() { export INSTALL_PATH=$out export INSTALL_MOD_PATH=$out - substituteInPlace scripts/depmod.sh --replace '-b "$INSTALL_MOD_PATH"' "" - # Set our own localversion, if specified. rm -f localversion* if test -n "$localVersion"; then @@ -70,14 +68,9 @@ installPhase() { cp vmlinux $out if grep -q "CONFIG_MODULES=y" .config; then - # Install the modules in $out/lib/modules with matching paths - # in modules.dep (i.e., refererring to $out/lib/modules, not - # /lib/modules). The depmod_opts= is to prevent the kernel - # from passing `-b PATH' to depmod. - export MODULE_DIR=$out/lib/modules/ - substituteInPlace Makefile --replace '-b $(INSTALL_MOD_PATH)' '' + # Install the modules in $out/lib/modules. make modules_install \ - DEPMOD=$module_init_tools/sbin/depmod depmod_opts= \ + DEPMOD=$kmod/sbin/depmod \ $makeFlags "${makeFlagsArray[@]}" \ $installFlags "${installFlagsArray[@]}" diff --git a/pkgs/os-specific/linux/kernel/generic.nix b/pkgs/os-specific/linux/kernel/generic.nix index ad243ae5b7c1..1ade24736279 100644 --- a/pkgs/os-specific/linux/kernel/generic.nix +++ b/pkgs/os-specific/linux/kernel/generic.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, perl, mktemp, module_init_tools, bc +{ stdenv, fetchurl, perl, mktemp, kmod, bc , # The kernel source tarball. src @@ -78,7 +78,7 @@ stdenv.mkDerivation { generateConfig = ./generate-config.pl; - inherit preConfigure src module_init_tools localVersion postInstall postBuild; + inherit preConfigure src kmod localVersion postInstall postBuild; patches = map (p: p.patch) kernelPatches; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 8b36b2f1595f..cdd240d89b85 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6377,7 +6377,7 @@ let kernelPatches = callPackage ../os-specific/linux/kernel/patches.nix { }; linux_3_0 = makeOverridable (import ../os-specific/linux/kernel/linux-3.0.nix) { - inherit fetchurl stdenv perl mktemp bc module_init_tools ubootChooser; + inherit fetchurl stdenv perl mktemp bc kmod ubootChooser; kernelPatches = [ kernelPatches.sec_perm_2_6_24 # kernelPatches.aufs3_0 @@ -6385,7 +6385,7 @@ let }; linux_3_2 = makeOverridable (import ../os-specific/linux/kernel/linux-3.2.nix) { - inherit fetchurl stdenv perl mktemp bc module_init_tools ubootChooser; + inherit fetchurl stdenv perl mktemp bc kmod ubootChooser; kernelPatches = [ kernelPatches.sec_perm_2_6_24 # kernelPatches.aufs3_2 @@ -6411,7 +6411,7 @@ let }); linux_3_4 = makeOverridable (import ../os-specific/linux/kernel/linux-3.4.nix) { - inherit fetchurl stdenv perl mktemp bc module_init_tools ubootChooser; + inherit fetchurl stdenv perl mktemp bc kmod ubootChooser; kernelPatches = [ kernelPatches.sec_perm_2_6_24 # kernelPatches.aufs3_4 @@ -6430,11 +6430,11 @@ let }); linux_3_6_rpi = makeOverridable (import ../os-specific/linux/kernel/linux-rpi-3.6.nix) { - inherit fetchurl stdenv perl mktemp bc module_init_tools ubootChooser; + inherit fetchurl stdenv perl mktemp bc kmod ubootChooser; }; linux_3_9 = makeOverridable (import ../os-specific/linux/kernel/linux-3.9.nix) { - inherit fetchurl stdenv perl mktemp bc module_init_tools ubootChooser; + inherit fetchurl stdenv perl mktemp bc kmod ubootChooser; kernelPatches = [ kernelPatches.sec_perm_2_6_24 @@ -6446,7 +6446,7 @@ let }; linux_3_10 = makeOverridable (import ../os-specific/linux/kernel/linux-3.10.nix) { - inherit fetchurl stdenv perl mktemp bc module_init_tools ubootChooser; + inherit fetchurl stdenv perl mktemp bc kmod ubootChooser; kernelPatches = [ kernelPatches.sec_perm_2_6_24 |