rust: add support for armv6l-linux and armv7l-linux

This commit is contained in:
Ben Wolsieffer
2018-12-20 19:28:09 -05:00
parent 9ab168b500
commit 83ac9c07e4
9 changed files with 32 additions and 50 deletions

View File

@@ -11,6 +11,14 @@
, llvmPackages_5
, pkgsBuildTarget, pkgsBuildBuild
}: rec {
toRustTarget = platform: with platform.parsed; let
cpu_ = {
"armv7a" = "armv7";
"armv7l" = "armv7";
"armv6l" = "arm";
}.${cpu.name} or cpu.name;
in "${cpu_}-${vendor.name}-${kernel.name}${lib.optionalString (abi.name != "unknown") "-${abi.name}"}";
makeRustPlatform = { rustc, cargo, ... }: {
rust = {
inherit rustc cargo;