Wellbin Huang Wellbin Huang - 7 months ago 67
iOS Question

xcodebuild doesn't show all compile errors?

There are 2 compile errors in my project(Display in XCode).

But when I use xcodebuild to compile the project in terminal, only one compile error display

xxx$xcodebuild -sdk iphoneos -configuration Debug
[self updateAccountInfo];1
1 warning and 1 error generated.

Is it possible to make xcodebuild display all compile errors?

In the Xcode's Preference, in the General Tab, check the "Continue building after errors" option. asked here

What I need is to use xcodebuild do the same thing.


After thinking and researching these days, I think xcodebuild can't do this. It's different from xcode. When we use xcode to compile iOS project, xcode compile every .m by clang. So xcode has "Continue building after errors" feature


You need to set the Xcode preferences to do this (from Terminal.app):

$ defaults write com.apple.Xcode PBXBuildsContinueAfterErrors YES

for xCode 8:

$ defaults write com.apple.dt.Xcode IDEBuildingContinueBuildingAfterErrors 1