Previous week Up Next week


Here is the latest Caml Weekly News, for the week of January 03 to 10, 2012.

  1. On packaging
  2. Understanding usage by the runtime
  3. Core (and associated libraries) on bitbucket!
  4. ocamlbrew
  5. Camomile 0.8.4
  7. Camlp5 new rel 6.03 -> compat with OCaml trunk
  8. OCamlSpotter 1.4.0 for OCaml 3.12.1
  9. Other Caml News

On packaging


Deep in this thread, Edgar Friendly said:
I have, and the result is odb[1]. It backends with oasis-db[2], meaning if you
upload your oasis package, it will be installable via odb, including
deps. After finding out about barbra[3], a similar project with a different
starting point, I stole many of their good ideas, and now have support for a
local `packages` file that provides metadata for packages not available
through oasis-db. This packages file allows installation of packages available
from arbitrary URLs (anything curl-able), git, svn, cvs, hg, darcs, as well as
local directories.

For a large number of package examples (plus non-examples of packages that
fail to auto-install through make/omake/oasis), look here:

Contributions of additional packages welcome, fixes to the programs that don't
auto-install (See the bottom half of the packages file) are doubly welcome.


[2] and
[3] still in stealth mode, maybe I shouldn't have stolen their thunder by
mentioning them

Understanding usage by the runtime


Deep in this thread, Richard Jones said and Damien Doligez added:
> Is compaction disabled?  lablgtk disables it unconditionally by
> setting the global Gc max_overhead (see also the Gc documentation):
>  src/
>    let () = Gc.set {(Gc.get()) with Gc.max_overhead = 1000000}

Anyone who disables compaction should seriously consider switching
to the first-fit allocation policy:

  let () = Gc.set {(Gc.get ()) with Gc.allocation_policy = 1}

This may slow down allocations a bit, but the theory tells us that
it completely prevents unbounded fragmentation of the OCaml heap.

Core (and associated libraries) on bitbucket!


Yaron Minsky announced:
For those who are interested in getting a look at a development version of the
next release of the Core suite of OCaml libraries, Core is now hosted on

We're still working on making installation smoother and easier, as well as
solving portability problems.  But please take a look.  There's also a
discussion list:!forum/ocaml-core

This represents a new and more open development model for us, and we hope that
as a result we'll be able to better interact with and accept patches from the
community, and that Core will become a base that many people can use for
building OCaml applications.



Hezekiah M. Carty announced:
I would like to announce ocamlbrew, a (very simple, very alpha) tool
for automating and managing builds of OCaml, findlib, and other
OCaml-related items under $HOME on Linux.  ocamlbrew takes it name and
a bit of wrapper code from perlbrew[1].  ocamlbrew provides a thin
bash wrapper around the standard OCaml + findlib build procedure,
taking advantage of odb[2] for further library and tool installations.

ocamlbrew currently lives on github:

With one command[3] ocamlbrew can build OCaml, findlib, oasis, utop,
Batteries, and ocamlscript from source, plus get an easily source-able
file to set up your environment.  Everything will be built and
installed under $HOME/ocamlbrew by default.

ocamlbrew can also be used to build OCaml from any branch on the
official Subversion server.  At this time I recommend using the "-f"
ocamlbrew flag with builds coming from Subversion due to some
incompatibilities between OCaml development versions and oasis.  The
-f flag tells ocamlbrew to only install OCaml, findlib, and,
skipping other tools and libraries.  This will hopefully provide a
simple way to test and provide feedback to the core OCaml development
team when new releases or experimental branches are ready for testing.

For more information, including ocamlbrew's requirements, see the file at the link above.

Enjoy!  Many thanks to Edgar/thelema and Adrien/adrien for taking the
time to test ocamlbrew and provide feedback as I was playing around
with the process.


[1] -
[2] -
[3] - Well, one command and the availability of all non-OCaml build

Camomile 0.8.4


Yoriyuki Yamagata announced:
I am pleased to announce the new release of Camomile, a Unicode
library for OCaml.  This release is a bug fix release.  The changes
from the previous version are
1) search_forward function of URe returns None, instead of raising
Not_found, if it does not find a match.  This is the documented
2) Parsing of regular expressions are changed, so that say </?a>
mathces <a>.  (Previously, it matches either a> or </a>)
3) The bugs of, UMap.domain and UMap.map_to_set are
fixed.  (incorporated from Batteries.)

Another big change is that, now we move the project to Github.  You
can download the new version from

You can find the general information at the Wiki


ygrek announced:
 Just a small announcement - GDB extension to inspect OCaml values :

 Basically an implementation of Std.dump (and hence Obj) in python.
 Not fully complete and could be enhanced in various ways, but already useful.
Fabrice Le Fessant then announced:
  If some people are interested in testing more gdb support, Thomas
Gazagnaire merged a few patches of OCaml and improved them to be able to
debug OCaml programs line by line in gdb, in this public repo:

(use either 3.12.1-gdb or trunk-gdb branches)

  There is no support for printing OCaml values, so you should use Ygrek
extension for that. All comments are welcome, as we would like to get as
much experience as possible to push for inclusion upstream as soon as

Camlp5 new rel 6.03 -> compat with OCaml trunk


Daniel de Rauglaudre announced:
For the ones who want to use Camlp5 with the current OCaml SVN development
(the 'trunk' directory), you can download the new version 6.03 of Camlp5

The gadt new feature is parsed but may not work. If you use it, please
let me know. I made it work with OCaml gadt branch, but I did not check
for the 'trunk' directory.

Camlp5 is a pre-processor-pretty-printer for OCaml.

OCamlSpotter 1.4.0 for OCaml 3.12.1


Jun Furuse announced:
An OCaml source browsing tool, OCamlSpotter 1.4.0 is out.

With OCamlSpotter, you can easily jump to identifier uses to the
corresponding definitions, resolving module inclusion and functor
applications. For further info, please check ;.

1.4.0 supports:
- Spotting the definitions of idents (Finding definition of idents)
- Spotting the uses of idents (Opposite of def spotting)
- Showing data types of expressions/patterns with their id numbers,
and the query of their definitions.
- Type driven expansion of expressions and patterns

It requires compiler modification. The modified compiler source and
OCamlSpotter is found at:

The diff against the original 3.12.1 can be easily obtained from the
bitbucket repo by

hg diff -r ocaml-3.12.1-11110 -r v3.12.1-ocamlspot-1.4.0 .

Happy hacking.

Other Caml News

From the ocamlcore planet blog:
Thanks to Alp Mestan, we now include in the Caml Weekly News the links to the
recent posts from the ocamlcore planet blog at

Putting Noise to the Test:

Camomile 0.8.4:


Fork Core!:

Text to PDF:

On the Bourbaki-Witt Principle in Toposes:

binmaps - compressed bitmaps:

Old cwn

If you happen to miss a CWN, you can send me a message and I'll mail it to you, or go take a look at the archive or the RSS feed of the archives.

If you also wish to receive it every week by mail, you may subscribe online.

Alan Schmitt