Skip to content

[wip] port to jbuilder#839

Closed
avsm wants to merge 3 commits intomirage:masterfrom
avsm:jbuilder
Closed

[wip] port to jbuilder#839
avsm wants to merge 3 commits intomirage:masterfrom
avsm:jbuilder

Conversation

@avsm
Copy link
Copy Markdown
Member

@avsm avsm commented Jun 17, 2017

not for merge yet until more documented, but with this PR multidirectory builds of mirage-types works with jbuilder. You can do:

for i in block channel clock console device flow fs kv net protocols random stack time; do
  opam source mirage-$i --dev
done
git clone -b jbuilder git://github.com/avsm/mirage
jbuilder build @mirage/types/lwt/doc
jbuilder build mirage/types/lwt/mirage_types_lwt.cmx

opam-free local development! and then multiple environments also work...

$ cat jbuilder-workspace
(context ((switch 4.03.0)))
(context ((switch 4.04.1)))

make sure both the switches have dependencies that we havent locally git cloned available:

OPAMSWITCH=4.03.0 opam install -y -j4 lwt cstruct ipaddr uri io-page
OPAMSWITCH=4.04.1 opam install -y -j4 lwt cstruct ipaddr uri io-page

then a build will build all the local files in both switches, in separate build dirs

$ jbuilder build mirage/types/lwt/mirage_types_lwt.cmx
<snip>
    ocamlopt mirage-channel/lwt/mirage_channel_lwt.{cmx,o} [4.04.1]
    ocamlopt mirage/types/mirage_types.{cmx,o} [4.04.1]
    ocamlopt mirage-block/lwt/mirage_block_iter.{cmx,o} [4.04.1]
    ocamlopt mirage-block/lwt/mirage_block_lwt.{cmx,o} [4.03.0]
    ocamlopt mirage-block/lwt/mirage_block_lwt.{cmx,o} [4.04.1]
    ocamlopt mirage/types/lwt/mirage_types_lwt.{cmx,o} [4.03.0]
    ocamlopt mirage/types/lwt/mirage_types_lwt.{cmx,o} [4.04.1]

@samoht samoht mentioned this pull request Jul 18, 2017
@samoht
Copy link
Copy Markdown
Member

samoht commented Jul 20, 2017

Closing as #850 is now ready.

@samoht samoht closed this Jul 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants