Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
CamlJava w/ recent OCaml (3.11.1) and Sun's JVM (OpenJDK)
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2009-12-01 (10:52)
From: Stefano Zacchiroli <zack@u...>
Subject: CamlJava w/ recent JVMs - solved (patches needed and included)
On Mon, Nov 23, 2009 at 04:55:37PM +0100, Stefano Zacchiroli wrote:
> Has anyone successfully built/used CamlJava [1] with recent OCaml and
> the open sourced Sun's JVM (OpenJDK)?

With the tremendous help of Grégoire Henry, we've come up to a fixed
version of CamlJava that:

- works well with recent JVMs (both Sun's 1.6 and OpenJDK)
  * fixes are both for building and for avoiding segfaults due to a
    distinction among local and global references introduced by JNI 1.6
- is a bit more debugger friendly
- has _conditional_ automatic mapping of Java strings to OCaml strings
  (needed by O'Jacare [1])
- is a bit more careful/strict in case of multithreading: you must
  ensure all Java-OCaml callbacks are called from the very same thread
  (need spotted by O'Jacare a while ago)
- fixes various minor issues that help packages

All patches are available at [2] and contain appropriate

The patches are integrated in the Debian package of CamlJava that I've
just uploaded to the archive. While the package gets processed for
copyright review, it is also available at:

  deb zack-unstable/
  deb-src zack-unstable/

Xavier: can you please consider integrating the above patches in a new
release of CamlJava?

AFAIK, a new release of O'Jacare based on the above work is being worked
on by Grégoire.



Stefano Zacchiroli -o- PhD in Computer Science \ PostDoc @ Univ. Paris 7
zack@{,,} -<>-
Dietro un grande uomo c'è ..|  .  |. Et ne m'en veux pas si je te tutoie
sempre uno zaino ...........| ..: |.... Je dis tu à tous ceux que j'aime