delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1998/10/24/21:06:10

From: khan AT xraylith DOT wisc DOT edu (Mumit Khan)
Subject: Re: dll, java, gcc, cygwin
24 Oct 1998 21:06:10 -0700 :
Message-ID: <Pine.SUN.3.93.981024160951.23565A-100000.cygnus.gnu-win32@modi.xraylith.wisc.edu>
References: <362F5356 DOT 36BA95C0 AT cmu DOT edu>
Mime-Version: 1.0
To: Andrew Mickish <mickish AT cmu DOT edu>
Cc: Glen Fullmer-EGF002 <Glen_Fullmer-EGF002 AT email DOT mot DOT com>,
gnu-win32 AT cygnus DOT com

On Thu, 22 Oct 1998, Andrew Mickish wrote:

> It might be related to name mangling.  Try adding .def aliases in your larger
> example.  I have to supply aliases in a .def file like the following for every native
> method I export from the DLL:
> 
>      EXPORTS
>      Java_HelloWorld_displayHelloWorld=Java_HelloWorld_displayHelloWorld AT 8
>      dll_entry AT 12
> 

Here's a proposal: how about I add a --add-stdcall-alias to dlltool which
essentially produce the following:

      EXPORTS
      Java_HelloWorld_displayHelloWorld=Java_HelloWorld_displayHelloWorld AT 8
      Java_HelloWorld_displayHelloWorld AT 8

When creating .def file using ``dlltool --output-def''. Would this solve 
the problem? Note that I'm keeping the original symbol as well, but we 
could always get rid of that too.

Making DLLs then look like the following:
  
  dlltool --output-def my.def --add-stdcall-alias [ ... ] *.o
  dllwrap -o my.dll --def my.def [ .... ]*.o

btw, you should *never* export DLL entry points (unless you really know
what you're doing of course).

Regards,
Mumit


-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019