diff --git a/examples/README.txt b/examples/README.txt index 523002537..a14f00f0c 100644 --- a/examples/README.txt +++ b/examples/README.txt @@ -228,40 +228,6 @@ examples/cpuhog back mode. This may be useful if you are trying run down other problems that you think might only occur when the system is very busy. -examples/cxxtest -^^^^^^^^^^^^^^^^ - - This is a test of the C++ standard library. At present a port of the uClibc++ - C++ library is available. Due to licensing issues, the uClibc++ C++ library - is not included in the NuttX source tree by default, but must be installed - (see the README.txt file in the uClibc++ download package for installation). - - The uClibc++ test includes simple test of: - - - iostreams, - - STL, - - RTTI, and - - Exceptions - - Example Configuration Options - ----------------------------- - CONFIG_EXAMPLES_CXXTEST=y - Eanbles the example - CONFIG_EXAMPLES_CXXTEST_CXXINITIALIZE=y - By default, if CONFIG_HAVE_CXX - and CONFIG_HAVE_CXXINITIALIZE are defined, then this example - will call the NuttX function to initialize static C++ constructors. - This option may be disabled, however, if that static initialization - was performed elsewhere. - - Other Required Configuration Settings - ------------------------------------- - Other NuttX setting that are required include: - - CONFIG_HAVE_CXX=y - CONFIG_HAVE_CXXINITIALIZE=y - CONFIG_UCLIBCXX=y - - Additional uClibc++ settings may be required in your build environment. - examples/dac ^^^^^^^^^^^^ diff --git a/testing/README.txt b/testing/README.txt index 374a16e8d..a7f7c4ffe 100644 --- a/testing/README.txt +++ b/testing/README.txt @@ -4,6 +4,40 @@ apps/testing README file The apps/testing directory is used to build NuttX-specific tests and to include external testing frameworks +testing/cxxtest +=============== + + This is a test of the C++ standard library. At present a port of the uClibc++ + C++ library is available. Due to licensing issues, the uClibc++ C++ library + is not included in the NuttX source tree by default, but must be installed + (see the README.txt file in the uClibc++ download package for installation). + + The uClibc++ test includes simple test of: + + - iostreams, + - STL, + - RTTI, and + - Exceptions + + Example Configuration Options + ----------------------------- + CONFIG_TESTINGCXXTEST=y - Eanbles the example + CONFIG_TESTINGCXXTEST_CXXINITIALIZE=y - By default, if CONFIG_HAVE_CXX + and CONFIG_HAVE_CXXINITIALIZE are defined, then this example + will call the NuttX function to initialize static C++ constructors. + This option may be disabled, however, if that static initialization + was performed elsewhere. + + Other Required Configuration Settings + ------------------------------------- + Other NuttX setting that are required include: + + CONFIG_HAVE_CXX=y + CONFIG_HAVE_CXXINITIALIZE=y + CONFIG_UCLIBCXX=y + + Additional uClibc++ settings may be required in your build environment. + testing/fstest ============== diff --git a/examples/cxxtest/.gitignore b/testing/cxxtest/.gitignore similarity index 100% rename from examples/cxxtest/.gitignore rename to testing/cxxtest/.gitignore diff --git a/examples/cxxtest/Kconfig b/testing/cxxtest/Kconfig similarity index 87% rename from examples/cxxtest/Kconfig rename to testing/cxxtest/Kconfig index 51b6b3c54..1b51c5015 100644 --- a/examples/cxxtest/Kconfig +++ b/testing/cxxtest/Kconfig @@ -3,16 +3,16 @@ # see the file kconfig-language.txt in the NuttX tools repository. # -config EXAMPLES_CXXTEST +config TESTINGCXXTEST tristate "C++ test program" default n depends on HAVE_CXX ---help--- Enable the C++ test program -if EXAMPLES_CXXTEST +if TESTINGCXXTEST -config EXAMPLES_CXXTEST_CXXINITIALIZE +config TESTINGCXXTEST_CXXINITIALIZE bool "C++ Initialization" default y depends on HAVE_CXX && HAVE_CXXINITIALIZE diff --git a/examples/cxxtest/Make.defs b/testing/cxxtest/Make.defs similarity index 94% rename from examples/cxxtest/Make.defs rename to testing/cxxtest/Make.defs index bf462df4c..66858bb41 100644 --- a/examples/cxxtest/Make.defs +++ b/testing/cxxtest/Make.defs @@ -1,5 +1,5 @@ ############################################################################ -# apps/examples/cxxtest/Make.defs +# apps/testing/Make.defs # Adds selected applications to apps/ build # # Copyright (C) 2015 Gregory Nutt. All rights reserved. @@ -34,6 +34,6 @@ # ############################################################################ -ifneq ($(CONFIG_EXAMPLES_CXXTEST),) -CONFIGURED_APPS += examples/cxxtest +ifneq ($(CONFIG_TESTINGCXXTEST),) +CONFIGURED_APPS += testing endif diff --git a/examples/cxxtest/Makefile b/testing/cxxtest/Makefile similarity index 96% rename from examples/cxxtest/Makefile rename to testing/cxxtest/Makefile index 403d5a434..815d417ed 100644 --- a/examples/cxxtest/Makefile +++ b/testing/cxxtest/Makefile @@ -1,5 +1,5 @@ ############################################################################ -# apps/examples/cxxtest/Makefile +# apps/testing/Makefile # # Copyright (C) 2009-2012 Gregory Nutt. All rights reserved. # Author: Gregory Nutt @@ -51,6 +51,6 @@ APPNAME = cxxtest PRIORITY = SCHED_PRIORITY_DEFAULT STACKSIZE = 4096 -MODULE = CONFIG_EXAMPLES_CXXTEST +MODULE = CONFIG_TESTINGCXXTEST include $(APPDIR)/Application.mk diff --git a/examples/cxxtest/cxxtest_main.cxx b/testing/cxxtest/cxxtest_main.cxx similarity index 98% rename from examples/cxxtest/cxxtest_main.cxx rename to testing/cxxtest/cxxtest_main.cxx index e29be1377..b2e1486f8 100644 --- a/examples/cxxtest/cxxtest_main.cxx +++ b/testing/cxxtest/cxxtest_main.cxx @@ -1,5 +1,5 @@ //*************************************************************************** -// examples/cxxtest/main.cxx +// testing/main.cxx // // Copyright (C) 2012, 2017 Gregory Nutt. All rights reserved. // Author: Qiang Yu, http://rgmp.sourceforge.net/wiki/index.php/Main_Page @@ -61,7 +61,7 @@ using namespace std; #if !defined(CONFIG_HAVE_CXX) || !defined(CONFIG_HAVE_CXXINITIALIZE) # warning Support for static initializers is NOT enabled -# undef CONFIG_EXAMPLES_CXXTEST_CXXINITIALIZE +# undef CONFIG_TESTINGCXXTEST_CXXINITIALIZE #endif //*************************************************************************** @@ -250,7 +250,7 @@ extern "C" // If C++ initialization for static constructors is supported, then do // that first -#ifdef CONFIG_EXAMPLES_CXXTEST_CXXINITIALIZE +#ifdef CONFIG_TESTINGCXXTEST_CXXINITIALIZE up_cxxinitialize(); #endif