Skip to content

Commit 22a2fc7

Browse files
committed
Publish OCaml/Unikraft packages v1.0.0
OCaml/Unikraft: an OCaml cross compiler to Unikraft backends OCaml/Unikraft is structured into many packages to allow users to build only what they need. Packages use one of two version numbers: - 0.18.0, the upstream release number of Unikraft: used for `unikraft`, `unikraft-musl` and backend packages, - 1.0.0, for packages that are more on the OCaml side. The 18 packages are as follows: - `unikraft` and `unikraft-musl`: the latest stable release of upstream sources for Unikraft and its lib-musl wrapper, with a couple of small patches to fix them for our use case. - `conf-<arch>-linux-gnu-gcc`: `conf-` packages used when targetting a different architecture. - `ocaml-unikraft-backend-<backend>-<arch>`: all the object files and headers necessary to build a unikernel for the specific `<backend>` and `<arch>` combination. - `ocaml-unikraft-option-debug`: if that package is installed, the backends will be built with debugging messages. - `ocaml-unikraft-toolchain-<arch>`: a toolchain using the `<arch>-unikraft-ocaml-` prefix; the toolchain is a set of wrapper shell scripts to add the necessary options to drive the underlying tools. - `ocaml-unikraft-<arch>`: the actual OCaml cross compilers for the given `<arch>`. - `ocaml-unikraft-default-<arch>`: simple packages that only install a `ocamlfind` toolchain named `unikraft` (so that switching between architecture do not require to rebuild the full OCaml compiler). - `ocaml-unikraft-backend-<backend>`: virtual packages to ensure that the given `<backend>` is installed for the default architecture, as set by which `ocaml-unikraft-default-<arch>` package is installed. - `ocaml-unikraft`: the virtual package to ensure one of the default compiler package is installed.
1 parent 8ae853b commit 22a2fc7

File tree

18 files changed

+521
-0
lines changed
  • packages
    • conf-aarch64-linux-gnu-gcc/conf-aarch64-linux-gnu-gcc.1
    • conf-x86_64-linux-gnu-gcc/conf-x86_64-linux-gnu-gcc.1
    • ocaml-unikraft-arm64/ocaml-unikraft-arm64.1.0.0
    • ocaml-unikraft-backend-firecracker-arm64/ocaml-unikraft-backend-firecracker-arm64.0.18.0
    • ocaml-unikraft-backend-firecracker-x86_64/ocaml-unikraft-backend-firecracker-x86_64.0.18.0
    • ocaml-unikraft-backend-firecracker/ocaml-unikraft-backend-firecracker.0.18.0
    • ocaml-unikraft-backend-qemu-arm64/ocaml-unikraft-backend-qemu-arm64.0.18.0
    • ocaml-unikraft-backend-qemu-x86_64/ocaml-unikraft-backend-qemu-x86_64.0.18.0
    • ocaml-unikraft-backend-qemu/ocaml-unikraft-backend-qemu.0.18.0
    • ocaml-unikraft-default-arm64/ocaml-unikraft-default-arm64.1.0.0
    • ocaml-unikraft-default-x86_64/ocaml-unikraft-default-x86_64.1.0.0
    • ocaml-unikraft-option-debug/ocaml-unikraft-option-debug.0.18.0
    • ocaml-unikraft-toolchain-arm64/ocaml-unikraft-toolchain-arm64.0.18.0
    • ocaml-unikraft-toolchain-x86_64/ocaml-unikraft-toolchain-x86_64.0.18.0
    • ocaml-unikraft-x86_64/ocaml-unikraft-x86_64.1.0.0
    • ocaml-unikraft/ocaml-unikraft.1.0.0
    • unikraft-musl/unikraft-musl.0.18.0
    • unikraft/unikraft.0.18.0

18 files changed

