summary refs log tree commit diff
path: root/pkgs/build-support/kernel
diff options
context:
space:
mode:
authorLinus Heckemann <git@sphalerite.org>2020-09-03 14:11:41 +0200
committerLinus Heckemann <git@sphalerite.org>2020-12-17 11:10:36 +0100
commita343ff7e1433130ac293e96bb04ea5dbe363fff1 (patch)
tree055ec06245ddd87be6a24e047bdad5544de7c358 /pkgs/build-support/kernel
parentb8e7a8d9236e5c88f5025f0fbcbf8a4aea2abb5a (diff)
downloadnixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.tar
nixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.tar.gz
nixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.tar.bz2
nixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.tar.lz
nixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.tar.xz
nixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.tar.zst
nixpkgs-a343ff7e1433130ac293e96bb04ea5dbe363fff1.zip
makeInitrd: make uinitrd behaviour optional
Diffstat (limited to 'pkgs/build-support/kernel')
-rw-r--r--pkgs/build-support/kernel/make-initrd.nix5
1 files changed, 2 insertions, 3 deletions
diff --git a/pkgs/build-support/kernel/make-initrd.nix b/pkgs/build-support/kernel/make-initrd.nix
index ed5dbdaee17..3915335b8da 100644
--- a/pkgs/build-support/kernel/make-initrd.nix
+++ b/pkgs/build-support/kernel/make-initrd.nix
@@ -17,6 +17,7 @@
 , compressor ? "gzip -9n"
 , prepend ? []
 , lib
+, makeUInitrd ? stdenvNoCC.hostPlatform.platform.kernelTarget == "uImage"
 }:
 let
   # !!! Move this into a public lib function, it is probably useful for others
@@ -24,12 +25,10 @@ let
     lib.concatStringsSep "-" (filter (x: !(isList x)) (split "[^a-zA-Z0-9_=.?-]+" x));
 
 in stdenvNoCC.mkDerivation rec {
-  inherit name;
+  inherit name makeUInitrd;
 
   builder = ./make-initrd.sh;
 
-  makeUInitrd = stdenvNoCC.hostPlatform.platform.kernelTarget == "uImage";
-
   nativeBuildInputs = [ perl cpio ]
     ++ stdenvNoCC.lib.optional makeUInitrd ubootTools;