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]

Shared LIbraries Registering classes


I am working on getting SharedLibLoader to work and have some questions about it.

What causes shared libraries to register classes? Does an _init function need to be written?
How about non-shared libraries?


Does the SharedLibLoader code actually work?
a handle is returned from dlopen and saved.
findClasses calls super(findClass) -> ClassLoader find class.
As far as I can tell if the library was opened without the global flag(RTLD_GLOBAL) you need to explicitly search the library using dlsym.


I have already one patch that fixes the init code to null terminate the library name. This was preventing the library from being found in some cases.

Thanks
Steve

--
Steve Pribyl
Steve AT NetFuel dot com
Computer Infrastructure Practitioner


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