Version française
Home     About     Download     Resources     Contact us    
Browse thread
ocamlc problem on Mac OS X
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Roberto Bagnara <bagnara@c...>
Subject: Re: [Caml-list] ocamlc problem on Mac OS X
Xavier Leroy wrote:
>> I have a problem compiling mlgmp
>>     ocamlc -g -custom gmp.cma test_suite.cmo -o test_suite
>> which results into
>>     gcc  -o 'test_suite' -I'/opt/local/lib/ocaml'
>> /tmp/camlprimd07b82.c  '-L/opt/local/lib/ocaml' '-lmlgmp' '-L.' \
>>       '-L' '-Wl,-rpath' '-lmpfr' '-lgmp' '-L/opt/local/lib/ocaml/gmp'
>> -lcamlrun -lcurses -lpthread
> 
>> which seems to suggest there is a bug in ocamlc (at least in the Mac OS
>> X version).
> 
> I believe the problem comes from the way your configured mlgmp in your
> Mac OS X build.  If I guess correctly, in Makefile you left GMP_LIBDIR
> empty and kept the Linux definition of RLIBFLAGS instead of selecting
> the MacOS X one.  You will be readily excused, as mlgmp's
> configuration is hardly described.

Thanks Xavier: I have been told (I do not use Mac OS X myself) that that
was indeed the problem.

> But if you have further problems,
> may I suggest you take them with the author of mlgmp first?

This is what I did one month ago, but got no answer.  Moreover, it seemed
that ocamlc was generating an invalid gcc '-L' option.
Thanks a lot,

     Roberto

-- 
Prof. Roberto Bagnara
Computer Science Group
Department of Mathematics, University of Parma, Italy
http://www.cs.unipr.it/~bagnara/
mailto:bagnara@cs.unipr.it