# TODO: This is to work around b/19059885. Remove after root cause is fixed
LOCAL_LDFLAGS_arm := -Wl,--hash-style=both
+LOCAL_LDFLAGS_x86 := -Wl,--hash-style=both
$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_arch_dynamic_src_files))
# TODO: This is to work around b/19059885. Remove after root cause is fixed
LOCAL_LDFLAGS_arm := -Wl,--hash-style=both
+LOCAL_LDFLAGS_x86 := -Wl,--hash-style=both
LOCAL_SRC_FILES := $(libstdcxx_common_src_files)
LOCAL_MODULE:= libstdc++
# TODO: This is to work around b/19059885. Remove after root cause is fixed
LOCAL_LDFLAGS_arm := -Wl,--hash-style=both
+LOCAL_LDFLAGS_x86 := -Wl,--hash-style=both
LOCAL_MODULE := libm
LOCAL_CLANG := $(libm_clang)
-fvisibility=hidden \
-Wall -Wextra -Wunused -Werror \
+LOCAL_CFLAGS_arm += -D__work_around_b_19059885__
+LOCAL_CFLAGS_x86 += -D__work_around_b_19059885__
+
LOCAL_CONLYFLAGS += \
-std=gnu99 \
}
}
} else {
-#if !defined(__arm__)
+#if !defined(__work_around_b_19059885__)
__libc_fatal("soinfo for \"%s\"@%p has no version", si->get_realpath(), si);
#else
PRINT("warning: soinfo for \"%s\"@%p has no version", si->get_realpath(), si);
}
const char* soinfo::get_realpath() const {
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
if (has_min_version(2)) {
return realpath_.c_str();
} else {
}
const char* soinfo::get_soname() const {
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
if (has_min_version(2)) {
return soname_;
} else {
for (ElfW(Dyn)* d = dynamic; d->d_tag != DT_NULL; ++d) {
if (d->d_tag == DT_SONAME) {
soname_ = get_string(d->d_un.d_val);
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
strlcpy(old_name_, soname_, sizeof(old_name_));
#endif
break;
#define SOINFO_VERSION 2
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
#define SOINFO_NAME_LEN 128
#endif
struct soinfo {
public:
typedef LinkedList<soinfo, SoinfoListAllocator> soinfo_list_t;
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
private:
char old_name_[SOINFO_NAME_LEN];
#endif
ElfW(Addr) base;
size_t size;
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
uint32_t unused1; // DO NOT USE, maintained for compatibility.
#endif
ElfW(Dyn)* dynamic;
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
uint32_t unused2; // DO NOT USE, maintained for compatibility
uint32_t unused3; // DO NOT USE, maintained for compatibility
#endif
bool is_gnu_hash() const;
bool inline has_min_version(uint32_t min_version __unused) const {
-#if defined(__arm__)
+#if defined(__work_around_b_19059885__)
return (flags_ & FLAG_NEW_SOINFO) != 0 && version_ >= min_version;
#else
return true;