binutils/binutils: do not fwd declare struct stat (2.22).
For canadian cross to host i686-mingw32 fwd declaring
struct stat is not possible.
Instead #include <sys/stat.h>
Signed-off-by: Titus von Boxberg <titus@v9g.de>
Message-Id: <417a15d4277913841ddd.1353100974@tschetwerikow.boxberg.lan>
Patchwork-Id: 199733
1 we kind of screwed ourselves into a corner by having the clock symbols
2 exported only with the glibc-2.0 version ... this patch fixes the
3 export so all new binaries built against librt will use the correct
4 glibc-2.2 symbol version
6 one day, we'll just drop this on the floor (maybe after 2006.1)
8 diff -durN glibc-2.10.1.orig/Versions.def glibc-2.10.1/Versions.def
9 --- glibc-2.10.1.orig/Versions.def 2008-12-03 05:19:06.000000000 +0100
10 +++ glibc-2.10.1/Versions.def 2009-11-13 00:51:27.000000000 +0100
19 diff -durN glibc-2.10.1.orig/glibc-ports-2.10.1/sysdeps/unix/sysv/linux/mips/Versions glibc-2.10.1/glibc-ports-2.10.1/sysdeps/unix/sysv/linux/mips/Versions
20 --- glibc-2.10.1.orig/glibc-ports-2.10.1/sysdeps/unix/sysv/linux/mips/Versions 2009-05-16 10:36:20.000000000 +0200
21 +++ glibc-2.10.1/glibc-ports-2.10.1/sysdeps/unix/sysv/linux/mips/Versions 2009-11-13 00:51:27.000000000 +0100
29 + clock_gettime; clock_settime;
32 diff -durN glibc-2.10.1.orig/ports/sysdeps/unix/sysv/linux/mips/Versions glibc-2.10.1/ports/sysdeps/unix/sysv/linux/mips/Versions
33 diff -durN glibc-2.10.1.orig/sysdeps/unix/clock_gettime.c glibc-2.10.1/sysdeps/unix/clock_gettime.c
34 --- glibc-2.10.1.orig/sysdeps/unix/clock_gettime.c 2007-07-28 22:36:04.000000000 +0200
35 +++ glibc-2.10.1/sysdeps/unix/clock_gettime.c 2009-11-13 00:51:27.000000000 +0100
38 #include <libc-internal.h>
40 +#include <shlib-compat.h>
46 /* Get current value of CLOCK and store it in TP. */
48 -clock_gettime (clockid_t clock_id, struct timespec *tp)
49 +__clock_gettime (clockid_t clock_id, struct timespec *tp)
57 -librt_hidden_def (clock_gettime)
58 +versioned_symbol (librt, __clock_gettime, clock_gettime, GLIBC_2_2);
59 +librt_hidden_ver (__clock_gettime, clock_gettime)
61 +#if defined __mips__ && defined SHARED
62 +strong_alias (__clock_gettime, __mips_clock_gettime)
63 +compat_symbol (librt, __mips_clock_gettime, clock_gettime, GLIBC_2_0);
65 diff -durN glibc-2.10.1.orig/sysdeps/unix/clock_settime.c glibc-2.10.1/sysdeps/unix/clock_settime.c
66 --- glibc-2.10.1.orig/sysdeps/unix/clock_settime.c 2007-08-14 05:19:33.000000000 +0200
67 +++ glibc-2.10.1/sysdeps/unix/clock_settime.c 2009-11-13 00:51:27.000000000 +0100
70 #include <libc-internal.h>
72 +#include <shlib-compat.h>
75 #if HP_TIMING_AVAIL && !defined HANDLED_CPUTIME
78 /* Set CLOCK to value TP. */
80 -clock_settime (clockid_t clock_id, const struct timespec *tp)
81 +__clock_settime (clockid_t clock_id, const struct timespec *tp)
89 +versioned_symbol (librt, __clock_settime, clock_settime, GLIBC_2_2);
91 +#if defined __mips__ && defined SHARED
92 +strong_alias (__clock_settime, __mips_clock_settime)
93 +compat_symbol (librt, __mips_clock_settime, clock_settime, GLIBC_2_0);