-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathflake.nix
54 lines (54 loc) · 1.7 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
{
description = "A modern SAT solver in Rust";
inputs.nixpkgs.url = "github:NixOS/nixpkgs";
inputs.sat-bench.url = "github:shnarazk/SAT-bench";
outputs = { self, nixpkgs, sat-bench }:
{
packages = builtins.listToAttrs
(map
(system:
with import nixpkgs { system = "${system}"; };
{
name = system;
value = {
default =
rustPlatform.buildRustPackage rec {
version = "0.17.4-20250128";
name = "splr-${version}";
pname = "splr";
src = self;
cargoHash = "sha256-Mbd15EIej0903yh6LWUmegpfujZScKMXedqgNBjjM30=";
buildInputs = rustc.buildInputs ++ lib.optional stdenv.isDarwin [ libiconv ];
buildPhase = "cargo build --release";
installPhase = ''
mkdir -p $out/bin;
install -t $out/bin target/release/splr target/release/dmcr
'';
};
};
}
)
[ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]
);
devShell = builtins.listToAttrs
(map
(system:
with import nixpkgs { system = "${system}"; };
{
name = system;
value = mkShell {
packages = [
bashInteractive
samply
tokei
# cargo-watch
# nixpkgs.lldb_19
sat-bench.packages.${system}.default
];
};
}
)
[ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]
);
};
}