caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Richard Jones <rich@annexia.org>
To: caml-list@inria.fr
Subject: [Caml-list] "Error while building custom runtime system"
Date: Wed, 15 Oct 2003 10:36:13 +0100	[thread overview]
Message-ID: <20031015093613.GA21312@redhat.com> (raw)

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


             reply	other threads:[~2003-10-15  9:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-10-15  9:36 Richard Jones [this message]
2003-10-15 16:57 ` [Caml-list] Initialization order bug Richard Jones
     [not found]   ` <16269.37646.599166.88324@karryall.dnsalias.org>
2003-10-16  9:18     ` Richard Jones

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20031015093613.GA21312@redhat.com \
    --to=rich@annexia.org \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).