From 5d34ae0908aca71fcb162c558ed399cc739e4207 Mon Sep 17 00:00:00 2001 From: bomanaps Date: Wed, 13 May 2026 15:44:41 +0100 Subject: [PATCH 1/3] cross mount --- .github/workflows/release.yaml | 1 + lean_client/Cross.toml | 2 ++ 2 files changed, 3 insertions(+) create mode 100644 lean_client/Cross.toml diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 1ec4c365..fcf9eb05 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -40,6 +40,7 @@ jobs: - name: Build & push docker images env: DOCKER_TAG: ${{ (github.ref_name == 'main' && 'unstable') || github.ref_name }} + LEAN_REPO_ROOT: ${{ github.workspace }} run: | make docker \ DOCKER_TAG=${{ env.DOCKER_TAG }} diff --git a/lean_client/Cross.toml b/lean_client/Cross.toml new file mode 100644 index 00000000..b5a973a5 --- /dev/null +++ b/lean_client/Cross.toml @@ -0,0 +1,2 @@ +[build.env] +volumes = ["LEAN_REPO_ROOT"] From c2bce17ca9a9e8fc240a71b271fd83c1002a9450 Mon Sep 17 00:00:00 2001 From: bomanaps Date: Wed, 13 May 2026 16:43:12 +0100 Subject: [PATCH 2/3] auto-export LEAN_REPO_ROOT from repo's git toplevel --- lean_client/Makefile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lean_client/Makefile b/lean_client/Makefile index e1d489b5..f527c66e 100644 --- a/lean_client/Makefile +++ b/lean_client/Makefile @@ -17,6 +17,10 @@ GIT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD) BUILD_DATE := $(shell date -u +'%Y-%m-%dT%H:%M:%SZ') # Currently supported devnet. Used to publish devnet tag, along with `latest`. CURRENT_DEVNET := devnet-4 +# Repo root that cross bind-mounts into its build container (see +# `lean_client/Cross.toml`). Auto-derived locally; CI overrides via env. +LEAN_REPO_ROOT ?= $(shell git rev-parse --show-toplevel) +export LEAN_REPO_ROOT # Temporary variable, which constructs `--tag` arguments, to be passed into # docker build command. It is used as intermediatery step, not as config From adc7a2c1a6f14f51b32bea979c335ccbfbd775fe Mon Sep 17 00:00:00 2001 From: bomanaps Date: Wed, 13 May 2026 16:54:01 +0100 Subject: [PATCH 3/3] inline LEAN_REPO_ROOT --- lean_client/Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lean_client/Makefile b/lean_client/Makefile index f527c66e..1d0b4237 100644 --- a/lean_client/Makefile +++ b/lean_client/Makefile @@ -20,7 +20,6 @@ CURRENT_DEVNET := devnet-4 # Repo root that cross bind-mounts into its build container (see # `lean_client/Cross.toml`). Auto-derived locally; CI overrides via env. LEAN_REPO_ROOT ?= $(shell git rev-parse --show-toplevel) -export LEAN_REPO_ROOT # Temporary variable, which constructs `--tag` arguments, to be passed into # docker build command. It is used as intermediatery step, not as config @@ -74,13 +73,13 @@ clean: x86_64-unknown-linux-gnu: ./target/x86_64-unknown-linux-gnu/release/lean_client ./target/x86_64-unknown-linux-gnu/release/lean_client: - cross build --bin lean_client --target x86_64-unknown-linux-gnu --profile release + LEAN_REPO_ROOT=$(LEAN_REPO_ROOT) cross build --bin lean_client --target x86_64-unknown-linux-gnu --profile release .PHONY: aarch64-unknown-linux-gnu aarch64-unknown-linux-gnu: ./target/aarch64-unknown-linux-gnu/release/lean_client ./target/aarch64-unknown-linux-gnu/release/lean_client: - cross build --bin lean_client --target aarch64-unknown-linux-gnu --profile release + LEAN_REPO_ROOT=$(LEAN_REPO_ROOT) cross build --bin lean_client --target aarch64-unknown-linux-gnu --profile release .PHONY: release release: docker