Hi Phil,
 
Why you make things complex? C++ naming convention depends on compiler. I would suggest to use MS C++ compiler to create a normal DLL in C which can be used in Delphi. Of course you need a license to use MS C++ compiler. That might be a trouble. Anyway if you can afford Delphi, that should not be a big issue for you.
 
Cheers
Leigh
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Phil Middlemiss
Sent: Tuesday, January 07, 2003 9:09 AM
To: Multiple recipients of list delphi
Subject: [DUG]: C++ Name mangling

Hi all,
 
We have a set of old .lib files generated with MS C++ (I think). I'm trying to use C++ Builder to create a DLL or OCX or something that can then be used in Delphi, but my lack of C++ knowledge is slowing me down. I am having trouble just using the lib files in a simple C++ Builder test app.
 
I have used coff2omf to convert the lib files to Borland format (was getting an invalid OMF error before), but the whole name mangling thing has got me stumped.
 
The header file for the lib has this declaration:
extern int __cdecl mobileCreateConnection(LPTHIS_CONNECTION connection);
 
and if I call mobileCreateConnection in my code then, when compiling, I get the error:
[LinkerError] Unresolved external '_mobileCreateConnection' referenced from c:\APath\TheCallingUnit.OBJ
 
I'm sure this is a simple matter for anyone who has used C++ Builder and had to link to older lib files. Can anyone help?
 
thanks,
Phil.

Reply via email to