public inbox for libstdc++@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] [libstdc++-v3] [rtems] enable filesystem support
@ 2024-05-30  5:02 Alexandre Oliva
  2024-05-30  6:35 ` Jonathan Wakely
  0 siblings, 1 reply; 4+ messages in thread
From: Alexandre Oliva @ 2024-05-30  5:02 UTC (permalink / raw)
  To: gcc-patches, libstdc++; +Cc: Joel Sherrill, Ralf Corsepius, Sebastian Huber


mkdir, chdir and chmod functions are defined in librtemscpu, that
doesn't get linked in during libstdc++-v3 configure, but applications
use -qrtems for linking, which brings those symbols in, so it makes
sense to mark them as available so that the C++ filesystem APIs are
enabled.

Regstrapped on x86_64-linux-gnu, also tested on aarch64-rtems6 with
gcc-13.  Ok to install?


for  libstdc++-v3/ChangeLog

	* configure.ac [*-*-rtems*]: Set chdir, chmod and mkdir as
	available.
	* configure: Rebuilt.
---
 libstdc++-v3/configure    |    7 +++++++
 libstdc++-v3/configure.ac |    7 +++++++
 2 files changed, 14 insertions(+)

diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
index 5179cc507f129..a7d1c015906c2 100755
--- a/libstdc++-v3/configure
+++ b/libstdc++-v3/configure
@@ -28610,6 +28610,13 @@ _ACEOF
 
         $as_echo "#define HAVE_USLEEP 1" >>confdefs.h
 
+
+	# These functions are defined in librtempscpu.  We don't use
+	# -qrtems during configure, so we don't link that in, and fail
+	# to find them.
+	glibcxx_cv_chdir=yes
+	glibcxx_cv_chmod=yes
+	glibcxx_cv_mkdir=yes
         ;;
     esac
   elif test "x$with_headers" != "xno"; then
diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
index 37396bd6ebbe6..0725c81bc9fa4 100644
--- a/libstdc++-v3/configure.ac
+++ b/libstdc++-v3/configure.ac
@@ -400,6 +400,13 @@ dnl # rather than hardcoding that information.
         AC_DEFINE(HAVE_SYMLINK)
         AC_DEFINE(HAVE_TRUNCATE)
         AC_DEFINE(HAVE_USLEEP)
+
+	# These functions are defined in librtempscpu.  We don't use
+	# -qrtems during configure, so we don't link that in, and fail
+	# to find them.
+	glibcxx_cv_chdir=yes
+	glibcxx_cv_chmod=yes
+	glibcxx_cv_mkdir=yes
         ;;
     esac
   elif test "x$with_headers" != "xno"; then


-- 
Alexandre Oliva, happy hacker            https://FSFLA.org/blogs/lxo/
   Free Software Activist                   GNU Toolchain Engineer
More tolerance and less prejudice are key for inclusion and diversity
Excluding neuro-others for not behaving ""normal"" is *not* inclusive

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] [libstdc++-v3] [rtems] enable filesystem support
  2024-05-30  5:02 [PATCH] [libstdc++-v3] [rtems] enable filesystem support Alexandre Oliva
@ 2024-05-30  6:35 ` Jonathan Wakely
  2024-05-30  8:18   ` Alexandre Oliva
  0 siblings, 1 reply; 4+ messages in thread
From: Jonathan Wakely @ 2024-05-30  6:35 UTC (permalink / raw)
  To: Alexandre Oliva
  Cc: gcc-patches, libstdc++, Joel Sherrill, Ralf Corsepius, Sebastian Huber

[-- Attachment #1: Type: text/plain, Size: 2423 bytes --]

On Thu, 30 May 2024, 06:03 Alexandre Oliva, <oliva@adacore.com> wrote:

>
> mkdir, chdir and chmod functions are defined in librtemscpu, that
> doesn't get linked in during libstdc++-v3 configure, but applications
> use -qrtems for linking, which brings those symbols in, so it makes
> sense to mark them as available so that the C++ filesystem APIs are
> enabled.
>
> Regstrapped on x86_64-linux-gnu, also tested on aarch64-rtems6 with
> gcc-13.  Ok to install?
>
>
> for  libstdc++-v3/ChangeLog
>
>         * configure.ac [*-*-rtems*]: Set chdir, chmod and mkdir as
>         available.
>         * configure: Rebuilt.
> ---
>  libstdc++-v3/configure    |    7 +++++++
>  libstdc++-v3/configure.ac |    7 +++++++
>  2 files changed, 14 insertions(+)
>
> diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
> index 5179cc507f129..a7d1c015906c2 100755
> --- a/libstdc++-v3/configure
> +++ b/libstdc++-v3/configure
> @@ -28610,6 +28610,13 @@ _ACEOF
>
>          $as_echo "#define HAVE_USLEEP 1" >>confdefs.h
>
> +
> +       # These functions are defined in librtempscpu.  We don't use
> +       # -qrtems during configure, so we don't link that in, and fail
> +       # to find them.
> +       glibcxx_cv_chdir=yes
> +       glibcxx_cv_chmod=yes
> +       glibcxx_cv_mkdir=yes
>          ;;
>      esac
>    elif test "x$with_headers" != "xno"; then
> diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
> index 37396bd6ebbe6..0725c81bc9fa4 100644
> --- a/libstdc++-v3/configure.ac
> +++ b/libstdc++-v3/configure.ac
> @@ -400,6 +400,13 @@ dnl # rather than hardcoding that information.
>          AC_DEFINE(HAVE_SYMLINK)
>          AC_DEFINE(HAVE_TRUNCATE)
>          AC_DEFINE(HAVE_USLEEP)
> +
> +       # These functions are defined in librtempscpu.  We don't use
>

Typo here, "rtemps"?

OK with that fixed (and configure regenerated).



+       # -qrtems during configure, so we don't link that in, and fail
> +       # to find them.

+       glibcxx_cv_chdir=yes
> +       glibcxx_cv_chmod=yes
> +       glibcxx_cv_mkdir=yes
>          ;;
>      esac
>    elif test "x$with_headers" != "xno"; then
>
>
> --
> Alexandre Oliva, happy hacker            https://FSFLA.org/blogs/lxo/
>    Free Software Activist                   GNU Toolchain Engineer
> More tolerance and less prejudice are key for inclusion and diversity
> Excluding neuro-others for not behaving ""normal"" is *not* inclusive
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] [libstdc++-v3] [rtems] enable filesystem support
  2024-05-30  6:35 ` Jonathan Wakely
