bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #32383] NSClassFromString returns nil on MinGw if the string class


From: Brock Erwin
Subject: [bug #32383] NSClassFromString returns nil on MinGw if the string class is in a shared library and hasn't yet been used
Date: Tue, 08 Feb 2011 17:34:52 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US) AppleWebKit/534.13 (KHTML, like Gecko) Chrome/9.0.597.84 Safari/534.13

Follow-up Comment #4, bug #32383 (project gnustep):

Richard:

I have attached a new tarball with a GNUmakefile which I believe should
compile on your system.

Matt & Nicola:

I agree that this definitely sounds like a problem with the compiler/linker
and not a bug in NSClassFromString.  As you point out and as I noticed as well
on my GNU/Linux/Ubuntu system, it seems as though the compiler/linker loads
all classes from shared libraries by default, but on windows this does not
seem to be the case (for DLLs).

Nicola wrote:
"Anyhow, Brock, 
making sure all symbols in DLLs are loaded is a typical 
Windows problem. Have you tried referencing symbols in the DLL 
in your program to make sure it is loaded up ? Eg, some people 
add a global function pointer variable to their program, and 
initialize it by pointing it to a function in the DLL they are 
loading, to make sure the DLL is loaded when the program starts 
up."

If you look at the file 'test.m' which I attached on line 14:

 13     // UNCOMMENT the following line, and you will see the bug
dissappear...
 14     //foo = [MYClass class];

-- is this what you are referring to in order to get the class loaded?

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?32383>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]