如何在项目之间添加弧[英] how to add ARC in between of project

本文是小编为大家收集整理的关于如何在项目之间添加弧的处理方法,想解了如何在项目之间添加弧的问题怎么解决?如何在项目之间添加弧问题的解决办法?那么可以参考本文帮助大家快速定位并解决问题。

问题描述

我正在创建iPhone应用程序,并且在我之间需要使用 SDWebImage .为此,我需要使用弧形.

如何在项目中添加arc的任何想法?

注意:在一个文件中我有以下内容.

#if !__has_feature(objc_arc)
#error SDWebImage is ARC only. Either turn on ARC for the project or use -fobjc-arc flag
#endif

我应该在哪里添加-fobjc-arc标志?

推荐答案

Select Project Form Project Manager
  |
  | 
  Targets
       |
       |
     Build Phases
          |
          |
        Compile Sources
                |
                |
            Select File that you Want to crate as ARC. (You can also Select Multiple File name from here)
                        |
                        |
                    Press "ENTER" key
                           |
                           |
                      Popup Box/Window is displayed 
                               |
                               |
                            Write here - '-fno-objc-arc'
                                    |
                                    |
                                And again Press 'ENTER' key.

Your selected file is being ARC.

其他推荐答案

Change from build settings

Project->Build setting->Objective-C Automatic Reference Counting  SET YES

If you need to remove ARC then Go to  Project->Build Phases->compile sources then find your file Which you need to remove ARC then set compile source '-fno-objc-arc' 

其他推荐答案

如果使用Xcode 4.6,请选择目标Target - > Build Settings并找到 Apple LLVM编译器4.2 如果目标-c自动参考,请参阅本节计数设置为是,如果没有,那么只需将其设置为yes.对于旧版Xcode,您可以更改Apple LLVM compiler 3.0

本文地址:https://www.itbaoku.cn/post/924566.html