Mark some libs as double_loadable

Following libs are explicitly marked as double_loadable since they are
one of the (indirect) dependencies of LLNDK libraries and at the same
time they themselves are marked as VNDK. Such lib can be double loaded
inside a vendor process.

* libgui and libbinder: due to indirect dependency from libmediandk via
libmediaomx. libmediandk is LLNDK)

* libui: due to dependency from libnativewindow, which is LLNDK.

Note: even without this change, the library is already capable of being
double loaded due to the dependency chain towards it. This change is to
make it explicit so that double loading of a library is carefully
tracked and signed-off by the owner of the lib.

Bug: 77155589
Test: m -j
Merged-In: Id4768162aeb72b71d63d7e4498980f276ef58e6b
Change-Id: Id4768162aeb72b71d63d7e4498980f276ef58e6b
(cherry picked from commit a75d3d6d9f2aef4b1855e6a58332859f3531143d)
diff --git a/libs/binder/Android.bp b/libs/binder/Android.bp
index 57c8775..d4db8c8 100644
--- a/libs/binder/Android.bp
+++ b/libs/binder/Android.bp
@@ -36,6 +36,7 @@
     vndk: {
         enabled: true,
     },
+    double_loadable: true,
 
     srcs: [
         "AppOpsManager.cpp",
diff --git a/libs/gui/Android.bp b/libs/gui/Android.bp
index a302f28..02d29a3 100644
--- a/libs/gui/Android.bp
+++ b/libs/gui/Android.bp
@@ -23,6 +23,7 @@
     vndk: {
         enabled: true,
     },
+    double_loadable: true,
 
     clang: true,
     cflags: [
diff --git a/libs/ui/Android.bp b/libs/ui/Android.bp
index dac9616..438fd2a 100644
--- a/libs/ui/Android.bp
+++ b/libs/ui/Android.bp
@@ -18,6 +18,7 @@
     vndk: {
         enabled: true,
     },
+    double_loadable: true,
 
     clang: true,
     cflags: [
diff --git a/libs/vr/libpdx/Android.bp b/libs/vr/libpdx/Android.bp
index 10c0b31..113074b 100644
--- a/libs/vr/libpdx/Android.bp
+++ b/libs/vr/libpdx/Android.bp
@@ -1,3 +1,9 @@
+cc_library_headers {
+    name: "libpdx_headers",
+    export_include_dirs: ["private"],
+    vendor_available: true,
+}
+
 cc_library_static {
     name: "libpdx",
     clang: true,
@@ -8,8 +14,8 @@
         "-DLOG_TAG=\"libpdx\"",
         "-DTRACE=0",
     ],
-    export_include_dirs: ["private"],
-    local_include_dirs: ["private"],
+    header_libs: ["libpdx_headers"],
+    export_header_lib_headers: ["libpdx_headers"],
     srcs: [
         "client.cpp",
         "service.cpp",