summaryrefslogtreecommitdiff
path: root/libnativeloader/library_namespaces.cpp
AgeCommit message (Collapse)Author
2020-04-27Use ART_TARGET_ANDROID instead of __ANDROID__ Nicolas Geoffray
On golem, we build for ART_TARGET_LINUX, which doesn't have support for linkerconfig. Therefore, guard all linker namespace code on ART_TARGET_ANDROID instead of __ANDROID__ (which is unfortunately not under ART's control). Test: build for golem and run Bug: 154074847 Change-Id: I7a2b81918177704b42d8aafbd6d7e9d06d34e5f4
2020-03-04libnativeloader: Remove hard-coded cronet Jooyung Han
Because cronet apex sets its jni_libs, its classloader-namespace is linked automatically via jni.config.txt. Bug: 143733063 Bug: 146420818 Test: atest CronetApiTest Change-Id: I7ae0f7bc60f09e7e384abd1f0a1e4f8f90f64052
2020-03-04Loading JNI libraries in an APEX Jooyung Han
To load JNI libraries in an APEX, libnativeloader relies on jni.config.txt file which contains available JNI libraries for APEX namespaces: com_android_foo libfoo_jni.so:... com_android_bar libbar_jni.so:... This file is generated by linkerconfig. Bug: 143733063 Test: cuttlestone boots (For now, no behavioral changes because jni.config.txt is empty) Change-Id: I066de90a73875118be53972e50d076061922d762
2020-02-21Use a different VNDK namespace for product apps Justin Yun
As product partition may have a different VNDK version than that of vendor partition, they may not share the same VNDK namespace for their apps. Define a new vndk_product namespace in the system section for product apps that uses ro.product.vndk.version. Bug: 149063221 Test: atest libnativeloader_test Change-Id: I1bb76617104a49b0d11af13d2f116959a18390a3
2020-02-21Rename APEX Namespace Kiyoung Kim
Current APEX Namespace is named with APEX name itself, which also uses .(dot) so linker configuration can keep the syntax safe. For example, if there are APEX modules named 'A' and 'A.link.A', then 'namespace.A.link.A.link.A = a.so' phrase can be ambiguous from the linker. To allow any additional linker syntax in the future, we should avoid dot separator from the namespace name. Bug: 148826508 Test: m -j passed Test: boot succeeded from cuttlefish and walleye Change-Id: I11b6da1b59b4ebf3016f1d783636c7e5d0f8309a
2020-02-16Add libstats_jni to linkerconfig/namespace Jeffrey Huang
As part of statsd becoming a Mainline module, moving libstats_jni to the apex requires adding it to the linker namespace here. Bug: 145922701 Test: m -j Change-Id: Ifcbea47cc36604e4a86df9af711d678b23012724
2020-02-12Remove old "platform" namespace name in a few remaining places. Martin Stjernholm
Follow-up to https://r.android.com/1220299. Test: atest libnativeloader_test Bug: 147987608 Change-Id: Ib5849c9a9f5dbde1bf2a85aad2fe96cc2a394f31
2020-02-11Use apex name for apex linker namespace Jooyung Han
Linkerconfig now uses apex_names to automatically generate linker namespaces from apexes. Bug: 148826508 Test: build / boot Change-Id: Id7fa68531033124727e618284af4fd2a61bdd85f
2020-02-10Use product vndk version for product apps Justin Yun
ro.vndk.version is only for vendor modules. Product modules use different vndk version that is set in ro.product.vndk.version. Use product vndk version for creating namespaces for product apps. Bug: 148823287 Test: atest libnativeloader_test Change-Id: Iade4b3ca846f1e47e5138f2ceda81bf188276a91
2020-02-09One more missing Result::ok() call in art/libnativeloader Bernie Innocenti
No functionality change. Test: m Change-Id: I3056596785447c5fb7410bcfc7d037eb295affc4
2020-02-07Convert art/ to Result::ok() Bernie Innocenti
No functionality changes, this is a mechanical cleanup. Test: m Change-Id: I10030314ad8a06d49a63f1e2f3c5aa5b484e34b6
2020-02-07Update platform namespace name Kiyoung Kim
Platform namespace has been renamed as 'system' from linkerconfig generator. To meet this requirement, libnativeloader should search for namespace 'system' rather than namespace 'platform'. Bug: 147987608 Test: m -j passed Test: atest libnativeloader_test passed Change-Id: I23d865ac71a80619f291eb9ae0761a2cad5df352
2020-02-06Update libnativeloader dependency on libnativehelper Orion Hodson
Only requires header library dependency. Test: m Change-Id: I84de37651f4cb01bdaaa2b354f0a71058a5772f8
2020-02-06Use valid pointer for app_main_namespace_ Orion Hodson
Test: device boots Test: atest libnativeloader_test Change-Id: I5c20f7f5c65a707fbeacf644e24b95ffab370cae
2020-01-07Make product libs available to unbundled product apks. Justin Yun
Unbundling product apps must be triggerred if the target is enforcing the product interfaces. The device must have ro.product.vndk.version property if its product interface is enforced. Unbundled product apps can use product libraries. Bug: 144534640 Bug: 127738095 Bug: 128557860 Test: check boot and basic features Change-Id: I32b2a1bd3e4f62b6acdbfab6bd277ec1132478a2
2019-12-17Add public lib of Cronet apex mainline Luke Huang
This is a workaround since apex module library path is not supported in jni Bug: 139397529 Bug: 145474221 Test: Build Test: manual test with Cronet Test: atest CtsJniTestCases Test: atest libnativeloader_test Change-Id: Ifd8aa85bd78e95131b2ce3eab0ad32c2bb19cee2
2019-11-13Use a different name for shared classloader namespace, to help debugging. Martin Stjernholm
Test: atest libnativeloader_test Bug: 130388701 Change-Id: I6dbb53cac7fb7ac8fb5178611a164c83c2ab59ba
2019-10-21Use art_defaults in libnative*, for consistency. Martin Stjernholm
Also change to //art:__submodules__ for consistent internal visibility, and some TODO comment corrections. Test: m WITH_TIDY=1 Test: build & boot Test: atest art/libnativeloader/test (no new errors, but existing ones on arm64 - b/142896688) Test: (atest art/libnativebridge/tests doesn't work at all, but that's not new - b/142897320) Bug: 137364733 Bug: 133140750 Change-Id: If9ddb5a597eea3606342c3625dcdb3bcf5d19041
2019-10-11Move libnative{bridge,loader} to art/ Orion Hodson
This change moves system/core/libnative{bridge,loader} under art/. Bug: 137364733 Test: m Change-Id: I9be7333d00fcd3f36cd80520e50a30ea840187ad