I have a generated libtensorflowlite.so library from tensorflow with bazel, I've been using it with CMake for cross compile executable files and was able to run them all smoothly in android, but when I want to use that library (libtensorflowlite.so) in my AOSP build system as a prebuilt I get this error:
ERROR: out/target/product/*/obj_arm/SHARED_LIBRARIES/libtensorflowlite_prebuilted_intermediates/PACKED/libtensorflowlite_prebuilted.so: Permission denied
My module in Android.bp looks like:
cc_prebuilt_library_shared {
name: "libtensorflowlite_prebuilted",
host_supported: true,
vendor_available: true,
target: {
android_arm: {
srcs: ["prebuilt_libs/armeabi-v7a/libtensorflowlite.so"],
},
android_arm64: {
srcs: ["prebuilt_libs/arm64-v8a/libtensorflowlite.so"],
},
},
strip: {
none:true,
},
}
I was able to compile against the other pre-built libraries in the past with completely the same form of Android.bp and never face this error!