aboutsummaryrefslogtreecommitdiff
path: root/pkgs/build-support/bintools-wrapper
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2020-11-28 21:57:00 +0000
committerJohn Ericson <John.Ericson@Obsidian.Systems>2020-11-29 00:03:51 +0000
commit04f6973200954f9ecd0f2fbc1d6ae029cd7ed857 (patch)
tree256f853fa3fa812b67fbd639bd9120bf06a683a3 /pkgs/build-support/bintools-wrapper
parent40e7be11c8098d11217786d106462e958e1d8718 (diff)
lib, binutils: Move Risc-V bfdEmulation to be by the others
Diffstat (limited to 'pkgs/build-support/bintools-wrapper')
-rw-r--r--pkgs/build-support/bintools-wrapper/default.nix3
1 files changed, 2 insertions, 1 deletions
diff --git a/pkgs/build-support/bintools-wrapper/default.nix b/pkgs/build-support/bintools-wrapper/default.nix
index 3b1b8ff570a8..6da0e58436d0 100644
--- a/pkgs/build-support/bintools-wrapper/default.nix
+++ b/pkgs/build-support/bintools-wrapper/default.nix
@@ -167,7 +167,7 @@ stdenv.mkDerivation {
else if targetPlatform.isWindows then "pe"
else "elf" + toString targetPlatform.parsed.cpu.bits;
endianPrefix = if targetPlatform.isBigEndian then "big" else "little";
- sep = optionalString (!targetPlatform.isMips && !targetPlatform.isPower) "-";
+ sep = optionalString (!targetPlatform.isMips && !targetPlatform.isPower && !targetPlatform.isRiscV) "-";
arch =
/**/ if targetPlatform.isAarch64 then endianPrefix + "aarch64"
else if targetPlatform.isAarch32 then endianPrefix + "arm"
@@ -187,6 +187,7 @@ stdenv.mkDerivation {
else if targetPlatform.isAlpha then "alpha"
else if targetPlatform.isVc4 then "vc4"
else if targetPlatform.isOr1k then "or1k"
+ else if targetPlatform.isRiscV then "lriscv"
else throw "unknown emulation for platform: ${targetPlatform.config}";
in if targetPlatform.useLLVM or false then ""
else targetPlatform.platform.bfdEmulation or (fmt + sep + arch);