caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: pierrchp@free.fr
To: caml-list@inria.fr
Subject: [Caml-list] native plugin ocaml-mysql
Date: Sat, 13 Aug 2011 04:08:29 +0200	[thread overview]
Message-ID: <1313201309.4e45dc9d7aff9@imp.free.fr> (raw)



Hello,

I am trying to compile a plugin for ocaml-mysql, in order to use it with the
native version of the ocsigen webserver. I ran into the following problem:

ocamlopt -shared -linkall  -o mysql.cmxs mysql.cmxa

 usr/bin/ld: cannot find -lmysql_stubs
 collect2: ld returned 1 exit status
 File "caml_startup", line 1, characters 0-1:
 Error: Error during linking

I looked at how mysql.cmxa was compiled :

   ocamlopt -a -cclib -lmysql_stubs -cclib -lzocamlopt -o mysql.cmxa mysql.cmx

which does not raise any error, and tried :

    ocamlopt -shared -cclib -lmysql_stubs -cclib -lzocamlopt  -o mysql.cmxs
mysql.cmx

    with the same error.


Any idea on how to make that native plugin ?


Cheers

 -Pierre

             reply	other threads:[~2011-08-13  2:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-13  2:08 pierrchp [this message]
2011-08-13  9:59 ` Stéphane Glondu

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=1313201309.4e45dc9d7aff9@imp.free.fr \
    --to=pierrchp@free.fr \
    --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).