summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2014-09-17 20:10:10 -0700
committerElliott Hughes <enh@google.com>2014-09-17 20:10:10 -0700
commit9229b1bee33f416f06bdfb28e466a36f80963575 (patch)
tree3e4efa58d78b1e6149a3149812388a79195b7823
parentc26f208487aa1d7cfb9baf2d0579a5696875c5d0 (diff)
downloadextras-9229b1bee33f416f06bdfb28e466a36f80963575.tar.gz
Remove old libstdc++ tests.
We have the libc++ tests now. Change-Id: I68dba2286e67142e5dd4fd69feaeedd16da882c4
-rw-r--r--tests/bionic/libstdc++/Android.mk84
-rw-r--r--tests/bionic/libstdc++/README.TXT19
-rw-r--r--tests/bionic/libstdc++/test_cassert.cpp49
-rw-r--r--tests/bionic/libstdc++/test_cctype.cpp100
-rw-r--r--tests/bionic/libstdc++/test_climits.cpp88
-rw-r--r--tests/bionic/libstdc++/test_cmath.cpp75
-rw-r--r--tests/bionic/libstdc++/test_csetjmp.cpp65
-rw-r--r--tests/bionic/libstdc++/test_csignal.cpp68
-rw-r--r--tests/bionic/libstdc++/test_cstddef.cpp103
-rw-r--r--tests/bionic/libstdc++/test_cstdint.cpp45
-rw-r--r--tests/bionic/libstdc++/test_cstdio.cpp166
-rw-r--r--tests/bionic/libstdc++/test_cstdlib.cpp120
-rw-r--r--tests/bionic/libstdc++/test_cstring.cpp76
-rw-r--r--tests/bionic/libstdc++/test_ctime.cpp110
14 files changed, 0 insertions, 1168 deletions
diff --git a/tests/bionic/libstdc++/Android.mk b/tests/bionic/libstdc++/Android.mk
deleted file mode 100644
index 12286622..00000000
--- a/tests/bionic/libstdc++/Android.mk
+++ /dev/null
@@ -1,84 +0,0 @@
-# Copyright (C) 2009 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# Build control file for Bionic's test programs
-# define the BIONIC_TESTS environment variable to build the test programs
-#
-
-ifdef BIONIC_TESTS
-
-LOCAL_PATH:= $(call my-dir)
-
-# used to define a simple test program and build it as a standalone
-# device executable.
-#
-# you can use EXTRA_CFLAGS to indicate additional CFLAGS to use
-# in the build. the variable will be cleaned on exit
-#
-define device-test
- $(foreach file,$(1), \
- $(eval include $(CLEAR_VARS)) \
- $(eval LOCAL_SRC_FILES := $(file)) \
- $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
- $(eval LOCAL_CFLAGS += $(EXTRA_CFLAGS)) \
- $(eval LOCAL_MODULE_TAGS := tests) \
- $(eval include $(BUILD_EXECUTABLE)) \
- ) \
- $(eval EXTRA_CFLAGS :=)
-endef
-
-# same as 'device-test' but builds a host executable instead
-# you can use EXTRA_LDLIBS to indicate additional linker flags
-#
-define host-test
- $(foreach file,$(1), \
- $(eval include $(CLEAR_VARS)) \
- $(eval LOCAL_SRC_FILES := $(file)) \
- $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
- $(eval LOCAL_CFLAGS += $(EXTRA_CFLAGS)) \
- $(eval LOCAL_LDLIBS += $(EXTRA_LDLIBS)) \
- $(eval LOCAL_MODULE_TAGS := tests) \
- $(eval include $(BUILD_HOST_EXECUTABLE)) \
- ) \
- $(eval EXTRA_CFLAGS :=) \
- $(eval EXTRA_LDLIBS :=)
-endef
-
-sources := \
- test_cassert.cpp \
- test_cctype.cpp \
- test_climits.cpp \
- test_cmath.cpp \
- test_csetjmp.cpp \
- test_csignal.cpp \
- test_cstddef.cpp \
- test_cstdio.cpp \
- test_cstdlib.cpp \
- test_cstring.cpp \
- test_ctime.cpp
-
-$(call host-test, $(sources))
-
-EXTRA_CFLAGS := -DBIONIC=1 -I bionic/libstdc++/include
-
-# <cstdint> is not part of the C++ standard yet, and some
-# host environments don't provide it unless you use specific
-# compiler flags, so only build this test for device/Bionic
-# builds at the moment.
-#
-sources += test_cstdint.cpp
-
-$(call device-test, $(sources))
-
-endif # BIONIC_TESTS
diff --git a/tests/bionic/libstdc++/README.TXT b/tests/bionic/libstdc++/README.TXT
deleted file mode 100644
index aa7f8a46..00000000
--- a/tests/bionic/libstdc++/README.TXT
+++ /dev/null
@@ -1,19 +0,0 @@
-This directory contains a set of tests for Android's Bionic Standard C++ library.
-
-You must define the BIONIC_TESTS environment variable to build these
-test programs. For example, do:
-
- cd system/extras/tests/bionic/libstdc++
- mm BIONIC_TESTS=1
-
-Preferably, to build and run you can use this:
-
- runtest_py libstdcpp
-
-All test programs should exit with a status code of 0 in case of success, and 1
-in case of failure.
-
-The directory layout is currently flat because there is one Bionic test. If you
-want to add GNU STDC++ or benchmark tests, look in tests/bionic/libc as an
-example how to structure your files.
-
diff --git a/tests/bionic/libstdc++/test_cassert.cpp b/tests/bionic/libstdc++/test_cassert.cpp
deleted file mode 100644
index fc669a92..00000000
--- a/tests/bionic/libstdc++/test_cassert.cpp
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-
-#include <cassert>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CASSERT__
-#error "Wrong header file included!!"
-#endif
-
-namespace {
-const int kPassed = 0;
-} // anonymous namespace
-
-namespace android
-{
-#ifndef assert
-#error "assert must be a macro"
-#endif
-} // android namespace
-
-int main(int argc, char **argv)
-{
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cctype.cpp b/tests/bionic/libstdc++/test_cctype.cpp
deleted file mode 100644
index cc641712..00000000
--- a/tests/bionic/libstdc++/test_cctype.cpp
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cctype>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CCTYPE__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-} // anonymous namespace
-
-namespace android
-{
-#ifdef isalnum
-#error "should be a real function"
-#endif
-#ifdef isalpha
-#error "should be a real function"
-#endif
-#ifdef iscntrl
-#error "should be a real function"
-#endif
-#ifdef isdigit
-#error "should be a real function"
-#endif
-#ifdef isgraph
-#error "should be a real function"
-#endif
-#ifdef islower
-#error "should be a real function"
-#endif
-#ifdef isprint
-#error "should be a real function"
-#endif
-#ifdef ispunct
-#error "should be a real function"
-#endif
-#ifdef isspace
-#error "should be a real function"
-#endif
-#ifdef isupper
-#error "should be a real function"
-#endif
-#ifdef isxdigit
-#error "should be a real function"
-#endif
-#ifdef tolower
-#error "should be a real function"
-#endif
-#ifdef toupper
-#error "should be a real function"
-#endif
-
-using std::isalnum;
-using std::isdigit;
-using std::isprint;
-using std::isupper;
-using std::tolower;
-using std::isalpha;
-using std::isgraph;
-using std::ispunct;
-using std::isxdigit;
-using std::toupper;
-using std::iscntrl;
-using std::islower;
-using std::isspace;
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_climits.cpp b/tests/bionic/libstdc++/test_climits.cpp
deleted file mode 100644
index 9fdba56c..00000000
--- a/tests/bionic/libstdc++/test_climits.cpp
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-
-#include <climits>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CLIMITS__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-bool testLimits()
-{
- // char
- volatile char c1 = CHAR_BIT;
- volatile char c2 = CHAR_MAX;
- volatile char c3 = CHAR_MIN;
-
- // int
- volatile int i1 = INT_MAX;
- volatile int i2 = INT_MIN;
-
- // short
- volatile short s1 = SHRT_MAX;
- volatile short s2 = SHRT_MIN;
-
- // long
- volatile long l1 = LONG_MAX;
- volatile long l2 = LONG_MIN;
-
- // long long
- volatile long long ll1 = LLONG_MAX;
- volatile long long ll2 = LLONG_MIN;
-
- volatile unsigned long mb = MB_LEN_MAX;
-
- // signed char
- volatile signed char sc1 = SCHAR_MIN;
- volatile signed char sc2 = SCHAR_MAX;
-
- // unsigned
- volatile unsigned int ui = UINT_MAX;
- volatile unsigned short us = USHRT_MAX;
- volatile unsigned long ul = ULONG_MAX;
- volatile unsigned long long ull = ULLONG_MAX;
-
- return true;
-}
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- FAIL_UNLESS(testLimits);
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cmath.cpp b/tests/bionic/libstdc++/test_cmath.cpp
deleted file mode 100644
index 847c9340..00000000
--- a/tests/bionic/libstdc++/test_cmath.cpp
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cmath>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CMATH__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-using ::cos;
-using ::sin;
-using ::tan;
-using ::acos;
-using ::asin;
-using ::atan;
-using ::atan2;
-
-using ::cosh;
-using ::sinh;
-using ::tanh;
-
-using ::exp;
-using ::frexp;
-using ::ldexp;
-using ::log;
-using ::log10;
-using ::modf;
-
-using ::pow;
-using ::sqrt;
-
-using ::ceil;
-using ::fabs;
-using ::floor;
-using ::fmod;
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_csetjmp.cpp b/tests/bionic/libstdc++/test_csetjmp.cpp
deleted file mode 100644
index 79b23d88..00000000
--- a/tests/bionic/libstdc++/test_csetjmp.cpp
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <csetjmp>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSETJMP__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-#ifdef longjmp
-#error "longjmp must not be a macro"
-#endif
-
-#ifndef setjmp
-#error "setjmp must be a macro"
-#endif
-
-using std::longjmp;
-
-bool testJmpbuf()
-{
- volatile std::jmp_buf jmpbuf;
- return true;
-}
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- FAIL_UNLESS(testJmpbuf);
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_csignal.cpp b/tests/bionic/libstdc++/test_csignal.cpp
deleted file mode 100644
index a460e649..00000000
--- a/tests/bionic/libstdc++/test_csignal.cpp
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <csignal>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSIGNAL__
-#error "Wrong header file included!!"
-#endif
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-#ifdef raise
-#error "raise must not be a macro"
-#endif
-
-#ifndef SIGABRT
-#error "SIGABRT must be a macro"
-#endif
-
-#ifndef SIGILL
-#error "SIGILL must be a macro"
-#endif
-
-using std::raise;
-using std::signal;
-bool testSigAtomicT()
-{
- volatile std::sig_atomic_t s;
- return true;
-}
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- FAIL_UNLESS(testSigAtomicT);
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cstddef.cpp b/tests/bionic/libstdc++/test_cstddef.cpp
deleted file mode 100644
index b1e280ff..00000000
--- a/tests/bionic/libstdc++/test_cstddef.cpp
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cstddef>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSTDDEF__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android {
-// Dummy struct used to calculate offset of some of its fields.
-struct Foo
-{
- char field1;
- char field2;
-};
-
-// Check various types are declared in the std namespace.
-bool testTypesStd()
-{
- // size_t should be defined in both namespaces
- volatile ::size_t size_t_in_top_ns = 0;
- volatile ::std::size_t size_t_in_std_ns = 0;
-
- if (sizeof(::size_t) != sizeof(::std::size_t))
- {
- return false;
- }
-
- // ptrdiff_t should be defined in both namespaces
- volatile ::ptrdiff_t ptrdiff_t_in_top_ns = 0;
- volatile ::std::ptrdiff_t ptrdiff_t_in_std_ns = 0;
-
- if (sizeof(::ptrdiff_t) != sizeof(::std::ptrdiff_t))
- {
- return false;
- }
- // NULL is only in the top namespace
- volatile int *null_is_defined = NULL;
- return true;
-}
-
-bool testOffsetOf()
-{
-#ifndef offsetof
-#error "offsetof is not a macro"
-#endif
-
- // offsetof is only in the top namespace
- volatile size_t offset = offsetof(struct Foo, field2);
- return offset == 1;
-}
-
-bool testNull()
-{
-#ifndef NULL
-#error "NULL is not a macro"
-#endif
- // If NULL is void* this will issue a warning.
- volatile int null_is_not_void_star = NULL;
- return true;
-}
-
-} // android namespace
-
-int main(int argc, char **argv)
-{
- FAIL_UNLESS(testTypesStd);
- FAIL_UNLESS(testOffsetOf);
- FAIL_UNLESS(testNull);
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cstdint.cpp b/tests/bionic/libstdc++/test_cstdint.cpp
deleted file mode 100644
index a01164f9..00000000
--- a/tests/bionic/libstdc++/test_cstdint.cpp
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cstdint>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSTDINT__
-#error "Wrong header file included!!"
-#endif
-
-namespace {
-const int kPassed = 0;
-} // anonymous namespace
-
-namespace android
-{
-} // namespace android
-
-int main(int argc, char **argv)
-{
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cstdio.cpp b/tests/bionic/libstdc++/test_cstdio.cpp
deleted file mode 100644
index f22250a4..00000000
--- a/tests/bionic/libstdc++/test_cstdio.cpp
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cstdio>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSTDIO__
-#error "Wrong header file included!!"
-#endif
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-#ifndef BUFSIZ
-#error "BUFSIZ must be a macro"
-#endif
-
-#ifndef EOF
-#error "EOF must be a macro"
-#endif
-
-#ifndef FILENAME_MAX
-#error "FILENAME_MAX must be a macro"
-#endif
-
-#ifndef FOPEN_MAX
-#error "FOPEN_MAX must be a macro"
-#endif
-
-#ifndef L_tmpnam
-#error "L_tmpnam must be a macro"
-#endif
-
-#ifndef NULL
-#error "NULL must be a macro"
-#endif
-
-#ifndef SEEK_CUR
-#error "SEEK_CUR must be a macro"
-#endif
-
-#ifndef SEEK_END
-#error "SEEK_END must be a macro"
-#endif
-#ifndef SEEK_SET
-#error "SEEK_SET must be a macro"
-#endif
-
-#ifndef TMP_MAX
-#error "TMP_MAX must be a macro"
-#endif
-
-#ifndef _IOFBF
-#error "_IOFBF must be a macro"
-#endif
-
-#ifndef _IOLBF
-#error "_IOLBF must be a macro"
-#endif
-
-#ifndef _IONBF
-#error "_IONBF must be a macro"
-#endif
-
-#ifndef stderr
-#error "stderr must be a macro"
-#endif
-
-#ifndef stdin
-#error "stdin must be a macro"
-#endif
-
-#ifndef stdout
-#error "stdout must be a macro"
-#endif
-
-using std::clearerr;
-using std::fclose;
-using std::feof;
-using std::ferror;
-using std::fflush;
-using std::fgetc;
-using std::fgetpos;
-using std::fgets;
-using std::fopen;
-using std::fprintf;
-using std::fputc;
-using std::fputs;
-using std::fread;
-using std::freopen;
-using std::fscanf;
-using std::fseek;
-using std::fsetpos;
-using std::ftell;
-using std::fwrite;
-using std::getc;
-using std::getchar;
-using std::gets;
-using std::perror;
-using std::printf;
-using std::putc;
-using std::putchar;
-using std::puts;
-using std::remove;
-using std::rename;
-using std::rewind;
-using std::scanf;
-using std::setbuf;
-using std::setvbuf;
-using std::sprintf;
-using std::sscanf;
-using std::tmpfile;
-using std::tmpnam;
-using std::ungetc;
-using std::vfprintf;
-using std::vprintf;
-using std::vsprintf;
-
-using std::snprintf;
-using std::vfscanf;
-using std::vscanf;
-using std::vsnprintf;
-using std::vsscanf;
-
-bool testTypesStd()
-{
- volatile std::size_t size;
- volatile std::FILE file;
- volatile std::fpos_t fpos_t;
- return true;
-}
-} // namespace android
-
-int main(int argc, char **argv)
-{
- FAIL_UNLESS(testTypesStd);
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cstdlib.cpp b/tests/bionic/libstdc++/test_cstdlib.cpp
deleted file mode 100644
index 0450d066..00000000
--- a/tests/bionic/libstdc++/test_cstdlib.cpp
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cstdlib>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSTDLIB__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-using ::exit;
-using ::abort;
-using ::atexit;
-using ::on_exit;
-
-using ::getenv;
-using ::putenv;
-using ::setenv;
-using ::unsetenv;
-using ::clearenv;
-
-using ::mktemp;
-using ::mkstemp;
-
-using ::strtol;
-using ::strtoll;
-using ::strtoul;
-using ::strtoull;
-using ::strtod;
-using ::strtof;
-
-using ::atoi;
-using ::atol;
-using ::atoll;
-using ::atof;
-
-using ::abs;
-using ::labs;
-using ::llabs;
-
-using ::realpath;
-using ::system;
-
-using ::bsearch;
-using ::qsort;
-
-using ::jrand48;
-using ::mrand48;
-using ::nrand48;
-using ::lrand48;
-using ::seed48;
-using ::srand48;
-
-using ::rand;
-using ::srand;
-using ::random;
-using ::srandom;
-
-using ::malloc;
-using ::free;
-using ::calloc;
-using ::realloc;
-
-using ::unlockpt;
-using ::ptsname;
-using ::ptsname_r;
-using ::getpt;
-using ::grantpt;
-
-using ::div_t;
-using ::div;
-using ::ldiv_t;
-using ::ldiv;
-using ::lldiv_t;
-using ::lldiv;
-
-using ::mblen;
-using ::mbstowcs;
-using ::mbtowc;
-using ::wctomb;
-using ::wcstombs;
-} // namespace android
-
-int main(int argc, char **argv)
-{
- // FAIL_UNLESS(testTypesStd);
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_cstring.cpp b/tests/bionic/libstdc++/test_cstring.cpp
deleted file mode 100644
index f01b8a84..00000000
--- a/tests/bionic/libstdc++/test_cstring.cpp
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <cstring>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CSTRING__
-#error "Wrong header file included!!"
-#endif
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-using std::memchr;
-using std::memcmp;
-using std::memcpy;
-using std::memmove;
-using std::memset;
-using std::strcat;
-using std::strchr;
-using std::strcmp;
-using std::strcoll;
-using std::strcpy;
-using std::strcspn;
-using std::strerror;
-using std::strlen;
-using std::strncat;
-using std::strncmp;
-using std::strncpy;
-using std::strpbrk;
-using std::strrchr;
-using std::strspn;
-using std::strstr;
-using std::strtok;
-using std::strxfrm;
-
-#ifndef NULL
-#error "NULL must be a macro"
-#endif
-
-volatile std::size_t size;
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- return kPassed;
-}
diff --git a/tests/bionic/libstdc++/test_ctime.cpp b/tests/bionic/libstdc++/test_ctime.cpp
deleted file mode 100644
index 9fae6837..00000000
--- a/tests/bionic/libstdc++/test_ctime.cpp
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include <ctime>
-#if defined BIONIC && !defined BIONIC_LIBSTDCPP_INCLUDE_CTIME__
-#error "Wrong header file included!!"
-#endif
-
-
-namespace {
-const int kPassed = 0;
-const int kFailed = 1;
-#define FAIL_UNLESS(f) if (!android::f()) return kFailed;
-} // anonymous namespace
-
-namespace android
-{
-#ifndef CLOCKS_PER_SEC
-#error "CLOCKS_PER_SEC must be a macro"
-#endif
-
-#ifdef clock
-#error "should be a real function"
-#endif
-#ifdef difftime
-#error "should be a real function"
-#endif
-#ifdef mktime
-#error "should be a real function"
-#endif
-#ifdef time
-#error "should be a real function"
-#endif
-#ifdef asctime
-#error "should be a real function"
-#endif
-#ifdef ctime
-#error "should be a real function"
-#endif
-#ifdef gmtime
-#error "should be a real function"
-#endif
-#ifdef localtime
-#error "should be a real function"
-#endif
-#ifdef strftime
-#error "should be a real function"
-#endif
-
-using std::clock;
-using std::difftime;
-using std::mktime;
-using std::time;
-using std::asctime;
-using std::ctime;
-using std::gmtime;
-using std::localtime;
-using std::strftime;
-
-// Check various types are declared in the std namespace.
-// This is a compilation test.
-bool testTypesStd()
-{
- volatile std::clock_t clock;
- volatile std::time_t time;
- volatile std::tm better_time;
- return true;
-}
-
-bool testGetClock()
-{
- volatile std::clock_t clock1 = std::clock();
- volatile std::clock_t clock2 = std::clock();
- if (clock2 < clock1) return false;
- return true;
-}
-
-} // namespace android
-
-int main(int argc, char **argv)
-{
- FAIL_UNLESS(testTypesStd);
- FAIL_UNLESS(testGetClock);
- return kPassed;
-}