You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2022/10/23 08:51:30 UTC
[incubator-nuttx-apps] branch master updated: Fix fatal error: array: No such file or directory
This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx-apps.git
The following commit(s) were added to refs/heads/master by this push:
new 2962af6fe Fix fatal error: array: No such file or directory
2962af6fe is described below
commit 2962af6fe6688eebfc30b4cd4e4d0da37e0d4097
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Sun Oct 23 14:00:00 2022 +0800
Fix fatal error: array: No such file or directory
enable test_stl2 only when CONFIG_LIBCXX is enabled
since uClibc++/minic++ doesn't have array header file
Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
---
testing/cxxtest/cxxtest_main.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/testing/cxxtest/cxxtest_main.cxx b/testing/cxxtest/cxxtest_main.cxx
index 4be644178..65b485d81 100644
--- a/testing/cxxtest/cxxtest_main.cxx
+++ b/testing/cxxtest/cxxtest_main.cxx
@@ -36,7 +36,7 @@
#ifdef CONFIG_CXX_EXCEPTION
#include <stdexcept>
#endif
-#if __cplusplus >= 201703L
+#if defined(CONFIG_LIBCXX) && __cplusplus >= 201703L
#include <array>
#include <utility>
#endif
@@ -61,7 +61,7 @@ public:
}
};
-#if __cplusplus >= 201703L
+#if defined(CONFIG_LIBCXX) && __cplusplus >= 201703L
class File
{
public:
@@ -193,7 +193,7 @@ static void test_stl()
// Name: test_stl2
//***************************************************************************/
-#if __cplusplus >= 201703L
+#if defined(CONFIG_LIBCXX) && __cplusplus >= 201703L
auto test_stl2() -> void
{
std::cout << "Test C++17 features ==========================" << std::endl;
@@ -274,7 +274,7 @@ extern "C" int main(int argc, char *argv[])
test_ofstream();
test_iostream();
test_stl();
-#if __cplusplus >= 201703L
+#if defined(CONFIG_LIBCXX) && __cplusplus >= 201703L
test_stl2();
#endif
#ifdef CONFIG_CXX_RTTI