caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Anil Madhavapeddy <anil@recoil.org>
To: Markus Mottl <markus.mottl@gmail.com>
Cc: Thomas Gazagnaire <thomas@ocamlpro.com>,
	Gerd Stolpmann <info@gerd-stolpmann.de>,
	Fabrice Le Fessant <Fabrice.Le_fessant@inria.fr>,
	Francois Berenger <berenger@riken.jp>,
	Ocaml Mailing List <caml-list@inria.fr>
Subject: Re: [Caml-list] GODI is shutting down
Date: Wed, 24 Jul 2013 09:39:19 -0700	[thread overview]
Message-ID: <7F8931D5-E65D-49EB-B54D-A50716F3EFDD@recoil.org> (raw)
In-Reply-To: <CAP_800qRrLs4Bc-4-2wB7+UC-s-S8fEirrz0tgm-q-AOX2fraw@mail.gmail.com>

On 24 Jul 2013, at 08:58, Markus Mottl <markus.mottl@gmail.com> wrote:

> My guess is that you are not totally happy with Oasis at this point so
> this may be a topic to address.  Being an Oasis user, I would say that
> the Oasis tools may not be as mature yet as one would hope, but the
> Cabal-like package specification syntax seems decent enough to be
> supported by OPAM.  It really shouldn't be that hard to automate the
> process of updating OPAM metadata (including version constraints)
> based on changes in Oasis package specifications.

I think that's fair, but the devil is in the details. The core of OASIS
is sound, but is hampered by its need to build on top of ocamlfind
and ocamlbuild, and the ensuing impedance mismatches that follow (e.g.
manually editing _tags files, and trying to debug which tool a failure
happens in is an advanced operation). OPAM packages represent an output
collection of (several optionally built) ocamlfind packages, and 
OASIS sits awkwardly in between these two right now, with ocamlbuild
crashing the party and getting drunk in the kitchen.

OASIS is structured very well to help get around this situation though.
It has a library that takes care of parsing the _oasis file, and then a
plugin generator that currently uses ocamlbuild to drive this specification
into concrete outputs.  Meanwhile, the OCaml compiler has been exposing
more of its innards via compiler-libs. Leo and I are taking advantage of
this by trying to folding all of these layers into a new "packaging-friendly"
OCaml driver that statically links:

- all the camlp4 libraries required for a project, and directly calls it
  instead of going via -pp (avoiding a fork/marshal).
- links to OPAM/findlib to find dependencies directly, avoiding a shell
  out to ocamlfind.
- can publish a static schedule of its activities to help Makefiles
  figure out what actually got built (similar to the recent ocamlbuild
  request).

The idea is to have a "ocamlmkcompiler" that builds a binary for-purpose,
as "ocamlmktop" does today for toplevels.  It shouldn't even need any
patches to the official compiler, thanks to compiler-libs.  More to the
point, it should make it far easier to build a camlp4-aware js_of_ocaml
toplevel, to fit into the experiments that OCamlPro is doing with web
IDE interfaces.

Anyway, these are still experiments and quite likely to run into unexpected
issues as we build them, and we'll have to consider all the alternatives
before folding them all into OPAM.

Right now, OPAM dictates the *minimal* possible set of requirements for
a package since it just uses shell commands.  It should be possible to
specialise this for common cases such as a OASIS library, but it does
require some careful thought first.  Luckily, we can use OPAM itself to
conduct such experiments [1].

