On Jan 23, 2012, at 14:10 , Jerry Krinock wrote: I searched and searched but could find no Apple documentation on this issue.
Now I realize how this happened. When I made my first archive, I just did it and it worked. In "Archive Your Application", it says:
"if [your application] relies on static libraries, ensure that those libraries are part of the application binary by setting the Skip Install build setting to Yes in the Release build configuration of the target that builds and archives the application."
There's no sense to made of this -- it just looks ludicrously wrong. It's so wrong that I'd guess it's more of a copyediting error than a confused statement.
No special action is needed to "ensure" that static libraries are part of the application binary. They're copied in during linking, that's why they're static. If they weren't copied in at link time, they'd be dynamic libraries.
The quoted statement is possibly a mishmash of two ideas. One is what the tech note says: Set "Skip Install" to YES when building static library targets. In this case, I suspect, an "install" refers to some Unix-ey thing about copying the static library to one of those directories like /usr/bin, which is irrelevant to building in Xcode.
The second idea may be something about getting private frameworks copied into application bundles, since Xcode is capable of running apps without doing the copy. However, AFAIK the correct way is to use a Copy Frameworks build phase in the application target. There's some voodoo (**) here, because Xcode's behavior depends on whether the frameworks are built as targets in the application project, referenced as sub-projects, or referenced as included frameworks, plus there's an "only on install" option of the build phase.
(**) This is genuine fake voodoo, not real voodoo, but it might as well be real because (AFAIK) there's no documentation about how to set up private frameworks in Xcode that's been updated for Xcode 4, where everything changed. For bonus points, try to figure out whether "Skip Install" is supposed to be YES or NO in a private framework target.
|