Android VNDK笔记

Android VNDK

Build system help to check depedencies between modules, build a vendor-specific variant for vendor modules and automatically installs these modules into designed directories.

When the dependencies are invisible to the build system (e.g. shared libraries that may be opened with dlopen() in runtime), you should specify the module names in PRODUCT_PACKAGES to install those modules explicitly.

The Vendor Native Development Kit (VNDK) is a set of libraries used by other libraries or binaries, in the vendor or product partition, on runtime for dlopen.
These libraries are used by the vendor image, on the system image.
在这里插入图片描述

TypeUsed by System imageUsed by Vendor imageInstallExampleComments
CoreYesNoSystem image
cc_library {
name: “libThatIsCore”,

}
Vendor-onlyNoYesVendor image
cc_library { 
name: “libThatIsVendorOnly”
proprietary: true,
# or: vendor: true, # (for things in AOSP)

}
vendor_availableNoYesVendor image
cc_library { 
name: “libThatIsVendorAvailable”,
vendor_available: true,

}
VNDKN/AYesSystem image
cc_library { 
name: “libThatIsVendorAvailable”,
vendor_available: true,
vndk: {
enabled: true,
}

}
When a lib is marked as vendor_available:true, it’s built twice:
Once for platform (and thus installed to /system/lib)
Once for vendor (and thus installed to /vendor/lib or VNDK APEX)
vndk-spYesYesSystem image
cc_library { 
name: “libThatIsVndkSp”,
vendor_available: true,
vndk: {
enabled: true,
support_system_process: true,
}

}
llndkYesYesSystem image
/system/lib[64]
cc_library {
name: “libThatIsLlndk”,
llndk: {
symbol_file: “libthatisllndk.map.txt”
}

}

参考资料:

  • https://source.android.com/docs/core/architecture/vndk/enabling
  • https://source.android.com/docs/core/architecture/vndk
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值