stdcall is a call to a Windows function call (very different from a C call convention). HTOD failed to flag multiple functions using extern (Windows) . This is normal, since the HTOD is not equipped for macro processing ( STDCALL is defined as a macro, I see this from the remaining comments in msyql.d).
The mysql.d file is updated here: http://dl.dropbox.com/u/9218759/mysql.d
Now you need the proper import library in OMF format. I would generally advise that you do not use the implicit for this. I had a few problems with this, and others reported problems using it. Using coffimplib is the way to go. But first, you need the COFF import library.
If you need it, the Mysql edition with the COFF import library can be downloaded here: http://dev.mysql.com/downloads/mirror.php?id=377977#mirrors (DLL libraries marked for Visual Studio usually come with COFF import libraries )
But I provide you with the translated COFF import library in OMF format here: http://dl.dropbox.com/u/9218759/libmysql.lib
I tried both of your test cases, and they both seem to be working fine now. In case of problems, try checking the translated header file (mysql.d) again, it is possible that I may have skipped to correctly specify all the calling conventions.
source share