I created a java library that containing 3 classes,I added these class names in "/frameworks/base/config/preloaded-classes" for preloading. But in startup logcat showing following error.
W/Zygote: Class not found for preloading: com.example.my.lib.preloadlibshared.CalcUtil
W/Zygote: Class not found for preloading: com.example.my.lib.preloadlibshared.CompareUtil
W/Zygote: Class not found for preloading: com.example.my.lib.preloadlibshared.DrawUtil
My intention is to preload classes in my jar file.
Any clues on how to do it?
Android.mk
for jar library to build your library to a module.PRODUCT_BOOT_JARS
, and the value will be wrote into init.rc
.PRODUCT_PACKAGES
.build/core/tasks/check_boot_jars/package_whitelist.txt
to avoid the system check to your class.