Merge "Move libcutils source to C++."
diff --git a/libvndksupport/linker.c b/libvndksupport/linker.c
index d06cafc..bc5620b 100644
--- a/libvndksupport/linker.c
+++ b/libvndksupport/linker.c
@@ -21,7 +21,8 @@
#define LOG_TAG "vndksupport"
#include <log/log.h>
-extern struct android_namespace_t* android_get_exported_namespace(const char*);
+__attribute__((weak)) extern struct android_namespace_t* android_get_exported_namespace(const char*);
+__attribute__((weak)) extern void* android_dlopen_ext(const char*, int, const android_dlextinfo*);
static const char* namespace_name = NULL;
@@ -31,7 +32,9 @@
if (vendor_namespace == NULL) {
int name_idx = 0;
while (namespace_names[name_idx] != NULL) {
- vendor_namespace = android_get_exported_namespace(namespace_names[name_idx]);
+ if (android_get_exported_namespace != NULL) {
+ vendor_namespace = android_get_exported_namespace(namespace_names[name_idx]);
+ }
if (vendor_namespace != NULL) {
namespace_name = namespace_names[name_idx];
break;
@@ -48,7 +51,10 @@
const android_dlextinfo dlextinfo = {
.flags = ANDROID_DLEXT_USE_NAMESPACE, .library_namespace = vendor_namespace,
};
- void* handle = android_dlopen_ext(name, flag, &dlextinfo);
+ void* handle = NULL;
+ if (android_dlopen_ext != NULL) {
+ handle = android_dlopen_ext(name, flag, &dlextinfo);
+ }
if (!handle) {
ALOGE("Could not load %s from %s namespace: %s.", name, namespace_name, dlerror());
}
diff --git a/rootdir/init.rc b/rootdir/init.rc
index 96eb6f3..ca7b991 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -430,6 +430,7 @@
mkdir /data/misc/vold 0700 root root
mkdir /data/misc/boottrace 0771 system shell
mkdir /data/misc/update_engine 0700 root root
+ mkdir /data/misc/update_engine_log 02750 root log
mkdir /data/misc/trace 0700 root root
# profile file layout
mkdir /data/misc/profiles 0771 system system