git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] config.mak.uname: enable OPEN_RETURNS_EINTR for macOS Big Sur

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 1, 2021, 23:57 UTC
Message-ID
<xmqqczwimnps.fsf@gitster.c.googlers.com>
In-Reply-To
<YDy0C9sRvboGXQ7P@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
> I got another off-list report of the problem. I think we probably want
> to do this on top:
Queued and pushed out.

I wonder if these hits for SA_RESTART in config.mak.uname would be a good way to guide us.

    [6c109904 (Port to HP NonStop, 2012-09-19)]
            # Not detected (nor checked for) by './configure'.
            # We don't have SA_RESTART on NonStop, unfortunalety.
            COMPAT_CFLAGS += -DSA_RESTART=0
    [40036bed (Port to QNX, 2012-12-18)]
    ifeq ($(uname_S),QNX)
            COMPAT_CFLAGS += -DSA_RESTART=0

One caveat is that we do not know if their system headers hide the real implementation of open(2) behind a C preprocessor macro, in whcih case OPEN_RETURNS_EINTR wrapper may not work correctly.

Show 17 quoted lines
>  config.mak.uname | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/config.mak.uname b/config.mak.uname
> index e22d4b6d67..d204c20a64 100644
> --- a/config.mak.uname
> +++ b/config.mak.uname
> @@ -124,6 +124,9 @@ ifeq ($(uname_S),Darwin)
>  	ifeq ($(shell test "`expr "$(uname_R)" : '\([0-9][0-9]*\)\.'`" -ge 11 && echo 1),1)
>  		HAVE_GETDELIM = YesPlease
>  	endif
> +	ifeq ($(shell test "`expr "$(uname_R)" : '\([0-9][0-9]*\)\.'`" -ge 20 && echo 1),1)
> +		OPEN_RETURNS_EINTR = UnfortunatelyYes
> +	endif
>  	NO_MEMMEM = YesPlease
>  	USE_ST_TIMESPEC = YesPlease
>  	HAVE_DEV_TTY = YesPlease
Previous: Junio C HamanoNext: Jeff King
Message 9 of 15 in “wrapper: add workaround for open() returning EINTR”
  1. wrapper: add workaround for open() returning EINTRJeff King, Feb 24, 2021
  2. Jeff KingFeb 24, 2021
  3. Junio C HamanoFeb 24, 2021
  4. Jeff KingFeb 24, 2021
  5. Makefile: add OPEN_RETURNS_EINTR knobJeff King, Feb 26, 2021
  6. Junio C HamanoFeb 26, 2021
  7. config.mak.uname: enable OPEN_RETURNS_EINTR for macOS Big SurJeff King, Mar 1, 2021
  8. Junio C HamanoMar 1, 2021
  9. Junio C HamanoMar 1, 2021
  10. Jeff KingMar 3, 2021
  11. Junio C HamanoMar 4, 2021
  12. Taylor BlauFeb 24, 2021
  13. Johannes SixtFeb 24, 2021
  14. Jeff KingFeb 24, 2021
  15. Jeff KingFeb 26, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.