[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: dlopen [was: Lua 5.1 (beta) now available]
- From: Mike Pall <mikelu-0511@...>
- Date: Thu, 17 Nov 2005 22:34:42 +0100
Hi,
Jens Alfke wrote:
> > In Mac OS X 10.4, dlopen was rewritten to be a native part of
> >dyld.
>
> So in 10.4 it should definitely not require additional libraries. Not
> sure about 10.3, although I can't think of what library it would be
> in if it weren't in libSystem.
Yes, but the dlopen() emulation uses dylibs. This is fine for
regular C libraries, but not a good match for Lua modules. The
native Mach-O API allows using bundles (which can be unloaded).
So Lua 5.1 on Mac OS X should be built with -DLUA_DL_DYLD
(no extra linker switches or libraries needed).
[This is no different for Windows: there are many dlopen()
emulations built on top of LoadLibrary. Still it's better
to use the native API.]
Bye,
Mike