Adds myDirtyFingerprint to flake.nix's existing eval-time let block, computed as builtins.hashString "sha256" self.narHash truncated to 8 hex chars (self.narHash is SRI base64, not hex -- rehashing is necessary), gated on the same clean/dirty branch myCommitId already uses. No preConfigure build-phase hook needed -- self.narHash has no pure-eval trap unlike build_time's builtins.currentTime. Threaded through nixSupport/default.nix into xce.nix/xcecli.nix's eval-time mesonFlags as -Ddirty_fingerprint=, alongside the completely untouched -Dcommit_id=/ myCommitId and build_time's separate preConfigure mechanism. Verified independently by review with real nix build/nix log inspection on both xcecore_debug and xcecli: real, non-empty, content-sensitive values reach mesonConfigurePhase, cross-checked deterministic via an independent Python recomputation, with commit_id fully unaffected. Full artifact completion is blocked by a pre-existing, unrelated sandbox network limitation (confirmed recurring on two disjoint Go module sets), not caused by this change. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
35 lines
1 KiB
Nix
35 lines
1 KiB
Nix
{
|
|
pkgs,
|
|
myCommitId,
|
|
myDirtyFingerprint,
|
|
...
|
|
}:
|
|
let
|
|
# NOTE (build-time-versioning task 2.2, remediation round): build-time is
|
|
# no longer threaded through here -- it's computed inside each
|
|
# derivation's own build phase (xce.nix/xcecli.nix `preConfigure`), since
|
|
# builtins.currentTime is unavailable under flake pure-eval. Only
|
|
# myCommitId (a genuine eval-time/flake-level value) still needs to be
|
|
# passed down.
|
|
# dirty-content-fingerprint task 2.2: myDirtyFingerprint is forwarded the
|
|
# same way myCommitId already is -- a second, independent eval-time value,
|
|
# not a build-phase one.
|
|
xcecore = pkgs.callPackage ./xce.nix {
|
|
inherit pkgs myCommitId myDirtyFingerprint;
|
|
withDebug = false;
|
|
withAsan = false;
|
|
};
|
|
xcecore_debug = pkgs.callPackage ./xce.nix {
|
|
inherit pkgs myCommitId myDirtyFingerprint;
|
|
withDebug = true;
|
|
withAsan = true;
|
|
};
|
|
xcecli = pkgs.callPackage ./xcecli.nix {
|
|
inherit pkgs myCommitId myDirtyFingerprint;
|
|
};
|
|
in
|
|
{
|
|
xcecore = xcecore;
|
|
xcecore_debug = xcecore_debug;
|
|
xcecli = xcecli;
|
|
}
|