@ 2024-05-30  8:18   ` Alexandre Oliva
  2024-05-30  9:47     ` Jonathan Wakely
  0 siblings, 1 reply; 4+ messages in thread
From: Alexandre Oliva @ 2024-05-30  8:18 UTC (permalink / raw)
  To: Jonathan Wakely
  Cc: gcc-patches, libstdc++, Joel Sherrill, Ralf Corsepius, Sebastian Huber

On May 30, 2024, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:

> Typo here, "rtemps"?

Ugh, thanks, fixed.

> OK with that fixed (and configure regenerated).

I also untabified the new lines, to match the surrounding context.
Here's what I installed:

[libstdc++-v3] [rtems] enable filesystem support

mkdir, chdir and chmod functions are defined in librtemscpu, that
doesn't get linked in during libstdc++-v3 configure, but applications
use -qrtems for linking, which brings those symbols in, so it makes
sense to mark them as available so that the C++ filesystem APIs are
enabled.


for  libstdc++-v3/ChangeLog

	* configure.ac [*-*-rtems*]: Set chdir, chmod and mkdir as
	available.
	* configure: Rebuilt.
---
 libstdc++-v3/configure    |    7 +++++++
 libstdc++-v3/configure.ac |    7 +++++++
 2 files changed, 14 insertions(+)

diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
index 5179cc507f129..5645e991af7ab 100755
--- a/libstdc++-v3/configure
+++ b/libstdc++-v3/configure
@@ -28610,6 +28610,13 @@ _ACEOF
 
         $as_echo "#define HAVE_USLEEP 1" >>confdefs.h
 
+
+        # These functions are defined in librtemscpu.  We don't use
+        # -qrtems during configure, so we don't link that in, and fail
+        # to find them.
+        glibcxx_cv_chdir=yes
+        glibcxx_cv_chmod=yes
+        glibcxx_cv_mkdir=yes
         ;;
     esac
   elif test "x$with_headers" != "xno"; then
diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
index 37396bd6ebbe6..ccb24a82be799 100644
--- a/libstdc++-v3/configure.ac
+++ b/libstdc++-v3/configure.ac
@@ -400,6 +400,13 @@ dnl # rather than hardcoding that information.
         AC_DEFINE(HAVE_SYMLINK)
         AC_DEFINE(HAVE_TRUNCATE)
         AC_DEFINE(HAVE_USLEEP)
