www.digitalmars.com         C & C++   DMDScript  

c++.windows.32-bits - import library generation

reply "V. Krishnakumar" <lvimala eth.net> writes:
Hi group,

I downloaded the 8.28 beta and compiled the MFC 4.21 library (NAFXCW.LIB).
However
I was not able to compile the DLL (SFC42.MAK). Help/tips/suggestions highly
appreciated.

Where are the import libraries (shell32.lib, winspool.lib etc.) ?

I did use the implib.exe to generate them but it seems that the generated
libs do not have the decorated symbols (like _somefunction 4 etc.)

Is there any tool to do that ?

The LCC-Win32 compiler generates all the import libraries on the client
system after installation. Maybe it should have the necessary .def files.

Another Q:  the magic header of the exe generated by dmc++ is MZ and PE.
Does it mean that the executables use the dos exe file format and not PE ?

sorry for being so long.

-Krish
Apr 19 2002
next sibling parent "Walter" <walter digitalmars.com> writes:
"V. Krishnakumar" <lvimala eth.net> wrote in message
news:a9oheh$1l6d$1 digitaldaemon.com...
 Where are the import libraries (shell32.lib, winspool.lib etc.) ?
They're on the CD version.
 I did use the implib.exe to generate them but it seems that the generated
 libs do not have the decorated symbols (like _somefunction 4 etc.)
 Is there any tool to do that ?
Not automatically, you'll need a def file for it.
 Another Q:  the magic header of the exe generated by dmc++ is MZ and PE.
 Does it mean that the executables use the dos exe file format and not PE ?
The MZ is just for the "stub executable" which just prints out that you need Win32 to run.
Apr 19 2002
prev sibling parent reply "V. Krishnakumar" <lvimala eth.net> writes:
I found the complete list of exports in the LCC-Win32 distribution and now
am able to build the import libraries by myself. But I still have problems.

1.  The dlls on my system have no associated symbols so I get unreferenced
symbol errors when linking. Do I need the ordinals to link ?

2. winspool is actually winspool.drv but lcc's export file marks it as
winspool.dll. So I renamed it to winspool.dll and generated the implib. But
when the application is run, I get the following error: "_ClosePrinter 4
unresolved" etc.

help appreciated.

-Krish
Apr 19 2002
parent "Walter" <walter digitalmars.com> writes:
"V. Krishnakumar" <lvimala eth.net> wrote in message
news:a9pmuv$6vk$1 digitaldaemon.com...
 I found the complete list of exports in the LCC-Win32 distribution and now
 am able to build the import libraries by myself. But I still have
problems.
 1.  The dlls on my system have no associated symbols so I get unreferenced
 symbol errors when linking. Do I need the ordinals to link ?
The linker doesn't read the dlls, so that can't be the problem. The problem is the symbols in your library don't match the references the compiler generates. You can try obj2asm on the .obj and .lib files and see what the names are.
 2. winspool is actually winspool.drv but lcc's export file marks it as
 winspool.dll. So I renamed it to winspool.dll and generated the implib.
But
 when the application is run, I get the following error: "_ClosePrinter 4
 unresolved" etc.
 help appreciated.
Do a grep on the .dll and see what symbols are in there.
Apr 19 2002