# New Ticket Created by  Jeff Clites 
# Please include the string:  [perl #24662]
# in the subject line of all future correspondence about this issue. 
# <URL: http://rt.perl.org:80/rt3/Ticket/Display.html?id=24662 >


This patch allows dynamic loading to work on Mac OS X (without using 
the dl* compatibility API included with Mac OS 10.3).

A couple of notes:

1) Mac OS X distinguishes between two types of "shared libraries": 
dylibs, which are meant to be linked at compile-time (and automatically 
loaded by the dynamic linker at runtime), and bundles, which are meant 
to be loaded "by hand", via explicit API. This implementation of the 
Parrot_dl* API attempts to hide the distinction and "do the right 
thing" for either case, but the two types of libraries do act 
differently--they are manipulated via different API, and among other 
differences dylibs cannot be unloaded (bundles can be), and bundles 
aren't searched for in any standard locations (dylibs can be).

2) The ncurses-life demo works partially with this patch 
applied--ncurses is clearly invoked (there is a generation count in 
green, counting up on a black background), but there doesn't seem to be 
any "life" animation. But I suspect that this is not a library loading 
issue.

3) There's some logging still in place which should be cleaned up 
long-term (maybe once Parrot_dlerror is implemented), but which is 
useful for the moment. (For instance, the ncurses-life demo will log 
when it fails to find its libraries without an extension.)

JEff

Attachment: macosx-dynamic-loading.patch
Description: Binary data

Reply via email to