Using the TARGET_IPHONE_SIMUATOR macro results in the same constant values being defined in am application. For example:
#ifdef TARGET_IPHONE_SIMULATOR
NSString * const Mode = @"Simulator";
#else
NSString * const Mode = @"Device";
#endif
- (void)applicationDidFinishLaunching:(UIApplication *)application
{
...
NSLog(@"Mode: %@", Mode);
...
}
Always results in "Mode: Simulator" being logged. I'm currently running XCode 3.2.4 if that helps. Thanks.