From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by yquem.inria.fr (Postfix) with ESMTP id 10E64BBAF; Tue, 1 Dec 2009 11:52:51 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AokDAJaEFEtDz4HegWdsb2JhbACbbQEBFiS7TYQyBA X-IronPort-AV: E=Sophos;i="4.47,320,1257116400"; d="scan'208";a="51299865" Received: from fettunta.fettunta.org ([67.207.129.222]) by mail4-smtp-sop.national.inria.fr with ESMTP; 01 Dec 2009 11:52:48 +0100 Received: from usha.takhisis.invalid (unknown [10.17.0.10]) by fettunta.fettunta.org (Postfix) with ESMTPS id AE2C6184E1; Tue, 1 Dec 2009 10:52:47 +0000 (UTC) Received: by usha.takhisis.invalid (Postfix, from userid 1000) id 980A0666C; Tue, 1 Dec 2009 11:52:48 +0100 (CET) Date: Tue, 1 Dec 2009 11:52:48 +0100 From: Stefano Zacchiroli To: OCaml Mailing List Cc: Xavier Leroy , =?iso-8859-1?Q?Gr=E9goire?= Henry Subject: CamlJava w/ recent JVMs - solved (patches needed and included) Message-ID: <20091201105248.GA30936@usha.takhisis.invalid> Mail-Followup-To: OCaml Mailing List , Xavier Leroy , =?iso-8859-1?Q?Gr=E9goire?= Henry References: <20091123155537.GA10062@usha.takhisis.invalid> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20091123155537.GA10062@usha.takhisis.invalid> User-Agent: Mutt/1.5.20 (2009-06-14) X-Spam: no; 0.00; zacchiroli:01 zack:01 camljava:01 0100,:01 zacchiroli:01 camljava:01 ocaml:01 gregoire:01 segfaults:01 jni:01 debugger:01 ocaml:01 callbacks:01 zack:01 afaik:01 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 descriptions. 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 http://people.debian.org/~zack/debian zack-unstable/ deb-src http://people.debian.org/~zack/debian 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. Cheers. [1] http://www.pps.jussieu.fr/~henry/ojacare/index.en.html [2] http://git.debian.org/?p=pkg-ocaml-maint/packages/camljava.git;a=tree;f=debian/patches -- Stefano Zacchiroli -o- PhD in Computer Science \ PostDoc @ Univ. Paris 7 zack@{upsilon.cc,pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/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