Re: Exporting symbols from EXE to DLL?
- From: Lars Erdmann <lars.erdmann@xxxxxxxx>
- Date: Wed, 08 Jul 2009 21:08:22 +0200
Marcel Müller schrieb:
As far as I know it is possible that a EXE module exports symbols too.
Interesting to know. I would have never thought that this is possible.
Is it possible to import this symbols in a DLL module?Reading the info for link386 from the "Tools reference" for the explanation of the IMPORTS def keyword:
Syntax:
IMPORTS
....
[internalname=]modulename.entry
....
<modulename>
The name of the application or library that contains the function.
....
That sounds like it should be possible for a DLL to import a symbol defined in an application. The question would be, how does the program loader know where to look for the module ? I'd think that it would always use the LIBPATH info. And the syntax looks like you cannot specify the module extension (.EXE in this case). Then I wonder what extension the program loader would expect.
If you try out, report the results.
I would like to use this scenario for API functions provided to plugin DLLs. In fact it would be much easier to use the API functions with load time linkage compared to passings a bunch of function pointers to the DLL module.
Lars
.
- Follow-Ups:
- Re: Exporting symbols from EXE to DLL?
- From: Marty
- Re: Exporting symbols from EXE to DLL?
- References:
- Exporting symbols from EXE to DLL?
- From: Marcel Müller
- Exporting symbols from EXE to DLL?
- Prev by Date: Re: Using too many threads?
- Next by Date: Re: realloc returns error (0)
- Previous by thread: Exporting symbols from EXE to DLL?
- Next by thread: Re: Exporting symbols from EXE to DLL?
- Index(es):
Relevant Pages
|