Skip to content
This repository has been archived by the owner on Oct 18, 2020. It is now read-only.

Add support for OCaml 4.06 and 4.07 #205

Merged
merged 3 commits into from
Dec 27, 2018
Merged

Add support for OCaml 4.06 and 4.07 #205

merged 3 commits into from
Dec 27, 2018

Conversation

anmonteiro
Copy link
Contributor

@anmonteiro anmonteiro commented Dec 19, 2018

This PR adds support for more recent OCaml versions (4.06.x and 4.07.x).

I tested across all the supported versions (including the old ones) manually to make sure I didn't introduce any regressions.

There's probably some more testing necessary, but I wanted to open the PR right away to get feedback as soon as possible.

@mato
Copy link

mato commented Dec 20, 2018

This looks fine to me from a cursory review. Have you tested that Mirage unikernels built with the newer compilers actually run on Xen?

@yomimono Could you review this please and/or help with testing?

@@ -14,5 +14,6 @@ depends: [
"ocamlfind" {build}
"ocaml-src"
"ocamlbuild" {build}

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Extraneous blank line.

@anmonteiro
Copy link
Contributor Author

@mato Yes, I ran a simple example in all switches and they compiled and ran successfully.

It was, however, a simple unikernel, I could do more testing with a more complex one that uses more functionality.

@anmonteiro
Copy link
Contributor Author

anmonteiro commented Dec 20, 2018

Following up, I just built and ran mirage-www on OCaml 4.07.1, so I think that can be considered the final round of testing?

EDIT: needed to pin a couple packages (rpc, rrd and xapi-rrd) to their development versions because the released versions were incompatible with OCaml < 4.06, otherwise everything looks good!

@mato
Copy link

mato commented Dec 21, 2018

Thank you for testing this. @mirage/core, can we get one more review and merge this if happy, then work together with @anmonteiro to release updated packages? My plate is full for the coming weeks.

@avsm
Copy link
Member

avsm commented Dec 21, 2018

I'll take this one and test shortly.

@avsm avsm self-assigned this Dec 21, 2018
@avsm
Copy link
Member

avsm commented Dec 23, 2018

Testing on 4.07; this patch works but just tracking down a possible race in mirage-net-xen that's causing the static website build to fail. mirage-www also works in 4.06 and needs rrd updated to 4.07

@avsm
Copy link
Member

avsm commented Dec 27, 2018

This changeset looks good. The issues on Xen were due to semantic changes in the device versioning (frontend trying to connect to tap0 instead of xenstore device 0), which can be dealt with separately. Thanks for the improvements @anmonteiro ! I'll cut a release shortly.

@avsm avsm merged commit 9eccf85 into mirage:master Dec 27, 2018
@anmonteiro anmonteiro deleted the anmonteiro/ocaml-406-407 branch December 27, 2018 11:10
avsm added a commit to avsm/opam-repository that referenced this pull request Jan 2, 2019
- add support for OCaml 4.06 and 4.07 in the xen backend (mirage/mirage-platform#205 by @anmonteiro)
- update opam metadata to 2.0 format (@avsm)
avsm added a commit to avsm/opam-repository that referenced this pull request Feb 19, 2019
supports forthcoming dune support as part of mirage/mirage#969:

* Add support for OCaml 4.08 (mirage/mirage-platform#206 by @anmonteiro)
* `libxenasmrun.a` is symlinked in the ocaml directory in order to be able to use ocamlopt's `-runtime-variant` option.
* Expose flags through files as well as pkg-config (mirage/mirage-platform#205 by @TheLortex).  Instead of pkg-config, one can use the following files to get compilation flags:
  * mirage-xen-ocaml/libs
  * mirage-xen-ocaml/cflags
  * mirage-xen-posix/minios-cflags
  * mirage-xen-posix/minios-libs
  * mirage-xen-posix/posix-cflags
  * mirage-xen-posix/posix-libs
  With dune this allows us to write `%{lib:mirage-xen-posix:posix-libs}` to get the flags instead of having a script invoking `pkg-config mirage-xen-posix --libs`.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants