summary refs log tree commit diff
path: root/lib
diff options
context:
space:
mode:
authorMatthew Bauer <mjbauer95@gmail.com>2018-10-30 13:46:01 -0500
committerMatthew Bauer <mjbauer95@gmail.com>2018-10-30 13:46:01 -0500
commit2634d376175d300c1c2572defe8c6d348ad61e20 (patch)
tree7c7798c6e97f390e38ea75ba9f6a2dc88391491d /lib
parent7a03d2d65f5fcb06ef693a442b806a34ab0803c7 (diff)
downloadnixlib-2634d376175d300c1c2572defe8c6d348ad61e20.tar
nixlib-2634d376175d300c1c2572defe8c6d348ad61e20.tar.gz
nixlib-2634d376175d300c1c2572defe8c6d348ad61e20.tar.bz2
nixlib-2634d376175d300c1c2572defe8c6d348ad61e20.tar.lz
nixlib-2634d376175d300c1c2572defe8c6d348ad61e20.tar.xz
nixlib-2634d376175d300c1c2572defe8c6d348ad61e20.tar.zst
nixlib-2634d376175d300c1c2572defe8c6d348ad61e20.zip
systems/examples: add i686 & x86-64 embedded
Fixes #28160
Diffstat (limited to 'lib')
-rw-r--r--lib/systems/examples.nix10
-rw-r--r--lib/systems/parse.nix2
2 files changed, 12 insertions, 0 deletions
diff --git a/lib/systems/examples.nix b/lib/systems/examples.nix
index 2bfa9700ccd1..a40c38924245 100644
--- a/lib/systems/examples.nix
+++ b/lib/systems/examples.nix
@@ -118,6 +118,16 @@ rec {
     libc = "newlib";
   };
 
+  i686-embedded = {
+    config = "i686-elf";
+    libc = "newlib";
+  };
+
+  x86_64-embedded = {
+    config = "x86_64-elf";
+    libc = "newlib";
+  };
+
   #
   # Darwin
   #
diff --git a/lib/systems/parse.nix b/lib/systems/parse.nix
index a390a098c60f..db97a5c4b33b 100644
--- a/lib/systems/parse.nix
+++ b/lib/systems/parse.nix
@@ -267,6 +267,8 @@ rec {
         then { cpu = elemAt l 0;                      kernel = "windows";  abi = "cygnus";   }
       else if (elemAt l 1 == "eabi")
         then { cpu = elemAt l 0; vendor = "none"; kernel = "none"; abi = elemAt l 1; }
+      else if (elemAt l 1 == "elf")
+        then { cpu = elemAt l 0; vendor = "none"; kernel = "none"; abi = elemAt l 1; }
       else   { cpu = elemAt l 0;                      kernel = elemAt l 1;                   };
     "3" = # Awkwards hacks, beware!
       if elemAt l 1 == "apple"