App won't build after upgrade to Xcode 4

Hello,

I’ve just upgraded to Xcode 4.0.2 and now when I do ‘Build And Run’ from Unity 3.3.0f4 I get the following errors when I try and run on an attached iphone:

/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.1.3.sdk/usr/include/stdarg.h:4:25: error: stdarg.h: No such file or directory

/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.1.3.sdk/usr/include/float.h:8:24: error: float.h: No such file or directory

I checked and both files (stdarg.h and float.h) are in the /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.1.3.sdk/usr/include/ folder. The exact lines that are causing the errors are:

#include_next <stdarg.h>
#include_next <float.h>

I’ve deleted the old builds and started fresh as well, but that didn’t make a difference. After reading around some in the forums I’m wondering if I should try and go back to Xcode 3. :expressionless: This project used to run just fine before the ‘upgrade’.

Any help would be great!

Thanks a lot,
-d

Also I forgot to add, I’ve never changed the xcode project directly. Everything in the project has been auto-created by Unity when I do the build and run. So this seems really strange to me. Is there any cache or something like that, that I should delete? I had thought deleting the builds and then building to another folder would be safe. I’m going to try an empty project from scratch next…

Thanks for any input,
-d

what you build there makes no sense anyway going by the error

you are building with a 3.x SDK which is not allowed by apple for anything. you must use at least 4.0 and to work with unity at maximum 4.2 if you want to send it to apple.
also xcode 4 to my knowledge isn’t supported at the time.

do a search on forum, but the long and short is use xcode 3.2.5

Thanks for the help guys. The reason I was trying to use the 3.x SDK was to test on an older iOS. After doing more research, I realize I can still test on 3.x iOS by building with 4.x SDK. I just tried the link for the Xcode 3.2.5 + iOS SDK 4.2 from the Unity email a month or so back and the site is down for a WWDC update. I guess I’m stuck until the site comes back online. ;( Unless there’s another link or something.

Thanks again,
-d