From: Jeremy G. <jn...@nt...> - 2003-12-01 15:02:01
|
Hi Matthew, This is what I do: In header file: #ifdef BUILD_DLL #define EXPORT __declspec(dllexport) #else #define EXPORT __declspec(dllimport) #endif #ifdef __cplusplus extern "C" { #endif EXPORT void __stdcall test(); #ifdef __cplusplus } #endif In cpp file: extern "C" { void __stdcall test() { } } Also, I link with the --add-stdcall-alias option. Have a look to see what names you are actually exporting. I use depends.exe from the Windows Platform SDK to do that. Jeremy --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.544 / Virus Database: 338 - Release Date: 25/11/2003 |