How can I see the output from the compiler of from the custom build steps (pre-action or post-action)?
Use the Xcode report navigator. To show the report navigator, either (1) click the rightmost button in the navigator bar at the top of the navigator area, which is on the left side of the workspace window, (2) select View > Navigators > Reports from the menu bar at the top of the screen, or (3) press ⌘ 9 .
You'll find (and you can watch during the build) the complete build output in the Log Navigator. That's the right most icon of the small icons just below the Run and Build buttons.
Pre-action output at least appears in system.log and is visible in Console.app.
EDIT: as pointed out in the comment below this answer only works for Build phase scripts, not pre action and post action scripts.
In Xcode 8 you need need to select your latest build in "Navigator -> Report Navigator". In the main area you will be able to see the complete build log including your output.
Here is a simple "Hello world" echo
Per my answer here ( Is it normal for Xcode not to detect if a pre-action failed? ) this is an issue that's been discussed in the dev forums. Pre-/post-action script non-zero status doesn't seem to have an affect, nor does the output seem to make it into any logs.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With