There's a bug in the iOS 5 SDK where symbols aren't showing up in the debugger for exception backtraces.
To work around it, go into the breakpoint navigator in Xcode 4, then down at the bottom left, click on the + button and choose "Add Exception Breakpoint…". Set it to break "On Throw", and you should get a breakpoint where the exception is thrown.
Per TN2250:
As of Xcode 4, you are no longer required to create a custom code signing entitlements file for Ad Hoc builds; previously, you had to set 'get-task-allow' or 'Can be debugged' to false (unchecked), however Xcode 4 now does this for you. Therefore, the only two reasons to specify a custom code signing entitlements file is for iCloud, or custom Keychain Access Sharing.
If you get an empty preview when refactoring an ARC project, try this tip from the devforums (which worked for me):
- File > Project Settings…
- Make sure Derived Data Location is "Default"
- Click Advanced…
- Change Build Location to "Derived Data Location"
- Make sure "Default subfolder" is selected
There's also a note in the iOS 5.0 release notes about a similar problem:
In Xcode, if the configuration is set to Device and there is a space in the path of one of the source files (more commonly, the project is inside a directory with spaces), the “Convert to Automatic Reference Counting” step (after Precheck) will fail with error: Error in format of file: . If encountered, the user should switch to Simulator and retry the migration.
Posters on devforums claim this can be solved by temporarily moving your .git
subfolder aside before converting, then moving it back.
xcodebuild clean
used to work. Now it doesn't, because intermediate products are cached in ~/Library/Developer/Xcode/DerivedData/ProjectName-*
. These intermediate products are used for the next build, regardless of whether a clean action was performed or not. This can leave image files and other resources around, causing incorrect builds.
If you really need to clean a project (as, for example, in a build script), removing the DerivedData/ProjectName-*
directories corresponding to your project seems to work.
I've logged this as rdar://10453382.