This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: dlltool & link to VC++ generated DLL

At 02:00 PM 4/17/2001, Bill Grigg wrote:


>Linking Against DLLs
>If you have an existing DLL already, you need to build a Cygwin-compatible
>import library (The supplied ones should work, but you might not have them)
>to link against. Unfortunately, there is not yet any tool to do this
>automatically. However, you can get most of the way by creating a .def file
>with these commands (you might need to do this in bash for the quoting to
>work correctly):
>echo EXPORTS > foo.defnm foo.dll | grep ' T _' | sed 's/.* T _//' >> foo.def
>Note that this will only work if the DLL is not stripped. Otherwise you will
>get an error message: "No symbols in foo.dll".
>Once you have the .def file, you can create an import library from it like
>dlltool --def foo.def --dllname foo.dll --output-lib foo.a
>7. I  skipped the "echo EXPORTS ..." part and just built my own .def file,
>MYDLL.def. See below:

You shouldn't do this.  My guess is that you now have the wrong function 
name due to improper calling convention.  Fix this or do the step you skipped.

>          Set_Status_Nav
>          Get_Status_Nav

Larry Hall                    
RFK Partners, Inc.            
118 Washington Street                   (508) 893-9779 - RFK Office
Holliston, MA 01746                     (508) 893-9889 - FAX

Want to unsubscribe from this list?
Check out:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]