Error Message: ARC is required to compile Pushwoosh SDK

牧云@^-^@ 提交于 2019-12-11 18:13:23

问题


I am new in xcode. I got recurring message error when building for testing:

*PWRequest.m
User defined issues
"ARC is required to compile Pushwoosh SDK"*

In code it shows: #if ! __has_feature(objc_arc) #error "ARC is required to compile Pushwoosh SDK" #endif

I don't understand. I added a new pushwoosh sdk. I thank you very much for your help.


回答1:


  1. You can set ARC on a file basis. Go to the BuildPhases->CompileSources. You can select sources there and pass ARC flag. Same as here: How can I disable ARC for a single file in a project? but with -fobjc-arc flag

  2. You can use XCode project that comes with the SDK. In this case you'll be linking to the output (library) that is produced by this project.

Hope it helps!




回答2:


So if you want to use Pushwoosh in your app, you're going to need to turn on ARC in your project settings.

And then you'll be using ARC in your app.

Which is somewhat nicer than doing good old fashioned Manual Retain / Release memory management, yes?

If you are determined to use MRC (manual retain count), then follow the steps in this related question.



来源:https://stackoverflow.com/questions/22321965/error-message-arc-is-required-to-compile-pushwoosh-sdk

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!