caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Robert Roessler <roessler@rftp.com>
To: Caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] ocamlopt and *using* DLLs
Date: Thu, 26 May 2005 18:50:39 -0700	[thread overview]
Message-ID: <42967CEF.6000003@rftp.com> (raw)
In-Reply-To: <005801c5602f$b786a070$0d05a8c0@PWARP>

Nicolas Cannasse wrote:

>>Put a different way, ml_scintilla.dll definitely has a dependence on
>>ocamlrun.dll - which logical need would not go away even if I
>>repackaged the DLL as a static lib.
> 
> 
> Actually the symbols are only imported from ocamlrun.dll if you compile-with
> or define the CAML_DLL preprocessor variable.
> If you don't have CAML_DLL defined, symbols will be resolved at linking
> time, and will then be found in your executable.
> So it's possible to have a staticly linked library in both bytecode
> (with -custom) and nativecode.

The proper use of CAML_DLL, along with your exposition on the
differences between the bytecode and native runtime models was key to
making this all work for me... but it is now.

> You can have a look at the OCaml Win32 API library Makefile that have
> different ways of building and linking it
> (http://ocaml-win32.sourceforge.net/).

This is actually funny - about a year and a half ago, when I was first
looking at OCaml, I corresponded with Harry Chomsky and pointed out a
bug in the makefile being distributed with this project - having to do
with [not] defining CAML_DLL! :)

I also contributed a small amount of code to the project, but ended up
not being able to use the "OCaml Win32 API" because of the license. :(

Robert Roessler
roessler@rftp.com
http://www.rftp.com



  reply	other threads:[~2005-05-27  1:49 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-24  3:54 Robert Roessler
2005-05-24  4:29 ` [Caml-list] " Jacques Garrigue
2005-05-24  6:39   ` Robert Roessler
2005-05-24  7:10     ` Nicolas Cannasse
2005-05-27  1:50       ` Robert Roessler [this message]
     [not found]       ` <42967B63.8040408@rftp.com>
     [not found]         ` <02ce01c56355$14c93db0$19b0e152@warp>
2005-06-01 20:32           ` Robert Roessler
     [not found]             ` <0d4f01c56702$94853300$0300a8c0@DBLSYG61>
2005-06-02  4:24               ` Robert Roessler
2005-05-27  2:13   ` Robert Roessler
2005-05-27  8:17     ` Anatoly Zaretsky
2005-05-28  6:42       ` Nicolas Cannasse
2005-05-24  5:06 ` Nicolas Cannasse
2005-05-27  1:50   ` Robert Roessler

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=42967CEF.6000003@rftp.com \
    --to=roessler@rftp.com \
    --cc=caml-list@inria.fr \
    /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;
as well as URLs for NNTP newsgroup(s).