Skip to content

Commit 41cf466

Browse files
committed
nix: repair flake for Nix 2.35 / macOS 26, take provers from nixpkgs
The flake had rotted against current toolchains: - `nixpkgs` declared both a URL and a `follows`; Nix >= 2.25 rejects the ambiguity (the `follows` was what the lock resolved all along). - The opam `conf-git` check had no git in its build environment; give it one via the overlay, like the existing `conf-pkg-config` fix. - opam-nix (2025-01) referenced `darwin.apple_sdk`, removed from nixpkgs, and its pinned nixpkgs shipped binaries that macOS 26's dyld rejects (duplicate LC_RPATH). Update opam-nix to 2026-06, re-pinning opam-repository to the previous revision so the OCaml package set (4.14.2, why3 1.8.0) is unchanged. - The pinned provers (z3 4.12.6, cvc4 1.8, cvc5 1.0.9) no longer compile with the clang 19 that comes with the newer nixpkgs. Take z3 (4.15.1) and cvc5 (1.3.0) directly from nixpkgs and drop cvc4 (archived upstream), removing the source pins and the mkProverPackage machinery. - ci: bump install-nix-action to v31 so CI exercises a current Nix (v26's would not have caught the input conflict), cachix-action to v17.
1 parent 0096d84 commit 41cf466

3 files changed

Lines changed: 94 additions & 101 deletions

File tree

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,11 +94,11 @@ jobs:
9494
steps:
9595
- uses: actions/checkout@v4
9696
- name: Setup Nix
97-
uses: cachix/install-nix-action@v26
97+
uses: cachix/install-nix-action@v31
9898
with:
9999
nix_path: nixpkgs=channel:nixos-unstable
100100
- name: Setup Cachix
101-
uses: cachix/cachix-action@v14
101+
uses: cachix/cachix-action@v17
102102
with:
103103
name: formosa-crypto
104104
authToken: '${{ secrets.CACHIX_WRITE_TOKEN }}'

flake.lock

Lines changed: 86 additions & 73 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 6 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,9 @@
44

55
flake-utils.url = "github:numtide/flake-utils";
66

7-
nixpkgs.url = "github:nixos/nixpkgs/24.05";
87
stable.url = "github:nixos/nixpkgs/24.05";
98
nixpkgs.follows = "opam-nix/nixpkgs";
109

11-
prover_cvc4_1_8 = {
12-
url = "github:CVC4/CVC4-archived/1.8";
13-
flake = false;
14-
};
15-
16-
prover_cvc5_1_0_9 = {
17-
url = "github:cvc5/cvc5/cvc5-1.0.9";
18-
flake = false;
19-
};
20-
21-
prover_z3_4_12_6 = {
22-
url = "github:z3prover/z3/z3-4.12.6";
23-
flake = false;
24-
};
2510
};
2611

2712
outputs = { self, flake-utils, opam-nix, nixpkgs, ... }@inputs:
@@ -57,6 +42,9 @@
5742
conf-pkg-config = prev.conf-pkg-config.overrideAttrs (oa: {
5843
nativeBuildInputs = oa.nativeBuildInputs ++ [pkgs.pkg-config];
5944
});
45+
conf-git = prev.conf-git.overrideAttrs (oa: {
46+
nativeBuildInputs = oa.nativeBuildInputs ++ [pkgs.git];
47+
});
6048
};
6149

6250
scope' = scope.overrideScope overlay;
@@ -71,27 +59,19 @@
7159
paths = [ scope'.${package} scope'.why3 ];
7260
};
7361

74-
# Create provers packages
75-
mkProverPackage = pkg: version:
76-
pkgs.${pkg}.overrideAttrs (_: {
77-
inherit version;
78-
src = inputs."${"prover_" + pkg + "_" + builtins.replaceStrings ["."] ["_"] version}";
79-
});
80-
8162
mkAltErgo = version:
8263
((on.queryToScope { } (query // { alt-ergo = version; })).overrideScope overlay).alt-ergo;
8364
in rec {
8465
legacyPackages = scope';
8566

8667
packages = rec {
87-
z3 = mkProverPackage "z3" "4.12.6";
88-
cvc4 = mkProverPackage "cvc4" "1.8";
89-
cvc5 = mkProverPackage "cvc5" "1.0.9";
68+
z3 = pkgs.z3;
69+
cvc5 = pkgs.cvc5;
9070
altErgo = mkAltErgo "2.4.3";
9171

9272
provers = pkgs.symlinkJoin {
9373
name = "provers";
94-
paths = [ altErgo z3 cvc4 cvc5 ];
74+
paths = [ altErgo z3 cvc5 ];
9575
};
9676

9777
with_provers = pkgs.symlinkJoin {

0 commit comments

Comments
 (0)