So I built an application which compiles and runs fine from Xcode. Now I want to distribute it to other people so they can use it. How do I do that correctly?
I thought it was as simple as archiving it, and then sharing it as a .pkg or an application. But whenever I open up the application it crashes with the following message:
Application Specific Information:
dyld: launch, loading dependent libraries
Dyld Error Message:
Symbol not found: _OBJC_CLASS_$_CPTBorderedLayer
Referenced from: /Users/USER/Desktop/StoreMon.app/Contents/MacOS/
StoreMon
Expected in: /Library/Frameworks/CorePlot.framework/Versions/A/
CorePlot
in /Users/USER/Desktop/StoreMon.app/Contents/MacOS/StoreMon
I am using the Core Plot framework.
The _CPTBorderedLayer
class is part of that framework. How do I package this framework into my app correctly?
You can provide an installer for the framework(s) you are using, or you can embed them in your Application's bundle.
Read the "Framework Programming Guide". Page 41 is what you are looking for:
http://developer.apple.com/library/mac/documentation/MacOSX/Conceptual/BPFrameworks/BPFrameworks.pdf
The trick is to copy the framework files in a special directory, inside your application. Then, you'll use @executable_path
to refer to your application's binary path, so the application's will be correctly linked to your framework at launch time.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With