All such discussions and experiments are very welcome on the mailing
list (http://lists.ocaml.org/listinfo/opam-devel) to help establish
everyone's use cases.  Daniel Buenzli's input has been particularly
interesting to date, as his libraries adopt a very minimal shell-script
driven approach that doesn't use OASIS, but still distributes META files.
That's just one example of someone that doesn't use OASIS directly.
The Core OASIS files are also a bit special due to their configuration
requirements.  Xen/Mirage is also quite demanding in terms of the 
compilation environment.

Here's my goal: I want to have near instant-rebuilds of Mirage packages.
I know it's possible to pull this off with the existing compiler tools,
since the monolithic Mirage tree (with lovingly crafted ocamlbuild rules
and judicious use of native code compiler binaries) could rebuild the
entire webserver in ~10s in parallel.  Nowadays, with OPAM, ocamlbuild,
ocamlfind and camlp4, it takes around 2-3 minutes, which just isn't
good enough.

-anil

[1] http://opam.ocamlpro.com/pkg/debug-camlp4-log.base.html: I hacked
up a debug camlp4 to trace all the uses of camlp4 in the OPAM repository,
during the wg-camlp4 discussion on the topic of where to go next with it.
This just required doing a mass OPAM install, drinking some coffee, and
reading the resulting trace logs. 

  parent reply	other threads:[~2013-07-24 16:39 UTC|newest]

Thread overview: 93+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-22 21:21 Gerd Stolpmann
2013-07-22 22:32 ` Anil Madhavapeddy
2013-07-23  6:49   ` Gabriel Scherer
2013-07-23  8:46     ` Keyan
2013-07-23  8:57       ` AW: " Gerd Stolpmann
2013-07-23  9:45         ` Paolo Donadeo
2013-07-23 13:31         ` Marek Kubica
2013-07-24  9:09           ` Mihamina Rakotomandimby
2013-07-23  9:34   ` AW: " Gerd Stolpmann
2013-07-23 10:00     ` Jesper Louis Andersen
2013-07-22 23:44 ` oliver
2013-07-23  0:03   ` Nicolas Braud-Santoni
2013-07-23  1:51 ` Francois Berenger
2013-07-24  9:27   ` [Caml-list] " Andreas Hauptmann
2013-07-23  9:07 ` [Caml-list] " Adrien Nader
2013-07-23 10:01   ` AW: " Gerd Stolpmann
2013-07-23 10:22   ` oliver
2013-07-24  1:55   ` Francois Berenger
2013-07-24  7:03     ` Fabrice Le Fessant
2013-07-24  8:42       ` Jun Furuse
2013-07-24 10:30         ` Daniel Bünzli
2013-07-25 14:46           ` [Caml-list] " Sylvain Le Gall
2013-07-24 12:36       ` AW: [Caml-list] " Gerd Stolpmann
2013-07-24 14:44         ` Thomas Gazagnaire
2013-07-24 15:58           ` Markus Mottl
2013-07-24 16:25             ` Thomas Gazagnaire
2013-07-24 16:36               ` Gabriel Scherer
2013-07-24 16:41                 ` Anil Madhavapeddy
2013-07-25 15:21                   ` [Caml-list] " Sylvain Le Gall
2013-07-24 16:39               ` AW: [Caml-list] " Markus Mottl
2013-07-24 16:58                 ` Thomas Gazagnaire
2013-07-24 17:06                   ` Thomas Gazagnaire
2013-07-24 17:33                   ` Török Edwin
2013-07-24 18:49                     ` Markus Mottl
2013-07-25 15:16               ` [Caml-list] Re: AW: " Sylvain Le Gall
2013-07-25 15:29                 ` Leo White
2013-07-25 15:33                   ` Sylvain Le Gall
2013-07-24 16:39             ` Anil Madhavapeddy [this message]
2013-07-24 17:05               ` [Caml-list] " Gabriel Scherer
2013-07-24 17:56                 ` Daniel Bünzli
2013-07-24 18:23                   ` Markus Mottl
2013-07-24 20:43                     ` Daniel Bünzli
2013-07-25  5:32                       ` Adrien Nader
2013-07-25  9:52                         ` Daniel Bünzli
2013-07-25 21:01                           ` Adrien Nader
2013-07-25  1:32                 ` Francois Berenger
2013-07-25 15:10                   ` [Caml-list] " Sylvain Le Gall
2013-07-25 15:23                     ` Christopher Zimmermann
2013-07-25 20:03                       ` Adrien Nader
2013-07-26  1:14                         ` ocamlbuild (was Re: [Caml-list] Re: GODI is shutting down) Francois Berenger
2013-07-26  2:43                           ` Peter Groves
2013-07-26  5:02                           ` Gabriel Scherer
2013-07-26  5:26                             ` [Caml-list] Re: ocamlbuild Francois Berenger
2013-07-26  7:25                               ` Wojciech Meyer
2013-07-26  8:07                                 ` Francois Berenger
2013-07-26  9:24                                   ` r.3
2013-07-26 10:48                                 ` Daniel Bünzli
2013-07-26 11:13                                   ` Wojciech Meyer
2013-07-26 17:29                                     ` Ashish Agarwal
2013-07-26  5:29                             ` ocamlbuild (was Re: [Caml-list] Re: GODI is shutting down) Jeff Meister
2013-07-26  6:14                               ` Gabriel Scherer
2013-07-26 13:48                                 ` Dario Teixeira
2013-07-25 20:18                 ` [Caml-list] GODI is shutting down Wojciech Meyer
2013-07-24 18:04               ` Markus Mottl
2013-07-24 16:18           ` AW: " Matej Kosik
2013-07-24 16:17             ` David Sheets
2013-07-24 16:56               ` Matej Kosik
2013-07-24 17:03                 ` Thomas Gazagnaire
2013-07-25 15:01                   ` [Caml-list] Re: AW: " Sylvain Le Gall
2013-07-24 22:05           ` AW: [Caml-list] " Siraaj Khandkar
2013-07-24 22:06           ` Virgile Prevosto
2013-07-24 22:47             ` Amir Chaudhry
2013-07-24 23:03             ` Anil Madhavapeddy
2013-07-25  5:22               ` Adrien Nader
2013-07-23  9:28 ` [Caml-list] Re: [Godi-list] " Thomas Gazagnaire
2013-07-23 15:32   ` Pierre-Etienne Meunier
2013-07-23 15:37     ` David Sheets
2013-07-23 15:44     ` Daniel Bünzli
2013-07-23 16:19       ` Pierre-Etienne Meunier
2013-07-23 16:26         ` Ashish Agarwal
2013-07-23 16:32         ` Daniel Bünzli
2013-07-23 16:55       ` Virgile Prevosto
2013-07-28 22:29       ` Wojciech Meyer
2013-07-23 19:38     ` Yaron Minsky
2013-07-23 19:49       ` Pierre-Etienne Meunier
2013-07-23 20:02         ` Yaron Minsky
2013-07-23 22:35 ` [Caml-list] " Mike Lin
2013-07-25 16:10 ` [Caml-list] " Sylvain Le Gall
2013-07-25 17:42   ` Daniel Bünzli
2013-07-25 18:52     ` Sylvain Le Gall
2013-07-25 18:28   ` Fabrice Le Fessant
2013-07-25 19:00     ` Sylvain Le Gall
2013-07-25 19:23       ` Yotam Barnoy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7F8931D5-E65D-49EB-B54D-A50716F3EFDD@recoil.org \
    --to=anil@recoil.org \
    --cc=Fabrice.Le_fessant@inria.fr \
    --cc=berenger@riken.jp \
    --cc=caml-list@inria.fr \
    --cc=info@gerd-stolpmann.de \
    --cc=markus.mottl@gmail.com \
    --cc=thomas@ocamlpro.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).