I'm running into some problems while trying to provide legacy support to iPhone 3G and iPod Touch 2G running iOS 4.2.1.

I'm working with Snow Leopard and Xcode 4.2, SDK 5.0. Everything works fine for newer devices but it seems that older ones don't like binary built by the IDE. I mostly find strange bugs eg:

* using LLVM GCC compiler creates problem with touch controls
* using Apple LLVM 3.0 creates a strange problem with some code (which halts a runtime)

Strangely these things disappear if I build with debug scheme, even if I tried to change every setting so that debug is as release.

Is there any particular trick? Can I use base plain GCC anymore on Xcode 4.2?

Also if I'm able to do GCC, how can I specify a different compiler for a different architecture? (I added armv6 to be able to build for old devices too)