how to fix library missing variant issue

Issue

This Content is from Stack Overflow. Question asked by kim hyeunggi

I want to add shared library to Aosp broadcastradio@1.1.

but when adding library, following errors occur:

cd "$(dirname "out/soong/.bootstrap/bin/soong_build")" && BUILDER="$PWD/$(basename "out/soong/.bootstrap/bin/soong_build")" && cd / && env -i "$BUILDER   "     --top "$TOP"     --out "out/soong"     -n "out"     -d "out/soong/build.ninja.d"     -t -l out/.module_paths/Android.bp.list -globFile out/soong/   .bootstrap/build-globs.ninja -o out/soong/build.ninja --available_env out/soong/soong.environment.available --used_env out/soong/soong.environment.used    Android.bp
error: hardware/interfaces/broadcastradio/1.1/default/Android.bp:26:1: dependency "libtchdradio" of "android.hardware.broadcastradio@1.1-service-lib" m   issing variant:
  os:android,image:vendor.31,arch:arm_armv8-a_cortex-a53,sdk:,link:shared
available variants:
  os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72 (alias to os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,link:shared,version:   )
  os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk: (alias to os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,link:shared,ver   sion:)
  os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,link:static
  os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,link:shared (alias to os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,lin   k:shared,version:)
  os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,link:shared,version:
  os:android,image:vendor.31,arch:arm64_armv8-a_cortex-a72,sdk:,link:shared,version:latest (alias to os:android,image:vendor.31,arch:arm64_armv8-a_cort   ex-a72,sdk:,link:shared,version:)
16:53:54 soong bootstrap failed with: exit status 1

the “libtchdradio” is the shared_library what i want to import.



Solution

This question is not yet answered, be the first one who answer using the comment. Later the confirmed answer will be published as the solution.

This Question and Answer are collected from stackoverflow and tested by JTuto community, is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.

people found this article helpful. What about you?