From: Jakub Jelinek <jakub@redhat.com>
To: Ulrich Drepper <drepper@redhat.com>
Cc: Glibc hackers <libc-hacker@sources.redhat.com>
Subject: [PATCH] ia64 build fixes
Date: Sun, 12 Aug 2007 08:31:00 -0000 [thread overview]
Message-ID: <20070812083711.GI4603@sunsite.mff.cuni.cz> (raw)
Hi!
This was needed to build glibc trunk on ia64. An obvious typo in
lowlevellock.h, missing pthread_rwlock_t changes on many arches and
ia64's bits/sigcontext.h including bits/sigstack.h (which needs size_t).
On all other arches, bits/sigstack.h is only included from signal.h,
after
#define __need_size_t
#include <stddef.h>, but on ia64 it is also included from bits/sigcontext.h
(not a ISO C nor POSIX violation IMHO), which is included from signal.h
(but earlier than the stddef.h include - could be fixed by moving that
stddef.h include earlier) but also from sys/ucontext.h (where we'd need
to add __need_size_t stddef.h include too). In the patch below ia64's
bits/sigcontext.h does that, as it is the only arch that needs this.
2007-08-12 Jakub Jelinek <jakub@redhat.com>
* sysdeps/unix/sysv/linux/ia64/bits/sigcontext.h: Include stddef.h
with __need_size_t.
nptl/
* sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h
[__WORDSIZE=32] (pthread_rwlock_t): Split __flags element into four
byte elements. One of them is the new __shared element.
[__WORDSIZE=64] (pthread_rwlock_t): Renamed __pad1 element to __shared,
adjust names of other padding elements.
* sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h
[__WORDSIZE=32] (pthread_rwlock_t): Split __flags element into four
byte elements. One of them is the new __shared element.
[__WORDSIZE=64] (pthread_rwlock_t): Renamed __pad1 element to __shared,
adjust names of other padding elements.
* sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_rwlock_t):
Renamed __pad1 element to __shared, adjust names of other padding
elements.
* sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
(pthread_rwlock_t): Likewise.
* sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_lock): Fix a
typo.
--- libc/nptl/sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h.jj 2006-02-15 12:14:34.000000000 -0500
+++ libc/nptl/sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h 2007-08-11 13:19:41.000000000 -0400
@@ -1,5 +1,5 @@
/* Machine-specific pthread type layouts. SPARC version.
- Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>, 2003.
@@ -160,9 +160,9 @@ typedef union
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
int __writer;
- int __pad1;
+ int __shared;
+ unsigned long int __pad1;
unsigned long int __pad2;
- unsigned long int __pad3;
/* FLAGS must stay at this position in the structure to maintain
binary compatibility. */
unsigned int __flags;
@@ -176,9 +176,12 @@ typedef union
unsigned int __writer_wakeup;
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
+ unsigned char __pad1;
+ unsigned char __pad2;
+ unsigned char __shared;
/* FLAGS must stay at this position in the structure to maintain
binary compatibility. */
- unsigned int __flags;
+ unsigned char __flags;
int __writer;
} __data;
# endif
--- libc/nptl/sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h.jj 2006-02-15 12:13:30.000000000 -0500
+++ libc/nptl/sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h 2007-08-11 13:14:49.000000000 -0400
@@ -1,4 +1,4 @@
-/* Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>, 2003.
@@ -126,9 +126,9 @@ typedef union
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
int __writer;
- int __pad1;
+ int __shared;
+ unsigned long int __pad1;
unsigned long int __pad2;
- unsigned long int __pad3;
/* FLAGS must stay at this position in the structure to maintain
binary compatibility. */
unsigned int __flags;
--- libc/nptl/sysdeps/unix/sysv/linux/ia64/lowlevellock.h.jj 2007-08-11 10:53:10.000000000 -0400
+++ libc/nptl/sysdeps/unix/sysv/linux/ia64/lowlevellock.h 2007-08-11 12:09:43.000000000 -0400
@@ -154,6 +154,7 @@ extern int __lll_robust_lock_wait (int *
__lll_lock_wait_private (__futex); \
else \
__lll_lock_wait (__futex, private); \
+ } \
}))
#define lll_lock(futex, private) __lll_lock (&(futex), private)
--- libc/nptl/sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h.jj 2006-02-15 12:13:30.000000000 -0500
+++ libc/nptl/sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h 2007-08-11 13:18:18.000000000 -0400
@@ -1,5 +1,5 @@
/* Machine-specific pthread type layouts. Alpha version.
- Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -126,9 +126,9 @@ typedef union
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
int __writer;
- int __pad1;
+ int __shared;
+ unsigned long int __pad1;
unsigned long int __pad2;
- unsigned long int __pad3;
/* FLAGS must stay at this position in the structure to maintain
binary compatibility. */
unsigned int __flags;
--- libc/nptl/sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h.jj 2006-02-15 12:14:33.000000000 -0500
+++ libc/nptl/sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h 2007-08-11 13:17:31.000000000 -0400
@@ -1,4 +1,4 @@
-/* Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Martin Schwidefsky <schwidefsky@de.ibm.com>, 2003.
@@ -159,9 +159,9 @@ typedef union
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
int __writer;
- int __pad1;
+ int __shared;
+ unsigned long int __pad1;
unsigned long int __pad2;
- unsigned long int __pad3;
/* FLAGS must stay at this position in the structure to maintain
binary compatibility. */
unsigned int __flags;
@@ -175,9 +175,12 @@ typedef union
unsigned int __writer_wakeup;
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
+ unsigned char __pad1;
+ unsigned char __pad2;
+ unsigned char __shared;
/* FLAGS must stay at this position in the structure to maintain
binary compatibility. */
- unsigned int __flags;
+ unsigned char __flags;
int __writer;
} __data;
# endif
--- libc/sysdeps/unix/sysv/linux/ia64/bits/sigcontext.h.jj 2004-10-13 22:22:38.000000000 -0400
+++ libc/sysdeps/unix/sysv/linux/ia64/bits/sigcontext.h 2007-08-11 12:50:21.000000000 -0400
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1997, 1998, 2000, 2001, 2003, 2004
+/* Copyright (C) 1996, 1997, 1998, 2000, 2001, 2003, 2004, 2007
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jes Sorensen <jes@linuxcare.com>, July 2000
@@ -25,6 +25,8 @@
#ifndef _BITS_SIGCONTEXT_H
#define _BITS_SIGCONTEXT_H 1
+#define __need_size_t
+#include <stddef.h>
#include <bits/sigstack.h>
struct ia64_fpreg
Jakub
reply other threads:[~2007-08-12 8:31 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070812083711.GI4603@sunsite.mff.cuni.cz \
--to=jakub@redhat.com \
--cc=drepper@redhat.com \
--cc=libc-hacker@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).