我想更新一个包中的Android.mk文件以构建新包,但我不理解LOCAL_MODULE_TAGS
的目的是什么。
LOCAL_MODULE_TAGS
有什么作用?
我想更新一个包中的Android.mk文件以构建新包,但我不理解LOCAL_MODULE_TAGS
的目的是什么。
LOCAL_MODULE_TAGS
有什么作用?
更正:
不再建议使用用户标签。
相反,
Add "LOCAL_MODULE_TAGS := optional"
Then add "LOCAL_MODULE" value to PRODUCT_PACKAGES section of product makefile.
原始帖子:
LOCAL_MODULE_TAGS定义了此模块应安装在哪个构建类型中。
如果您要将模块安装在所有(user、userdebug、eng)构建中,只需提供"user"标记。
您可以在此处找到完整的文档。
eng This is the default flavor. A plain make is the same as make eng.
* Installs modules tagged with: eng, debug, user, and/or development.
* Installs non-APK modules that have no tags specified.
* Installs APKs according to the product definition files, in addition to tagged APKs.
* ro.secure=0
* ro.debuggable=1
* ro.kernel.android.checkjni=1
* adb is enabled by default.
user make user
This is the flavor intended to be the final release bits.
* Installs modules tagged with user.
* Installs non-APK modules that have no tags specified.
* Installs APKs according to the product definition files; tags are ignored for APK modules.
* ro.secure=1
* ro.debuggable=0
* adb is disabled by default.
userdebug make userdebug
The same as user, except:
* Also installs modules tagged with debug.
* ro.debuggable=1
* adb is enabled by default.
LOCAL_MODULE_TAGS
,它默认设置为 optional
,并且只有在 PRODUCT_PACKAGES
中声明了模块才会安装该模块。 - Fredrick Gauss
samples
而不是optional
,对我来说导致它包括了so库。 - zeitgeist