From: "Nicolas Pouillard" <nicolas.pouillard@gmail.com>
To: "Joel Reymont" <joelr1@gmail.com>
Cc: "Caml List" <caml-list@inria.fr>
Subject: Re: [Caml-list] Producing a C wrapper with ocamlbuild or OMake
Date: Wed, 28 Mar 2007 17:49:28 +0200 [thread overview]
Message-ID: <cd67f63a0703280849o237a1208x30b8f4e875177190@mail.gmail.com> (raw)
In-Reply-To: <2378477D-F40B-4A4D-B8A4-E0446FB46F7A@gmail.com>
On 3/28/07, Joel Reymont <joelr1@gmail.com> wrote:
> One last question... Two, actually.
>
> How would I add another C file to the pipeline to produce the final
> executable?
Add it like a link flag.
flag ["ocaml"; "link"; "output_obj"(* I think that's where you want it
*)] (A"your_file.o");
Then add it to dependencies to force it's creation.
dep ["ocaml"; "link"; "output_obj"(* I think that's where you want it
*)] ["your_file.o"];
> Then, I tried using the library I built but I get an error. I have no
> iea what's going on, does anyone? I'm on Mac OSX if it matters.
>
> gcc foo.c -L_build -lmorpher -o foo
> /usr/bin/ld: Undefined symbols:
> _caml_atom_table
> _caml_code_area_end
> _caml_code_area_start
> _caml_static_data_end
> _caml_static_data_start
> collect2: ld returned 1 exit status
>
> nm _build/libmorpher.a |grep caml_atom_table
> 00000400 C _caml_atom_table
> U _caml_atom_table
>
No idea.
--
Nicolas Pouillard
next prev parent reply other threads:[~2007-03-28 15:49 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-27 23:10 Joel Reymont
2007-03-28 8:53 ` [Caml-list] " Nicolas Pouillard
[not found] ` <cd67f63a0703280158g559eff38pb6cca758682cad4a@mail.gmail.com>
2007-03-28 9:04 ` Joel Reymont
2007-03-28 12:38 ` Nicolas Pouillard
2007-03-28 13:25 ` Joel Reymont
2007-03-28 13:57 ` Nicolas Pouillard
2007-03-28 14:10 ` Joel Reymont
2007-03-28 15:46 ` Nicolas Pouillard
2007-03-28 18:58 ` Joel Reymont
2007-03-28 21:13 ` Nicolas Pouillard
2007-03-28 14:44 ` Joel Reymont
2007-03-28 15:49 ` Nicolas Pouillard [this message]
2007-03-28 22:46 ` Joel Reymont
2007-03-29 11:20 ` Nicolas Pouillard
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=cd67f63a0703280849o237a1208x30b8f4e875177190@mail.gmail.com \
--to=nicolas.pouillard@gmail.com \
--cc=caml-list@inria.fr \
--cc=joelr1@gmail.com \
/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