summaryrefslogtreecommitdiffstats
path: root/patches/coreutils-5.2.1/fix-declaration.diff
diff options
context:
space:
mode:
authorWolfram Sang <w.sang@pengutronix.de>2009-06-10 10:57:52 +0000
committerWolfram Sang <w.sang@pengutronix.de>2009-06-10 10:57:52 +0000
commit0c5c03d095485f7521d96cd44314f9a0ee826232 (patch)
tree1df111a8270ba417537931cc6e1a4952b3000ee9 /patches/coreutils-5.2.1/fix-declaration.diff
parentd3ee0775cadf505c4bae7b1df483d73bf8294815 (diff)
downloadptxdist-0c5c03d095485f7521d96cd44314f9a0ee826232.tar.gz
ptxdist-0c5c03d095485f7521d96cd44314f9a0ee826232.tar.xz
* patches: remove 'generic'-layer
git-svn-id: https://svn.pengutronix.de/svn/ptxdist/trunks/ptxdist-trunk@10711 33e552b5-05e3-0310-8538-816dae2090ed
Diffstat (limited to 'patches/coreutils-5.2.1/fix-declaration.diff')
-rw-r--r--patches/coreutils-5.2.1/fix-declaration.diff92
1 files changed, 92 insertions, 0 deletions
diff --git a/patches/coreutils-5.2.1/fix-declaration.diff b/patches/coreutils-5.2.1/fix-declaration.diff
new file mode 100644
index 000000000..b11b98fd3
--- /dev/null
+++ b/patches/coreutils-5.2.1/fix-declaration.diff
@@ -0,0 +1,92 @@
+Subject: fix declarations
+From: Marc Kleine-Budde <mkl@pengutronix.de>
+
+This patch fixes these errors:
+
+test.c:129: error: static declaration of 'eaccess' follows non-static declaration
+/usr/include/unistd.h:268: error: previous declaration of 'eaccess' was here
+
+tee.c:34: error: conflicting types for 'tee'
+/usr/include/bits/fcntl.h:233: error: previous declaration of 'tee' was here
+
+Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
+
+---
+ src/tee.c | 6 +++---
+ src/test.c | 10 +++++-----
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+Index: coreutils-5.2.1/src/test.c
+===================================================================
+--- coreutils-5.2.1.orig/src/test.c
++++ coreutils-5.2.1/src/test.c
+@@ -125,7 +125,7 @@ test_syntax_error (char const *format, c
+ /* Do the same thing access(2) does, but use the effective uid and gid. */
+
+ static int
+-eaccess (char const *file, int mode)
++_eaccess (char const *file, int mode)
+ {
+ static int have_ids;
+ static uid_t uid, euid;
+@@ -158,7 +158,7 @@ eaccess (char const *file, int mode)
+ return result;
+ }
+ #else
+-# define eaccess(F, M) euidaccess (F, M)
++# define _eaccess(F, M) euidaccess (F, M)
+ #endif
+
+ /* Increment our position in the argument list. Check that we're not
+@@ -623,17 +623,17 @@ unary_operator (void)
+
+ case 'r': /* file is readable? */
+ unary_advance ();
+- value = -1 != eaccess (argv[pos - 1], R_OK);
++ value = -1 != _eaccess (argv[pos - 1], R_OK);
+ return (TRUE == value);
+
+ case 'w': /* File is writable? */
+ unary_advance ();
+- value = -1 != eaccess (argv[pos - 1], W_OK);
++ value = -1 != _eaccess (argv[pos - 1], W_OK);
+ return (TRUE == value);
+
+ case 'x': /* File is executable? */
+ unary_advance ();
+- value = -1 != eaccess (argv[pos - 1], X_OK);
++ value = -1 != _eaccess (argv[pos - 1], X_OK);
+ return (TRUE == value);
+
+ case 'O': /* File is owned by you? */
+Index: coreutils-5.2.1/src/tee.c
+===================================================================
+--- coreutils-5.2.1.orig/src/tee.c
++++ coreutils-5.2.1/src/tee.c
+@@ -31,7 +31,7 @@
+
+ #define AUTHORS "Mike Parker", "Richard M. Stallman", "David MacKenzie"
+
+-static int tee (int nfiles, const char **files);
++static int _tee (int nfiles, const char **files);
+
+ /* If nonzero, append to output files rather than truncating them. */
+ static int append;
+@@ -146,7 +146,7 @@ main (int argc, char **argv)
+ /* Do *not* warn if tee is given no file arguments.
+ POSIX requires that it work when given no arguments. */
+
+- errs = tee (argc - optind, (const char **) &argv[optind]);
++ errs = _tee (argc - optind, (const char **) &argv[optind]);
+ if (close (STDIN_FILENO) != 0)
+ error (EXIT_FAILURE, errno, _("standard input"));
+
+@@ -158,7 +158,7 @@ main (int argc, char **argv)
+ Return 0 if successful, 1 if any errors occur. */
+
+ static int
+-tee (int nfiles, const char **files)
++_tee (int nfiles, const char **files)
+ {
+ FILE **descriptors;
+ char buffer[BUFSIZ];