Date: Wed, 5 Apr 1995 13:11:03 -0400 From: hines-michael AT CTAN DOT YALE DOT EDU (Michael Hines) To: djgpp AT sun DOT soe DOT clarkson DOT edu Subject: gcc dll, win32s, borland It's a miracle but I was able to use the dll-940219.zip with djgpp-old.3 maillist fixes to make a gcc compiled dll and load it into a borland4.5 compiled .exe that runs under win32s. The only problem I had to work around is that gcc aligns 32bit items in a struct on a 32 bit boundary so if you use shorts they need to come in pairs so the struct records will have the same addresses in gcc and borland. Also I was able to use fprintf(stderr... in the dll by making gcc's _iob[] consistent (in size) with borland's _streams[]. (my windows program has a stdio terminal window with its own implementation of fprintf). Lastly the fixes for mkdlllib.cc leave an extra underscore in the MKDLL macro but fixing that is trivial. Many thanks to dj for doing the dll.cc, Dong Liu for the dll..zip fixes, and Steve Chamberlain for the hint that it wouldn't be too hard. It's a LOT easier to work by analogy than to figure it out from scratch. --Michael