Re: DLL and external references

From: alias.name (alias.name_at_gmail.com)
Date: 07/15/04


Date: Thu, 15 Jul 2004 20:08:36 GMT


Thank you, I was trying mimic the shared library behavior from Unix, but
since DLL are essentially EXE's and not just shared objects since it won't
work for my purpose.

A little more description of what I was trying to do:

I was trying to convert a static library into a DLL. The static library is
used to build an application. The "static library" uses functions from some
other static libraries. So to convert just that static library to a DLL I
would essentially have to resolve all external calls, which gets quite
involved and intricate and creates a huge DLL (the original EXE, almost).

Is my understanding correct?

Victor Bazarov <v.Abazarov@comAcast.net> wrote in
news:eWauhnpaEHA.3892@TK2MSFTNGP10.phx.gbl:

>
> Not sure I understand this question. An EXE is essentially a DLL.
> So, when a DLL is built, all external references need to be resolved.
> If the function uses static binding (comes from a static library),
> the library has to be supplied at the time of linking. If the symbol
> (function) uses dynamic binding (comes from a DLL), the _import_
> library needs to be supplied at the time of linking.
>
> Basically, there is no difference in linking a DLL or an EXE. The
> latter doesn't produce the import lib (usually), and has a different
> file extension. The inner format and ways to resolve symbols are
> essentially the same.
>
> Victor



Relevant Pages

  • Re: How to get imagebase after a DLL gets loaded
    ... that he wants to use his approach in a DLL, and Kevin says that Will's ... libraries and the logical equivalent (shared source, ... Um, actually, this is /very/ common for static libraries and/or ...
    (microsoft.public.win32.programmer.kernel)
  • Re: How to get imagebase after a DLL gets loaded
    ... The main difference between DLL and static library in this context is ... so that it is not meant to be integrated with the client code ... SPEAKING ABOUT STATIC LIBRARIES HERE, AND I *EXPLICITLY* SAID IT THIS ...
    (microsoft.public.win32.programmer.kernel)
  • Re: How to get a .lib from .dll
    ... Using the Borland tools, you should first run "IMPDEF" on the DLL file ... information in it to create ".LIB" import libraries with;)... ... from Windows version to Windows version...so, ...
    (comp.lang.asm.x86)
  • Re: How to get a .lib from .dll
    ... Using the Borland tools, you should first run "IMPDEF" on the DLL file ... information in it to create ".LIB" import libraries with;)... ... from Windows version to Windows version...so, ...
    (alt.lang.asm)
  • Re: How to get imagebase after a DLL gets loaded
    ... During the process of building the DLL, ... Implementing a library that requires users of the library to instantiate ... predict what variable name you will use at initialization time. ... Some third-party libraries DO require that you instantiate a pre-defined ...
    (microsoft.public.win32.programmer.kernel)

Loading