RE: [OFFTOPIC...but not really] DLLs and MinGW32

new topic     » topic index » view thread      » older message » newer message

Hi Mike,

Sorry for taking so long to respond.

I can email you a DLL (source I mean!) I created for euLibnet using 
Mingw.

Let me know if you want it.

The compiling and linking is based on dllHelpers by Mumit Khan.
http://www.nanotech.wisc.edu/%7Ekhan/software/gnu-win32/dllhelpers.html

There has been much discussion on the Mingw email list for months
about "how to create a dll".  There are many ways and most depend
on what patch version of mingw you have.

I was able to produce a dll using the dllhelpers "technique" and have
stuck with it.

Ray Smith


Mike Hurley wrote:
> How does one go about making DLLs with MinGW32?  I've tried reading docs 
> online but none have been all too clear.  I've played with dlltool and 
> dllwrap, but I haven't gotten one (DLL) that'll work with Eu's open_dll. 
>  Could someone tell me the steps I'd need to take assuming MinGW32 (GCC 
> 2.95.2)?  Thanks in advance.
> 
> WARNING: C code to follow.
> 
> WITH THESE FILES:
> 
> MYDLL.C        Source File
> DLLINIT.C        DLL Initialization (DllMain) ** What should I code for 
> this?
> LIBMYDLL.A    Library to be made so I can access my DLL from C (not have 
> to use LoadLibrary())
> MYDLL.DLL    Outputted DLL file that can be called from anything 
> supporting DLLs
> 
> Instead of putzing with .DEFs, I put some kind of "export" command in 
> front of my routines.
> Ex. Want to export "TheAnswerIsThree"
> 
> _export int TheAnswerIsThree()    //pointless, I know
> {
>     return 3;
> }
> 
> I am basing the _export off what I saw in the included API files.  What 
> should I use for that?
> 
> I'd like what I could do step by step at probably a DOS command prompt.
> 
> --Mike
> 



Ray Smith
http;//www.geocities.com/ray_223

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu