Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Guillaume Yziquel <guillaume.yziquel@citycable.ch>
Cc: Gerd Stolpmann <gerd@gerd-stolpmann.de>, OCaml List <caml-list@inria.fr>
Subject: Re: [Caml-list] Controlling module loading order.
Date: Fri, 15 Jan 2010 18:31:35 +0100	[thread overview]
Message-ID: <4B50A677.3030302@citycable.ch> (raw)
In-Reply-To: <4B4B6498.3050407@citycable.ch>

Guillaume Yziquel a écrit :
> Gerd Stolpmann a écrit :
>> Hi Guillaume,
>>
>> if you want to control from findlib that a certain function is invoked,
>> the usual way to do it is to put a .cmo/.cmx file into the "archive"
>> variables. The problem is that the linker drops all unused modules
>> from .cma/.cmxa archives, and as a consequence the initialization code
>> of these modules is not executed. So you could make R.interpreter
>> a .cmo/.cmx - in this case the module is always initialized.
> 
> Thank you so much!

Just a complementary remark: when using a .cmo instead of a .cma, one 
should ship a .o file in place of the .a file. For the sake of exhaustivity.

-- 
      Guillaume Yziquel
http://yziquel.homelinux.org/


      reply	other threads:[~2010-01-15 17:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-08 20:54 Guillaume Yziquel
2010-01-09  8:22 ` [Caml-list] " Stéphane Glondu
2010-01-11 11:59 ` Gerd Stolpmann
2010-01-11 17:49   ` Guillaume Yziquel
2010-01-15 17:31     ` Guillaume Yziquel [this message]

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=4B50A677.3030302@citycable.ch \
    --to=guillaume.yziquel@citycable.ch \
    --cc=caml-list@inria.fr \
    --cc=gerd@gerd-stolpmann.de \
    /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