Subject: Re: [PATCH] pkt-line: initialize packet_buffer to avoid macOS linker warning

From: Junio C Hamano <[email-masked]>
Date: Fri, 29 May 2026 05:12:39 +0900

Harald Nordgren <[email-masked]> writes:

> So maybe we can do something like this then?
>
> ```
> +       # Silence Xcode 16.3+ linker warning about __DATA,__common alignment.
> +       LD_MAJOR_VERSION = $(shell ld -v 2>&1 | sed -n
> 's/.*PROJECT:ld-\([0-9]*\).*/\1/p')
> +        ifeq ($(shell test "$(LD_MAJOR_VERSION)" -ge 1167 && echo 1),1)
> +               BASIC_CFLAGS += -fno-common
> +        endif
> ```
>
> Harald

I do not exactly know where these magic numbers and patterns for
"ld" comes from, but yes, something like that in macOS specific
section would be what I had in mind.

Thanks.