http://stackoverflow.com/questions/6595208/what-does-this-line-mean-local-export-c-includes

LOCAL_EXPORT_CFLAGS
Define this variable to record a set of C/C++ compiler flags that will
be added to the LOCAL_CFLAGS definition of any other module that uses
this one with LOCAL_STATIC_LIBRARIES or LOCAL_SHARED_LIBRARIES.

LOCAL_EXPORT_CFLAGS定义了一组C/C++编译器flags,当其他模块以LOCAL_STATIC_LIBRARIES/LOCAL_SHARED_LIBRARIES方式引用该模块时,就会将该组值加入到LOCAL_CFLAGS,从而传递给编译器。

LOCAL_EXPORT_C_INCLUDES和LOCALC_INCLUDES:

编译某模块时,如果它依赖别的模块,那么别的模块的LOCAL_EXPORT×的值,会自动加入到本模块。(但是反过来不会有作用)

For example, consider the module 'foo' with the following definition:

   include $(CLEAR_VARS)
LOCAL_MODULE := foo
LOCAL_SRC_FILES := foo/foo.c
LOCAL_EXPORT_CFLAGS :=-DFOO=
include $(BUILD_STATIC_LIBRARY)

And another module, named 'bar' that depends on it as:

   include $(CLEAR_VARS)
LOCAL_MODULE := bar
LOCAL_SRC_FILES := bar.c
LOCAL_CFLAGS :=-DBAR=
LOCAL_STATIC_LIBRARIES := foo
include $(BUILD_SHARED_LIBRARY)

Then, the flags '-DFOO=1 -DBAR=2' will be passed to the compiler when building bar.c

// 这样,编译bar.c文件时,flags -DFOO=1 -DBAR=2将会被传递到编译器。

Exported flags are prepended to your module's LOCAL_CFLAGS so you can
easily override them. They are also transitive: if 'zoo' depends on
'bar' which depends on 'foo', then 'zoo' will also inherit all flags
exported by 'foo'.

// 被导出的flags是继承的,如果zoo依赖bar,bar依赖foo,那么zoo也会继承foo模块中导出的flags。

Finally, exported flags are not used when building the module that
exports them. In the above example, -DFOO=1 would not be passed to the
compiler when building foo/foo.c.

// 被导出的flags对于导出他们的模块是无用的,如上面的例子中,编译foo模块时-DFOO=1不会被传递到编译器。

LOCAL_EXPORT_CPPFLAGS
Same as LOCAL_EXPORT_CFLAGS, but for C++ flags only.

LOCAL_EXPORT_C_INCLUDES
Same as LOCAL_EXPORT_CFLAGS, but for C include paths.
This can be useful if 'bar.c' wants to include headers that are provided by module 'foo'.

LOCAL_EXPORT_××用法的更多相关文章

随机推荐

  1. golang运算与循环等

    一.golang运算符 1.算术运算符 + 相加- 相减* 相乘/ 相除% 求余++ 自增-- 自减 2.关系运算符 == 等于!= 不等于> 大于< 小于>= 大于等于<= ...

  2. ABP mysql

    SetSqlGenerator("MySql.Data.MySqlClient", new MySql.Data.Entity.MySqlMigrationSqlGenerator ...

  3. Python——Tk控件说明

    控件 描述 具体说明 Button 按钮  点此链接 Canvas 提供绘图形状的功能,包含图像和位图  点此链接 Checkbutton 多选框  点此链接 Entry 单行文本框  点此链接 Fr ...

  4. Visual Studio 2019 (VS2019)正式版安装 Ankh SVN和VisualSVN插件

    VS2019 正式版最近刚刚推出来,目前 Ankhsvn 还不支持,它最高只支持 VS2017,全网搜索了一下,也没有找到.在 Stackoverflow 上看了一下,找到这篇问答: 自己按照这种方法 ...

  5. purge旧的ubuntu 的linux内核

    https://www.sysgeek.cn/remove-old-kernels-ubuntu-16-04/

  6. 首次使用Oracle SQL Developer 提示: enter the full pathname for java.exe

    https://www.cnblogs.com/520future/p/7699095.html 首次使用Oracle SQL Developer 提示: enter the full pathnam ...

  7. Redux Todos Example

    此项目模板是使用Create React App构建的,它提供了一种简单的方法来启动React项目而无需构建配置. 使用Create-React-App构建的项目包括对ES6语法的支持,以及几种非官方 ...

  8. python实现加密

    1.md5加密 hashlib 库中包括如SHA1.SHA224.SHA256.SHA384.SHA512和MD5算法等 >>> import hashlib>>> ...

  9. UOJ #109「APIO2013」TASKSAUTHOR

    貌似是最入门的题答题 刚好我就是入门选手 就这样吧 UOJ #109 题意 太热了不讲了 $ Solution$ 第一个点:$ 105$个数字卡掉$ Floyd$ 直接$101$个点无出边一次询问就好 ...

  10. 残差网络ResNet笔记

    发现博客园也可以支持Markdown,就把我之前写的博客搬过来了- 欢迎转载,请注明出处:http://www.cnblogs.com/alanma/p/6877166.html 下面是正文: Dee ...