My development machine died and I’ve had to rebuild it from scratch. I reinstalled the latest XCode which came with iOS SDK 4.3. I reopened my project and have had to readd all my frameworks to get the code to mostly compile. I’m down to two errors, both basically this:
error: expected specifier-qualifier-list before ‘UIBackgroundTaskIdentifier’
This is on the file: ASIHTTPRequest.h on these lines:
#if TARGET_OS_IPHONE && __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_4_0
BOOL shouldContinueWhenAppEntersBackground;
UIBackgroundTaskIdentifier backgroundTask;
#endif
which is part of the ASI HTTP library.
I’m targeting iOS 3.2.2 and building on the latest iOS 4.3. This did not happen in my old environment which was XCode 4 using iOS 4.2. I have tried using a bunch of different build settings but none have fixed the issue. Commenting out the lines causes a number of other issues, and that is not a good solution anyways. Any ideas?
Thanks in advance!
OK, my “fix” for this problem was to create a new project in the new XCode version and copy my classes and resources over. It took about a half an hour to do so as I had about 100 files to move, but it worked on the first attempt.
I can only guess that there was some subtle difference between XCode versions I wasn’t aware of. XCode certainly didn’t provide any kind of meaningful error message to guide me to it in any event.