blob: 0246ad2756edef2bcb5108955f4fdcc5b0138c82 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
{ system, nixpkgs
, default, c
, arch, fpu ? null
}:
with nixpkgs.lib;
let
pkgs = import nixpkgs.outPath {
localSystem = system;
crossSystem = {
config = "arm-none-eabi" + (optionalString (fpu != null) "hf");
libc = "newlib";
gcc = {
arch = arch;
} // (optionalAttrs (fpu != null) { fpu = fpu; });
};
};
in pkgs.buildPackages.mkShell {
packages = with pkgs.buildPackages; [
kconfig-frontends genromfs xxd
openocd
gcc gdb
];
inputsFrom = [ default c ];
meta.platforms = nixpkgs.lib.platforms.linux;
}
|