DLL at fixed location and memory sharing between executables

Alexandre Julliard julliard at winehq.com
Fri Apr 13 15:42:27 CDT 2001


Bill Medland <medbi01 at accpac.com> writes:

> Is there a way to get the following to work under WINE? (i.e. to get two
> executables to share global memory as they do under windows)
> 
> We have a DLL that is at a specified memory location.
> 
> At the top of the code a variable is declared as follows:
> 
> #pragma   data_seg( "global_mem" )
> #pragma   bss_seg( "global_mem" )
> 
> unsigned uAttachmentCount = 0;
> 
> [...]
> 
> Is there any way for me to configure Wine so that both processes use
> the same memory?

You cannot do that for whole processes, but if the data section in the
dll is marked as shared, Wine will share it among all processes, even
though the processes themselves are in separate address spaces. Did
you configure the global_mem section as shared in your dll .def file?
(I assume you are compiling your dll under Windows; the above #pragma
is not supported by Linux compilers).

-- 
Alexandre Julliard
julliard at winehq.com



More information about the wine-users mailing list