Loading shared obj implicitly
What''s the unix/linux equivalent of the win32 LoadLibrary/
GetProcAddress api calls (if they exists)?
quote: Original post by Abominus
What''s the unix/linux equivalent of the win32 LoadLibrary/
GetProcAddress api calls (if they exists)?
Never mind that. I''ve found it. But...
Is there an initialisation function or address in the so (sort of like DllMain in Windows) that is called when the dll is loaded?
April 17, 2002 06:08 PM
quote: Original post by AbominusOriginal post by Abominus
What''s the unix/linux equivalent of the win32 LoadLibrary/
GetProcAddress api calls (if they exists)?
Never mind that. I''ve found it. But…
Is there an initialisation function or address in the so (sort of like DllMain in Windows) that is called when the dll is loaded?
void _init() is called when you dlopen() a module (or when it is loaded dynamically by the loader), void _fini() is called when you dlclose() it. A default implementation is supplied so that you don''t have to write them. You can, however, override them if you want.
Hope this helps.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement