public inbox for libstdc++-cvs@sourceware.org help / color / mirror / Atom feed
From: Jonathan Wakely <redi@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r11-9440] libstdc++: Fix definition of _GLIBCXX_NO_SLEEP config macro Date: Wed, 5 Jan 2022 22:07:07 +0000 (GMT) [thread overview] Message-ID: <20220105220707.F16E13858027@sourceware.org> (raw) https://gcc.gnu.org/g:0bc256f8e1ae6db423c167f15ffdd126fd8199f9 commit r11-9440-g0bc256f8e1ae6db423c167f15ffdd126fd8199f9 Author: Jonathan Wakely <jwakely@redhat.com> Date: Fri Dec 10 11:39:26 2021 +0000 libstdc++: Fix definition of _GLIBCXX_NO_SLEEP config macro If no OS function to sleep (e.g. nanosleep, usleep, Win32 Sleep etc.) is available then configure defines the macro NO_SLEEP. But this will not get prefixed with "_GLIBCXX_" because include/Makefile.am only does that for macros beginning with "HAVE_". The configure script should define _GLIBCXX_NO_SLEEP instead (which is what the code actually checks for). libstdc++-v3/ChangeLog: * acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Add _GLIBCXX_ prefix to NO_SLEEP macro. * config.h.in: Regenerate. * configure: Regenerate. (cherry picked from commit ca1c7065e9de04ceb521a0b409071275c5690341) Diff: --- libstdc++-v3/acinclude.m4 | 2 +- libstdc++-v3/config.h.in | 6 +++--- libstdc++-v3/configure | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4 index 1c0a4c13052..56405328844 100644 --- a/libstdc++-v3/acinclude.m4 +++ b/libstdc++-v3/acinclude.m4 @@ -1639,7 +1639,7 @@ AC_DEFUN([GLIBCXX_ENABLE_LIBSTDCXX_TIME], [ fi if test x"$ac_no_sleep" = x"yes"; then - AC_DEFINE(NO_SLEEP,1, [Defined if no way to sleep is available.]) + AC_DEFINE(_GLIBCXX_NO_SLEEP,1, [Defined if no way to sleep is available.]) fi AC_SUBST(GLIBCXX_LIBS) diff --git a/libstdc++-v3/config.h.in b/libstdc++-v3/config.h.in index 37b56b82b0e..61c342681d4 100644 --- a/libstdc++-v3/config.h.in +++ b/libstdc++-v3/config.h.in @@ -714,9 +714,6 @@ */ #undef LT_OBJDIR -/* Defined if no way to sleep is available. */ -#undef NO_SLEEP - /* Name of package */ #undef PACKAGE @@ -838,6 +835,9 @@ /* Define if C99 llrint and llround functions are missing from <math.h>. */ #undef _GLIBCXX_NO_C99_ROUNDING_FUNCS +/* Defined if no way to sleep is available. */ +#undef _GLIBCXX_NO_SLEEP + /* Define if ptrdiff_t is int. */ #undef _GLIBCXX_PTRDIFF_T_IS_INT diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure index 16baffffc6c..acf20989c9e 100755 --- a/libstdc++-v3/configure +++ b/libstdc++-v3/configure @@ -21189,7 +21189,7 @@ $as_echo "$ac_has_win32_sleep" >&6; } if test x"$ac_no_sleep" = x"yes"; then -$as_echo "#define NO_SLEEP 1" >>confdefs.h +$as_echo "#define _GLIBCXX_NO_SLEEP 1" >>confdefs.h fi
reply other threads:[~2022-01-05 22:07 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20220105220707.F16E13858027@sourceware.org \ --to=redi@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ --cc=libstdc++-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).