Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using .dylib with a CFM Application



On Wed, 18 Jan 2006 17:59:50, "Pierre Thibault" <email@hidden> wrote:

> Is it possible to use a dylib from a Carbon CFM application? I made a
> bundle with my dylib with Xcode but while I can easily get access to the
> bundle executable, .dylib files are not working well when I try to use
> the function pointers after a CFBundleGetFunctionPointerForName call.
> Well, I think that bundle are incompatible with dylib. Is it the case? I
> have error because my app is not able to find the dylib (image not found
> errors). I have no problem with these dylib in my other apps.
> 
> I made a search on the subject on the web and I was not able to find
> how.
> 
> Note that I don't have the source code, I only have the dylib.
> 
> So, what should I do to be able to use it with my CFM App?

Works for me without doing anything special in CFM app. Given a
"foo.so" library, I created an empty folder, name it "foo.framework",
renamed the library to "foo" and put it into folder. After that
opened bundle with CFBundleCreate, loaded it with
CFBundleLoadExecutable (optional), grab a function from it with
CFBundleGetFunctionPointerForName and call it successfully. Do you
get non-null function pointers with CFBundleGetFunctionPointerForName?

Mike

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.