English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2005-11-14 (18:09)
From: Daniel Margolis <dmargoli+lists@a...>
Subject: OCaml-MySQL

I'm trying to get database access working in OCaml, using v. 3.0.9 on  
MacOS 10.4. So first, if anyone has recommendations of a good  
interface for any (free) database server (i.e. I'm not tied to  
implementation--MySQL, PostgreSQL, SQLite, etc, are all fine), I'd  
gladly like to hear them. Performance is something of a concern, but  
my main concern is ease of use--something with an intuitive interface  
would be nice.

Second, I've been trying to get OCaml-MySQL  (from http:// 
raevnos.pennmush.org/code/ocaml-mysql/) working, since it seems a  
good option. So I had to replace the OCamlMakefile it comes with with  
a newer version (because the version it comes with tries to do gcc - 
shared, which is unavailable on OSX) to get it to compile. But when I  
try to build the demo, using "ocamlc mysql.cma demo.ml", I get

> Error on dynamically loaded library: Symbol not found:  
> _mysql_get_host_info
>   Referenced from: ./dllmysql_stubs.so
>   Expected in: flat namespace

I don't know anything much about linking OCaml code to C modules, so  
I'm a bit lost. Can anyone suggest what might be causing this, and  
how I can fix it?