如何将facebook开源代码直接添加到项目中 [英] How to add facebook open source code pop to project directly

查看:262
本文介绍了如何将facebook开源代码直接添加到项目中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经从流行rel = noreferrer> github上。但是所有头文件都是这样导入的: #import< POP / POPAnimatableProperty.h> 。我应该怎么做项目设置来支持我的项目中的这样的导入文件。我知道我可以用 #import XXX.h #import< POP / XXX.h> c>但是我会使用开源的流行示例项目。

解决方案

通过学习cocoapod项目,我有如何配置项目。将pop文件路径配置为系统路径,然后我可以将 c> cimport <


  1. 添加新的配置设置文件,编辑带有以下内容的文件:



    HEADER_SEARCH_PATHS =$ {SRCROOT} / Library$ {SRCROOT} / Library / pop
    OTHER_CFLAGS = $(inherited)-isystem $ {SRCROOT} / Library-isystem $ {SRCROOT将/ $ / code code code code code code code code code $ c




I have downloaded the facebook open source code pop from github. But all header files are imported like this: #import <POP/POPAnimatableProperty.h>. What should I to do with project setting to support import file like this in my project. I know that I can run it by replace all #import <POP/XXX.h> with #import XXX.h but I'd to use the open source like the pop sample project.

解决方案

Through learning cocoapod project, I have got how to config project. Config pop file path to system path, then I can include pod with #import <POP/POP.h>.

  1. Add a new configuration setting file, edit file with following content:

    HEADER_SEARCH_PATHS = "${SRCROOT}/Library" "${SRCROOT}/Library/pop" OTHER_CFLAGS = $(inherited) "-isystem${SRCROOT}/Library" "-isystem${SRCROOT}/Library/pop"

  2. Put pop folder to ${SRCROOT}/Library dictionary.

  3. In project setting, info tab, set configurations with the new configuration file.

这篇关于如何将facebook开源代码直接添加到项目中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