From e08fc345d91fa8b4b9ba12d456b9b22ff8323b96 Mon Sep 17 00:00:00 2001 From: Virgile Robles Date: Wed, 15 Oct 2025 19:09:35 +0200 Subject: [PATCH 1/4] add OCaml 5.4 builder in parallel to 5.3 --- src/lib/common/platform.ml | 14 ++++++++++++-- src/pipelines/PR.ml | 2 ++ 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/lib/common/platform.ml b/src/lib/common/platform.ml index 1303554..a4e3d4f 100644 --- a/src/lib/common/platform.ml +++ b/src/lib/common/platform.ml @@ -1,10 +1,14 @@ -type ocaml_version = V4_14 | V5_3 +type ocaml_version = V4_14 | V5_3 | V5_4 -let pp_ocaml f = function V4_14 -> Fmt.pf f "4.14" | V5_3 -> Fmt.pf f "5.3" +let pp_ocaml f = function + | V4_14 -> Fmt.pf f "4.14" + | V5_3 -> Fmt.pf f "5.3" + | V5_4 -> Fmt.pf f "5.4" let pp_exact_ocaml f = function | V4_14 -> Fmt.pf f "4.14.2" | V5_3 -> Fmt.pf f "5.3.0" + | V5_4 -> Fmt.pf f "5.4.0" type os = Debian | Ubuntu | Fedora @@ -54,6 +58,12 @@ let platform_v53_amd64 = let platform_v53_arm64 = { system = { ocaml = V5_3; os = Debian }; arch = Arm64 } +let platform_v54_amd64 = + { system = { ocaml = V5_4; os = Debian }; arch = Amd64 } + +let platform_v54_arm64 = + { system = { ocaml = V5_4; os = Debian }; arch = Arm64 } + let platform_host = Bos.Cmd.(v "uname" % "-m") |> Bos.OS.Cmd.run_out diff --git a/src/pipelines/PR.ml b/src/pipelines/PR.ml index adc88fd..7db539e 100644 --- a/src/pipelines/PR.ml +++ b/src/pipelines/PR.ml @@ -410,6 +410,8 @@ module Run = struct platform_v414_arm64; platform_v53_amd64; platform_v53_arm64; + platform_v54_amd64; + platform_v54_arm64; ] |> List.map (fun platform -> perform_test ~metadata ~platform commit) From d1440f9b64c36b505c79e68d1da43f5e0493a27d Mon Sep 17 00:00:00 2001 From: Virgile Robles Date: Wed, 15 Oct 2025 19:34:41 +0200 Subject: [PATCH 2/4] add unikraft-qemu target to the pipelines --- src/pipelines/skeleton.ml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pipelines/skeleton.ml b/src/pipelines/skeleton.ml index 357ee1d..dee9c4c 100644 --- a/src/pipelines/skeleton.ml +++ b/src/pipelines/skeleton.ml @@ -3,10 +3,12 @@ open Common type 'a build_mode = Mirage_4 of { overlay : 'a option } -let targets = [ "unix"; "hvt"; "xen" ] (* "virtio"; "spt"; "muen" ]*) +let targets = [ "unix"; "hvt"; "xen"; "unikraft-qemu" ] +(* "virtio"; "spt"; "muen" ]*) let is_available_on (platform : Platform.t) = function | "unix" | "hvt" -> true + | "unikraft-qemu" when platform.system.ocaml = V5_3 -> true | "xen" when platform.arch = Amd64 -> true | _ -> false From d773e480ba0178a3909e86f1badc22b60bb21f1b Mon Sep 17 00:00:00 2001 From: Virgile Robles Date: Wed, 15 Oct 2025 21:05:20 +0200 Subject: [PATCH 3/4] use latest OCaml version for host platform --- src/lib/common/platform.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib/common/platform.ml b/src/lib/common/platform.ml index a4e3d4f..7ac0b97 100644 --- a/src/lib/common/platform.ml +++ b/src/lib/common/platform.ml @@ -70,6 +70,6 @@ let platform_host = |> Bos.OS.Cmd.out_string |> Result.to_option |> Option.map (function - | ("aarch64" | "arm64"), _ -> platform_v414_arm64 - | _ -> platform_v414_amd64) - |> Option.value ~default:platform_v414_amd64 + | ("aarch64" | "arm64"), _ -> platform_v53_arm64 + | _ -> platform_v53_amd64) + |> Option.value ~default:platform_v53_amd64 From 81c6d3fa818005189c929cede7d29961e15f8f8e Mon Sep 17 00:00:00 2001 From: Virgile Robles Date: Thu, 16 Oct 2025 12:35:23 +0200 Subject: [PATCH 4/4] rebase on ocaml54 --- src/pipelines/skeleton.ml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/pipelines/skeleton.ml b/src/pipelines/skeleton.ml index dee9c4c..3019989 100644 --- a/src/pipelines/skeleton.ml +++ b/src/pipelines/skeleton.ml @@ -6,9 +6,12 @@ type 'a build_mode = Mirage_4 of { overlay : 'a option } let targets = [ "unix"; "hvt"; "xen"; "unikraft-qemu" ] (* "virtio"; "spt"; "muen" ]*) +let is_unikraft_available_on (platform : Platform.t) = + match platform.system.ocaml with V5_3 | V5_4 -> true | _ -> false + let is_available_on (platform : Platform.t) = function | "unix" | "hvt" -> true - | "unikraft-qemu" when platform.system.ocaml = V5_3 -> true + | "unikraft-qemu" -> is_unikraft_available_on platform | "xen" when platform.arch = Amd64 -> true | _ -> false