Re: Strip not working
Re: Strip not working
- Subject: Re: Strip not working
- From: James Bucanek <email@hidden>
- Date: Sun, 10 Dec 2006 08:47:17 -0700
Trygve Inda wrote on Sunday, December 10, 2006:
>I have to add a Build Phase script:
>
>#!/bin/bash
>strip "$TARGET_BUILD_DIR/$EXECUTABLE_PATH"
The '#!/bin/bash' line is redundant (but harmless). A "she-bang" line is automatically pre-pended to your script using the contents of the Shell field of the script phase info. If you really require bash, make sure this is set to /bin/bash.
>Because no matter what strip settings I use in XCode, they never work. Are
>they know to be broken?
strip works just fine. I've spent several days running strip on executable for an article that I'm writing.
> Separate Strip checkbox does nothing it seems.
See below.
>Also, how then can I make a Build Phase conditional on the Build
>Configuration so the strip script can be only in the Release build?
Simple: Check the box 'Run script only when installing'. This makes the phase dependent on the Deployment Postprocessing build settings. In your Release configuration, set Deployment Postprocessing to YES and leave it off in other configurations. Your script will run only in your Release configuration.
Also note that all of the other built-in strip options (Strip Linked Product, Separate Strip, Strip Debug Symbols During Copy, ...) are all dependent on setting Deployment Postprocessing. If Deployment Postprocessing is NO, all of these build settings are ignored.
James Bucanek
____________________________________________________________________
Author of Beginning Xcode ISBN: 047175479X
<http://www.beginningxcode.com/>
_______________________________________________
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