This is a mirror of official site: http://jasper-net.blogspot.com/

How To Create 32-bit Import Libraries Without .OBJs or Source

| Wednesday, August 3, 2011
This article explains how to create an import library given a .DLL for which you have no source code or object modules. There is no 32-bit utility that can create an import library from a .DLL, as there was with 16-bit versions of Visual C++.

NOTE: This method may not work with DLLs generated with non-Microsoft development tools.

Normally, when building a .DLL or any target that exports functions or data items, an import library (and exports file) is generated as part of the linking process. But in the case of a third-party .DLL that does not ship with an import library, you may need to generate an import library in order to use the .DLL successfully using load-time dynamic linking. An import library is not needed for run-time dynamic linking.

There are two ways to create an import library given a .DLL:

    Create a .DEF file for use with the LIB /DEF: command.
    Stub out functions, and use the .OBJ files created to mimic the import/export relationships. Then use the LIB /DEF: command to create the import library.


Read more: MS Support
QR: 131313

Posted via email from Jasper-net

0 comments: