Skip to content

Commit fa2832f

Browse files
committed
Fix static linking
Signed-off-by: Christoph Knittel <ck@cca.io>
1 parent d4bf184 commit fa2832f

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ jobs:
3535
upload_libs: true
3636
node-target: linux-x64
3737
rust-target: x86_64-unknown-linux-musl
38+
dune-profile: static
3839
- os: ubuntu-24.04-arm # ARM
3940
ocaml_compiler: ocaml-variants.5.3.0+options,ocaml-option-static
4041
upload_binaries: true
@@ -44,34 +45,40 @@ jobs:
4445
benchmarks: true
4546
node-target: linux-arm64
4647
rust-target: aarch64-unknown-linux-musl
48+
dune-profile: static
4749
- os: macos-15-intel # x64
4850
ocaml_compiler: 5.3.0
4951
upload_binaries: true
5052
node-target: darwin-x64
5153
rust-target: x86_64-apple-darwin
54+
dune-profile: release
5255
- os: macos-15 # ARM
5356
ocaml_compiler: 5.3.0
5457
upload_binaries: true
5558
node-target: darwin-arm64
5659
rust-target: aarch64-apple-darwin
60+
dune-profile: release
5761
- os: windows-2025
5862
ocaml_compiler: 5.3.0
5963
upload_binaries: true
6064
node-target: win32-x64
6165
rust-target: x86_64-pc-windows-gnu
6266
exe-suffix: ".exe"
67+
dune-profile: release
6368

6469
# Verify that the compiler still builds with the oldest OCaml version we support.
6570
- os: ubuntu-24.04
6671
ocaml_compiler: ocaml-variants.5.0.0+options,ocaml-option-static
6772
node-target: linux-x64
6873
rust-target: x86_64-unknown-linux-musl
74+
dune-profile: static
6975

7076
runs-on: ${{matrix.os}}
7177

7278
env:
7379
# When changing the setup-ocaml version, also adjust it in the setup step further below.
7480
SETUP_OCAML_VERSION: 3.4.6 # OPAM <2.6.0
81+
DUNE_PROFILE: ${{ matrix.dune-profile }}
7582

7683
steps:
7784
- name: "Windows: Set git config"
@@ -264,12 +271,7 @@ jobs:
264271
key: ${{ steps.compiler-build-state-key.outputs.value }}
265272

266273
- name: Build compiler
267-
if: runner.os != 'Linux'
268-
run: opam exec -- dune build --display quiet --profile release
269-
270-
- name: Build compiler (Linux static)
271-
if: runner.os == 'Linux'
272-
run: opam exec -- dune build --display quiet --profile static
274+
run: opam exec -- dune build --display quiet
273275

274276
- name: Delete stable compiler build state
275277
if: github.event_name == 'push' && github.ref == 'refs/heads/master'

0 commit comments

Comments
 (0)