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 LAA22939; Wed, 15 Oct 2003 11:36:16 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id LAA16428 for ; Wed, 15 Oct 2003 11:36:15 +0200 (MET DST) Received: from aomori.annexia.org (annexia.force9.co.uk [212.56.101.183]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id h9F9aE111398 for ; Wed, 15 Oct 2003 11:36:14 +0200 (MET DST) Received: from rich by aomori.annexia.org with local (Exim 3.36 #1 (Debian)) id 1A9i4j-0005Y3-00 for ; Wed, 15 Oct 2003 10:36:13 +0100 Date: Wed, 15 Oct 2003 10:36:13 +0100 To: caml-list@inria.fr Subject: [Caml-list] "Error while building custom runtime system" Message-ID: <20031015093613.GA21312@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.4i From: Richard Jones X-Loop: caml-list@inria.fr X-Spam: no; 0.00; runtime:01 ocamlc:01 '-verbose':01 ocamlc:01 -verbose:01 gcc:01 -verbose:01 lablgtk:01 lablgtk:01 postgres:01 pcre:01 pcre:01 gtkinit:01 postgres:01 dbi:99 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk I'm getting very strange behaviour from ocamlc when linking. Here's my small test program. Note the '-verbose' arg: $ ocamlc -verbose -I +perl -w s perl4caml.cma perl_init.cmo loadpage.cmo -o loadpage $ (ie. everything is OK - it doesn't run any external programs such as gcc or ld). Now here's the *real* program I want to compile, note also the -verbose arg: $ ocamlc -verbose -w s -I +lablgtk2 -I ../lablgtk2-mozembed -I +apache -I +postgres -I +perl -I +pcre unix.cma pcre.cma lablgtk.cma gtkInit.cmo lablgtkmoz.cma postgres.cma dbi.cmo dbi_postgres.cmo perl4caml.cma perl_init.cmo lib.cmo globals.cmo database.cmo google.cmo loadpage.cmo parsepage.cmo gtkError.cmo gtkTied.cmo selection_dialog.cmo browser.cmo mainWindowControls.cmo autoPage.cmo productRankingPage.cmo salesAsmtPage.cmo commitPage.cmo pages.cmo main.cmo -o assessor + gcc -Wl,-E -o 'assessor' -I'/usr/lib/ocaml/3.07' -L/usr/local/lib -L/usr/lib/perl/5.8.1/CORE -Wl,-rpath,/usr/local/lib:/usr/lib/perl/5.8.1/CORE -L/usr/lib/mozilla -Wl,-rpath,/usr/lib/mozilla /tmp/camlprim5ffb86.c '-L/usr/lib/ocaml/3.07/lablgtk2' '-L../lablgtk2-mozembed' '-L/usr/lib/ocaml/3.07/apache' '-L/usr/lib/ocaml/3.07/postgres' '-L/usr/lib/ocaml/3.07/perl' '-L/usr/lib/ocaml/3.07/pcre' '-L/usr/lib/ocaml/3.07' '-lperl4caml' '-lperl' '-ldl' '-lm' '-lpthread' '-lc' '-lcrypt' '-lpq' '-lmlpostgres' '-llablgtkmoz' '-lgtkembedmoz' '-lxpcom' '-lplds4' '-lplc4' '-lnspr4' '-ldl' '-lc' '-lpthread' '-llablgtk2' '-lgtk-x11-2.0' '-lgdk-x11-2.0' '-latk-1.0' '-lgdk_pixbuf-2.0' '-lm' '-lpangoxft-1.0' '-lpangox-1.0' '-lpango-1.0' '-lgobject-2.0' '-lgmodule-2.0' '-ldl' '-lglib-2.0' '-lpcre_stubs' '-lpcre' '-lunix' -lcamlrun -lm -ldl -lcurses -lpthread /usr/lib/ocaml/3.07/perl/libperl4caml.a(perl_c.o)(.text+0x1b): In function `xs_init': : undefined reference to `boot_DynaLoader' collect2: ld returned 1 exit status Error while building custom runtime system I'm not using the -custom option anywhere. Ocamlc seems to react entirely differently. First it launches gcc. Secondly (and more importantly) it fails to link in a particular static library which I specified when I created perl4caml.cma. The test program also relies on the 'boot_DynaLoader' symbol, so I don't understand why the test program works, but the real program fails, and why ocamlc works completely differently in each case. Something to do with the other libraries I'm using?? Rich. -- Richard Jones. http://www.annexia.org/ http://freshmeat.net/users/rwmj Merjis Ltd. http://www.merjis.com/ - all your business data are belong to you. "I wish more software used text based configuration files!" -- A Windows NT user, quoted on Slashdot. ------------------- 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