From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=AWL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by yquem.inria.fr (Postfix) with ESMTP id 7E5CCBBCA for ; Wed, 16 Apr 2008 23:23:41 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArgAANcKBkjOvjGvfGdsb2JhbACRXAEBCwUCBwcWnB8 X-IronPort-AV: E=Sophos;i="4.25,666,1199660400"; d="scan'208";a="9669104" Received: from web54605.mail.re2.yahoo.com ([206.190.49.175]) by mail2-smtp-roc.national.inria.fr with SMTP; 16 Apr 2008 23:23:40 +0200 Received: (qmail 43627 invoked by uid 60001); 16 Apr 2008 21:23:40 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=y9vchQnWbDeegJARxBvOex4knhzvlP/i/Gkgqycib3LDmw+IMt+9slvUyEAzHbaG7Ax6pZc5A20fgkejOaE1WFG/AjS7qa4QDebkgTT+W8kVYSdo1tiCrNvIVU6kBPnGm8fAsJB5tGEzL0rMZKHyJZhHWwZ/kC4Y122KeYO7z5A=; X-YMail-OSG: BjEbnRwVM1ndlQLG3WIFLa4BpVBBjmhnL4LE.Q92q78QNKP4KDf0n56TM70YzdEMWGJfRIkZOgPrTZTAVK.yIBVegomVYGE- Received: from [85.244.10.118] by web54605.mail.re2.yahoo.com via HTTP; Wed, 16 Apr 2008 22:23:40 BST Date: Wed, 16 Apr 2008 22:23:40 +0100 (BST) From: Dario Teixeira Subject: Re: [Caml-list] Trying out Ocaml CVS HEAD To: Alain Frisch Cc: caml-list@yquem.inria.fr In-Reply-To: <4805A2ED.7010606@frisch.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <173750.43276.qm@web54605.mail.re2.yahoo.com> X-Spam: no; 0.00; ocaml:01 cvs:01 byte-code:01 -custom:01 -wl:01 cvs:01 -wl:01 ocamlc:01 native-code:01 ocamlopt:01 -verbose:01 -noautolink:01 recompiled:01 ocaml:01 compiler:01 > > I've been able to reproduce the problem in byte-code only, when the main > program is linked in -custom mode. The reason is that the -Wl,-E was not > passed to the linker. This is now fixed in the CVS. (For a quick test, > you can try to pass "-ccopt -Wl,-E" explicitly to ocamlc when linking.) > > For the native-code, I don't know. Can you show me the command line > passed to the linker (ocamlopt -verbose)? You should see -Wl,-E. > If you compile with -noautolink, you must add "-ccopt -Wl,-E" manually. > Hi Alain, Thanks for the help. I have recompiled the Ocaml compiler using the latest CVS, and bytecode now seems to work fine. As for native code, I am still having some problems. There's a subset of modules that load fine, but also one module that produces an error message when the main programme attempts to load it. As far as I can tell, what distinguishes this problematic module from the ones that work fine is the fact that its cmxs file is built from a large number of cmx files, whereas the cmxs from a "good" module is built from a single cmx. Here are the compiler lines that build the cmx and cmxs for a good module: (note the "-dlcode" used to build the cmx and the "-dlcode -shared -linkall" used to link the cmxs) ocamlfind ocamlopt -thread -package netstring,camlzip,sqlite3 -I ../lwt -I ../baselib -I ../http -I ../xmlp4 -I ../server -I ../extensions -I ../eliom -dlcode -c deflatemod.ml ocamlfind ocamlopt -thread -package netstring,camlzip,sqlite3 -I ../lwt -I ../baselib -I ../http -I ../xmlp4 -I ../server -I ../extensions -I ../eliom -dlcode -shared -linkall -o deflatemod.cmxs deflatemod.cmx The lines for the problematic module are (almost) identical, except that the order of arguments is not the same, and the linking stage takes multiple cmx arguments instead of just one: ocamlfind ocamlopt -dlcode -verbose -thread -package netstring,cryptokit -I ../lwt -I ../baselib -I ../http -I ../xmlp4 -I ../server -I ../extensions -I ../eliom -shared -linkall -o eliom.cmxs \ error_pages.cmx \ eliommod_sessiongroups.cmx eliom_common.cmx \ eliommod_gc.cmx eliommod_persess.cmx \ eliommod_sessadmin.cmx eliommod_cookies.cmx \ eliommod_naservices.cmx eliommod_sersess.cmx eliommod_sessexpl.cmx \ eliommod_datasess.cmx eliommod_pagegen.cmx \ eliommod_services.cmx eliommod_timeouts.cmx \ eliommod.cmx eliom_sessions.cmx \ eliom_parameters.cmx eliom_services.cmx \ eliom_mkforms.cmx eliom_mkreg.cmx eliom_predefmod.cmx \ eliom_tools.cmx As for the runtime error message, this is what is produced when the programme attempts to load eliom.cmxs: [errors.log] 2008-04-16 22:15:50 - Fatal - While loading /home/dario/.local/lib/ocsigen/extensions/eliom.cmxs: Dynlink.Error: no implementation available for Eliommod_persess (note that Eliommod_persess.cmx is included in the list of modules that are linked into eliom.cmxs) Kind regards, Dario Teixeira ___________________________________________________________ Yahoo! For Good helps you make a difference http://uk.promotions.yahoo.com/forgood/