public inbox for newlib@sourceware.org
 help / color / mirror / Atom feed
From: Torbjorn SVENSSON <torbjorn.svensson@foss.st.com>
To: Joseph Myers <josmyers@redhat.com>,
	Newlib <newlib@sourceware.org>, Andrew Pinski <pinskia@gmail.com>,
	Yvan Roux <yvan.roux@foss.st.com>
Subject: Re: Mismatch between newlib and glibc regarding fileno
Date: Thu, 15 Feb 2024 18:36:39 +0100	[thread overview]
Message-ID: <7de14786-e033-4182-9d2c-1c59f5e46c33@foss.st.com> (raw)
In-Reply-To: <Zcp0PtJN2tPuKqOU@calimero.vinschen.de>



On 2024-02-12 20:40, Corinna Vinschen wrote:
> On Feb 12 20:27, Torbjorn SVENSSON wrote:
>>
>>
>> On 2024-02-12 19:14, Joseph Myers wrote:
>>> On Mon, 12 Feb 2024, Corinna Vinschen wrote:
>>>
>>>> How is it possible that with -std=c++98, everything and the kitchen sink
>>>> is enabled?  Is that really correct?!?
>>>
>>> See <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=11196> (though
>>> <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=2082> is older).  Much of
>>> the standard C++ library implementation is in the headers, which makes it
>>> tricky to implement without _GNU_SOURCE when the C++ library wants to use
>>> (internally) lots of features not in ISO C.
>>>
>>
>> So, based on this, is it correct that newlib includes the check for
>> __STRICT_ANSI__?
>>
>> I.e., should GCC tests be updated to add -D_POSIX_SOURCE or should the check
>> for __STRICT_ANSI__ be removed from the newlib features.h file? Or maybe
>> both should be done?
> 
> glibc's feature.h performs the same __STRICT_ANSI__ checks, afaics.

I've pushed a patch on GCC14 that defines _POSIX_SOURCE.
https://gcc.gnu.org/pipermail/gcc-patches/2024-February/645731.html

Don't know if someone will look more into why newlib has a different set 
of defines than newlib, but I'm happy with that the test cases no longer 
produces fails in the log.

Kind regards,
Torbjörn

      reply	other threads:[~2024-02-15 17:37 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-09 16:29 Torbjorn SVENSSON
2024-02-09 16:40 ` Andrew Pinski
2024-02-09 16:54   ` Corinna Vinschen
2024-02-12 15:36     ` Torbjorn SVENSSON
2024-02-12 16:33       ` Corinna Vinschen
2024-02-12 16:40         ` Corinna Vinschen
2024-02-12 17:11           ` Torbjorn SVENSSON
2024-02-12 17:44             ` Corinna Vinschen
2024-02-12 18:14         ` Joseph Myers
2024-02-12 19:27           ` Torbjorn SVENSSON
2024-02-12 19:40             ` Corinna Vinschen
2024-02-15 17:36               ` Torbjorn SVENSSON [this message]

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=7de14786-e033-4182-9d2c-1c59f5e46c33@foss.st.com \
    --to=torbjorn.svensson@foss.st.com \
    --cc=josmyers@redhat.com \
    --cc=newlib@sourceware.org \
    --cc=pinskia@gmail.com \
    --cc=yvan.roux@foss.st.com \
    /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: link
Be 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).