Thanks, it looks like you were right. Fixed now.  I had been down the -ObjC &  
-all_load route a number of times this week but was not getting any luck.
I assume that -ObjC in combination with “perform single object prefix” & 
“precompile prefix header” to YES was key.

Once again, thanks for your help, I can now sleep properly at night.



> On 7 Feb 2017, at 00:34, Jens Alfke <[email protected]> wrote:
> 
> 
>> On Feb 6, 2017, at 2:46 PM, Mr steve davis <[email protected]> 
>> wrote:
>> 
>> Thanks for the reply. However, it all seems to be in place.
>> 
>> MyProject->'Ljnk Binary with Libraries’ = MyFramework
>> MyFramework->'Ljnk Binary with Libraries’ = libMyLibrary.a
> 
> Ah — I think you are running into a linker ‘feature’ where, if no symbol from 
> a .a file is being used in the target being linked, it’ll just dead-strip the 
> entire contents of the .a file. In other words, the linker sees that your 
> framework doesn’t use anything in the .a file, so it just ignores the .a file 
> when building the framework.
> 
> In the framework target, set “Other Linker Flags” to "-ObjC -all_load” (with 
> single hyphens, not double.) That should fix it.
> 
> Another way to fix this is to explicitly list the symbols that your framework 
> exports. This is actually a better solution because it can help dead-strip 
> unused code from the framework, but it takes a little more work to set up 
> (look up “.exp file”…)
> 
> —Jens

_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to