+521
-0
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
opam-version: "2.0"
2+
synopsis: "Virtual package relying on the aarch64-linux-gnu-gcc compiler (for C)"
3+
description:
4+
"This package can only install if the aarch64-linux-gnu-gcc compiler is installed on the system (whether this is a cross compiler or not)."
5+
maintainer: "[email protected]"
6+
authors: ["Samuel Hym"]
7+
license: "GPL-2.0-or-later"
8+
homepage: "https://github.com/ocaml/opam-repository"
9+
bug-reports: "https://github.com/ocaml/opam-repository/issues"
10+
flags: conf
11+
build: ["aarch64-linux-gnu-gcc" "--version"]
12+
depexts: [
13+
["gcc-aarch64-linux-gnu"] {os-family = "debian"}
14+
["gcc-aarch64-linux-gnu"] {os-family = "fedora"}
15+
["aarch64-linux-gnu-gcc"] {os-family = "arch"}
16+
]
17+
post-messages:
18+
"""\
19+
Please install aarch64-linux-gnu-gcc manually, as there is no known package
20+
for it for your distribution."""
21+
{failure}
22+
x-maintenance-intent: ["(latest)"]
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
opam-version: "2.0"
2+
synopsis: "Virtual package relying on the x86_64-linux-gnu-gcc compiler (for C)"
3+
description:
4+
"This package can only install if the x86_64-linux-gnu-gcc compiler is installed on the system (whether this is a cross compiler or not)."
5+
maintainer: "[email protected]"
6+
authors: ["Samuel Hym"]
7+
license: "GPL-2.0-or-later"
8+
homepage: "https://github.com/ocaml/opam-repository"
9+
bug-reports: "https://github.com/ocaml/opam-repository/issues"
10+
flags: conf
11+
build: ["x86_64-linux-gnu-gcc" "--version"]
12+
depexts: [
13+
["gcc-x86-64-linux-gnu"] {os-family = "debian"}
14+
["gcc-x86_64-linux-gnu"] {os-family = "fedora"}
15+
["x86_64-linux-gnu-gcc"] {os-family = "arch"}
16+
]
17+
post-messages:
18+
"""\
19+
Please install x86_64-linux-gnu-gcc manually, as there is no known package
20+
for it for your distribution."""
21+
{failure}
22+
x-maintenance-intent: ["(latest)"]
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis: "OCaml cross compiler to the freestanding Unikraft arm64 backends"
8+
description:
9+
"This package provides an OCaml cross compiler, suitable for linking with a Unikraft arm64 unikernel."
10+
authors: "Samuel Hym"
11+
license: ["MIT" "LGPL-2.1-or-later WITH OCaml-LGPL-linking-exception"]
12+
depends: [
13+
"ocaml" {= "5.3.0"}
14+
"ocaml-unikraft-toolchain-arm64"
15+
"ocamlfind"
16+
"ocaml-src" {build}
17+
"conf-git" {build}
18+
]
19+
build: [
20+
[
21+
make
22+
"-j%{jobs}%"
23+
"prefix=%{prefix}%"
24+
"BIN=%{bin}%"
25+
"LIB=%{lib}%"
26+
"SHARE=%{share}%"
27+
"OCUKARCH=arm64"
28+
"%{name}%.install"
29+
]
30+
]
31+
install: [
32+
[make "install-ocaml"]
33+
]
34+
conflicts: ["ocaml-option-bytecode-only"]
35+
url {
36+
src:
37+
"https://github.com/mirage/ocaml-unikraft/archive/refs/tags/v1.0.0.tar.gz"
38+
checksum:
39+
"sha256=1ee307b066765da124056ce825683b2dcf58145297f9b717345b6c55e84af2c4"
40+
}
41+
available: os = "linux"
42+
x-maintenance-intent: ["(latest)"]
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis: "Firecracker/arm64 Unikraft backend for OCaml"
8+
authors: ["Samuel Hym" "Unikraft contributors"]
9+
license: ["MIT" "BSD-3-Clause" "GPL-2.0-only"]
10+
depends: [
11+
"unikraft" {= version}
12+
"unikraft-musl" {= version}
13+
"conf-aarch64-linux-gnu-gcc" {arch != "arm64"}
14+
]
15+
depopts: [
16+
"ocaml-unikraft-option-debug"
17+
]
18+
build: [
19+
[
20+
make
21+
"-j%{jobs}%"
22+
"UNIKRAFT=%{unikraft:lib}%"
23+
"UNIKRAFTMUSL=%{unikraft-musl:lib}%"
24+
"OCUKPLAT=firecracker"
25+
"OCUKARCH=arm64"
26+
"OCUKEXTLIBS=musl"
27+
"OCUKCONFIGOPTS+=debug" {ocaml-unikraft-option-debug:installed}
28+
"UK_CFLAGS=-std=gnu11"
29+
"%{name}%.install"
30+
]
31+
]
32+
url {
33+
src:
34+
"https://github.com/mirage/ocaml-unikraft/archive/refs/tags/v1.0.0.tar.gz"
35+
checksum:
36+
"sha256=1ee307b066765da124056ce825683b2dcf58145297f9b717345b6c55e84af2c4"
37+
}
38+
available: os = "linux"
39+
x-maintenance-intent: ["(latest)"]
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis: "Firecracker/x86_64 Unikraft backend for OCaml"
8+
authors: ["Samuel Hym" "Unikraft contributors"]
9+
license: ["MIT" "BSD-3-Clause" "GPL-2.0-only"]
10+
depends: [
11+
"unikraft" {= version}
12+
"unikraft-musl" {= version}
13+
"conf-x86_64-linux-gnu-gcc" {arch != "x86_64"}
14+
]
15+
depopts: [
16+
"ocaml-unikraft-option-debug"
17+
]
18+
build: [
19+
[
20+
make
21+
"-j%{jobs}%"
22+
"UNIKRAFT=%{unikraft:lib}%"
23+
"UNIKRAFTMUSL=%{unikraft-musl:lib}%"
24+
"OCUKPLAT=firecracker"
25+
"OCUKARCH=x86_64"
26+
"OCUKEXTLIBS=musl"
27+
"OCUKCONFIGOPTS+=debug" {ocaml-unikraft-option-debug:installed}
28+
"UK_CFLAGS=-std=gnu11"
29+
"%{name}%.install"
30+
]
31+
]
32+
url {
33+
src:
34+
"https://github.com/mirage/ocaml-unikraft/archive/refs/tags/v1.0.0.tar.gz"
35+
checksum:
36+
"sha256=1ee307b066765da124056ce825683b2dcf58145297f9b717345b6c55e84af2c4"
37+
}
38+
available: os = "linux"
39+
x-maintenance-intent: ["(latest)"]
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis:
8+
"Virtual package to ensure the Firecracker Unikraft backend is installed for the default cross compiler"
9+
description:
10+
"This virtual package ensures that the Firecracker backend is installed for the default `unikraft` ocamlfind cross toolchain."
11+
authors: "Samuel Hym"
12+
license: "MIT"
13+
depends: [
14+
"ocaml-unikraft"
15+
("ocaml-unikraft-default-x86_64" & "ocaml-unikraft-backend-firecracker-x86_64") |
16+
("ocaml-unikraft-default-arm64" & "ocaml-unikraft-backend-firecracker-arm64")
17+
]
18+
available: os = "linux"
19+
x-maintenance-intent: ["(latest)"]
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis: "QEMU/arm64 Unikraft backend for OCaml"
8+
authors: ["Samuel Hym" "Unikraft contributors"]
9+
license: ["MIT" "BSD-3-Clause" "GPL-2.0-only"]
10+
depends: [
11+
"unikraft" {= version}
12+
"unikraft-musl" {= version}
13+
"conf-aarch64-linux-gnu-gcc" {arch != "arm64"}
14+
]
15+
depopts: [
16+
"ocaml-unikraft-option-debug"
17+
]
18+
build: [
19+
[
20+
make
21+
"-j%{jobs}%"
22+
"UNIKRAFT=%{unikraft:lib}%"
23+
"UNIKRAFTMUSL=%{unikraft-musl:lib}%"
24+
"OCUKPLAT=qemu"
25+
"OCUKARCH=arm64"
26+
"OCUKEXTLIBS=musl"
27+
"OCUKCONFIGOPTS+=debug" {ocaml-unikraft-option-debug:installed}
28+
"UK_CFLAGS=-std=gnu11"
29+
"%{name}%.install"
30+
]
31+
]
32+
url {
33+
src:
34+
"https://github.com/mirage/ocaml-unikraft/archive/refs/tags/v1.0.0.tar.gz"
35+
checksum:
36+
"sha256=1ee307b066765da124056ce825683b2dcf58145297f9b717345b6c55e84af2c4"
37+
}
38+
available: os = "linux"
39+
x-maintenance-intent: ["(latest)"]
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis: "QEMU/x86_64 Unikraft backend for OCaml"
8+
authors: ["Samuel Hym" "Unikraft contributors"]
9+
license: ["MIT" "BSD-3-Clause" "GPL-2.0-only"]
10+
depends: [
11+
"unikraft" {= version}
12+
"unikraft-musl" {= version}
13+
"conf-x86_64-linux-gnu-gcc" {arch != "x86_64"}
14+
]
15+
depopts: [
16+
"ocaml-unikraft-option-debug"
17+
]
18+
build: [
19+
[
20+
make
21+
"-j%{jobs}%"
22+
"UNIKRAFT=%{unikraft:lib}%"
23+
"UNIKRAFTMUSL=%{unikraft-musl:lib}%"
24+
"OCUKPLAT=qemu"
25+
"OCUKARCH=x86_64"
26+
"OCUKEXTLIBS=musl"
27+
"OCUKCONFIGOPTS+=debug" {ocaml-unikraft-option-debug:installed}
28+
"UK_CFLAGS=-std=gnu11"
29+
"%{name}%.install"
30+
]
31+
]
32+
url {
33+
src:
34+
"https://github.com/mirage/ocaml-unikraft/archive/refs/tags/v1.0.0.tar.gz"
35+
checksum:
36+
"sha256=1ee307b066765da124056ce825683b2dcf58145297f9b717345b6c55e84af2c4"
37+
}
38+
available: os = "linux"
39+
x-maintenance-intent: ["(latest)"]
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis:
8+
"Virtual package to ensure the QEMU Unikraft backend is installed for the default cross compiler"
9+
description:
10+
"This virtual package ensures that the QEMU backend is installed for the default `unikraft` ocamlfind cross toolchain."
11+
authors: "Samuel Hym"
12+
license: "MIT"
13+
depends: [
14+
"ocaml-unikraft"
15+
("ocaml-unikraft-default-x86_64" & "ocaml-unikraft-backend-qemu-x86_64") |
16+
("ocaml-unikraft-default-arm64" & "ocaml-unikraft-backend-qemu-arm64")
17+
]
18+
available: os = "linux"
19+
x-maintenance-intent: ["(latest)"]
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
homepage: "https://github.com/mirage/ocaml-unikraft/"
4+
dev-repo: "git+https://github.com/mirage/ocaml-unikraft.git"
5+
bug-reports: "https://github.com/mirage/ocaml-unikraft/issues"
6+
tags: "org:mirage"
7+
synopsis:
8+
"OCaml default cross compiler to the freestanding Unikraft arm64 backends"
9+
description:
10+
"This package provides an OCaml cross compiler, suitable for linking with a Unikraft arm64 unikernel, as the default `unikraft` ocamlfind toolchain."
11+
authors: "Samuel Hym"
12+
license: "MIT"
13+
depends: ["ocaml-unikraft-arm64" "ocamlfind"]
14+
conflict-class: "ocaml-unikraft-default"
15+
build: [
16+
[make "prefix=%{prefix}%" "OCUKARCH=arm64" "%{name}%.install"]
17+
]
18+
url {
19+
src:
20+
"https://github.com/mirage/ocaml-unikraft/archive/refs/tags/v1.0.0.tar.gz"
21+
checksum:
22+
"sha256=1ee307b066765da124056ce825683b2dcf58145297f9b717345b6c55e84af2c4"
23+
}
24+
available: os = "linux"
25+
x-maintenance-intent: ["(latest)"]

0 commit comments

Comments
 (0)