threads / patch / 17338

patchMakefile: Use libc strlcpy on OSX

Subject: [PATCH] Makefile: Use libc strlcpy on OSX

## tl;dr

3 messages between Jan 24, 2009 and Jan 24, 2009. Diffs are folded; open one to read it.

replies: 2people: 2as markdown or json

Benjamin Kramer· Jan 24, 2009, 15:41 UTC · lore

OSX supports strlcpy(3) since 10.2 so we don't need to use our own.

Signed-off-by: Benjamin Kramer <benny.kra@gmail.com>
---
 Makefile |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)
Show changes to Makefile +0 −1
diff --git a/Makefile b/Makefile
index b4d9cb4..4c9aab5 100644
--- a/Makefile
+++ b/Makefile
@@ -643,7 +643,6 @@ ifeq ($(uname_S),Darwin)
 	ifneq ($(shell expr "$(uname_R)" : '9\.'),2)
 		OLD_ICONV = UnfortunatelyYes
 	endif
-	NO_STRLCPY = YesPlease
 	NO_MEMMEM = YesPlease
 	THREADED_DELTA_SEARCH = YesPlease
 endif
-- 
1.6.1.285.g3454
Junio C Hamano· Jan 24, 2009, 18:39 UTC · re: Benjamin Kramer · lore

Re: [PATCH] Makefile: Use libc strlcpy on OSX

Benjamin Kramer <benny.kra@googlemail.com> writes:
> OSX supports strlcpy(3) since 10.2 so we don't need
> to use our own.

How does your patch to Makefile refrain from kicking in for people with OSX older than 10.2, so that their builds are not broken?

Show 18 quoted lines
>
> Signed-off-by: Benjamin Kramer <benny.kra@gmail.com>
> ---
>  Makefile |    1 -
>  1 files changed, 0 insertions(+), 1 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index b4d9cb4..4c9aab5 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -643,7 +643,6 @@ ifeq ($(uname_S),Darwin)
>  	ifneq ($(shell expr "$(uname_R)" : '9\.'),2)
>  		OLD_ICONV = UnfortunatelyYes
>  	endif
> -	NO_STRLCPY = YesPlease
>  	NO_MEMMEM = YesPlease
>  	THREADED_DELTA_SEARCH = YesPlease
>  endif
Benjamin Kramer· Jan 24, 2009, 18:51 UTC · re: Junio C Hamano · lore

Re: [PATCH] Makefile: Use libc strlcpy on OSX

On Sat, Jan 24, 2009 at 19:39, Junio C Hamano <gitster@pobox.com> wrote:
> How does your patch to Makefile refrain from kicking in for people with
> OSX older than 10.2, so that their builds are not broken?

I'm not even sure anyone uses <= 10.1 nowadays. But of course you're right, I'll write a better patch.

-- Benjamin

← back to recent threads