awong-dev/ndk — pull request #26 by awong-dev (2013-11-27 22:51:23+00:00)
Title: Fix new.delete tests by correctly delegating to gabi new handlers and li...

...nk methodology.

Previously GABIXX_LIBCXX incorrectly selected the default libc++
implementation for set_new_handler which defined a set handler per
translation unit. This made overriding incomplete.

Furthermore, the linking of libc++.so incorreclty specified -Bsymbolic which,
aside from causing issues with rtti and exception handlers, it also makes the
default implementations of the array operator new, and the single-object
no-throw variant (both of which wrap the normal single-object new) link
directly to the single-object new rather than jump through the PLT. This
means that even if you override single-object new, the default implementations
of these other new operators will NOT find the override. Bad bad bad.

Removed -Bsymbolic and also added --dynamic-list-cpp-new to correctly allow
overriding of operator new. The build script fix is kinda hacked...but
good enough for now.

Change-Id: I1abc21a849efdf4639689d4ae4499819cae32cd2