|
From: Wu Y. <ad...@ne...> - 2005-01-20 06:04:48
|
How was the DLL built? If it was by MSVC, then the recent MinGW toolchain should directly work with the library for function exports, like "gcc mymain.o multicam.lib". It it was not the case, the first thing you could try is follow the steps outlined in http://mingw.sourceforge.net/mingwfaq.shtml#faq-msvcdll esp. the part the concerning __stdcall functions in the end. If this still does not work, read http://wyw.dcweb.cn/stdcall.htm try to understand the case, and walk your own way. Best regards, Yongwei --- Original Message from Fe Kater --- Hi, I'd be happy for any hint if and maybe how I could create a suitable lib for a dll I have to use. Here are the settings and what I tried so far: (a) With "dumpbin multicam.dll /exports" I got a list of all 74 functions: ordinal hint RVA name 1 0 000066E0 ?McOpenDriverMaintenance@@YGHXZ 2 1 ... ?_McOpenDriverMaintenance@@YGHXZ 3 2 ... _AlphaSelfTest@16 .. 13 C ... _McCreate@8 .. 61 3C ... __McOpenDriver@4 .. 74 Note (don't know if this is significant): The first 2 entrys start with "?", then some functions start with 1 underscore, finally there are functions with 2 underscores. (b) There was a def file provided: IMPORTS McOpenDriver=MULTICAM._McOpenDriver@4 McCloseDriver=MULTICAM._McCloseDriver@0 McCreate=MULTICAM._McCreate@8 .. (c) There was a lib-file provided which of course did *not* work for me. The error message right when my program starts: Can't find entry point for function "McOpenDriver". Here is what I tried: (a) Changed "IMPORTS" to "EXPORTS" in the provided def file, inserted "LIBRARY multicam.dll". (b) Used dlltool in msys like this (tried also combinitions of -U and -k) dlltool.exe -l name_of_new_lib -D name_of_existing_dll -d def_file_to_read [-U] [-k] (c) compiled and linked again against the new lib (d) program starts with same error: can't find entry for function McOpenDriver. |