[PATCH] libstdc++: testsuite: fs rename to self may fail
Alexandre Oliva
oliva@adacore.com
Thu Jun 23 12:41:18 GMT 2022
On Jun 23, 2022, Jonathan Wakely <jwakely@redhat.com> wrote:
>> Regstrapped on x86_64-linux-gnu, also tested with a cross to
>> aarch64-rtems6. Ok to install?
> OK, thanks.
Sorry, I failed to refresh this one too.
Here's what I'm going to install:
libstdc++: xfail rename tests on rtems
From: Alexandre Oliva <oliva@adacore.com>
::rename on RTEMS does not meet several POSIX requirements, despite
compliance with C and C++ standards. ::std::filesystem::rename, in
turn, has requirements borrowed from POSIX, so it would have to be a
lot more than a simple wrapper around ::rename on RTEMS, and even then
fall short.
Until RTEMS reimplements ::rename for POSIX compliance, expect
filesystem rename tests to fail on it.
for libstdc++-v3/ChangeLog
* testsuite/27_io/filesystem/operations/rename.cc: xfail on
rtems.
* testsuite/experimental/filesystem/operations/rename.cc:
Likewise.
---
.../27_io/filesystem/operations/rename.cc | 1 +
.../experimental/filesystem/operations/rename.cc | 1 +
2 files changed, 2 insertions(+)
diff --git a/libstdc++-v3/testsuite/27_io/filesystem/operations/rename.cc b/libstdc++-v3/testsuite/27_io/filesystem/operations/rename.cc
index b74e1133a7618..983374f42e448 100644
--- a/libstdc++-v3/testsuite/27_io/filesystem/operations/rename.cc
+++ b/libstdc++-v3/testsuite/27_io/filesystem/operations/rename.cc
@@ -17,6 +17,7 @@
// { dg-do run { target c++17 } }
// { dg-require-filesystem-ts "" }
+// { dg-xfail-run-if "rename is not POSIX-compliant" { *-*-rtems* } }
#include <filesystem>
#include <testsuite_hooks.h>
diff --git a/libstdc++-v3/testsuite/experimental/filesystem/operations/rename.cc b/libstdc++-v3/testsuite/experimental/filesystem/operations/rename.cc
index 37e743b770fdf..762b943888f9e 100644
--- a/libstdc++-v3/testsuite/experimental/filesystem/operations/rename.cc
+++ b/libstdc++-v3/testsuite/experimental/filesystem/operations/rename.cc
@@ -18,6 +18,7 @@
// { dg-options "-DUSE_FILESYSTEM_TS -lstdc++fs" }
// { dg-do run { target c++11 } }
// { dg-require-filesystem-ts "" }
+// { dg-xfail-run-if "rename is not POSIX-compliant" { *-*-rtems* } }
#include <experimental/filesystem>
#include <testsuite_hooks.h>
--
Alexandre Oliva, happy hacker https://FSFLA.org/blogs/lxo/
Free Software Activist GNU Toolchain Engineer
Disinformation flourishes because many people care deeply about injustice
but very few check the facts. Ask me about <https://stallmansupport.org>
More information about the Libstdc++
mailing list