Version française
Home     About     Download     Resources     Contact us    
Browse thread
undefined reference to caml_init_exceptions
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Michael Alexander Hamburg <hamburg@f...>
Subject: undefined reference to caml_init_exceptions
I'm working on a project with an event core, coded in an OCaml library
with C glue to libevent (not the released one; rather, my own, but I might
release it fairly soon).  The library is in
ocaml-libevent/ocaml_libevent.cmxa, with the C glue in
ocaml-libevent/glue.o, symlinked to ./glue.o.

When linking the program, make runs:

ocamlopt [-o stuff] -cclib -levent ocaml-libevent/ocaml_libevent.cmxa \
	[bunch of .cmx files]

And it returns:

glue.o(.text+0xf): In function `ocaml_event_init':
ocaml-libevent/glue.c:47: undefined reference to `caml_init_exceptions'
collect2: ld returned 1 exit status
Error during linking
make: *** [run.opt] Error 2

I can make a bytecode version with ocamlc -custom, or a native version
without caml_init_exceptions; is caml_init_exceptions deprecated?

Mike