From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id KAA32068; Wed, 24 Jul 2002 10:21:24 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id KAA32054 for ; Wed, 24 Jul 2002 10:21:23 +0200 (MET DST) X-SPAM-Warning: Sending machine is listed in blackholes.five-ten-sg.com Received: from athlon.baretta.com (r-mi214-6a124.tin.it [62.211.4.124]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id g6O8LMX26762 for ; Wed, 24 Jul 2002 10:21:22 +0200 (MET DST) Received: from baretta.com (localhost.localdomain [127.0.0.1]) by athlon.baretta.com (Postfix) with ESMTP id 9FD132724B; Wed, 24 Jul 2002 10:28:51 +0200 (CEST) Message-ID: <3D3E6543.2050001@baretta.com> Date: Wed, 24 Jul 2002 10:28:51 +0200 From: Alessandro Baretta Organization: Baretta srl -- www.baretta.com User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.0) Gecko/20020529 X-Accept-Language: it, en MIME-Version: 1.0 To: rolf.wester@ilt.fhg.de Cc: caml-list@inria.fr Subject: Re: [Caml-list] Problem building custom toplevel References: <200207221608.17010.rolf.wester@ilt.fraunhofer.de> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Rolf Wester wrote: > Hi, > > I have a c++-library compiled with the icc-compiler, a c-interface to this > library (cinterface.h and cinterface.cpp) and stubs files generated using > camlidl (ocaml_opt.idl, ocaml_opt_stubs.cpp, ocaml_opt.ml, ocaml_opt.mli). > I try to build a custom toplevel with: > > ocamlmktop -custom -thread unix.cma str.cma bigarray.cma nums.cma \ > threads.cm graphics.cma \ > ../cinterface/cinterface.o ocaml_opt_stubs.o ocaml_opt.cmo \ > /usr/lib/libexpat.a \ > /usr/lib/libdfftw.a \ > /opt/intel/compiler60/ia32/lib/libcxa.so \ > /lib/ld-linux.so \ > ../lib/libopt.a \ > -cclib -ldl -cclib -lpthread -cclib -lutil -cclib -lm -cclib -lc \ > -o ocaml_opt > ... Apparently no Jedi Camler has answered your question yet, so I'll give you my opinion FWIW. I believe you are linking the files in the wrong order. All references in a given file provided as input to the ocaml compiler during the linking phase must be resolved in the files *preceding* it on the command line. The fact that the linker is unable to resolve such "banal" references as operator new probably indicates that libcxa.so should be placed towards the beginning of the cammand line. Anyhow, try to work out a dependency DAG between the different linking modules, in order to discover precisely what conflict(s) is(are) causing the above mentioned problem. I hope this helps. Otherwise, you'll have to wait for one of the Jedis to come along and solve the problem. Alex ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners