diff options
Diffstat (limited to 'sysdeps/unix')
20 files changed, 89 insertions, 38 deletions
diff --git a/sysdeps/unix/sysv/linux/alpha/getdents.c b/sysdeps/unix/sysv/linux/alpha/getdents.c index f127cd8..dfecfef 100644 --- a/sysdeps/unix/sysv/linux/alpha/getdents.c +++ b/sysdeps/unix/sysv/linux/alpha/getdents.c @@ -1,5 +1,3 @@ -#define DIRENT_TYPE struct dirent64 -#define __getdents64 __no___getdents64_decl +#define DIRENT_SET_DP_INO(dp, value) \ + do { (dp)->d_ino = (value); (dp)->__pad = 0; } while (0) #include <sysdeps/unix/sysv/linux/getdents.c> -#undef __getdents64 -weak_alias(__getdents, __getdents64); diff --git a/sysdeps/unix/sysv/linux/alpha/getdents64.c b/sysdeps/unix/sysv/linux/alpha/getdents64.c deleted file mode 100644 index 0df2c8f..0000000 --- a/sysdeps/unix/sysv/linux/alpha/getdents64.c +++ /dev/null @@ -1 +0,0 @@ -/* getdents64 is in getdents.c */ diff --git a/sysdeps/unix/sysv/linux/alpha/readdir.c b/sysdeps/unix/sysv/linux/alpha/readdir.c deleted file mode 100644 index 300ebb2..0000000 --- a/sysdeps/unix/sysv/linux/alpha/readdir.c +++ /dev/null @@ -1,7 +0,0 @@ -#define readdir64 __no_readdir64_decl -#define __readdir64 __no___readdir64_decl -#include <sysdeps/unix/readdir.c> -#undef __readdir64 -strong_alias (__readdir, __readdir64) -#undef readdir64 -weak_alias (__readdir, readdir64) diff --git a/sysdeps/unix/sysv/linux/alpha/readdir64.c b/sysdeps/unix/sysv/linux/alpha/readdir64.c deleted file mode 100644 index 9796431..0000000 --- a/sysdeps/unix/sysv/linux/alpha/readdir64.c +++ /dev/null @@ -1 +0,0 @@ -/* readdir64 is in readdir.c */ diff --git a/sysdeps/unix/sysv/linux/alpha/readdir64_r.c b/sysdeps/unix/sysv/linux/alpha/readdir64_r.c deleted file mode 100644 index b8fe9a3..0000000 --- a/sysdeps/unix/sysv/linux/alpha/readdir64_r.c +++ /dev/null @@ -1 +0,0 @@ -/* readdir64_r is in readdir_r.c */ diff --git a/sysdeps/unix/sysv/linux/alpha/readdir_r.c b/sysdeps/unix/sysv/linux/alpha/readdir_r.c deleted file mode 100644 index adb92db..0000000 --- a/sysdeps/unix/sysv/linux/alpha/readdir_r.c +++ /dev/null @@ -1,4 +0,0 @@ -#define readdir64_r __no_readdir64_r_decl -#include <sysdeps/unix/readdir_r.c> -#undef readdir64_r -weak_alias (__readdir_r, readdir64_r) diff --git a/sysdeps/unix/sysv/linux/arm/Versions b/sysdeps/unix/sysv/linux/arm/Versions index 5498086..aeda9fa 100644 --- a/sysdeps/unix/sysv/linux/arm/Versions +++ b/sysdeps/unix/sysv/linux/arm/Versions @@ -17,6 +17,9 @@ libc { # a* alphasort64; + # g* + glob64; + # New rlimit interface getrlimit; setrlimit; getrlimit64; diff --git a/sysdeps/unix/sysv/linux/arm/glob64.c b/sysdeps/unix/sysv/linux/arm/glob64.c new file mode 100644 index 0000000..82a9a29 --- /dev/null +++ b/sysdeps/unix/sysv/linux/arm/glob64.c @@ -0,0 +1 @@ +#include <sysdeps/unix/sysv/linux/i386/glob64.c> diff --git a/sysdeps/unix/sysv/linux/i386/Versions b/sysdeps/unix/sysv/linux/i386/Versions index b7af24b..3015c41 100644 --- a/sysdeps/unix/sysv/linux/i386/Versions +++ b/sysdeps/unix/sysv/linux/i386/Versions @@ -19,6 +19,9 @@ libc { # a* alphasort64; + # g* + glob64; + # New rlimit interface getrlimit; setrlimit; getrlimit64; diff --git a/sysdeps/unix/sysv/linux/i386/glob64.c b/sysdeps/unix/sysv/linux/i386/glob64.c new file mode 100644 index 0000000..9f32742 --- /dev/null +++ b/sysdeps/unix/sysv/linux/i386/glob64.c @@ -0,0 +1,48 @@ +#include <dirent.h> +#include <glob.h> +#include <sys/stat.h> + +#define dirent dirent64 +#define __readdir(dirp) __readdir64 (dirp) + +#define glob_t glob64_t +#define glob(pattern, flags, errfunc, pglob) \ + __glob64 (pattern, flags, errfunc, pglob) +#define globfree(pglob) globfree64 (pglob) + +#undef stat +#define stat stat64 +#undef __stat +#define __stat(file, buf) __xstat64 (_STAT_VER, file, buf) + +#define NO_GLOB_PATTERN_P 1 + +#include <sysdeps/generic/glob.c> + +#include "shlib-compat.h" + +versioned_symbol (libc, __glob64, glob64, GLIBC_2_2); + +#if SHLIB_COMPAT(libc, GLIBC_2_1, GLIBC_2_2) + +#include <sysdeps/unix/sysv/linux/i386/olddirent.h> + +int __old_glob64 (__const char *__pattern, int __flags, + int (*__errfunc) (__const char *, int), + glob64_t *__pglob); + +#undef dirent +#define dirent __old_dirent64 +#undef __readdir +#define __readdir(dirp) __old_readdir64 (dirp) +#undef glob +#define glob(pattern, flags, errfunc, pglob) \ + __old_glob64 (pattern, flags, errfunc, pglob) +#define glob_in_dir __old_glob_in_dir + +#define GLOB_ONLY_P 1 + +#include <sysdeps/generic/glob.c> + +compat_symbol (libc, __old_glob64, glob64, GLIBC_2_1); +#endif diff --git a/sysdeps/unix/sysv/linux/ia64/readdir.c b/sysdeps/unix/sysv/linux/ia64/readdir.c index e64b2f8..300ebb2 100644 --- a/sysdeps/unix/sysv/linux/ia64/readdir.c +++ b/sysdeps/unix/sysv/linux/ia64/readdir.c @@ -1 +1,7 @@ -#include <sysdeps/unix/sysv/linux/alpha/readdir.c> +#define readdir64 __no_readdir64_decl +#define __readdir64 __no___readdir64_decl +#include <sysdeps/unix/readdir.c> +#undef __readdir64 +strong_alias (__readdir, __readdir64) +#undef readdir64 +weak_alias (__readdir, readdir64) diff --git a/sysdeps/unix/sysv/linux/ia64/readdir_r.c b/sysdeps/unix/sysv/linux/ia64/readdir_r.c index fc5818f..adb92db 100644 --- a/sysdeps/unix/sysv/linux/ia64/readdir_r.c +++ b/sysdeps/unix/sysv/linux/ia64/readdir_r.c @@ -1 +1,4 @@ -#include <sysdeps/unix/sysv/linux/alpha/readdir_r.c> +#define readdir64_r __no_readdir64_r_decl +#include <sysdeps/unix/readdir_r.c> +#undef readdir64_r +weak_alias (__readdir_r, readdir64_r) diff --git a/sysdeps/unix/sysv/linux/powerpc/Versions b/sysdeps/unix/sysv/linux/powerpc/Versions index 1ea93d7..a2296a9 100644 --- a/sysdeps/unix/sysv/linux/powerpc/Versions +++ b/sysdeps/unix/sysv/linux/powerpc/Versions @@ -9,6 +9,9 @@ libc { # functions used in other libraries __xstat64; __fxstat64; __lxstat64; + # g* + glob64; + # New rlimit interface getrlimit; setrlimit; getrlimit64; setrlimit64; diff --git a/sysdeps/unix/sysv/linux/powerpc/glob64.c b/sysdeps/unix/sysv/linux/powerpc/glob64.c new file mode 100644 index 0000000..82a9a29 --- /dev/null +++ b/sysdeps/unix/sysv/linux/powerpc/glob64.c @@ -0,0 +1 @@ +#include <sysdeps/unix/sysv/linux/i386/glob64.c> diff --git a/sysdeps/unix/sysv/linux/readdir64.c b/sysdeps/unix/sysv/linux/readdir64.c index 9341e3b..fa815e9 100644 --- a/sysdeps/unix/sysv/linux/readdir64.c +++ b/sysdeps/unix/sysv/linux/readdir64.c @@ -4,11 +4,4 @@ #include <sysdeps/unix/readdir.c> -#include <shlib-compat.h> - -versioned_symbol (libc, __readdir64, readdir64, GLIBC_2_2); - -#if SHLIB_COMPAT(libc, GLIBC_2_1, GLIBC_2_2) -strong_alias (__readdir64, __old_readdir64) -compat_symbol (libc, __old_readdir64, readdir64, GLIBC_2_1); -#endif +weak_alias(__readdir64, readdir64) diff --git a/sysdeps/unix/sysv/linux/readdir64_r.c b/sysdeps/unix/sysv/linux/readdir64_r.c index 63a6b80..d63680b 100644 --- a/sysdeps/unix/sysv/linux/readdir64_r.c +++ b/sysdeps/unix/sysv/linux/readdir64_r.c @@ -4,11 +4,4 @@ #include <sysdeps/unix/readdir_r.c> -#include <shlib-compat.h> - -versioned_symbol (libc, __readdir64_r, readdir64_r, GLIBC_2_2); - -#if SHLIB_COMPAT(libc, GLIBC_2_1, GLIBC_2_2) -strong_alias (__readdir64_r, __old_readdir64_r) -compat_symbol (libc, __old_readdir64_r, readdir64_r, GLIBC_2_1); -#endif +weak_alias(__readdir64_r, readdir64_r) diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/Versions b/sysdeps/unix/sysv/linux/sparc/sparc32/Versions index 2448fa2..d7a19f8 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc32/Versions +++ b/sysdeps/unix/sysv/linux/sparc/sparc32/Versions @@ -9,6 +9,9 @@ libc { # functions used in other libraries __xstat64; __fxstat64; __lxstat64; + # g* + glob64; + # r* readdir64; readdir64_r; diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/glob64.c b/sysdeps/unix/sysv/linux/sparc/sparc32/glob64.c new file mode 100644 index 0000000..82a9a29 --- /dev/null +++ b/sysdeps/unix/sysv/linux/sparc/sparc32/glob64.c @@ -0,0 +1 @@ +#include <sysdeps/unix/sysv/linux/i386/glob64.c> diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/readdir.c b/sysdeps/unix/sysv/linux/sparc/sparc64/readdir.c index e64b2f8..300ebb2 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/readdir.c +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/readdir.c @@ -1 +1,7 @@ -#include <sysdeps/unix/sysv/linux/alpha/readdir.c> +#define readdir64 __no_readdir64_decl +#define __readdir64 __no___readdir64_decl +#include <sysdeps/unix/readdir.c> +#undef __readdir64 +strong_alias (__readdir, __readdir64) +#undef readdir64 +weak_alias (__readdir, readdir64) diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/readdir_r.c b/sysdeps/unix/sysv/linux/sparc/sparc64/readdir_r.c index fc5818f..adb92db 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/readdir_r.c +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/readdir_r.c @@ -1 +1,4 @@ -#include <sysdeps/unix/sysv/linux/alpha/readdir_r.c> +#define readdir64_r __no_readdir64_r_decl +#include <sysdeps/unix/readdir_r.c> +#undef readdir64_r +weak_alias (__readdir_r, readdir64_r) |