diff options
author | Chris Lord <chris@openedhand.com> | 2006-08-17 15:19:29 +0000 |
---|---|---|
committer | Chris Lord <chris@openedhand.com> | 2006-08-17 15:19:29 +0000 |
commit | 22a7b205e4337895e6eaad5eeba596245a22bfe7 (patch) | |
tree | c00fc89bd0617cea041edc7f8fa45762a5da609f /meta/packages/coreutils/coreutils-5.1.3 | |
parent | d58cfb05fa0b8d6bf93f435713995b46616330cc (diff) | |
download | poky-22a7b205e4337895e6eaad5eeba596245a22bfe7.tar.gz |
Add patch to rename eaccess function in coreutils-native so it doesn't
conflict with any system-provided eaccess.
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@610 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/packages/coreutils/coreutils-5.1.3')
-rw-r--r-- | meta/packages/coreutils/coreutils-5.1.3/rename-eaccess.patch | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/meta/packages/coreutils/coreutils-5.1.3/rename-eaccess.patch b/meta/packages/coreutils/coreutils-5.1.3/rename-eaccess.patch new file mode 100644 index 0000000000..cde2731477 --- /dev/null +++ b/meta/packages/coreutils/coreutils-5.1.3/rename-eaccess.patch | |||
@@ -0,0 +1,44 @@ | |||
1 | # On Ubuntu edgy (and perhaps other distributions), eaccess is provided by | ||
2 | # unistd.h - This renames the function so as not to conflict. | ||
3 | |||
4 | --- coreutils-5.1.3/src/test.c.old 2006-08-17 15:29:41.000000000 +0100 | ||
5 | +++ coreutils-5.1.3/src/test.c 2006-08-17 15:30:44.000000000 +0100 | ||
6 | @@ -125,7 +125,7 @@ | ||
7 | /* Do the same thing access(2) does, but use the effective uid and gid. */ | ||
8 | |||
9 | static int | ||
10 | -eaccess (char const *file, int mode) | ||
11 | +_eaccess (char const *file, int mode) | ||
12 | { | ||
13 | static int have_ids; | ||
14 | static uid_t uid, euid; | ||
15 | @@ -158,7 +158,7 @@ | ||
16 | return result; | ||
17 | } | ||
18 | #else | ||
19 | -# define eaccess(F, M) euidaccess (F, M) | ||
20 | +# define _eaccess(F, M) euidaccess (F, M) | ||
21 | #endif | ||
22 | |||
23 | /* Increment our position in the argument list. Check that we're not | ||
24 | @@ -623,17 +623,17 @@ | ||
25 | |||
26 | case 'r': /* file is readable? */ | ||
27 | unary_advance (); | ||
28 | - value = -1 != eaccess (argv[pos - 1], R_OK); | ||
29 | + value = -1 != _eaccess (argv[pos - 1], R_OK); | ||
30 | return (TRUE == value); | ||
31 | |||
32 | case 'w': /* File is writable? */ | ||
33 | unary_advance (); | ||
34 | - value = -1 != eaccess (argv[pos - 1], W_OK); | ||
35 | + value = -1 != _eaccess (argv[pos - 1], W_OK); | ||
36 | return (TRUE == value); | ||
37 | |||
38 | case 'x': /* File is executable? */ | ||
39 | unary_advance (); | ||
40 | - value = -1 != eaccess (argv[pos - 1], X_OK); | ||
41 | + value = -1 != _eaccess (argv[pos - 1], X_OK); | ||
42 | return (TRUE == value); | ||
43 | |||
44 | case 'O': /* File is owned by you? */ | ||