From c183c7b3ec282c56b3b9943ce0496281f3b15cec Mon Sep 17 00:00:00 2001 From: Danie Roux Date: Mon, 2 Sep 2013 18:47:20 +0200 Subject: [PATCH] coreutils: Make it build on OSX 10.0.8 Take patch from: https://lists.gnu.org/archive/html/bug-coreutils/2013-01/msg00119.html --- pkgs/tools/misc/coreutils/8.19.nix | 2 ++ pkgs/tools/misc/coreutils/stpncpy.patch | 11 +++++++++++ 2 files changed, 13 insertions(+) create mode 100644 pkgs/tools/misc/coreutils/stpncpy.patch diff --git a/pkgs/tools/misc/coreutils/8.19.nix b/pkgs/tools/misc/coreutils/8.19.nix index 23db167f307..59602e69d1d 100644 --- a/pkgs/tools/misc/coreutils/8.19.nix +++ b/pkgs/tools/misc/coreutils/8.19.nix @@ -14,6 +14,8 @@ stdenv.mkDerivation rec { sha256 = "1rx9x3fp848w4nny7irdkcpkan9fcx24d99v5dkwgkyq7wc76f5d"; }; + patches = [ ./stpncpy.patch ]; + nativeBuildInputs = [ perl ]; buildInputs = [ gmp ] ++ stdenv.lib.optional aclSupport acl diff --git a/pkgs/tools/misc/coreutils/stpncpy.patch b/pkgs/tools/misc/coreutils/stpncpy.patch new file mode 100644 index 00000000000..d4a0e0ee0e1 --- /dev/null +++ b/pkgs/tools/misc/coreutils/stpncpy.patch @@ -0,0 +1,11 @@ +--- coreutils-8.19/lib/stpncpy.c.orig 2013-09-02 18:20:00.000000000 +0200 ++++ coreutils-8.19/lib/stpncpy.c 2013-09-02 18:20:31.000000000 +0200 +@@ -31,7 +31,7 @@ + /* Copy no more than N bytes of SRC to DST, returning a pointer past the + last non-NUL byte written into DST. */ + char * +-__stpncpy (char *dest, const char *src, size_t n) ++(__stpncpy) (char *dest, const char *src, size_t n) + { + char c; + char *s = dest;