Skip to content

Commit

Permalink
Have native in another directory
Browse files Browse the repository at this point in the history
  • Loading branch information
JulianGCalderon committed Oct 25, 2024
1 parent 845a53a commit fcb28f7
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/daily.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,18 @@ jobs:
- 748000
- 749000
fail-fast: false
defaults:
run:
shell: bash
working-directory: ./starknet-replay

steps:
# We checkout replay first, as it's the main repository for this workflow
- name: Checkout Replay
uses: actions/checkout@v4
with:
repository: lambdaclass/starknet-replay
path: .
path: starknet-replay
# We need native for building the runtime, so we checkout it to a subdirectory
- name: Checkout Native
uses: actions/checkout@v4
Expand All @@ -58,14 +62,18 @@ jobs:
- name: Build Cairo Native Runtime Library
shell: bash
run: |
cd cairo_native
cd ../cairo_native
make runtime
echo "CAIRO_NATIVE_RUNTIME_LIBRARY=$(pwd)/libcairo_native_runtime.a" > $GITHUB_ENV
- name: Patch dependencies
run: |
# Patches native dependency to local path, to use current cairo native version
sed -Ei "s/^(cairo-native = \{).*/\1 path = 'cairo_native' }/" Cargo.toml
DEPENDENCY="cairo-native"
NEW_PATH="../cairo_native"
sed -Ei "s/^($DEPENDENCY\s*=).*/\1 { path = '$NEW_PATH' }/" Cargo.toml
- run: cat Cargo.toml | tail -n 1

- name: Run with Native
run: |
Expand Down

0 comments on commit fcb28f7

Please sign in to comment.