Commit Graph

9 Commits

Author SHA1 Message Date
isabel
22d9ea8bf8 buildLakePackage: Small clean-ups for new builder (#519478) 2026-07-12 10:48:25 +00:00
Nadja Yang
bdea40b4ed leanPackages.mathlib: lgz preprocessing
Per-module leantar strips olean structural overhead. See
https://github.com/NixOS/nixpkgs/pull/511524#issuecomment-4615610073
2026-06-04 16:48:52 -04:00
Nadja Yang
6987e3afbe leanPackages.lean4: 4.29.0 -> 4.29.1
Strip ephemeral setup.json build artifacts from library outputs.
These are produced per-module during compilation and not included
in upstream cache distributions
(https://github.com/NixOS/nixpkgs/issues/510957).

Disable Hydra builds for mathlib since the output exceeds the NAR
size limit.

Pre-build static library for batteries so downstream executables
can link against it.

Refactor update.sh to pin each dependency to the rev from mathlib's
lake-manifest.json.
2026-06-04 16:48:52 -04:00
Ross Smyth
cada9af7d2 buildLakePackage: make FOD use extendMkDerivation as well
Also add the usual suspects (strict, structuredAttrs)
2026-05-07 17:36:30 -04:00
Ross Smyth
d692663784 buildLakePackage: Remove redundant bindings
These just redeclare bindings with their already declared
defaults
2026-05-07 17:36:30 -04:00
Ross Smyth
82b8052284 buildLakePackage: force pname, version, and structured attrs
This is a new builder so we should force those attrs
2026-05-07 17:36:08 -04:00
Nadja Yang
3c2a3b804d leanPackages: structural reimagining — own toolchain, lake --packages, Hydra visibility
Give leanPackages its own lean4, independent of pkgs.lean4. Binary-
patch the toolchain so the language server discovers the wrapped lake
despite lake serve deriving LAKE from IO.appPath unconditionally.
Supplant Lake's config trace validation for /nix/store/ dependencies,
deferring cache coherence to Nix.

Migrate Nix-managed dependency injection from package-overrides.json
to lake --packages. Patch Cli to pre-build static library for
downstream executables. Add recurseIntoAttrs for Hydra.

Upstream accepted FetchContent for mimalloc vendoring:
a145b9c11a
2026-04-01 11:13:44 -04:00
Nadja Yang
9f1cb0f57c buildLakePackage: add weak-minimax test
Verifies that buildLakePackage works with nix-only deps (no
lake-manifest.json).  Builds a proof of the weak minimax inequality
from Mathlib.Order.CompleteLattice.Basic using leanDeps = [ mathlib ].
2026-03-21 17:53:43 -04:00
Nadja Yang
e8db345716 buildLakePackage: init
Build Lean 4 projects that use the Lake build system.

Dependencies can be provided as nix-packaged libraries (leanDeps)
or via a fixed-output derivation that clones git deps from
lake-manifest.json (lakeHash), following the same pattern as
buildGoModule's vendorHash.

Includes a setup hook that propagates LEAN_PATH for transitive
dependency resolution.
2026-03-21 17:52:54 -04:00