Re: Linking to library in Xcode 5.1.1
Re: Linking to library in Xcode 5.1.1
- Subject: Re: Linking to library in Xcode 5.1.1
- From: Jens Alfke <email@hidden>
- Date: Sat, 21 Jun 2014 10:34:26 -0700
On Jun 20, 2014, at 8:37 PM, Livio Isaia < email@hidden> wrote: I tried to add a Copy Files build phase but still get same error. Tried creating any folder(Frameworks, Plugins, etc.) but nothing changes…
The app probably isn’t looking for the library at the correct path. When you build the library, set the “Dynamic Library Install Name” setting (under Linking) to $(EXECUTABLE_PATH) … then you’ll be able to copy the library into the “MacOS” folder of the bundle (next to the app binary) and the app will find it.
If you didn’t build the library, then it gets a bit more complicated. You’ll need a custom build phase that runs a command that edits the path where the app binary looks for the library … unfortunately I don’t remember the name of this command.
It would be nice if Xcode did this for you, but this has been an obvious missing feature for so long that I’ve given up hope. For some reason Apple seems to believe that developers never create (or use) 3rd party frameworks, so there’s no need to make it work smoothly.
—Jens |
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden