summary refs log tree commit diff
path: root/pkgs/tools/archivers/cpio
diff options
context:
space:
mode:
authorMichael Raskin <7c6f434c@mail.ru>2007-10-11 03:41:29 +0000
committerMichael Raskin <7c6f434c@mail.ru>2007-10-11 03:41:29 +0000
commit77a46300fa05cd780e71cbf1ca400c714bd13340 (patch)
treec3b7c22a0f84aab3cbe9a4b6b302bbda1d1bd6bc /pkgs/tools/archivers/cpio
parentdeca7d257f3ffa4359ea412e7c0277b112fbf366 (diff)
downloadnixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.tar
nixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.tar.gz
nixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.tar.bz2
nixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.tar.lz
nixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.tar.xz
nixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.tar.zst
nixpkgs-77a46300fa05cd780e71cbf1ca400c714bd13340.zip
Added patch from Gentoo for glibc 2.6 compatibility. It just randomly renames an inner function, so glibc 2.5-safe.
svn path=/nixpkgs/trunk/; revision=9441
Diffstat (limited to 'pkgs/tools/archivers/cpio')
-rw-r--r--pkgs/tools/archivers/cpio/default.nix2
-rw-r--r--pkgs/tools/archivers/cpio/gnulib-futimens.patch30
2 files changed, 31 insertions, 1 deletions
diff --git a/pkgs/tools/archivers/cpio/default.nix b/pkgs/tools/archivers/cpio/default.nix
index deed73bc031..225bc557350 100644
--- a/pkgs/tools/archivers/cpio/default.nix
+++ b/pkgs/tools/archivers/cpio/default.nix
@@ -6,5 +6,5 @@ stdenv.mkDerivation {
     url = http://ftp.gnu.org/gnu/cpio/cpio-2.7.tar.bz2;
     md5 = "69ad6cb3d288aafe5f969f68d9fd0fb7";
   };
-  patches = [./symlink.patch];
+  patches = [./symlink.patch ./gnulib-futimens.patch];
 }
diff --git a/pkgs/tools/archivers/cpio/gnulib-futimens.patch b/pkgs/tools/archivers/cpio/gnulib-futimens.patch
new file mode 100644
index 00000000000..11703d5706d
--- /dev/null
+++ b/pkgs/tools/archivers/cpio/gnulib-futimens.patch
@@ -0,0 +1,30 @@
+now hat glibc-2.6  declares futimens.
+http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00089.html
+
+diff -ru cpio-2.7.orig/lib/utimens.c cpio-2.7/lib/utimens.c
+--- cpio-2.7.orig/lib/utimens.c	2007-05-20 21:23:57.000000000 +0900
++++ cpio-2.7/lib/utimens.c	2007-05-21 08:40:22.000000000 +0900
+@@ -73,7 +73,7 @@
+    Return 0 on success, -1 (setting errno) on failure.  */
+ 
+ int
+-futimens (int fd ATTRIBUTE_UNUSED,
++gl_futimens (int fd ATTRIBUTE_UNUSED,
+ 	  char const *file, struct timespec const timespec[2])
+ {
+   /* There's currently no interface to set file timestamps with
+@@ -166,5 +166,5 @@
+ int
+ utimens (char const *file, struct timespec const timespec[2])
+ {
+-  return futimens (-1, file, timespec);
++  return gl_futimens (-1, file, timespec);
+ }
+diff -ru cpio-2.7.orig/lib/utimens.h cpio-2.7/lib/utimens.h
+--- cpio-2.7.orig/lib/utimens.h	2007-05-20 21:23:57.000000000 +0900
++++ cpio-2.7/lib/utimens.h	2007-05-21 08:39:57.000000000 +0900
+@@ -1,3 +1,3 @@
+ #include "timespec.h"
+-int futimens (int, char const *, struct timespec const [2]);
++int gl_futimens (int, char const *, struct timespec const [2]);
+ int utimens (char const *, struct timespec const [2]);