Christoph Höger
2016-09-07 08:58:23 UTC
Dear all,
I attempt to compile an oasis project structured like this:
library Bar
Modules: Wrapper
CSources: bar.c
BuildDepends: ctypes.foreign
CCLib: -lfoo
Essentially, bar is both an extension of foo and a binding of this
extension for OCaml (using ctypes).
The "extension" point is problematic. While I can build this lib just
fine, the ctype bindings to the extension methods in bar.c are not found
at runtime using Dl:
Dl.DL_error("./main.native: undefined symbol: some_bar")
This is to be expected, as there is no dynamic library for bar.
So how do I solve this?
Is there some way to tell oasis to build a shared library from the
csources (and link it to all depending artifacts)?
thanks,
Christoph
--
Christoph Höger
Technische Universität Berlin
Fakultät IV - Elektrotechnik und Informatik
Übersetzerbau und Programmiersprachen
Sekr. TEL12-2, Ernst-Reuter-Platz 7, 10587 Berlin
Tel.: +49 (30) 314-24890
E-Mail: ***@tu-berlin.de
I attempt to compile an oasis project structured like this:
library Bar
Modules: Wrapper
CSources: bar.c
BuildDepends: ctypes.foreign
CCLib: -lfoo
Essentially, bar is both an extension of foo and a binding of this
extension for OCaml (using ctypes).
The "extension" point is problematic. While I can build this lib just
fine, the ctype bindings to the extension methods in bar.c are not found
at runtime using Dl:
Dl.DL_error("./main.native: undefined symbol: some_bar")
This is to be expected, as there is no dynamic library for bar.
So how do I solve this?
Is there some way to tell oasis to build a shared library from the
csources (and link it to all depending artifacts)?
thanks,
Christoph
--
Christoph Höger
Technische Universität Berlin
Fakultät IV - Elektrotechnik und Informatik
Übersetzerbau und Programmiersprachen
Sekr. TEL12-2, Ernst-Reuter-Platz 7, 10587 Berlin
Tel.: +49 (30) 314-24890
E-Mail: ***@tu-berlin.de
--
Caml-list mailing list. Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs
Caml-list mailing list. Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs