diff options
author | Vladimír Čunát <v@cunat.cz> | 2019-09-02 23:25:24 +0200 |
---|---|---|
committer | Vladimír Čunát <v@cunat.cz> | 2019-09-02 23:25:24 +0200 |
commit | f21211ebfe21797c6f0444d42ec7cb835c737388 (patch) | |
tree | 816465981f650242d4b22e0f01b912917e7008f8 /lib/systems/parse.nix | |
parent | b291f2a9953d48d6edc5c73776db9ba289ccf213 (diff) | |
parent | 12ae04518b004adf949a43125954b99c05189e6f (diff) | |
download | nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.tar nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.tar.gz nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.tar.bz2 nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.tar.lz nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.tar.xz nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.tar.zst nixpkgs-f21211ebfe21797c6f0444d42ec7cb835c737388.zip |
Merge branch 'master' into staging
Diffstat (limited to 'lib/systems/parse.nix')
-rw-r--r-- | lib/systems/parse.nix | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/systems/parse.nix b/lib/systems/parse.nix index 1339f50f057..5e12df32ffd 100644 --- a/lib/systems/parse.nix +++ b/lib/systems/parse.nix @@ -106,11 +106,13 @@ rec { wasm32 = { bits = 32; significantByte = littleEndian; family = "wasm"; }; wasm64 = { bits = 64; significantByte = littleEndian; family = "wasm"; }; - + alpha = { bits = 64; significantByte = littleEndian; family = "alpha"; }; msp430 = { bits = 16; significantByte = littleEndian; family = "msp430"; }; avr = { bits = 8; family = "avr"; }; + + js = { bits = 32; significantByte = littleEndian; family = "js"; }; }; # Determine where two CPUs are compatible with each other. That is, @@ -271,6 +273,7 @@ rec { solaris = { execFormat = elf; families = { }; }; wasi = { execFormat = wasm; families = { }; }; windows = { execFormat = pe; families = { }; }; + ghcjs = { execFormat = unknown; families = { }; }; } // { # aliases # 'darwin' is the kernel for all of them. We choose macOS by default. darwin = kernels.macos; @@ -384,6 +387,8 @@ rec { then { cpu = elemAt l 0; vendor = elemAt l 1; kernel = elemAt l 2; } else if (elem (elemAt l 2) ["eabi" "eabihf" "elf"]) then { cpu = elemAt l 0; vendor = "unknown"; kernel = elemAt l 1; abi = elemAt l 2; } + else if (elemAt l 2 == "ghcjs") + then { cpu = elemAt l 0; vendor = "unknown"; kernel = elemAt l 2; } else throw "Target specification with 3 components is ambiguous"; "4" = { cpu = elemAt l 0; vendor = elemAt l 1; kernel = elemAt l 2; abi = elemAt l 3; }; }.${toString (length l)} |