mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

655 lines
24 KiB

  1. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  2. #
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. # Please add additional copyright information _after_ the line containing
  5. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  6. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  7. #
  8. # ROCK Linux: rock-src/package/base/glibc/glibc23/mips-updates-july04.patch.mips
  9. # ROCK Linux is Copyright (C) 1998 - 2005 Clifford Wolf
  10. #
  11. # This patch file is dual-licensed. It is available under the license the
  12. # patched project is licensed under, as long as it is an OpenSource license
  13. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  14. # of the GNU General Public License as published by the Free Software
  15. # Foundation; either version 2 of the License, or (at your option) any later
  16. # version.
  17. #
  18. # --- ROCK-COPYRIGHT-NOTE-END ---
  19. --- ./sysdeps/unix/sysv/linux/mips/Makefile 2003-09-03 05:16:54.000000000 +0200
  20. +++ ./sysdeps/unix/sysv/linux/mips/Makefile 2004-07-20 18:37:41.000000000 +0200
  21. @@ -21,20 +21,25 @@
  22. echo '# error "Never use <bits/syscall.h> directly; include <sys/syscall.h> instead."'; \
  23. echo '#endif'; \
  24. echo ''; \
  25. + echo '#include <sgidefs.h>'; \
  26. rm -f $(@:.d=.h).newt; \
  27. $(CC) -E -MD -MP -MF $(@:.h=.d)-t -MT '$(@:.d=.h) $(@:.h=.d)' \
  28. - -x c -I $(common-objdir) $(sysincludes) $< -D_LIBC -dM | \
  29. + -x c $(+includes) $(sysincludes) $< -D_LIBC -dM | \
  30. sed -n 's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' \
  31. > $(@:.d=.h).newt; \
  32. if grep SYS_O32_ $(@:.d=.h).newt > /dev/null; then \
  33. - echo '#if defined _ABI64 && _MIPS_SIM == _ABI64'; \
  34. - sed -n 's/^\(#define SYS_\)N64_/\1/p' < $(@:.d=.h).newt; \
  35. - echo '#elif defined _ABIN32 && _MIPS_SIM == _ABIN32'; \
  36. - sed -n 's/^\(#define SYS_\)N32_/\1/p' < $(@:.d=.h).newt; \
  37. + echo '#if _MIPS_SIM == _MIPS_SIM_NABI32'; \
  38. + sed -n 's/^\(#define SYS_\)N32_/\1/p' < $(@:.d=.h).newt | \
  39. + LC_ALL=C sort; \
  40. + echo '#elif _MIPS_SIM == _MIPS_SIM_ABI64'; \
  41. + sed -n 's/^\(#define SYS_\)N64_/\1/p' < $(@:.d=.h).newt | \
  42. + LC_ALL=C sort; \
  43. echo '#else'; \
  44. - sed -n 's/^\(#define SYS_\)O32_/\1/p' < $(@:.d=.h).newt; \
  45. + sed -n 's/^\(#define SYS_\)O32_/\1/p' < $(@:.d=.h).newt | \
  46. + LC_ALL=C sort; \
  47. echo '#endif'; \
  48. - sed -n '/^#define SYS_\([ON]32\|N64\)_/p' < $(@:.d=.h).newt; \
  49. + sed -n '/^#define SYS_\([ON]32\|N64\)_/p' < $(@:.d=.h).newt | \
  50. + LC_ALL=C sort +1.8; \
  51. else \
  52. cat $(@:.d=.h).newt; \
  53. fi; \
  54. --- ./sysdeps/unix/sysv/linux/mips/bits/fcntl.h 2003-04-04 07:12:00.000000000 +0200
  55. +++ ./sysdeps/unix/sysv/linux/mips/bits/fcntl.h 2004-07-20 18:35:29.000000000 +0200
  56. @@ -1,5 +1,5 @@
  57. /* O_*, F_*, FD_* bit values for Linux.
  58. - Copyright (C) 1995, 1996, 1997, 1998, 2000, 2002, 2003
  59. + Copyright (C) 1995, 1996, 1997, 1998, 2000, 2002, 2003, 2004
  60. Free Software Foundation, Inc.
  61. This file is part of the GNU C Library.
  62. @@ -23,7 +23,7 @@
  63. #endif
  64. #include <sys/types.h>
  65. -
  66. +#include <sgidefs.h>
  67. /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
  68. located on an ext2 file system */
  69. @@ -81,7 +81,7 @@
  70. #define F_SETLK64 34 /* Set record locking info (non-blocking). */
  71. #define F_SETLKW64 35 /* Set record locking info (blocking). */
  72. -#if defined __USE_BSD || defined __USE_XOPEN2K
  73. +#if defined __USE_BSD || defined __USE_UNIX98
  74. # define F_SETOWN 24 /* Get owner of socket (receiver of SIGIO). */
  75. # define F_GETOWN 23 /* Set owner of socket (receiver of SIGIO). */
  76. #endif
  77. @@ -143,7 +143,7 @@
  78. #ifndef __USE_FILE_OFFSET64
  79. __off_t l_start; /* Offset where the lock begins. */
  80. __off_t l_len; /* Size of the locked area; zero means until EOF. */
  81. -#if ! (defined _ABI64 && _MIPS_SIM == _ABI64)
  82. +#if _MIPS_SIM != _MIPS_SIM_ABI64
  83. /* The 64-bit flock structure, used by the n64 ABI, and for 64-bit
  84. fcntls in o32 and n32, never has this field. */
  85. long int l_sysid;
  86. @@ -153,7 +153,7 @@
  87. __off64_t l_len; /* Size of the locked area; zero means until EOF. */
  88. #endif
  89. __pid_t l_pid; /* Process holding the lock. */
  90. -#if ! defined __USE_FILE_OFFSET64 && ! (defined _ABI64 && _MIPS_SIM == _ABI64)
  91. +#if ! defined __USE_FILE_OFFSET64 && _MIPS_SIM != _MIPS_SIM_ABI64
  92. /* The 64-bit flock structure, used by the n64 ABI, and for 64-bit
  93. flock in o32 and n32, never has this field. */
  94. long int pad[4];
  95. --- ./sysdeps/unix/sysv/linux/mips/bits/sigcontext.h 2003-04-13 13:36:32.000000000 +0200
  96. +++ ./sysdeps/unix/sysv/linux/mips/bits/sigcontext.h 2004-07-20 18:35:29.000000000 +0200
  97. @@ -1,4 +1,4 @@
  98. -/* Copyright (C) 1996, 1997, 1998, 2003 Free Software Foundation, Inc.
  99. +/* Copyright (C) 1996, 1997, 1998, 2003, 2004 Free Software Foundation, Inc.
  100. This file is part of the GNU C Library.
  101. The GNU C Library is free software; you can redistribute it and/or
  102. @@ -20,6 +20,8 @@
  103. # error "Never use <bits/sigcontext.h> directly; include <signal.h> instead."
  104. #endif
  105. +#include <sgidefs.h>
  106. +
  107. #ifndef sigcontext_struct
  108. /* Kernel headers before 2.1.1 define a struct sigcontext_struct, but
  109. we need sigcontext. */
  110. --- ./sysdeps/unix/sysv/linux/mips/bits/stat.h 2003-04-05 21:57:35.000000000 +0200
  111. +++ ./sysdeps/unix/sysv/linux/mips/bits/stat.h 2004-07-20 18:35:28.000000000 +0200
  112. @@ -1,4 +1,4 @@
  113. -/* Copyright (C) 1992, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003
  114. +/* Copyright (C) 1992, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004
  115. Free Software Foundation, Inc.
  116. This file is part of the GNU C Library.
  117. @@ -21,6 +21,8 @@
  118. # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
  119. #endif
  120. +#include <sgidefs.h>
  121. +
  122. /* Versions of the `struct stat' data structure. */
  123. #define _STAT_VER_LINUX_OLD 1
  124. #define _STAT_VER_KERNEL 1
  125. --- ./sysdeps/unix/sysv/linux/mips/configure 2003-03-28 07:11:03.000000000 +0100
  126. +++ ./sysdeps/unix/sysv/linux/mips/configure 2004-07-20 18:35:29.000000000 +0200
  127. @@ -30,6 +30,7 @@
  128. -e 's,__NR_N64_N32_,__NR_N32_,g' \
  129. -e 's,__NR_N64_N64_,__NR_N64_,g' \
  130. | awk > asm-unistd.h '
  131. +BEGIN { print "#include <sgidefs.h>"; }
  132. /^#define __NR.*unused/ { print; next; }
  133. /^#define __NR_N64__exit __NR_N64_exit/ {
  134. print "#define __NR__exit __NR_exit";
  135. @@ -50,7 +51,7 @@
  136. name = $2;
  137. sub (/_N32_/, "_", name);
  138. print;
  139. - print "#if defined _ABIN32 && _MIPS_SIM == _ABIN32";
  140. + print "#if _MIPS_SIM == _MIPS_SIM_NABI32";
  141. print "# define " name " " $2;
  142. print "#endif";
  143. next;
  144. @@ -59,7 +60,7 @@
  145. name = $2;
  146. sub (/_N64_/, "_", name);
  147. print;
  148. - print "#if defined _ABI64 && _MIPS_SIM == _ABI64";
  149. + print "#if _MIPS_SIM == _MIPS_SIM_ABI64";
  150. print "# define " name " " $2;
  151. print "#endif";
  152. next;
  153. --- ./sysdeps/unix/sysv/linux/mips/configure.in 2003-03-17 16:50:05.000000000 +0100
  154. +++ ./sysdeps/unix/sysv/linux/mips/configure.in 2004-07-20 18:35:29.000000000 +0200
  155. @@ -30,6 +30,7 @@
  156. -e 's,__NR_N64_N32_,__NR_N32_,g' \
  157. -e 's,__NR_N64_N64_,__NR_N64_,g' \
  158. | awk > asm-unistd.h '
  159. +BEGIN { print "#include <sgidefs.h>"; }
  160. /^#define __NR.*unused/ { print; next; }
  161. /^#define __NR_N64__exit __NR_N64_exit/ {
  162. print "#define __NR__exit __NR_exit";
  163. @@ -50,7 +51,7 @@
  164. name = $2;
  165. sub (/_N32_/, "_", name);
  166. print;
  167. - print "#if defined _ABIN32 && _MIPS_SIM == _ABIN32";
  168. + print "#if _MIPS_SIM == _MIPS_SIM_NABI32";
  169. print "# define " name " " $2;
  170. print "#endif";
  171. next;
  172. @@ -59,7 +60,7 @@
  173. name = $2;
  174. sub (/_N64_/, "_", name);
  175. print;
  176. - print "#if defined _ABI64 && _MIPS_SIM == _ABI64";
  177. + print "#if _MIPS_SIM == _MIPS_SIM_ABI64";
  178. print "# define " name " " $2;
  179. print "#endif";
  180. next;
  181. --- ./sysdeps/unix/sysv/linux/mips/kernel_stat.h 2003-04-05 21:57:35.000000000 +0200
  182. +++ ./sysdeps/unix/sysv/linux/mips/kernel_stat.h 2004-07-20 18:35:29.000000000 +0200
  183. @@ -1,3 +1,4 @@
  184. +#include <sgidefs.h>
  185. /* As tempting as it is to define XSTAT_IS_XSTAT64 for n64, the
  186. userland data structures are not identical, because of different
  187. padding. */
  188. --- ./sysdeps/unix/sysv/linux/mips/mips64/syscalls.list 2003-09-03 05:16:25.000000000 +0200
  189. +++ ./sysdeps/unix/sysv/linux/mips/mips64/syscalls.list 2004-07-21 08:13:15.000000000 +0200
  190. @@ -16,5 +16,6 @@
  191. shmdt - shmdt i:s __shmdt shmdt
  192. shmget - shmget i:iii __shmget shmget
  193. semop - semop i:ipi __semop semop
  194. +semtimedop - semtimedop i:ipip semtimedop
  195. semget - semget i:iii __semget semget
  196. semctl - semctl i:iiii __semctl semctl
  197. --- ./sysdeps/unix/sysv/linux/mips/pread.c 2003-09-11 01:38:52.000000000 +0200
  198. +++ ./sysdeps/unix/sysv/linux/mips/pread.c 2004-07-20 18:35:29.000000000 +0200
  199. @@ -1,4 +1,5 @@
  200. -/* Copyright (C) 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
  201. +/* Copyright (C) 1997, 1998, 2000, 2002, 2003, 2004
  202. + Free Software Foundation, Inc.
  203. This file is part of the GNU C Library.
  204. Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
  205. @@ -27,6 +28,7 @@
  206. #include <bp-checks.h>
  207. #include <kernel-features.h>
  208. +#include <sgidefs.h>
  209. #ifdef __NR_pread64 /* Newer kernels renamed but it's the same. */
  210. # ifdef __NR_pread
  211. @@ -51,14 +53,14 @@
  212. {
  213. ssize_t result;
  214. -#if (defined _ABI64 && _MIPS_SIM != _ABI64)
  215. +#if _MIPS_SIM != _MIPS_SIM_ABI64
  216. assert (sizeof (offset) == 4);
  217. #endif
  218. if (SINGLE_THREAD_P)
  219. {
  220. /* First try the syscall. */
  221. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  222. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  223. result = INLINE_SYSCALL (pread, 4, fd, CHECK_N (buf, count), count,
  224. offset);
  225. #else
  226. @@ -76,7 +78,7 @@
  227. int oldtype = LIBC_CANCEL_ASYNC ();
  228. /* First try the syscall. */
  229. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  230. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM_ABI64
  231. result = INLINE_SYSCALL (pread, 4, fd, CHECK_N (buf, count), count, offset);
  232. #else
  233. result = INLINE_SYSCALL (pread, 6, fd, CHECK_N (buf, count), count, 0,
  234. --- ./sysdeps/unix/sysv/linux/mips/pread64.c 2003-09-11 01:38:52.000000000 +0200
  235. +++ ./sysdeps/unix/sysv/linux/mips/pread64.c 2004-07-20 18:35:29.000000000 +0200
  236. @@ -1,4 +1,5 @@
  237. -/* Copyright (C) 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
  238. +/* Copyright (C) 1997, 1998, 2000, 2002, 2003, 2004
  239. + Free Software Foundation, Inc.
  240. This file is part of the GNU C Library.
  241. Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
  242. @@ -26,6 +27,7 @@
  243. #include <bp-checks.h>
  244. #include <kernel-features.h>
  245. +#include <sgidefs.h>
  246. #ifdef __NR_pread64 /* Newer kernels renamed but it's the same. */
  247. # ifdef __NR_pread
  248. @@ -54,7 +56,7 @@
  249. if (SINGLE_THREAD_P)
  250. {
  251. /* First try the syscall. */
  252. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  253. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  254. result = INLINE_SYSCALL (pread, 4, fd, CHECK_N (buf, count), count,
  255. offset);
  256. #else
  257. @@ -73,7 +75,7 @@
  258. int oldtype = LIBC_CANCEL_ASYNC ();
  259. /* First try the syscall. */
  260. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  261. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  262. result = INLINE_SYSCALL (pread, 4, fd, CHECK_N (buf, count), count, offset);
  263. #else
  264. result = INLINE_SYSCALL (pread, 6, fd, CHECK_N (buf, count), count, 0,
  265. --- ./sysdeps/unix/sysv/linux/mips/ptrace.c 2003-09-03 05:21:27.000000000 +0200
  266. +++ ./sysdeps/unix/sysv/linux/mips/ptrace.c 2004-07-20 18:35:29.000000000 +0200
  267. @@ -1,4 +1,4 @@
  268. -/* Copyright (C) 1995, 1996, 1997, 1998, 2000, 2002, 2003
  269. +/* Copyright (C) 1995, 1996, 1997, 1998, 2000, 2002, 2003, 2004
  270. Free Software Foundation, Inc.
  271. This file is part of the GNU C Library.
  272. @@ -26,8 +26,9 @@
  273. #include <sysdep.h>
  274. #include <sys/syscall.h>
  275. #include <bp-checks.h>
  276. +#include <sgidefs.h>
  277. -#if defined _ABIN32 && _MIPS_SIM == _ABIN32
  278. +#if _MIPS_SIM == _MIPS_SIM_NABI32
  279. __extension__ typedef long long int reg_type;
  280. #else
  281. typedef long int reg_type;
  282. --- ./sysdeps/unix/sysv/linux/mips/pwrite.c 2003-09-11 01:38:52.000000000 +0200
  283. +++ ./sysdeps/unix/sysv/linux/mips/pwrite.c 2004-07-20 18:35:29.000000000 +0200
  284. @@ -1,4 +1,5 @@
  285. -/* Copyright (C) 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
  286. +/* Copyright (C) 1997, 1998, 2000, 2002, 2003, 2004
  287. + Free Software Foundation, Inc.
  288. This file is part of the GNU C Library.
  289. Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
  290. @@ -27,6 +28,7 @@
  291. #include <bp-checks.h>
  292. #include <kernel-features.h>
  293. +#include <sgidefs.h>
  294. #ifdef __NR_pwrite64 /* Newer kernels renamed but it's the same. */
  295. # ifdef __NR_pwrite
  296. @@ -51,14 +53,14 @@
  297. {
  298. ssize_t result;
  299. -#if (defined _ABI64 && _MIPS_SIM != _ABI64)
  300. +#if _MIPS_SIM == _MIPS_SIM_ABI64
  301. assert (sizeof (offset) == 4);
  302. #endif
  303. if (SINGLE_THREAD_P)
  304. {
  305. /* First try the syscall. */
  306. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  307. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  308. result = INLINE_SYSCALL (pwrite, 4, fd, CHECK_N (buf, count), count,
  309. offset);
  310. #else
  311. @@ -76,7 +78,7 @@
  312. int oldtype = LIBC_CANCEL_ASYNC ();
  313. /* First try the syscall. */
  314. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  315. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  316. result = INLINE_SYSCALL (pwrite, 4, fd, CHECK_N (buf, count), count, offset);
  317. #else
  318. result = INLINE_SYSCALL (pwrite, 6, fd, CHECK_N (buf, count), count, 0,
  319. --- ./sysdeps/unix/sysv/linux/mips/pwrite64.c 2003-09-11 01:38:52.000000000 +0200
  320. +++ ./sysdeps/unix/sysv/linux/mips/pwrite64.c 2004-07-20 18:35:29.000000000 +0200
  321. @@ -1,4 +1,5 @@
  322. -/* Copyright (C) 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
  323. +/* Copyright (C) 1997, 1998, 2000, 2002, 2003, 2004
  324. + Free Software Foundation, Inc.
  325. This file is part of the GNU C Library.
  326. Contributed by Ralf Baechle <ralf@gnu.org>, 1998.
  327. @@ -53,7 +54,7 @@
  328. if (SINGLE_THREAD_P)
  329. {
  330. /* First try the syscall. */
  331. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  332. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  333. result = INLINE_SYSCALL (pwrite, 4, fd, CHECK_N (buf, count), count,
  334. offset);
  335. #else
  336. @@ -73,7 +74,7 @@
  337. int oldtype = LIBC_CANCEL_ASYNC ();
  338. /* First try the syscall. */
  339. -#if (defined _ABIN32 && _MIPS_SIM == _ABIN32) || (defined _ABI64 && _MIPS_SIM == _ABI64)
  340. +#if _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64
  341. result = INLINE_SYSCALL (pwrite, 4, fd, CHECK_N (buf, count), count, offset);
  342. #else
  343. result = INLINE_SYSCALL (pwrite, 6, fd, CHECK_N (buf, count), count, 0,
  344. --- ./sysdeps/unix/sysv/linux/mips/sigaction.c 2003-09-03 05:21:27.000000000 +0200
  345. +++ ./sysdeps/unix/sysv/linux/mips/sigaction.c 2004-07-20 18:35:29.000000000 +0200
  346. @@ -1,4 +1,5 @@
  347. -/* Copyright (C) 1997,1998,1999,2000,2002,2003 Free Software Foundation, Inc.
  348. +/* Copyright (C) 1997,1998,1999,2000,2002,2003, 2004
  349. + Free Software Foundation, Inc.
  350. This file is part of the GNU C Library.
  351. The GNU C Library is free software; you can redistribute it and/or
  352. @@ -23,6 +24,8 @@
  353. #include <sysdep.h>
  354. #include <sys/syscall.h>
  355. +#include <sgidefs.h>
  356. +
  357. #include "kernel-features.h"
  358. /* The difference here is that the sigaction structure used in the
  359. --- ./sysdeps/unix/sysv/linux/mips/sigcontextinfo.h 2003-04-13 13:36:32.000000000 +0200
  360. +++ ./sysdeps/unix/sysv/linux/mips/sigcontextinfo.h 2004-07-20 18:35:29.000000000 +0200
  361. @@ -1,4 +1,4 @@
  362. -/* Copyright (C) 2000, 2001, 2003 Free Software Foundation, Inc.
  363. +/* Copyright (C) 2000, 2001, 2003, 2004 Free Software Foundation, Inc.
  364. This file is part of the GNU C Library.
  365. Contributed by Andreas Jaeger <aj@suse.de>, 2000.
  366. @@ -18,6 +18,8 @@
  367. 02111-1307 USA. */
  368. +#include <sgidefs.h>
  369. +
  370. #if _MIPS_SIM == _MIPS_SIM_ABI32
  371. #define SIGCONTEXT unsigned long _code, struct sigcontext *
  372. --- ./sysdeps/unix/sysv/linux/mips/sys/procfs.h 2003-03-17 16:47:13.000000000 +0100
  373. +++ ./sysdeps/unix/sysv/linux/mips/sys/procfs.h 2004-07-20 18:35:28.000000000 +0200
  374. @@ -1,4 +1,4 @@
  375. -/* Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003
  376. +/* Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004
  377. Free Software Foundation, Inc.
  378. This file is part of the GNU C Library.
  379. @@ -28,12 +28,13 @@
  380. #include <sys/time.h>
  381. #include <sys/types.h>
  382. #include <sys/user.h>
  383. +#include <sgidefs.h>
  384. /* ELF register definitions */
  385. #define ELF_NGREG 45
  386. #define ELF_NFPREG 33
  387. -#if defined _ABIN32 && _MIPS_SIM == _ABIN32
  388. +#if _MIPS_SIM == _MIPS_SIM_NABI32
  389. __extension__ typedef unsigned long long elf_greg_t;
  390. #else
  391. typedef unsigned long elf_greg_t;
  392. @@ -64,7 +65,7 @@
  393. {
  394. struct elf_siginfo pr_info; /* Info associated with signal. */
  395. short int pr_cursig; /* Current signal. */
  396. -#if defined _ABIN32 && _MIPS_SIM == _ABIN32
  397. +#if _MIPS_SIM == _MIPS_SIM_NABI32
  398. __extension__ unsigned long long int pr_sigpend;
  399. __extension__ unsigned long long int pr_sighold;
  400. #else
  401. @@ -92,7 +93,7 @@
  402. char pr_sname; /* Char for pr_state. */
  403. char pr_zomb; /* Zombie. */
  404. char pr_nice; /* Nice val. */
  405. -#if defined _ABIN32 && _MIPS_SIM == _ABIN32
  406. +#if _MIPS_SIM == _MIPS_SIM_NABI32
  407. __extension__ unsigned long long int pr_flag;
  408. #else
  409. unsigned long int pr_flag; /* Flags. */
  410. --- ./sysdeps/unix/sysv/linux/mips/sys/ptrace.h 2003-03-17 16:48:52.000000000 +0100
  411. +++ ./sysdeps/unix/sysv/linux/mips/sys/ptrace.h 2004-07-20 18:35:28.000000000 +0200
  412. @@ -1,5 +1,5 @@
  413. /* `ptrace' debugger support interface. Linux version.
  414. - Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003
  415. + Copyright (C) 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004
  416. Free Software Foundation, Inc.
  417. This file is part of the GNU C Library.
  418. @@ -22,6 +22,7 @@
  419. #define _SYS_PTRACE_H 1
  420. #include <features.h>
  421. +#include <sgidefs.h>
  422. __BEGIN_DECLS
  423. @@ -123,7 +124,7 @@
  424. appear (those that are used for the particular request) as:
  425. pid_t PID, void *ADDR, int DATA, void *ADDR2
  426. after REQUEST. */
  427. -#if defined _ABIN32 && _MIPS_SIM == _ABIN32
  428. +#if _MIPS_SIM == _MIPS_SIM_NABI32
  429. __extension__ extern long long int ptrace
  430. (enum __ptrace_request __request, ...) __THROW;
  431. #else
  432. --- ./sysdeps/unix/sysv/linux/mips/sys/tas.h 2003-03-14 08:03:36.000000000 +0100
  433. +++ ./sysdeps/unix/sysv/linux/mips/sys/tas.h 2004-07-20 18:35:28.000000000 +0200
  434. @@ -1,4 +1,4 @@
  435. -/* Copyright (C) 2000, 2002, 2003 Free Software Foundation, Inc.
  436. +/* Copyright (C) 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
  437. This file is part of the GNU C Library.
  438. Contributed by Maciej W. Rozycki <macro@ds2.pg.gda.pl>, 2000.
  439. @@ -22,6 +22,8 @@
  440. #include <features.h>
  441. +#include <sgidefs.h>
  442. +
  443. __BEGIN_DECLS
  444. extern int _test_and_set (int *p, int v) __THROW;
  445. --- ./sysdeps/unix/sysv/linux/mips/sys/ucontext.h 2003-05-01 01:22:09.000000000 +0200
  446. +++ ./sysdeps/unix/sysv/linux/mips/sys/ucontext.h 2004-07-20 18:35:28.000000000 +0200
  447. @@ -1,4 +1,4 @@
  448. -/* Copyright (C) 1997, 1998, 2000, 2003 Free Software Foundation, Inc.
  449. +/* Copyright (C) 1997, 1998, 2000, 2003, 2004 Free Software Foundation, Inc.
  450. This file is part of the GNU C Library.
  451. The GNU C Library is free software; you can redistribute it and/or
  452. @@ -28,6 +28,7 @@
  453. included in <signal.h>. */
  454. #include <bits/sigcontext.h>
  455. +#include <sgidefs.h>
  456. /* Type for general register. Even in o32 we assume 64-bit registers,
  457. like the kernel. */
  458. --- ./sysdeps/unix/sysv/linux/mips/sys/user.h 2003-04-13 13:36:32.000000000 +0200
  459. +++ ./sysdeps/unix/sysv/linux/mips/sys/user.h 2004-07-20 18:35:28.000000000 +0200
  460. @@ -1,4 +1,4 @@
  461. -/* Copyright (C) 2002, 2003 Free Software Foundation, Inc.
  462. +/* Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.
  463. This file is part of the GNU C Library.
  464. The GNU C Library is free software; you can redistribute it and/or
  465. @@ -19,6 +19,8 @@
  466. #ifndef _SYS_USER_H
  467. #define _SYS_USER_H 1
  468. +#include <sgidefs.h>
  469. +
  470. /* The whole purpose of this file is for GDB and GDB only. Don't read
  471. too much into it. Don't use it for anything other than GDB unless
  472. you know what you are doing. */
  473. --- libc/sysdeps/mips/machine-gmon.h 2003/03/17 15:53:37 1.7
  474. +++ libc/sysdeps/mips/machine-gmon.h 2004/07/20 16:35:31 1.8
  475. @@ -18,6 +18,8 @@
  476. Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
  477. 02111-1307 USA. */
  478. +#include <sgidefs.h>
  479. +
  480. #define _MCOUNT_DECL(frompc,selfpc) \
  481. static void __attribute_used__ __mcount (u_long frompc, u_long selfpc)
  482. @@ -81,10 +83,10 @@
  483. # define CPRETURN
  484. #endif
  485. -#if defined _ABIN32 && _MIPS_SIM == _ABIN32
  486. +#if _MIPS_SIM == _MIPS_SIM_NABI32
  487. # define PTR_ADDU_STRING "add" /* no u */
  488. # define PTR_SUBU_STRING "sub" /* no u */
  489. -#elif defined _ABI64 && _MIPS_SIM == _ABI64
  490. +#elif _MIPS_SIM == _MIPS_SIM_ABI64
  491. # define PTR_ADDU_STRING "daddu"
  492. # define PTR_SUBU_STRING "dsubu"
  493. #else
  494. --- ./sysdeps/mips/atomicity.h.orig 2004-07-30 19:08:54.638252096 +0200
  495. +++ ./sysdeps/mips/atomicity.h 2004-07-30 19:10:20.967128112 +0200
  496. @@ -21,6 +21,7 @@
  497. #define _MIPS_ATOMICITY_H 1
  498. #include <inttypes.h>
  499. +#include <sgidefs.h>
  500. static inline int
  501. __attribute__ ((unused))
  502. @@ -85,7 +86,7 @@
  503. #if _MIPS_SIM == _MIPS_SIM_ABI32
  504. ".set mips2\n\t"
  505. #endif
  506. -#if defined _ABI64 && _MIPS_SIM == _ABI64
  507. +#if _MIPS_SIM == _MIPS_SIM_ABI64
  508. "lld %1,%5\n\t"
  509. #else
  510. "ll %1,%5\n\t"
  511. @@ -93,7 +94,7 @@
  512. "move %0,$0\n\t"
  513. "bne %1,%3,2f\n\t"
  514. "move %0,%4\n\t"
  515. -#if defined _ABI64 && _MIPS_SIM == _ABI64
  516. +#if _MIPS_SIM == _MIPS_SIM_ABI64
  517. "scd %0,%2\n\t"
  518. #else
  519. "sc %0,%2\n\t"
  520. --- ./sysdeps/mips/dl-machine.h 2004/04/15 14:08:16 1.71
  521. +++ ./sysdeps/mips/dl-machine.h 2004/07/20 16:35:32 1.74
  522. @@ -130,7 +130,7 @@
  523. }
  524. /* The MSB of got[1] of a gnu object is set to identify gnu objects. */
  525. -#if defined _ABI64 && _MIPS_SIM == _ABI64
  526. +#if _MIPS_SIM == _MIPS_SIM_ABI64
  527. # define ELF_MIPS_GNU_GOT1_MASK 0x8000000000000000L
  528. #else
  529. # define ELF_MIPS_GNU_GOT1_MASK 0x80000000L
  530. @@ -254,7 +254,7 @@
  531. }
  532. }
  533. - INTUSE (_dl_signal_error) (0, NULL, NULL, "cannot find runtime link map");
  534. + _dl_signal_error (0, NULL, NULL, "cannot find runtime link map");
  535. return NULL;
  536. }
  537. @@ -281,26 +281,30 @@
  538. #else /* _MIPS_SIM == _MIPS_SIM_NABI32 || _MIPS_SIM == _MIPS_SIM_ABI64 */
  539. -#define ELF_DL_FRAME_SIZE 64
  540. +#define ELF_DL_FRAME_SIZE 80
  541. #define ELF_DL_SAVE_ARG_REGS "\
  542. - sd $15, 56($29)\n \
  543. + sd $15, 72($29)\n \
  544. sd $4, 8($29)\n \
  545. sd $5, 16($29)\n \
  546. sd $6, 24($29)\n \
  547. sd $7, 32($29)\n \
  548. sd $8, 40($29)\n \
  549. sd $9, 48($29)\n \
  550. + sd $10, 56($29)\n \
  551. + sd $11, 64($29)\n \
  552. "
  553. #define ELF_DL_RESTORE_ARG_REGS "\
  554. - ld $31, 56($29)\n \
  555. + ld $31, 72($29)\n \
  556. ld $4, 8($29)\n \
  557. ld $5, 16($29)\n \
  558. ld $6, 24($29)\n \
  559. ld $7, 32($29)\n \
  560. ld $8, 40($29)\n \
  561. ld $9, 48($29)\n \
  562. + ld $10, 56($29)\n \
  563. + ld $11, 64($29)\n \
  564. "
  565. #define IFABIO32(X)
  566. @@ -362,17 +366,17 @@
  567. \
  568. if (version->hash != 0) \
  569. { \
  570. - value = _dl_lookup_versioned_symbol(strtab + sym->st_name, l, \
  571. - &sym, l->l_scope, version,\
  572. - ELF_RTYPE_CLASS_PLT, 0); \
  573. + value = _dl_lookup_symbol_x (strtab + sym->st_name, l, \
  574. + &sym, l->l_scope, version, \
  575. + ELF_RTYPE_CLASS_PLT, 0, 0); \
  576. break; \
  577. } \
  578. /* Fall through. */ \
  579. } \
  580. case 0: \
  581. - value = _dl_lookup_symbol (strtab + sym->st_name, l, &sym, \
  582. - l->l_scope, ELF_RTYPE_CLASS_PLT, \
  583. - DL_LOOKUP_ADD_DEPENDENCY); \
  584. + value = _dl_lookup_symbol_x (strtab + sym->st_name, l, &sym, \
  585. + l->l_scope, 0, ELF_RTYPE_CLASS_PLT, \
  586. + DL_LOOKUP_ADD_DEPENDENCY, 0); \
  587. } \
  588. \
  589. /* Currently value contains the base load address of the object \