Re: Frameworks (dylib) Within The App Bundle
Re: Frameworks (dylib) Within The App Bundle
- Subject: Re: Frameworks (dylib) Within The App Bundle
- From: Nils Hjelte <email@hidden>
- Date: Wed, 3 Sep 2003 13:11:24 +0200
I had the same problem with my application. I solved it by using the
command line tool "install_name_tool". You can see the current linking
of your app with "otool -L /path/to/MyApp.app/Contents/MacOS/MyApp".
Then use install_name_tool to change the paths. Something like this:
"install_name_tool -change /usr/local/lib/libsomething.dylib
@executable_path/../Frameworks/libsomething.dylib
/path/to/MyApp.app/Contents/MacOS/MyApp"
See "man install_name_tool" for more info. You can then add a shell
script build phase to your project to automate this.
// Nils Hjelte
On onsdag, sep 3, 2003, at 07:08 Europe/Stockholm, Pei Xiang wrote:
sorry to raise maybe an already discussed problem
here.
i'm building an application with a dylib, for instance
'myLib.dylib', by adding link flag -lmyLib. it builds
and runs well with 'myLib.dylib' located in
/usr/local/lib/.
as i wish to ship it with my application bundle, i
added the dylib as framework and added a new build
phase enabling project builder to put the
'myLib.dylib'
into Frameworks folder in the bundle, also changed the
installation path to @executable_path/../Frameworks .
BUT, the application just wouldn't search the above
path for the 'myLib.dylib' but keep telling me cannot
find it in /usr/local/lib/ (if it's not there)
i also tried things like adding the link flag
-seg1addr 0x10000000 and different ways mentioned
online, but still didnt get it to search there. could
anybody give a pointer? thanks!
Pei
__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.