Re: [Caml-list] Compiling a shared library with amd64

2008-07-23 Thread Alain Frisch
Jonathan Marchand wrote: I got rid of the complains with 3.10.2 version (for libasmrun.a only). In the CVS version, if I compile by adding -fPIC in *COMOPTS, I still have some errors with libasmrun.a: Here is the complete build trace for rocaml (I use it as an exemple as it the same problem wit

Re: [Caml-list] Compiling a shared library with amd64

2008-07-23 Thread Alain Frisch
Jonathan Marchand wrote: I still have the same problem with ocaml from CVS (exemple from rocaml): cc -shared -o foo.so foo_rocaml_wrapper.o -L. -L/usr/lib -L. -rdynamic -Wl,-export-dynamic foo_rocaml_runtime.o /usr/local/lib/ocaml/libasmrun.a /usr/local/lib/ocaml/libunix.a /usr/local/lib/ocaml

Re: [Caml-list] Compiling a shared library with amd64

2008-07-23 Thread Jonathan Marchand
I still have the same problem with ocaml from CVS (exemple from rocaml): cc -shared -o foo.so foo_rocaml_wrapper.o -L. -L/usr/lib -L. -rdynamic -Wl,-export-dynamic foo_rocaml_runtime.o /usr/local/lib/ocaml/libasmrun.a /usr/local/lib/ocaml/libunix.a /usr/local/lib/ocaml/libnums.a -lruby1.8 -lpth

Re: [Caml-list] Compiling a shared library with amd64

2008-07-22 Thread Alain Frisch
Jonathan Marchand wrote: But I still have issues with the ocaml libraries. I don't know how to compile the standard library from the ocaml tarball with -fPIC. You should try the current CVS version of OCaml. Under AMD64, ocamlopt now produces PIC code by default. -- Alain __

[Caml-list] Compiling a shared library with amd64

2008-07-22 Thread Jonathan Marchand
Hi, I would like to compile a native shared library with ocaml on amd64. I googled the problem and as far as I understand, I need both runtimes and libraries (the ones used in my library) compiled with -fPIC: http://caml.inria.fr/mantis/view.php?id=3924 The above trick allowed me to compile ocam