Skip to content

Commit 6dacaa8

Browse files
authored
Merge pull request #6192 from kit-ty-kate/gha-ocaml-5.3
GHA: Add OCaml 5.3 to the build matrix
2 parents c872562 + a194a11 commit 6dacaa8

File tree

7 files changed

+40
-25
lines changed

7 files changed

+40
-25
lines changed

.github/scripts/main/ocaml-cache.sh

+8-1
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,12 @@ case "$HOST" in
4545
esac
4646

4747
FLEXDLL_VERSION=0.43
48+
MINGW_W64_VERSION=12.0.0
4849

4950
curl -sLO "https://github.com/ocaml/ocaml/archive/refs/tags/${OCAML_VERSION}.tar.gz"
5051
if [[ $PLATFORM = 'Windows' ]] ; then
5152
curl -sLO "https://github.com/ocaml/flexdll/archive/refs/tags/$FLEXDLL_VERSION.tar.gz"
53+
curl -sLO "https://github.com/mingw-w64/mingw-w64/archive/refs/tags/v${MINGW_W64_VERSION}.tar.gz"
5254
fi
5355

5456
tar -xzf "$OCAML_VERSION.tar.gz"
@@ -72,6 +74,11 @@ if [[ $PLATFORM = 'Windows' ]] ; then
7274
tar -xzf ../$FLEXDLL_VERSION.tar.gz
7375
rm -rf flexdll
7476
mv "flexdll-$FLEXDLL_VERSION" flexdll
77+
78+
tar -xzf "../v${MINGW_W64_VERSION}.tar.gz"
79+
rm -rf winpthreads
80+
mv "mingw-w64-${MINGW_W64_VERSION}/mingw-w64-libraries/winpthreads" winpthreads
81+
rm -rf "mingw-w64-${MINGW_W64_VERSION}"
7582
fi
7683

7784
if [[ $PLATFORM = 'macOS' ]]; then
@@ -115,7 +122,7 @@ if [[ $OPAM_TEST -ne 1 ]] ; then
115122
fi
116123
fi
117124

118-
if ! ./configure --prefix "$PREFIX"$HOST --with-vendored-deps ${CONFIGURE_SWITCHES:-} ; then
125+
if ! ./configure --prefix "$PREFIX"$HOST ${CONFIGURE_SWITCHES:-} ; then
119126
echo
120127
echo -e "[\e[31mERROR\e[0m] OCaml's configure script failed"
121128
(set +x ; echo -en "::group::config.log contents\r") 2>/dev/null

.github/workflows/ci.ml

+6-5
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@
1414
open Lib
1515

1616
let latest_ocaml4 = "4.14.2"
17-
let latest_ocaml5 = "5.2.0" (* Add this number to ocamls below when the next version comes out *)
17+
let latest_ocaml5 = "5.3.0" (* Add this number to ocamls below when the next version comes out *)
1818
let ocamls = [
1919
(* Fully supported versions *)
2020
"4.08.1"; "4.09.1"; "4.10.2"; "4.11.2"; "4.12.1"; "4.13.1";
21-
"5.0.0"; "5.1.1";
21+
"5.0.0"; "5.1.1"; "5.2.1";
2222

2323
(* The last elements of the list after 4.14 will be used as default versions *)
2424
latest_ocaml4; latest_ocaml5;
@@ -312,8 +312,9 @@ let main_build_job ~analyse_job ~cygwin_job ?section runner start_version ~oc ~w
312312
"x86_64-pc-windows"
313313
] in
314314
let ocaml5 = [
315+
(* "x86_64-pc-cygwin"; *) (* TODO: Restore Cygwin + OCaml 5.3 when C++ support is fixed and released *)
315316
"x86_64-w64-mingw32";
316-
(* "x86_64-pc-windows"; 5.3 needed *)
317+
"x86_64-pc-windows";
317318
] in
318319
let matrix_elem ocamlv hosts =
319320
let elem ocaml host =
@@ -525,8 +526,8 @@ let main oc : unit =
525526
("OPAM12CACHE", "~/.cache/opam1.2/cache");
526527
(* These should be identical to the values in appveyor.yml *)
527528
("OPAM_REPO", "https://github.com/ocaml/opam-repository.git");
528-
("OPAM_TEST_REPO_SHA", "dff745994c64d083a6ba3ddc5a9c28ed0ad0f40a");
529-
("OPAM_REPO_SHA", "6eee105e52e098e36949a584c053a18bcb9b2f6b");
529+
("OPAM_TEST_REPO_SHA", "67e940587b8aca227f511e1943bcd31eabe6b1db");
530+
("OPAM_REPO_SHA", "67e940587b8aca227f511e1943bcd31eabe6b1db");
530531
("SOLVER", "");
531532
(* Cygwin configuration *)
532533
("CYGWIN_MIRROR", "http://mirrors.kernel.org/sourceware/cygwin/");

