-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathflake.nix
119 lines (113 loc) · 5.19 KB
/
flake.nix
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
{
description = "Custom nixpkgs for OSI";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
};
outputs =
{ self, nixpkgs, ... }:
let
system = "x86_64-linux";
pkgs = import nixpkgs {
inherit system;
config.allowUnfree = true;
};
in
{
overlays.default = final: prev: rec {
dev-env = prev.callPackage ./pkgs/dev-env/package.nix { };
ergogen = prev.callPackage ./pkgs/ergogen/package.nix { };
hello-nix = prev.callPackage ./pkgs/hello-nix/package.nix { };
hypre = prev.callPackage ./pkgs/hypre/package.nix { };
#mpi = prev.callPackage ./pkgs/mpi { };
scotch = prev.callPackage ./pkgs/scotch/package.nix { };
#libspatialindex = pkgs.callPackage ./pkgs/libspatialindex/package.nix { };
petsc = prev.callPackage ./pkgs/petsc { };
petsc-project = prev.callPackage ./pkgs/petsc-project/package.nix { };
petscrc-update = prev.callPackage ./pkgs/petscrc-update/package.nix { };
waybar-weather = prev.callPackage ./pkgs/waybar-weather { };
#petsc4py = prev.python311Packages.callPackage ./pkgs/petsc4py { inherit petsc; };
#mpi4py = prev.python311Packages.callPackage ./pkgs/mpi4py { };
python311 = prev.python311.override {
packageOverrides = py-final: _: rec {
fenicsx = py-final.callPackage ./pkgs/fenicsx {
inherit petsc petsc4py mpi4py;
};
mpi4py = py-final.callPackage ./pkgs/mpi4py { };
petsc4py = py-final.callPackage ./pkgs/petsc4py { inherit petsc; };
};
};
# pythonPackagesOverlays = (prev.pythonPackagesOverlays or [ ]) ++ [
# (python-final: python-prev: rec {
# fenicsx = python-final.callPackage ./pkgs/fenicsx {
# inherit petsc petsc4py mpi4py nanobind;
# };
# pylit = python-final.callPackage ./pkgs/pylit { };
# mpi4py = python-final.callPackage ./pkgs/mpi4py { };
# nanobind = python-final.callPackage ./pkgs/nanobind { };
# petsc4py = python-final.callPackage ./pkgs/petsc4py {
# inherit petsc;
# };
# recursivenodes = python-final.callPackage ./pkgs/recursivenodes { };
# firedrake = python-final.callPackage ./pkgs/firedrake {
# inherit mpi4py petsc pylit recursivenodes;};
# })
# ];
# python3 =
# let
# self = prev.python3.override {
# inherit self;
# packageOverrides = prev.lib.composeManyExtensions final.pythonPackagesOverlays;
# }; in
# self;
# python3Packages = final.python3.pkgs;
# Python extensions
# pythonPackagesExtensions = (prev.pythonPackagesExtensions or [ ]) ++ [
# (python-final: python-prev: rec {
# # Custom Python packages
# fenicsx = python-prev.fenicsx.callPackage ./pkgs/fenicsx {
# inherit petsc petsc4py mpi4py nanobind;
# };
# pylit = python-final.callPackage ./pkgs/pylit { };
# mpi4py = python-final.callPackage ./pkgs/mpi4py { };
# #nanobind = python-final.callPackage ./pkgs/nanobind { };
# petsc4py = python-final.callPackage ./pkgs/petsc4py { inherit petsc; };
# recursivenodes = python-final.callPackage ./pkgs/recursivenodes { };
# firedrake = python-final.callPackage ./pkgs/firedrake {
# inherit mpi4py petsc pylit recursiven"odes;
# };
# })
# ];
#
# # Extend Python 3 packages with the extensions
# python3 = prev.python3.override {
# packageOverrides = prev.lib.composeExtensions prev.pythonPackagesExtensions;
# };
# python3Packages = final.python3.pkgs;
};
packages.${system} = rec {
hello-nix = pkgs.callPackage ./pkgs/hello-nix/package.nix { };
asciimatics2 = pkgs.python3Packages.callPackage ./pkgs/numpy2 { };
dev-env = pkgs.callPackage ./pkgs/dev-env/package.nix { };
fenicsx = pkgs.python311Packages.callPackage ./pkgs/fenicsx {
inherit petsc petsc4py mpi4py nanobind;
};
ergogen = pkgs.callPackage ./pkgs/ergogen/package.nix { };
hypre = pkgs.callPackage ./pkgs/hypre/package.nix { };
scotch = pkgs.callPackage ./pkgs/scotch/package.nix { };
libspatialindex = pkgs.callPackage ./pkgs/libspatialindex/package.nix { };
#mpi = pkgs.callPackage ./pkgs/mpi { };
mpi4py = pkgs.python3Packages.callPackage ./pkgs/mpi4py { };
nanobind = pkgs.python3Packages.callPackage ./pkgs/nanobind { };
petsc = pkgs.callPackage ./pkgs/petsc { };
petsc-project = pkgs.callPackage ./pkgs/petsc-project/package.nix { };
petscrc-update = pkgs.callPackage ./pkgs/petscrc-update/package.nix { };
petsc4py = pkgs.python3Packages.callPackage ./pkgs/petsc4py {
inherit petsc; };
pylit = pkgs.python3Packages.callPackage ./pkgs/pylit { };
recursivenodes = pkgs.python3Packages.callPackage ./pkgs/recursivenodes { };
firedrake = pkgs.python3Packages.callPackage ./pkgs/firedrake {
inherit mpi4py petsc pylit recursivenodes nanobind; };
waybar-weather = pkgs.callPackage ./pkgs/waybar-weather { };
};
};
}