[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: DLLs under Linux
Steve Baker wrote:
> > A very, very important question:
> > Does Visual C++ 6.0 suppoert dlopen()?
> > How to create the .dso files with VC++?
> No - but Windoze has equivelent functionality via
> it's DLL feature. There is a windoze API call to do
> stuff just like the dlopen/dlsym calls and VC++ can
> make DLL's just like you'd make DSO's under Linux/UNIX.
DLL and DSO are almost the same. The few differences are more
ELF-specific than DSO-specific (if you made a DSO on a different type of
system, like a.out or COFF, it might behave the same as on Windows).
> Someone needs to write a 10 line portability layer to
> hide all that stuff from the application writers.
The calls in Windows are LoadLibrary, GetProcAddress, and the one to
close the library, I do not remember. They behave very similarly to
dlopen/dlsym/dlclose, very easy to wrap and hide.
> BTW: Does anyone know if MacOS has similar features?
> I might be prepared to support such a portability
> layer if I could find someone to do the MacOS code.
I guess it does, since Netscape and Mozilla supports plugins there.
Talking of which, look at NSPR for a portable abstraction of this.
Ludus Design, http://ludusdesign.com/
"First they ignore you. Then they laugh at you.
Then they fight you. Then you win." -- Gandhi