diff --git a/benchmarks/Android.mk b/benchmarks/Android.mk index 4d7ad962a..00250a5c8 100644 --- a/benchmarks/Android.mk +++ b/benchmarks/Android.mk @@ -49,9 +49,8 @@ LOCAL_MODULE_STEM_64 := bionic-benchmarks64 LOCAL_MULTILIB := both LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk LOCAL_CFLAGS += $(benchmark_c_flags) -LOCAL_C_INCLUDES += external/stlport/stlport bionic/ bionic/libstdc++/include -LOCAL_SHARED_LIBRARIES += libstlport LOCAL_SRC_FILES := $(benchmark_src_files) +LOCAL_CXX_STL := libc++ include $(BUILD_EXECUTABLE) ifeq ($(HOST_OS)-$(HOST_ARCH),$(filter $(HOST_OS)-$(HOST_ARCH),linux-x86 linux-x86_64)) diff --git a/tests/Android.build.mk b/tests/Android.build.mk index d54c851b2..956228794 100644 --- a/tests/Android.build.mk +++ b/tests/Android.build.mk @@ -15,6 +15,7 @@ # include $(CLEAR_VARS) +LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk LOCAL_MODULE := $(module) LOCAL_MODULE_TAGS := $(module_tag) @@ -85,9 +86,13 @@ LOCAL_LDLIBS := \ $($(module)_ldlibs) \ $($(module)_ldlibs_$(build_type)) \ -ifeq ($(build_type),target) - include external/stlport/libstlport.mk +ifeq ($(LOCAL_FORCE_STATIC_EXECUTABLE),true) +LOCAL_CXX_STL := libc++_static +else +LOCAL_CXX_STL := libc++ +endif +ifeq ($(build_type),target) include $(BUILD_$(build_target)) endif diff --git a/tests/Android.mk b/tests/Android.mk index 448a8dc83..d946d307c 100644 --- a/tests/Android.mk +++ b/tests/Android.mk @@ -271,10 +271,10 @@ bionic-unit-tests-static_whole_static_libraries := \ libBionicTests \ bionic-unit-tests-static_static_libraries := \ - libstlport_static \ libm \ libc \ - libstdc++ \ + libc++_static \ + libdl \ libtinyxml2 \ liblog \ diff --git a/tests/stdatomic_test.cpp b/tests/stdatomic_test.cpp index b7fb19b0d..eb030bfa7 100644 --- a/tests/stdatomic_test.cpp +++ b/tests/stdatomic_test.cpp @@ -14,8 +14,10 @@ * limitations under the License. */ -#include #include +// Fool stdatomic.h into not using . +#undef _USING_LIBCXX +#include #include #include