.github/workflows/lib.ml

+1-1
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ let find_need need = Hashtbl.find jobs need
110110
let emit_runs_on ~oc runs_on =
111111
let runner_of_platform (type a) (platform : a platform) =
112112
match platform with
113-
| Windows -> "windows-2019"
113+
| Windows -> "windows-2022"
114114
| MacOS
115115
| Linux as platform -> os_name_of_platform platform ^ "-latest"
116116
| Specific (platform, version) -> os_name_of_platform platform ^ "-" ^ version

.github/workflows/main.yml

+17-14
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ env:
2626
OPAMBSROOT: ~/.cache/.opam.cached
2727
OPAM12CACHE: ~/.cache/opam1.2/cache
2828
OPAM_REPO: https://github.com/ocaml/opam-repository.git
29-
OPAM_TEST_REPO_SHA: dff745994c64d083a6ba3ddc5a9c28ed0ad0f40a
30-
OPAM_REPO_SHA: 6eee105e52e098e36949a584c053a18bcb9b2f6b
29+
OPAM_TEST_REPO_SHA: 67e940587b8aca227f511e1943bcd31eabe6b1db
30+
OPAM_REPO_SHA: 67e940587b8aca227f511e1943bcd31eabe6b1db
3131
SOLVER:
3232
CYGWIN_MIRROR: http://mirrors.kernel.org/sourceware/cygwin/
3333
CYGWIN_ROOT: D:\cygwin
@@ -79,7 +79,7 @@ jobs:
7979
run: bash -exu .github/scripts/main/archives-cache.sh
8080

8181
Cygwin:
82-
runs-on: windows-2019
82+
runs-on: windows-2022
8383
needs: Analyse
8484
steps:
8585
- name: Cygwin64 Cache
@@ -106,7 +106,7 @@ jobs:
106106
needs: Analyse
107107
strategy:
108108
matrix:
109-
ocamlv: [ 4.08.1, 4.09.1, 4.10.2, 4.11.2, 4.12.1, 4.13.1, 5.0.0, 5.1.1, 4.14.2, 5.2.0 ]
109+
ocamlv: [ 4.08.1, 4.09.1, 4.10.2, 4.11.2, 4.12.1, 4.13.1, 5.0.0, 5.1.1, 5.2.1, 4.14.2, 5.3.0 ]
110110
fail-fast: true
111111
steps:
112112
- name: Install bubblewrap
@@ -139,7 +139,7 @@ jobs:
139139
run: bash -exu .github/scripts/main/test.sh
140140

141141
Build-Windows:
142-
runs-on: windows-2019
142+
runs-on: windows-2022
143143
needs: [ Analyse, Cygwin ]
144144
strategy:
145145
matrix:
@@ -161,7 +161,10 @@ jobs:
161161
ocamlv: 4.14.2
162162
- host: x86_64-w64-mingw32
163163
build: x86_64-pc-cygwin
164-
ocamlv: 5.2.0
164+
ocamlv: 5.3.0
165+
- host: x86_64-pc-windows
166+
build: x86_64-pc-cygwin
167+
ocamlv: 5.3.0
165168
fail-fast: false
166169
defaults:
167170
run:
@@ -244,7 +247,7 @@ jobs:
244247
needs: Analyse
245248
strategy:
246249
matrix:
247-
ocamlv: [ 4.14.2, 5.2.0 ]
250+
ocamlv: [ 4.14.2, 5.3.0 ]
248251
fail-fast: true
249252
steps:
250253
- name: Install GNU patch
@@ -282,7 +285,7 @@ jobs:
282285
needs: [ Analyse, Build-Linux ]
283286
strategy:
284287
matrix:
285-
ocamlv: [ 4.14.2, 5.2.0 ]
288+
ocamlv: [ 4.14.2, 5.3.0 ]
286289
fail-fast: false
287290
env:
288291
OPAM_TEST: 1
@@ -339,7 +342,7 @@ jobs:
339342
needs: Analyse
340343
strategy:
341344
matrix:
342-
ocamlv: [ 4.14.2, 5.2.0 ]
345+
ocamlv: [ 4.14.2, 5.3.0 ]
343346
fail-fast: false
344347
env:
345348
OPAM_TEST: 1
@@ -428,7 +431,7 @@ jobs:
428431
needs: [ Analyse, Build-Linux ]
429432
strategy:
430433
matrix:
431-
ocamlv: [ 4.14.2, 5.2.0 ]
434+
ocamlv: [ 4.14.2, 5.3.0 ]
432435
fail-fast: false
433436
env:
434437
OPAM_DOC: 1
@@ -485,7 +488,7 @@ jobs:
485488
strategy:
486489
matrix:
487490
solver: [ z3, 0install ]
488-
ocamlv: [ 4.14.2, 5.2.0 ]
491+
ocamlv: [ 4.14.2, 5.3.0 ]
489492
fail-fast: false
490493
env:
491494
SOLVER: ${{ matrix.solver }}
@@ -535,7 +538,7 @@ jobs:
535538
strategy:
536539
matrix:
537540
solver: [ z3, 0install ]
538-
ocamlv: [ 4.14.2, 5.2.0 ]
541+
ocamlv: [ 4.14.2, 5.3.0 ]
539542
fail-fast: false
540543
env:
541544
SOLVER: ${{ matrix.solver }}
@@ -583,7 +586,7 @@ jobs:
583586
needs: [ Analyse, Build-Linux ]
584587
strategy:
585588
matrix:
586-
ocamlv: [ 4.14.2, 5.2.0 ]
589+
ocamlv: [ 4.14.2, 5.3.0 ]
587590
fail-fast: false
588591
steps:
589592
- name: Install bubblewrap
@@ -618,7 +621,7 @@ jobs:
618621
needs: [ Analyse, Build-macOS ]
619622
strategy:
620623
matrix:
621-
ocamlv: [ 4.14.2, 5.2.0 ]
624+
ocamlv: [ 4.14.2, 5.3.0 ]
622625
fail-fast: false
623626
steps:
624627
- name: Checkout tree

