My Carbon CFM application used to load plugins via GetSharedLibrary().
Now the application is converted to MachO, and it seems that the
libraries cannot be found any longer (error code -2804).
Where does a Carbon MachO application look for its plugins? What is
the search path?
PS:
I know that LoadDiskFragment() could be an alternative, but not in my
case, where the library name, not the library file name is given.
PS/2:
I found some glue code to call CFM (or PEF) functions from MachO, but
this seems not to be from Apple. Is there an official solution?
MW Ron - 08 Jan 2004 19:17 GMT
>My Carbon CFM application used to load plugins via GetSharedLibrary().
>Now the application is converted to MachO, and it seems that the
[quoted text clipped - 10 lines]
>I found some glue code to call CFM (or PEF) functions from MachO, but
>this seems not to be from Apple. Is there an official solution?
I was looking for this for someone else Apple has some examples
I think what you are looking for (or a good start) is here
Using CFBundle and CFPlugIn
http://developer.apple.com/documentation/ReleaseNotes/CoreFoundation/CFBu
ndleAndCFPlugIn.html
Also this is CFM to MachO to CFM it seems to cover mixing CFM with Mach-O
http://developer.apple.com/samplecode/Sample_Code/Runtime_Architecture/CF
M_MachO_CFM.htm
Ron

Signature
Metrowerks, maker of CodeWarrior - "Software Starts Here"
Ron Liechty - MWRon@metrowerks.com - <http://www.metrowerks.com>
Andreas Kromke - 09 Jan 2004 07:51 GMT
(...)
OK. If nobody else uses GetSharedLibrary(), I will write a bug report
to Apple. Maybe they have an idea or at least confirm that there is a
bug.