google-ai-edge / mediapipe

Cross-platform, customizable ML solutions for live and streaming media.
https://ai.google.dev/edge/mediapipe
Apache License 2.0
27.47k stars 5.15k forks source link

AAR problem with support for specific android architecture #501

Closed momo1986 closed 4 years ago

momo1986 commented 4 years ago

AAR external/maven/v1/https/jcenter.bintray.com/com/serenegiant/uvccamera/libuvccamera/1.2.0/libuvccamera-1.2.0.aar missing native libs for requested architecture: arm64-v8a

This blocks the support for android compilation.

How can I resolve it?

Regards!

momo1986 commented 4 years ago

Actually, two maven artifact exists: com/serenegiant/uvccamera/libuvccamera/1.2.0 com/serenegiant/uvccamera/libuvccameras/0.0.2.

Will it have conflict?

The issue always happens, since BUILD script is a little different from build.graddle. Some compilation is not very convenient.

momo1986 commented 4 years ago

If this error started occurring in Bazel 0.27 and later, it may be because the Python toolchain now enforces that targets analyzed as PY2 and PY3 run under a Python 2 and Python 3 interpreter, respectively. See https://github.com/bazelbuild/bazel/issues/7899 for more information.

jiuqiant commented 4 years ago

Hi, I downloaded libuvccamera-1.2.0.aar and took a close look at its jni directory: Screen Shot 2020-03-09 at 10 41 43 AM As you can see, libuvccamera-1.2.0.aar only has armeabi directory. However, MediaPipe generally needs the armeabi-v7a and arm64-v8a directory when we build the Android mobile apps with config=android_arm or config=android_arm64. For example, if you take a look at MediaPipe's AARs, you can find armeabi-v7a and arm64-v8a subdirectories in its jni dir: Screen Shot 2020-03-09 at 10 42 10 AM Here is a good explanation of ABI. Hope this helps.