diff options
author | Lluís Batlle i Rossell <viric@vicerveza.homeunix.net> | 2010-03-10 20:44:48 +0000 |
---|---|---|
committer | Lluís Batlle i Rossell <viric@vicerveza.homeunix.net> | 2010-03-10 20:44:48 +0000 |
commit | 648b17197ff0812c9f94816e134001ce918a26c1 (patch) | |
tree | a4bee5c725e3c5b1461db8e601e0a21e96fb9a60 /pkgs | |
parent | 57ea53f67a6e28d77b17aebda96692018bf88e68 (diff) |
Adding linux 2.4 kernel headers for cross builds.
(I'm thinking of OpenWRT machines out there, mips, with linux 2.4) svn path=/nixpkgs/trunk/; revision=20539
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/top-level/all-packages.nix | 15 | ||||
-rw-r--r-- | pkgs/top-level/platforms.nix | 3 | ||||
-rw-r--r-- | pkgs/top-level/release-cross.nix | 10 |
3 files changed, 23 insertions, 5 deletions
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index dfa4928b2d344..37c6e5238b1ea 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5891,11 +5891,24 @@ let linuxHeaders = linuxHeaders_2_6_28; - linuxHeadersCross = forceBuildDrv (import ../os-specific/linux/kernel-headers/2.6.32.nix { + linuxHeaders26Cross = forceBuildDrv (import ../os-specific/linux/kernel-headers/2.6.32.nix { inherit stdenv fetchurl perl; cross = assert crossSystem != null; crossSystem; }); + linuxHeaders24Cross = forceBuildDrv (import ../os-specific/linux/kernel-headers/2.4.nix { + inherit stdenv fetchurl perl; + cross = assert crossSystem != null; crossSystem; + }); + + # We can choose: + linuxHeadersCrossChooser = ver : if (ver == "2.4") then linuxHeaders24Cross + else if (ver == "2.6") then linuxHeaders26Cross + else throw "Unknown linux kernel version"; + + linuxHeadersCross = assert crossSystem != null; + linuxHeadersCrossChooser crossSystem.platform.kernelMajor; + linuxHeaders_2_6_18 = import ../os-specific/linux/kernel-headers/2.6.18.5.nix { inherit fetchurl stdenv unifdef; }; diff --git a/pkgs/top-level/platforms.nix b/pkgs/top-level/platforms.nix index 3c680cac9e401..eb2943f8c70ca 100644 --- a/pkgs/top-level/platforms.nix +++ b/pkgs/top-level/platforms.nix @@ -26,6 +26,7 @@ rec { sheevaplug = { name = "sheevaplug"; + kernelMajor = "2.6"; kernelHeadersBaseConfig = "kirkwood_defconfig"; kernelBaseConfig = "kirkwood_defconfig"; kernelArch = "arm"; @@ -69,6 +70,7 @@ rec { versatileARM = { name = "versatileARM"; + kernelMajor = "2.6"; kernelHeadersBaseConfig = "versatile_defconfig"; kernelBaseConfig = "versatile_defconfig"; kernelArch = "arm"; @@ -106,6 +108,7 @@ rec { integratorCP = { name = "integratorCP"; + kernelMajor = "2.6"; kernelHeadersBaseConfig = "integrator_defconfig"; kernelBaseConfig = "integrator_defconfig"; kernelArch = "arm"; diff --git a/pkgs/top-level/release-cross.nix b/pkgs/top-level/release-cross.nix index 7d4173bd988b4..37ecda0e02762 100644 --- a/pkgs/top-level/release-cross.nix +++ b/pkgs/top-level/release-cross.nix @@ -80,20 +80,21 @@ let arch = "mips"; float = "soft"; withTLS = true; - libc = "glibc"; + libc = "uclibc"; platform = { name = "malta"; + kernelMajor = "2.4"; kernelBaseConfig = "malta_defconfig"; - kernelHeadersBaseConfig = "malta_defconfig"; + kernelHeadersBaseConfig = "defconfig-malta"; uboot = null; kernelArch = "mips"; kernelAutoModules = false; - kernelTarget = "vmlinux.bin"; + kernelTarget = "vmlinux"; }; openssl.system = "linux-generic32"; }; in { - crossMipselLinux = mapTestOnCross crossSystem basic; + crossMipselLinux24 = mapTestOnCross crossSystem basic; }) // ( /* Test some cross builds to the ultrasparc */ @@ -108,6 +109,7 @@ let libc = "glibc"; platform = { name = "ultrasparc"; + kernelMajor = "2.6"; kernelHeadersBaseConfig = "sparc64_defconfig"; kernelBaseConfig = "sparc64_defconfig"; kernelArch = "sparc"; |