Browse thread
problem with LACAML and static linking
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: | 2009-01-28 (17:56) |
From: | Erick Matsen <matsen@b...> |
Subject: | Re: [Caml-list] problem with LACAML and static linking |
Hello Mauricio--- Is this what you mean? ocamlopt \ -I /home/matsen/ocaml/bio/ -I /home/matsen/ocaml/common/ -I /usr/lib/ocaml/3.10.2/pcre/ -I /usr/lib/ocaml/3.10.2/glpk/ -I /usr/lib/ocaml/3.10.2/gsl/ -I /usr/lib/ocaml/3.10.2/lacaml/ -I /usr/lib/gcc/i486-linux-gnu/4.3/ \ -ccopt -static \ #HERE... -cclib /usr/lib/gcc/i486-linux-gnu/4.3/libgfortran.a \ -ccopt -L/home/matsen/ocaml/bio/ -ccopt -L/home/matsen/ocaml/common/ -ccopt -L/usr/lib/ocaml/3.10.2/pcre/ -ccopt -L/usr/lib/ocaml/3.10.2/glpk/ -ccopt -L/usr/lib/ocaml/3.10.2/gsl/ -ccopt -L/usr/lib/ocaml/3.10.2/lacaml/ -ccopt -L/usr/lib/gcc/i486-linux-gnu/4.3/ pcre.cmxa bigarray.cmxa unix.cmxa gsl.cmxa lacaml.cmxa -o placer \ /home/matsen/ocaml/common/common_base.cmx /home/matsen/ocaml/bio/biobase.cmx base.cmx minimization.cmx integration.cmx /home/matsen/ocaml/bio/liketree.cmx liketreeFuns.cmx /home/matsen/ocaml/common/number.cmx /home/matsen/ocaml/common/mat.cmx /home/matsen/ocaml/bio/diagd.cmx /home/matsen/ocaml/bio/qtree.cmx /home/matsen/ocaml/bio/protModels.cmx /home/matsen/ocaml/bio/alignment.cmx /home/matsen/ocaml/bio/alignmentLike.cmx placerFuns.cmx placer.cmx That gives /usr/lib/libblas.a(xerbla.o): In function `xerbla_': (.text+0x0): multiple definition of `xerbla_' /usr/lib/liblapack.a(xerbla.o):(.text+0x0): first defined here /usr/lib/ocaml/3.10.2/libasmrun.a(unix.o): In function `caml_dlopen': (.text+0x223): warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking /usr/lib/ocaml/3.10.2/libunix.a(getgr.o): In function `unix_getgrgid': ... similar messages .... so BLAS and gfortran both define xerbla. Hm... but progress! Thanks, Erick On Wed, Jan 28, 2009 at 9:33 AM, Mauricio Fernandez <mfp@acm.org> wrote: > On Wed, Jan 28, 2009 at 09:17:56AM -0800, Erick Matsen wrote: >> Here is my compile line >> >> ocamlopt \ >> >> # source directories: >> -I /home/matsen/ocaml/bio/ -I /home/matsen/ocaml/common/ -I >> /usr/lib/ocaml/3.10.2/pcre/ -I /usr/lib/ocaml/3.10.2/glpk/ -I >> /usr/lib/ocaml/3.10.2/gsl/ -I /usr/lib/ocaml/3.10.2/lacaml/ -I >> /usr/lib/gcc/i486-linux-gnu/4.3/ \ >> >> # cc directives >> -ccopt -static -ccopt -lgfortran -ccopt > > I think you need -cclib here (just did s/cclib/ccopt/ with some code of mine > and got undefined refs...). > > -- > Mauricio Fernandez - http://eigenclass.org > > _______________________________________________ > Caml-list mailing list. Subscription management: > http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list > Archives: http://caml.inria.fr > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > Bug reports: http://caml.inria.fr/bin/caml-bugs >