forked from sogno-platform/dpsim
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
57 lines (52 loc) · 1.61 KB
/
flake.nix
File metadata and controls
57 lines (52 loc) · 1.61 KB
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
{
description = "DPsim - Solver library for dynamic power system simulation";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
flake-utils.url = "github:numtide/flake-utils";
villas-node = {
url = "github:VILLASframework/node";
};
};
outputs =
{
self,
nixpkgs,
flake-utils,
villas-node,
}:
flake-utils.lib.eachDefaultSystem (
system:
let
pkgs = import nixpkgs {
inherit system;
# Required for old sundials version
config.permittedInsecurePackages = [ "python-2.7.18.8" ];
overlays = [
(final: prev: let
villasPkg = villas-node.packages.${system}.villas-node;
in {
readerwriterqueue = final.callPackage ./packaging/Nix/readerwriterqueue.nix { };
cimpp = final.callPackage ./packaging/Nix/cimpp.nix { };
suitesparse-dpsim = prev.callPackage ./packaging/Nix/suitesparse.nix { };
sundials321 = prev.callPackage ./packaging/Nix/sundials.nix { };
dpsim = final.callPackage ./packaging/Nix/dpsim.nix { villas-node=villasPkg; };
dpsimpy = final.callPackage ./packaging/Nix/dpsimpy.nix { };
})
];
};
in {
packages = {
default = pkgs.dpsim;
inherit (pkgs)
dpsim
dpsimpy
readerwriterqueue
cimpp
;
};
devShells = {
default = pkgs.callPackage ./packaging/Nix/shell.nix { };
};
}
);
}