Re: Complex dynamic loading
Re: Complex dynamic loading
- Subject: Re: Complex dynamic loading
- From: "Peter O'Gorman" <email@hidden>
- Date: Sat, 23 Jul 2005 23:19:33 +0900
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Solra Bizna wrote:
| I was under the impression that this wasn't possible on Darwin. From
| what I understand, you can either create a module which you can
| dynamically load (.bundle) or one which you can dynamically link
| (.dylib), but not both. Is it possible after all?
| Also, will Darwin properly deal with modules that are both dynamically
| linked against other modules and dynamically loaded?
On all versions of darwin so far, it is suggested that code which is
designed to be runtime loaded be linked with the -bundle option to cc (ld).
If, however, you are in a situation where the code must be used as input to
ld(1) and must also be runtime loaded, then it is okay on Mac OS X 10.1 and
later to use dylibs. There is no api to load dylibs on Mac OS X 10.0.x and
10.4 does the job much better than previous attempts.
There is a bug somewhere asking for reference counting of loaded dylibs
which will allow for dynamic shared libraries to be unloaded, at present
only bundles may be unloaded. This is not usually a big issue, but it
depends on your app.
Hope this helps,
Peter
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (Darwin)
iQCVAwUBQuJR9biDAg3OZTLPAQIXXAP+OHM5SKRxjCSXhXCYaLGNL8EO8QFYDu84
I6DpYxE8pwSh/4JtXj5tCzkdqv6DlzcPQByYUVvS8S6czSW7pb784DPNkgWN8PvC
m8ezbQ+v/jhTD1ZgEJAfxBgEfBBI7IE1495RH5//wShc0eln5eONM3SLJNvmqD1q
RkAt6mexMbE=
=X6+h
-----END PGP SIGNATURE-----
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden