|
From: <Chr...@in...> - 2007-04-06 12:38:04
|
Hi all, I got some MSVC dll (along with the according .lib files) which I tried to link to a project developed with minGW under Eclipse CDT. My problem is, that the linker gives me unresolved references whenever I try to create instances for objects stored in those dlls. I found various resources on the web dealing with this and so I played around with pexports and dlltool like this: pexports my.dll >my.def=20 dlltool -U -d my.def -l libmy.a I tried to link my program against the .dll, the .lib and the .a files (using the -l flag). Nothing worked. The class definitions in the header files look like this: =09 class __declspec(dllimport) Utils Within my main program I simply try to call the constructor, but the linker gives me: undefined reference to `MyNameSpace::Utils::Utils()' The .def file created by pexports looks like: LIBRARY my.dll EXPORTS ??1Utils@MyNameSpace@@UAE@XZ ??4Utils@MyNameSpace@@QAEAAV01@ABV01@@Z=09 ??_7Utils@MyNameSpace@@6B@ DATA=09 All those '?' and '@' look weird and do not match with the formats I found at http://wyw.dcweb.cn/stdcall.htm How does a valid .def file have to look like?=20 Thanks for your help Christian Pontesegger |