Created
March 26, 2019 15:26
-
-
Save lheckemann/4cd0cc20b475473ef1ebee4fe51fa649 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 6min kernel, 7m30 zfs, on community box | |
{ pkgs ? import <nixpkgs> {}}: with pkgs; | |
linuxPackagesFor ((buildLinux rec { | |
src = fetchFromGitHub { | |
owner = "friendlyarm"; | |
repo = "kernel-rockchip"; | |
rev = "decbad503ca983f939baca6c19a79117b11f5bd6"; | |
sha256 = "1mwykah9yr68gscrc8lqi3jay4553yq9cs86m5b21wizm5ikhpfn"; | |
}; | |
version = "4.4.154"; | |
defconfig = "nanopi4_linux_defconfig"; | |
structuredExtraConfig = with import (pkgs.path + "/lib/kernel.nix") {inherit lib version;}; { | |
CROSS_COMPILE = freeform ""; | |
IKCONFIG = yes; | |
IKCONFIG_PROC = yes; | |
BPF_SYSCALL = yes; | |
IP_NF_MATCH_RPFILTER = yes; | |
}; | |
allowImportFromDerivation = true; | |
kernelPatches = []; | |
}).overrideAttrs (o: { | |
buildFlags = ["nanopi4-images"] ++ o.buildFlags; | |
nativeBuildInputs = [ lz4 ] ++ o.nativeBuildInputs; | |
postInstall = o.postInstall + '' | |
cp $buildRoot/kernel.img $buildRoot/resource.img $out | |
''; | |
})) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment