How to resolve missing variant arch:common for a dependency using Android.bp?
Asked Answered
F

0

6

Originally, the dependency was included inside the Android.mk file for Android 9. This module would compile and run with no build errors.

When migrating to Android 11, the dependency "libvlc" must be added to the Android.bp static_libs.

 android_app {

   compile_multilib: "both",

   static_libs: [
    " libvlc",
    ...
   ],
 }

cc_prebuilt_library_shared {
    name: "libvlc",
    srcs: ["libs/libvlc.so"],
    vendor: true,
}

This throws the error:

  dependency "libvlc" of "MyModule" missing variant:

  os:android, arch:common

available variants:
  os:android, image:vendor.30, arch:arm64_armv8-a_cortex-a53, sdk:, link:shared, version:

  os:android, image:vendor.30, arch:arm64_armv8-a_cortex-a53, sdk:, link:static, version:

  os:android, image:vendor.30, arch:arm_armv7-a-neon_cortex-a9, sdk:, link:shared, version:

  os:android, image:vendor.30, arch:arm_armv7-a-neon_cortex-a9, sdk:, link:static, version:

14:54:21 soong bootstrap failed with: exit status 1

#### failed to build some targets (10 seconds) ####

From this list its apparent that I need access to an arch variant known as common, and the ones that are currently available are not listed as arch:common.

Perhaps instead of resolving my issue can someone who is knowledgeable answer a few questions of mine that I could not find answers for anywhere on the internet. Knowing the answer to these questions I could probably solve the problem myself.

  1. What is the architecture of the arch:common?
  2. Is VLC supported for A11 AOSP? - I couldn't find a clear answer for this. The hardware that I want to support is for arm64.
Falconiform answered 8/10, 2021 at 14:45 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.