+
+        # These functions are defined in librtemscpu.  We don't use
+        # -qrtems during configure, so we don't link that in, and fail
+        # to find them.
+        glibcxx_cv_chdir=yes
+        glibcxx_cv_chmod=yes
+        glibcxx_cv_mkdir=yes
         ;;
     esac
   elif test "x$with_headers" != "xno"; then


-- 
Alexandre Oliva, happy hacker            https://FSFLA.org/blogs/lxo/
   Free Software Activist                   GNU Toolchain Engineer
More tolerance and less prejudice are key for inclusion and diversity
Excluding neuro-others for not behaving ""normal"" is *not* inclusive

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] [libstdc++-v3] [rtems] enable filesystem support
  2024-05-30  8:18   ` Alexandre Oliva
@ 2024-05-30  9:47     ` Jonathan Wakely
  0 siblings, 0 replies; 4+ messages in thread
From: Jonathan Wakely @ 2024-05-30  9:47 UTC (permalink / raw)
  To: Alexandre Oliva
  Cc: Jonathan Wakely, gcc-patches, libstdc++,
	Joel Sherrill, Ralf Corsepius, Sebastian Huber

Thanks.

I got bounces from oarcorp.com and rtems.org, are the details in
MAINTAINERS out of date for Joel and Ralf?

On Thu, 30 May 2024 at 09:19, Alexandre Oliva <oliva@adacore.com> wrote:
>
> On May 30, 2024, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
>
> > Typo here, "rtemps"?
>
> Ugh, thanks, fixed.
>
> > OK with that fixed (and configure regenerated).
>
> I also untabified the new lines, to match the surrounding context.
> Here's what I installed:
>
> [libstdc++-v3] [rtems] enable filesystem support
>
> mkdir, chdir and chmod functions are defined in librtemscpu, that
> doesn't get linked in during libstdc++-v3 configure, but applications
> use -qrtems for linking, which brings those symbols in, so it makes
> sense to mark them as available so that the C++ filesystem APIs are
> enabled.
>
>
> for  libstdc++-v3/ChangeLog
>
>         * configure.ac [*-*-rtems*]: Set chdir, chmod and mkdir as
>         available.
>         * configure: Rebuilt.
> ---
>  libstdc++-v3/configure    |    7 +++++++
>  libstdc++-v3/configure.ac |    7 +++++++
>  2 files changed, 14 insertions(+)
>
> diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
> index 5179cc507f129..5645e991af7ab 100755
> --- a/libstdc++-v3/configure
> +++ b/libstdc++-v3/configure
> @@ -28610,6 +28610,13 @@ _ACEOF
>
>          $as_echo "#define HAVE_USLEEP 1" >>confdefs.h
>
> +
> +        # These functions are defined in librtemscpu.  We don't use
> +        # -qrtems during configure, so we don't link that in, and fail
> +        # to find them.
> +        glibcxx_cv_chdir=yes
> +        glibcxx_cv_chmod=yes
> +        glibcxx_cv_mkdir=yes
>          ;;
>      esac
>    elif test "x$with_headers" != "xno"; then
> diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
> index 37396bd6ebbe6..ccb24a82be799 100644
> --- a/libstdc++-v3/configure.ac
> +++ b/libstdc++-v3/configure.ac
> @@ -400,6 +400,13 @@ dnl # rather than hardcoding that information.
>          AC_DEFINE(HAVE_SYMLINK)
>          AC_DEFINE(HAVE_TRUNCATE)
>          AC_DEFINE(HAVE_USLEEP)
> +
> +        # These functions are defined in librtemscpu.  We don't use
> +        # -qrtems during configure, so we don't link that in, and fail
> +        # to find them.
> +        glibcxx_cv_chdir=yes
> +        glibcxx_cv_chmod=yes
> +        glibcxx_cv_mkdir=yes
>          ;;
>      esac
>    elif test "x$with_headers" != "xno"; then
>
>
> --
> Alexandre Oliva, happy hacker            https://FSFLA.org/blogs/lxo/
>    Free Software Activist                   GNU Toolchain Engineer
> More tolerance and less prejudice are key for inclusion and diversity
> Excluding neuro-others for not behaving ""normal"" is *not* inclusive
>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-05-30  9:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-30  5:02 [PATCH] [libstdc++-v3] [rtems] enable filesystem support Alexandre Oliva
2024-05-30  6:35 ` Jonathan Wakely
2024-05-30  8:18   ` Alexandre Oliva
2024-05-30  9:47     ` Jonathan Wakely

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).