I have a static library xcode project (.a) and a bundle xcode project (.bundle) I added the (.a) as a sub project of (.bundle) and added to [Target Dependencies] and [Link Binary With Libraries].
After run the bulid the (.bundle) still not contain any binary file inside (.bundle).
It's work if I add the .c and .h files to under (.bundle) directly, but that make me need to handle two project files. Any way can make (.bundle) just build with the (.a) ?
This question same as what I asked, I tried to follow his 11 steps without the step 10 because he said lastly no need that step. But the generated (.bundle) still without contain any binary
Finally, I make it work.
The step 10 still important and below is corrected step 10.
Link Binary With Libraries
instead use-Wl,-force_load,$(CONFIGURATION_BUILD_DIR)/libYourLib.a
or-all_load
toOther Linker Flags
PS: And also can use sub-project instead of workspace. and use
Target Dependencies
instead ofEdit Scheme
to achieve the same effect.The testing project