This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Naked DllMain in win32_threads.c (boehm-gc)


Hi,

    The win32_threads.c file in boehm-gc defines a naked
DllMain function that creates a multiple definition problem
while creating a DLL using "gcj -shared" on Windows. Newer
versions of MinGW provide a default DllMain function in
libmingw32.a.

IMHO, this DllMain should be protected with a #ifdef checking
GC_DLL or some such thing. I tried it out with GCJ 3.2 and
it actually seems to work. (The DLL creation bit, not the
actual DLL itself - that's another story.)

BTW, win32_threads.c seems to use a "_DLL" guard all over the
place but I couldn't find anyone who actually defines it - the
closest seems to be a definition of GC_DLL instead. What gives?

Sincerely Yours,
Ranjit.

--
Ranjit Mathew        Email: rmathew AT hotmail DOT com
Bangalore,
INDIA.               Web: http://ranjitmathew.tripod.com/




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]