1
1
name : Build Engines for Apple Silicon
2
+
2
3
on :
3
- workflow_dispatch :
4
+ workflow_call :
4
5
inputs :
5
6
commit :
6
- description : " Commit on the given branch to build"
7
+ description : ' Commit on the given branch to build'
8
+ type : string
7
9
required : false
8
10
9
11
jobs :
10
12
build :
11
- # Do not change `name`, prisma-engines Buildkite build job depends on this name ending with the commit
12
- name : " MacOS ARM64 (Apple Silicon) engines build on branch ${{ github.event.ref }} for commit ${{ github.event.inputs.commit }}"
13
+ name : ' MacOS ARM64 (Apple Silicon) engines build for commit ${{ inputs.commit }}'
13
14
env :
14
15
SQLITE_MAX_VARIABLE_NUMBER : 250000
15
16
SQLITE_MAX_EXPR_DEPTH : 10000
16
17
runs-on : macos-13
17
18
18
19
steps :
19
20
- name : Output link to real commit
20
- run : echo ${{ github.repository }}/commit/${{ github.event. inputs.commit }}
21
+ run : echo ${{ github.repository }}/commit/${{ inputs.commit }}
21
22
22
- - name : Checkout ${{ github.event. inputs.commit }}
23
+ - name : Checkout ${{ inputs.commit }}
23
24
uses : actions/checkout@v4
24
25
with :
25
- ref : ${{ github.event. inputs.commit }}
26
+ ref : ${{ inputs.commit }}
26
27
27
- - uses : actions-rust-lang/setup-rust-toolchain@v1
28
+ - run : xcodebuild -showsdks
28
29
29
- - name : Install aarch64 toolchain
30
- run : rustup target add aarch64-apple-darwin
30
+ - uses : actions-rust-lang/setup-rust-toolchain@v1
31
31
32
32
- uses : actions/cache@v4
33
33
with :
@@ -37,16 +37,25 @@ jobs:
37
37
target
38
38
key : ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
39
39
40
- - run : xcodebuild -showsdks
41
-
42
40
- run : |
43
41
cargo build --target=aarch64-apple-darwin --release -p query-engine -p query-engine-node-api -p schema-engine-cli -p prisma-fmt
44
42
43
+ - name : Rename files
44
+ working-directory : ${{ github.workspace }}/target/aarch64-apple-darwin/release
45
+ run : |
46
+ echo "Files in target/release before renaming"
47
+ ls -la .
48
+
49
+ mv libquery_engine.dylib libquery_engine.dylib.node
50
+
51
+ echo "Files in target/release after renaming"
52
+ ls -la .
53
+
45
54
- uses : actions/upload-artifact@v4
46
55
with :
47
- name : binaries
56
+ name : darwin-arm64
48
57
path : |
49
58
${{ github.workspace }}/target/aarch64-apple-darwin/release/schema-engine
50
59
${{ github.workspace }}/target/aarch64-apple-darwin/release/prisma-fmt
51
60
${{ github.workspace }}/target/aarch64-apple-darwin/release/query-engine
52
- ${{ github.workspace }}/target/aarch64-apple-darwin/release/libquery_engine.dylib
61
+ ${{ github.workspace }}/target/aarch64-apple-darwin/release/libquery_engine.dylib.node
0 commit comments