Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }}
2 changes: 2 additions & 0 deletions lean_client/Cross.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[build.env]
volumes = ["LEAN_REPO_ROOT"]
7 changes: 5 additions & 2 deletions lean_client/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ 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)

# Temporary variable, which constructs `--tag` arguments, to be passed into
# docker build command. It is used as intermediatery step, not as config
Expand Down Expand Up @@ -70,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
Expand Down
Loading