libnativehelper missing product variant in Android build

1,103 views
Skip to first unread message

Arach MOHAMMED BRAHIM

unread,
Apr 21, 2021, 5:12:10 PM4/21/21
to Android Building

I'm trying to compile a JNI in the Android product partition. For that purpose I added the property product_specific: true in the Android.bp such as:

cc_library_shared { name : "..." ... shared_libs: [ "libandroidicu", "libnativehelper", "libcutils", "libutils", "liblog", ], proprietary : false; product_specific: true

Unfortunately, at compilation I have the following error :

Android.bp:1:1: dependency "libnativehelper" of "libTest_jni" missing variant:
  os:android, image:product.30, arch:arm64_armv8-a, sdk:, link:shared, version:1

available variants:
  os:android, image:, arch:arm64_armv8-a, sdk:, link:shared, version:
  os:android, image:, arch:arm64_armv8-a, sdk:, link:shared, version:1
  os:android, image:, arch:arm64_armv8-a, sdk:, link:static, version:
  os:android, image:, arch:arm64_armv8-a, sdk:, link:static, version:1
  os:android, image:, arch:arm_armv8-a, sdk:, link:shared, version:
  os:android, image:, arch:arm_armv8-a, sdk:, link:shared, version:1
  os:android, image:, arch:arm_armv8-a, sdk:, link:static, version:
  os:android, image:, arch:arm_armv8-a, sdk:, link:static, version:1

How can I add a product variant to libnativehelper?

Orion Hodson

unread,
Apr 21, 2021, 5:23:39 PM4/21/21
to android-...@googlegroups.com
Try libnativehelper_compat_libc++ instead.

--
--
You received this message because you are subscribed to the "Android Building" mailing list.
To post to this group, send email to android-...@googlegroups.com
To unsubscribe from this group, send email to
android-buildi...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

---
You received this message because you are subscribed to the Google Groups "Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-buildi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-building/abc6c16d-ba46-474e-b51c-d1da3342551dn%40googlegroups.com.

Arach MB

unread,
Apr 22, 2021, 11:09:48 AM4/22/21
to Android Building
I tried also with libnativehelper_compat_libc++ with the same issue.

dependency "libnativehelper_compat_libc++" of "libstnfc_nci_jni" missing variant:
  os:android, image:product.30, arch:arm64_armv8-a, sdk:, link:shared, version:
available variants:
  os:android, image:, arch:arm64_armv8-a, sdk:, link:shared, version:


Reply all
Reply to author
Forward
0 new messages