master_changes.md

+4
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,8 @@ users)
100100
* Upgrade to opam-file-format 2.2.0~alpha1 [#6321 @kit-ty-kate]
101101
* Add menhir to the list of vendored packages [#6321 @kit-ty-kate]
102102
* Upgrade the vendored spdx\_licenses to 1.3.0 [#6370 @kit-ty-kate - fix #6369]
103+
* Bump the vendored dune to 3.16.1 [#6192 @kit-ty-kate]
104+
* Fix compilation on macOS with OCaml 5.3 by bumping the vendored mccs to 1.1+19 [#6192 @kit-ty-kate]
103105

104106
## Infrastructure
105107

@@ -172,6 +174,8 @@ users)
172174
* Check `shell/install.sh` using `shellcheck` [#6313 @kit-ty-kate]
173175
* Fix the alpine depexts test [#6363 @kit-ty-kate]
174176
* Speedup the gentoo depexts test [#6363 @kit-ty-kate]
177+
* Add OCaml 5.3 to the build matrix [#6192 @kit-ty-kate]
178+
* Add OCaml 5.3/MSVC to the build matrix [#6192 @kit-ty-kate]
175179

176180
## Doc
177181
* Update the command to install opam to point to the new simplified url on opam.ocaml.org [#6226 @kit-ty-kate]

src_ext/Makefile.dune

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# NB If minimum OCaml version for Dune changes, update DUNE_SECONDARY in configure.ac
2-
URL_dune-local = https://github.com/ocaml/dune/releases/download/3.16.0/dune-3.16.0.tbz
3-
MD5_dune-local = 4605a1d9783a96a16cbec381cfbb3ac1
2+
URL_dune-local = https://github.com/ocaml/dune/releases/download/3.16.1/dune-3.16.1.tbz
3+
MD5_dune-local = c19a1bb71eb3510ca15ddcf9f875947a

src_ext/Makefile.sources

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ MD5_cudf = ed8fea314d0c6dc0d8811ccf860c53dd
2222
URL_dose3 = https://gitlab.com/irill/dose3/-/archive/7.0.0/dose3-7.0.0.tar.gz
2323
MD5_dose3 = bc99cbcea8fca29dca3ebbee54be45e1
2424

25-
URL_mccs = https://github.com/ocaml-opam/ocaml-mccs/releases/download/1.1+18/mccs-1.1+18.tar.gz
26-
MD5_mccs = 3fd6f609a02f3357f57570750fcacde0
25+
URL_mccs = https://github.com/ocaml-opam/ocaml-mccs/releases/download/1.1+19/mccs-1.1+19.tar.gz
26+
MD5_mccs = f852da188bf7de20e64be2fce0e48e0a
2727

2828
URL_opam-0install-cudf = https://github.com/ocaml-opam/opam-0install-cudf/releases/download/v0.5.0/opam-0install-cudf-0.5.0.tar.gz
2929
MD5_opam-0install-cudf = 75419722aa839f518a25cae1b3c6efd4

0 commit comments

Comments
 (0)