Re: How to strip Cocoa Touch frameworks
Re: How to strip Cocoa Touch frameworks
- Subject: Re: How to strip Cocoa Touch frameworks
- From: Alex Zavatone <email@hidden>
- Date: Tue, 27 Dec 2016 07:20:51 -0600
When you build your FW, that's going to be specified in your build configuration and in your scheme. Make sure you create a scheme that uses a Release setting and make sure that Release setting has strip set.
As I mentioned previously, make sure that you use this setting.
As for what's going on underneath that, I have no idea.
Good luck.
On Dec 27, 2016, at 6:09 AM, Andreas Falkenhahn wrote:
> I have a Cocoa Touch framework which should just export a single
> symbol named "mytestsymbol". To do this, I create an exported
> symbols file that contains just this line:
>
> _mytestsymbol
>
> I then tell the linker to use this file by adding it to the
> "Exported Symbols File" entry in "Build Settings->Linking".
>
> However, when building the framework and examining the executable's
> contents using a hex editor I can see that pretty much all
> global symbols are still there but I don't want to expose those!
>
> When checking the stripping options of the Cocoa Touch framework
> I can see that by default this is just set to "Debugging symbols"
> whereas when building apps it is set to "All symbols" by default.
> So I changed the "Strip style" mode to "All symbols" for my framework
> and tried to archive it.
>
> However, that doesn't work either. Now strip returns the following
> error:
>
> "Symbols referenced by indirect symbol table entries that can't be stripped in: ..."
>
> Then a list of symbols follows. Those are all symbols my framework
> imports from other frameworks, e.g. stuff from the C runtime like
> printf(), fopen(), etc but also stuff from Apple frameworks like
> CFBundleCopyBundleURL() and so on.
>
> So I think I get this error because strip tries to strip those symbols
> but this is of course forbidden because those are needed by my framework.
>
> So how can I tell Xcode to strip *only* the global symbols defined
> by my framework (except "mytestsymbol") and not any other imports from
> other frameworks?
>
> --
> Best regards,
> Andreas Falkenhahn mailto:email@hidden
>
> _______________________________________________
> 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
_______________________________________________
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