build-settings

treat specific warning as error Xcode

女生的网名这么多〃 提交于 2019-11-30 15:50:34
In the Build Settings is it possible to treat Specific warnings as Error instead of Treating all warnings are Errors. This is a simple Switch statement checker in xcode : GCC_WARN_CHECK_SWITCH_STATEMENTS = YES_Error instead of : GCC_WARN_CHECK_SWITCH_STATEMENTS = YES But its not working for me. Treat specific warnings as errors use -Werror= for example: -Werror=unused-variable will treat unused variable as error, which originally treat as warning by -Wunused-variable flag add these to Other Warning Flags in project setting. Treat all warnings as errors except for some warnings use -Werror and

How to differentiate multiple targets with Xcode 4.2

三世轮回 提交于 2019-11-30 09:04:35
I've developed a lite version of an app. Now I want to create a paid version. So I've duplicated the target, changed its name (so change plist and other stuff with that name) and now I have to differentiate in code. I'm using Xcode 4.2 and I see on the web that I have to create a preprocessor flag. My problem is that this flag in Xcode 4.2 is only in the project's build setting and not in the target's build setting. I will need to be able to do something like this: #ifdef paid ... #else ... #endif Use preprocessor macros to do this. Go to Target -> Build Setting and choose "All configurations"

iPhone apps with a deployment target lower than 4.3 should include an armv6 architecture

馋奶兔 提交于 2019-11-30 05:52:26
I have a problem :-( When I build my application for release XCode shows a warning saying: iPhone apps with a deployment target lower than 4.3 should include an armv6 architecture (current IPHONEOS_DEPLOYMENT_TARGET = "3.0", ARCHS = "armv7"). But how can I set armv6 in my build settings? I'm using XCode 4.2 and here's my build settings: Thanks! I haven't used the version, but the current Xcode won't support signing for iOS 2.0 , so when iOS 5 comes out, 3.0 might have the same issue of not being supported This is from http://www.weston-fl.com/blog/?p=3050 (This site has helped me resolve so

Can no longer import app module into unit tests after changing deployment target

瘦欲@ 提交于 2019-11-30 03:40:55
问题 For unit testing public classes of my main app target in my swift unit tests, I have to import my main app module in my tests like so: #import MyAppModuleName This worked just fine until I changed my deployment target from 7.0 to 8.4. Now building and running my app still works perfectly, but running unit tests stopped working. The compiler complains about the above import statement: Swift Compiler Error: Module file's minimum deployment target is iOS8.4 v8.4 I have no clue why. Did I forget

treat specific warning as error Xcode

浪尽此生 提交于 2019-11-29 22:58:36
问题 In the Build Settings is it possible to treat Specific warnings as Error instead of Treating all warnings are Errors. This is a simple Switch statement checker in xcode : GCC_WARN_CHECK_SWITCH_STATEMENTS = YES_Error instead of : GCC_WARN_CHECK_SWITCH_STATEMENTS = YES But its not working for me. 回答1: Treat specific warnings as errors use -Werror= for example: -Werror=unused-variable will treat unused variable as error, which originally treat as warning by -Wunused-variable flag add these to

How to differentiate multiple targets with Xcode 4.2

拥有回忆 提交于 2019-11-29 14:07:59
问题 I've developed a lite version of an app. Now I want to create a paid version. So I've duplicated the target, changed its name (so change plist and other stuff with that name) and now I have to differentiate in code. I'm using Xcode 4.2 and I see on the web that I have to create a preprocessor flag. My problem is that this flag in Xcode 4.2 is only in the project's build setting and not in the target's build setting. I will need to be able to do something like this: #ifdef paid ... #else ...

Is there a way to have a different Default.png (splash image) for different languages/locales in iOS? [duplicate]

北城余情 提交于 2019-11-28 04:49:48
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: Localization of Default.png is not working My splash screen has English text in it, so I would like to be able to have a different splash image when users have a different language set. Is this possible? 回答1: Yes, it's possible. Pretty much the same way you localize all your resources. You just need to provide a Default.png image and then enable all the languages you're interested in. The result is that you'll

How to read current app version in Xcode 11 with script

可紊 提交于 2019-11-27 17:43:02
问题 Until Xcode 11 , I used a script that reads the current app version (for the AppStore) and help me change the LaunchScreen since we can't use swift for that. sourceFilePath="$PROJECT_DIR/$PROJECT_NAME/App/Base.lproj/LaunchScreen.storyboard" versionNumber=$(/usr/libexec/PlistBuddy -c "Print CFBundleShortVersionString" "$INFOPLIST_FILE") buildNumber=$(/usr/libexec/PlistBuddy -c "Print CFBundleVersion" "$INFOPLIST_FILE") sed -i .bak -e "/userLabel=\"APP_VERSION_LABEL\"/s/text=\"[^\"]*\"/text=\"v

How do I configure full URLs in xcconfig files

爱⌒轻易说出口 提交于 2019-11-26 13:48:43
问题 I have an xcconfig file which contains a configuration for which server my app should hit. In debug mode, this will be a different server than for release builds. The problem I have is that a URL of the form http://www.stackoverflow.com is treated as a comment after the double slash. So the string I get in code is 'http:' I have read that I can put a -traditional build flag on Info.plist, I was wondering if someone else has had a similar issue and has solved it? Thanks. 回答1: Here's a simple