apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dongsheng Song <dongsh...@apache.org>
Subject [PATCH] Fix apr_dbd_mysql link error on windows
Date Thu, 13 May 2010 06:46:52 GMT
In function dbd_mysql_init, there have a function call (my_init) which does
not export in libmysql.dll
(mysql-connector-c-6.0.2). So we got link error:

apr_dbd_mysql.obj : error LNK2019: unresolved external symbol _my_init
referenced in function _dbd_mysql_init
.\Release\apr_dbd_mysql-1.dll : fatal error LNK1120: 1 unresolved externals

As in dbd_mysql_open, we call mysql_init, which call mysql_server_init, then
mysql_server_init call my_init,
so we need not to direct call my_init.

This issues exists in 1.3.x, 1.4.x, 1.5.x and trunk.

Index: apr_dbd_mysql.c
===================================================================
--- apr_dbd_mysql.c     (revision 943816)
+++ apr_dbd_mysql.c     (working copy)

@@ -1284,7 +1284,6 @@

 static void dbd_mysql_init(apr_pool_t *pool)
 {
-    my_init();
     mysql_thread_init();

     /* FIXME: this is a guess; find out what it really does */


Regards,

Dongsheng

Mime
View raw message