aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--devShells/c.nix7
-rw-r--r--devShells/default.nix13
-rw-r--r--devShells/nuttx.nix4
-rw-r--r--devShells/riscv.nix4
4 files changed, 19 insertions, 9 deletions
diff --git a/devShells/c.nix b/devShells/c.nix
index 949b291..c1b5553 100644
--- a/devShells/c.nix
+++ b/devShells/c.nix
@@ -1,19 +1,20 @@
-{ nixpkgs, shellrc, system }:
+{ system, nixpkgs, default }:
let
pkgs = nixpkgs.legacyPackages.${system};
in pkgs.mkShell {
packages = (with pkgs; [
clang-tools
- gcc gdb
+ gcc gdb pkg-config
cppcheck flawfinder bear
meson
lcov massif-visualizer
]);
inputsFrom = with pkgs; [
check
+ curl
- shellrc.packages.${system}.default
+ default
];
meta.platforms = nixpkgs.lib.platforms.linux;
}
diff --git a/devShells/default.nix b/devShells/default.nix
index 6c91b20..be2d89f 100644
--- a/devShells/default.nix
+++ b/devShells/default.nix
@@ -1,14 +1,23 @@
{ nixpkgs, shellrc, system }:
let
+ default = let
+ pkgs = nixpkgs.legacyPackages.${system};
+ in pkgs.mkShell {
+ inputsFrom = with pkgs; [
+ shellrc.packages.${system}.default
+ ];
+ };
+
callDevelop = file: import file {
- inherit nixpkgs;
- inherit shellrc;
inherit system;
+ inherit nixpkgs;
+ inherit default;
};
in {
+ default = default;
armv6 = callDevelop ./nuttx.nix { arch = "armv6s-m"; };
armv7e = callDevelop ./nuttx.nix { arch = "armv7e-m"; fpu = "vfpv3-d16"; };
c = callDevelop ./c.nix;
diff --git a/devShells/nuttx.nix b/devShells/nuttx.nix
index d3303c1..7fa690c 100644
--- a/devShells/nuttx.nix
+++ b/devShells/nuttx.nix
@@ -1,4 +1,4 @@
-{ nixpkgs, shellrc, system }:
+{ system, nixpkgs, default }:
{ arch, fpu ? null }:
with nixpkgs.lib;
let
@@ -22,6 +22,6 @@ in pkgs.mkShell {
]) ++ (with pkgs-riscv.buildPackages; [
gcc gdb
]);
- inputsFrom = [ shellrc.packages.${system}.default ];
+ inputsFrom = [ default ];
meta.platforms = nixpkgs.lib.platforms.linux;
}
diff --git a/devShells/riscv.nix b/devShells/riscv.nix
index ded7859..bd19eef 100644
--- a/devShells/riscv.nix
+++ b/devShells/riscv.nix
@@ -1,4 +1,4 @@
-{ nixpkgs, shellrc, system }:
+{ system, nixpkgs, default }:
let
pkgs = nixpkgs.legacyPackages.${system};
pkgs-riscv = import nixpkgs.outPath {
@@ -18,6 +18,6 @@ in pkgs.mkShell {
]) ++ (with pkgs-riscv.buildPackages; [
gcc pkg-config
]);
- inputsFrom = [ shellrc.packages.${system}.default ];
+ inputsFrom = [ default ];
meta.platforms = nixpkgs.lib.platforms.linux;
}