aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2022-10-31 16:00:14 +0100
committerKarel Kočí <cynerd@email.cz>2022-10-31 16:00:14 +0100
commitef902c887abca97a7efe39f13ee87674680a47c4 (patch)
tree95a0ce7692a459ad61a695b30888d8dea9b7a4de
parentc5a4325596fbb71e75f4f945db5ab70881b43357 (diff)
downloadnixos-personal-ef902c887abca97a7efe39f13ee87674680a47c4.tar.gz
nixos-personal-ef902c887abca97a7efe39f13ee87674680a47c4.tar.bz2
nixos-personal-ef902c887abca97a7efe39f13ee87674680a47c4.zip
devShells/nuttx: improve some syntax
-rw-r--r--devShells/nuttx.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/devShells/nuttx.nix b/devShells/nuttx.nix
index 03f51f9..ef6e632 100644
--- a/devShells/nuttx.nix
+++ b/devShells/nuttx.nix
@@ -8,7 +8,7 @@ let
pkgs = import nixpkgs.outPath {
localSystem = system;
crossSystem = {
- config = if (match "armv.*" arch != null) then
+ config = if (hasPrefix "armv" arch) then
"arm-none-eabi" + (optionalString (fpu != null) "hf")
else "riscv32-none-elf";
libc = "newlib";
@@ -23,7 +23,7 @@ in pkgs.buildPackages.mkShell {
kconfig-frontends genromfs xxd
openocd
gcc gdb
- ] ++ (optionals (match "rv32.*" arch != null) [
+ ] ++ (optionals (hasPrefix "rv32" arch) [
esptool
]);
inputsFrom = [ default c ];