summary refs log tree commit diff
path: root/pkgs/system/all-packages-generic.nix
diff options
context:
space:
mode:
authorArmijn Hemel <armijn@gpl-violations.org>2005-12-31 14:35:49 +0000
committerArmijn Hemel <armijn@gpl-violations.org>2005-12-31 14:35:49 +0000
commit3eb9903b16353bde60b76248e48fe9bfe833f868 (patch)
tree95f6079b8b40504f6db616499778f80996e3a9c5 /pkgs/system/all-packages-generic.nix
parentbcfef16b460ce3f265c6e254482f6cc65c5a3ace (diff)
downloadnixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.tar
nixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.tar.gz
nixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.tar.bz2
nixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.tar.lz
nixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.tar.xz
nixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.tar.zst
nixpkgs-3eb9903b16353bde60b76248e48fe9bfe833f868.zip
Add kernel headers for MIPS, uClibc for MIPS, binutils for MIPS, gcc for MIPS,
all in a generic way. Adding new platforms to cross compile applications for
with uClibc becomes pretty trivial this way (unless you want C++ support,
see 'maintainers/docs/cross.txt' for an explanation why this is so tough
to build with Nix.)

So, Nix starts with Linux/MIPS support in the New Year :)

svn path=/nixpkgs/trunk/; revision=4467
Diffstat (limited to 'pkgs/system/all-packages-generic.nix')
-rw-r--r--pkgs/system/all-packages-generic.nix50
1 files changed, 44 insertions, 6 deletions
diff --git a/pkgs/system/all-packages-generic.nix b/pkgs/system/all-packages-generic.nix
index 644dd428a82..6928a988c4a 100644
--- a/pkgs/system/all-packages-generic.nix
+++ b/pkgs/system/all-packages-generic.nix
@@ -489,20 +489,40 @@ rec {
     inherit stdenv;
   };
 
+  gcc40mips = (import ../build-support/gcc-cross-wrapper) {
+    nativeTools = false;
+    nativeGlibc = false;
+    cross = "mips-linux";
+    gcc = (import ../development/compilers/gcc-4.0-cross) {
+      inherit fetchurl stdenv noSysDirs;
+      langF77 = false;
+      langCC = false;
+      binutilsCross = binutilsMips;
+      kernelHeadersCross = kernelHeadersMips;
+      cross = "mips-linux";
+    };
+    inherit (stdenv.gcc) glibc;
+    binutils = binutilsMips;
+    inherit stdenv;
+  };
+
   gcc40arm = (import ../build-support/gcc-cross-wrapper) {
     nativeTools = false;
     nativeGlibc = false;
     cross = "arm-linux";
-    gcc = (import ../development/compilers/gcc-4.0-arm) {
-      inherit fetchurl stdenv noSysDirs binutilsArm kernelHeadersArm;
+    gcc = (import ../development/compilers/gcc-4.0-cross) {
+      inherit fetchurl stdenv noSysDirs;
       langF77 = false;
       langCC = false;
+      binutilsCross = binutilsArm;
+      kernelHeadersCross = kernelHeadersArm;
+      cross = "arm-linux";
     };
-    #inherit (stdenv.gcc) binutils glibc;
     inherit (stdenv.gcc) glibc;
     binutils = binutilsArm;
     inherit stdenv;
   };
+
   gcc40 = (import ../build-support/gcc-wrapper) {
     nativeTools = false;
     nativeGlibc = false;
@@ -1424,8 +1444,20 @@ rec {
   
   ### OS-SPECIFIC
 
-  uclibc = (import ../development/uclibc) {
-    inherit fetchurl stdenv gcc40arm kernelHeadersArm binutilsArm;
+  uclibcArm = (import ../development/uclibc) {
+    inherit fetchurl stdenv;
+    kernelHeadersCross = kernelHeadersArm;
+    binutilsCross = binutilsArm;
+    gccCross = gcc40arm;
+    cross = "arm-linux";
+  };
+
+  uclibcMips = (import ../development/uclibc) {
+    inherit fetchurl stdenv;
+    kernelHeadersCross = kernelHeadersMips;
+    binutilsCross = binutilsMips;
+    gccCross = gcc40mips;
+    cross = "mips-linux";
   };
 
   dietlibc = (import ../os-specific/linux/dietlibc) {
@@ -1461,8 +1493,14 @@ rec {
     inherit fetchurl stdenv;
   };
 
-  kernelHeadersArm = (import ../os-specific/linux/kernel-headers-arm) {
+  kernelHeadersArm = (import ../os-specific/linux/kernel-headers-cross) {
+    inherit fetchurl stdenv;
+    cross = "arm-linux";
+  };
+
+  kernelHeadersMips = (import ../os-specific/linux/kernel-headers-cross) {
     inherit fetchurl stdenv;
+    cross = "mips-linux";
   };
 
   kernel = (import ../os-specific/linux/kernel) {