summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2014-11-07 01:27:16 +0000
committerJoseph Myers <joseph@codesourcery.com>2014-11-07 01:27:16 +0000
commit2c46a66a3a24e94fbe78151b6a53f15972ef7e2b (patch)
treef785d8ebe76c02bb440f1121b82baab64ff135dd
parenta2887bdb2729e77786a56139d02a6d8cb1290bce (diff)
downloadglibc-2c46a66a3a24e94fbe78151b6a53f15972ef7e2b.tar.gz
Remove __libc_waitpid function name.
Continuing the removal of unused __libc_* function names, this patch removes the __libc_waitpid name. Tested for x86_64 (testsuite, and that disassembly of installed shared libraries is unchanged by the patch; __waitpid, which is exported from shared libc, changes from weak to strong on some configurations, which is of no significance). * include/sys/wait.h (__libc_waitpid): Remove declaration. * posix/waitpid.c (__libc_waitpid): Rename to __waitpid. (__waitpid): Don't define as alias. Use libc_hidden_def not libc_hidden_weak. (waitpid): Define as alias of __waitpid. * sysdeps/unix/bsd/waitpid.c (__libc_waitpid): Rename to __waitpid. (__waitpid): Don't define as alias. Use libc_hidden_def not libc_hidden_weak. (waitpid): Define as alias of __waitpid. * sysdeps/unix/sysv/linux/i386/syscalls.list (waitpid): Remove __libc_waitpid alias. * sysdeps/unix/sysv/linux/m68k/syscalls.list (waitpid): Likewise. * sysdeps/unix/sysv/linux/powerpc/syscalls.list (waitpid): Likewise. * sysdeps/unix/sysv/linux/sh/syscalls.list (waitpid): Likewise. * sysdeps/unix/sysv/linux/sparc/syscalls.list (waitpid): Likewise. * sysdeps/unix/sysv/linux/tile/waitpid.S (__libc_waitpid): Remove alias. * sysdeps/unix/sysv/linux/waitpid.c (__libc_waitpid): Rename to __waitpid. (__waitpid): Don't define as alias. Use libc_hidden_def not libc_hidden_weak. (waitpid): Define as alias of __waitpid.
-rw-r--r--ChangeLog27
-rw-r--r--include/sys/wait.h1
-rw-r--r--posix/waitpid.c7
-rw-r--r--sysdeps/unix/bsd/waitpid.c7
-rw-r--r--sysdeps/unix/sysv/linux/i386/syscalls.list2
-rw-r--r--sysdeps/unix/sysv/linux/m68k/syscalls.list2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/syscalls.list2
-rw-r--r--sysdeps/unix/sysv/linux/sh/syscalls.list2
-rw-r--r--sysdeps/unix/sysv/linux/sparc/syscalls.list2
-rw-r--r--sysdeps/unix/sysv/linux/tile/waitpid.S2
-rw-r--r--sysdeps/unix/sysv/linux/waitpid.c7
11 files changed, 41 insertions, 20 deletions
diff --git a/ChangeLog b/ChangeLog
index 6f3a85f123..a8d9c4996d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,30 @@
+2014-11-07 Joseph Myers <joseph@codesourcery.com>
+
+ * include/sys/wait.h (__libc_waitpid): Remove declaration.
+ * posix/waitpid.c (__libc_waitpid): Rename to __waitpid.
+ (__waitpid): Don't define as alias. Use libc_hidden_def not
+ libc_hidden_weak.
+ (waitpid): Define as alias of __waitpid.
+ * sysdeps/unix/bsd/waitpid.c (__libc_waitpid): Rename to
+ __waitpid.
+ (__waitpid): Don't define as alias. Use libc_hidden_def not
+ libc_hidden_weak.
+ (waitpid): Define as alias of __waitpid.
+ * sysdeps/unix/sysv/linux/i386/syscalls.list (waitpid): Remove
+ __libc_waitpid alias.
+ * sysdeps/unix/sysv/linux/m68k/syscalls.list (waitpid): Likewise.
+ * sysdeps/unix/sysv/linux/powerpc/syscalls.list (waitpid):
+ Likewise.
+ * sysdeps/unix/sysv/linux/sh/syscalls.list (waitpid): Likewise.
+ * sysdeps/unix/sysv/linux/sparc/syscalls.list (waitpid): Likewise.
+ * sysdeps/unix/sysv/linux/tile/waitpid.S (__libc_waitpid): Remove
+ alias.
+ * sysdeps/unix/sysv/linux/waitpid.c (__libc_waitpid): Rename to
+ __waitpid.
+ (__waitpid): Don't define as alias. Use libc_hidden_def not
+ libc_hidden_weak.
+ (waitpid): Define as alias of __waitpid.
+
2014-11-06 Carlos O'Donell <carlos@redhat.com>
* manual/llio.texi: Add comment that write safety has been
diff --git a/include/sys/wait.h b/include/sys/wait.h
index 2239501614..9a38e61be7 100644
--- a/include/sys/wait.h
+++ b/include/sys/wait.h
@@ -8,7 +8,6 @@ extern __pid_t __waitpid (__pid_t __pid, int *__stat_loc,
libc_hidden_proto (__waitpid)
extern int __waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options);
-extern __pid_t __libc_waitpid (pid_t __pid, int *__stat_loc, int __options);
extern __pid_t __libc_wait (int *__stat_loc);
extern __pid_t __wait (__WAIT_STATUS __stat_loc);
extern __pid_t __wait3 (__WAIT_STATUS __stat_loc,
diff --git a/posix/waitpid.c b/posix/waitpid.c
index 68157830b0..54a786fceb 100644
--- a/posix/waitpid.c
+++ b/posix/waitpid.c
@@ -33,7 +33,7 @@
Return (pid_t) -1 for errors. If the WUNTRACED bit is set in OPTIONS,
return status for stopped children; otherwise don't. */
pid_t
-__libc_waitpid (pid_t pid, int *stat_loc, int options)
+__waitpid (pid_t pid, int *stat_loc, int options)
{
if ((options & ~(WNOHANG|WUNTRACED)) != 0)
{
@@ -44,8 +44,7 @@ __libc_waitpid (pid_t pid, int *stat_loc, int options)
__set_errno (ENOSYS);
return (pid_t) -1;
}
-weak_alias (__libc_waitpid, __waitpid)
-libc_hidden_weak (__waitpid)
-weak_alias (__libc_waitpid, waitpid)
+libc_hidden_def (__waitpid)
+weak_alias (__waitpid, waitpid)
stub_warning (waitpid)
diff --git a/sysdeps/unix/bsd/waitpid.c b/sysdeps/unix/bsd/waitpid.c
index 321d97975f..34e758b384 100644
--- a/sysdeps/unix/bsd/waitpid.c
+++ b/sysdeps/unix/bsd/waitpid.c
@@ -33,11 +33,10 @@
Return (pid_t) -1 for errors. If the WUNTRACED bit is set in OPTIONS,
return status for stopped children; otherwise don't. */
pid_t
-__libc_waitpid (pid_t pid, int *stat_loc, int options)
+__waitpid (pid_t pid, int *stat_loc, int options)
{
return __wait4 (pid, (union wait *) stat_loc, options, NULL);
}
-weak_alias (__libc_waitpid, __waitpid)
-libc_hidden_weak (__waitpid)
-weak_alias (__libc_waitpid, waitpid)
+libc_hidden_def (__waitpid)
+weak_alias (__waitpid, waitpid)
diff --git a/sysdeps/unix/sysv/linux/i386/syscalls.list b/sysdeps/unix/sysv/linux/i386/syscalls.list
index 901501a7aa..1cebd6a50f 100644
--- a/sysdeps/unix/sysv/linux/i386/syscalls.list
+++ b/sysdeps/unix/sysv/linux/i386/syscalls.list
@@ -20,7 +20,7 @@ vm86old EXTRA vm86old i:p __vm86old vm86@GLIBC_2.0
vm86 - vm86 i:ip __vm86 vm86@@GLIBC_2.3.4
oldgetrlimit EXTRA getrlimit i:ip __old_getrlimit getrlimit@GLIBC_2.0
setrlimit - setrlimit i:ip __setrlimit setrlimit@GLIBC_2.0 setrlimit@@GLIBC_2.2
-waitpid - waitpid Ci:ipi __waitpid waitpid __libc_waitpid
+waitpid - waitpid Ci:ipi __waitpid waitpid
prlimit64 EXTRA prlimit64 i:iipp prlimit64
diff --git a/sysdeps/unix/sysv/linux/m68k/syscalls.list b/sysdeps/unix/sysv/linux/m68k/syscalls.list
index 6ebca162c1..ad4ca46b50 100644
--- a/sysdeps/unix/sysv/linux/m68k/syscalls.list
+++ b/sysdeps/unix/sysv/linux/m68k/syscalls.list
@@ -3,7 +3,7 @@
chown - chown32 i:sii __chown chown
lchown - lchown32 i:sii __lchown lchown
fchown - fchown32 i:iii __fchown fchown
-waitpid - waitpid Ci:ipi __waitpid waitpid __libc_waitpid
+waitpid - waitpid Ci:ipi __waitpid waitpid
getegid - getegid32 Ei: __getegid getegid
geteuid - geteuid32 Ei: __geteuid geteuid
diff --git a/sysdeps/unix/sysv/linux/powerpc/syscalls.list b/sysdeps/unix/sysv/linux/powerpc/syscalls.list
index a6665936e8..4f821e9b01 100644
--- a/sysdeps/unix/sysv/linux/powerpc/syscalls.list
+++ b/sysdeps/unix/sysv/linux/powerpc/syscalls.list
@@ -1,3 +1,3 @@
# File name Caller Syscall name # args Strong name Weak names
-waitpid - waitpid Ci:ipi __waitpid waitpid __libc_waitpid
+waitpid - waitpid Ci:ipi __waitpid waitpid
diff --git a/sysdeps/unix/sysv/linux/sh/syscalls.list b/sysdeps/unix/sysv/linux/sh/syscalls.list
index 5fd7c9a42f..2f4ac6548d 100644
--- a/sysdeps/unix/sysv/linux/sh/syscalls.list
+++ b/sysdeps/unix/sysv/linux/sh/syscalls.list
@@ -15,7 +15,7 @@ getgroups - getgroups32 i:ip __getgroups getgroups
setfsgid - setfsgid32 Ei:i setfsgid
setfsuid - setfsuid32 Ei:i setfsuid
-waitpid - waitpid Ci:ipi __waitpid waitpid __libc_waitpid
+waitpid - waitpid Ci:ipi __waitpid waitpid
prlimit64 EXTRA prlimit64 i:iipp prlimit64
diff --git a/sysdeps/unix/sysv/linux/sparc/syscalls.list b/sysdeps/unix/sysv/linux/sparc/syscalls.list
index a6665936e8..4f821e9b01 100644
--- a/sysdeps/unix/sysv/linux/sparc/syscalls.list
+++ b/sysdeps/unix/sysv/linux/sparc/syscalls.list
@@ -1,3 +1,3 @@
# File name Caller Syscall name # args Strong name Weak names
-waitpid - waitpid Ci:ipi __waitpid waitpid __libc_waitpid
+waitpid - waitpid Ci:ipi __waitpid waitpid
diff --git a/sysdeps/unix/sysv/linux/tile/waitpid.S b/sysdeps/unix/sysv/linux/tile/waitpid.S
index 9aa793e12b..22642aee41 100644
--- a/sysdeps/unix/sysv/linux/tile/waitpid.S
+++ b/sysdeps/unix/sysv/linux/tile/waitpid.S
@@ -14,7 +14,5 @@ PSEUDO_END(__waitpid)
libc_hidden_def (__waitpid)
weak_alias (__waitpid, waitpid)
libc_hidden_weak (waitpid)
-weak_alias (__waitpid, __libc_waitpid)
-libc_hidden_weak (__libc_waitpid)
#endif
diff --git a/sysdeps/unix/sysv/linux/waitpid.c b/sysdeps/unix/sysv/linux/waitpid.c
index c0a86826fb..cfd7c6d24b 100644
--- a/sysdeps/unix/sysv/linux/waitpid.c
+++ b/sysdeps/unix/sysv/linux/waitpid.c
@@ -21,7 +21,7 @@
#include <sys/wait.h>
__pid_t
-__libc_waitpid (__pid_t pid, int *stat_loc, int options)
+__waitpid (__pid_t pid, int *stat_loc, int options)
{
if (SINGLE_THREAD_P)
{
@@ -44,6 +44,5 @@ __libc_waitpid (__pid_t pid, int *stat_loc, int options)
return result;
}
-weak_alias (__libc_waitpid, __waitpid)
-libc_hidden_weak (__waitpid)
-weak_alias (__libc_waitpid, waitpid)
+libc_hidden_def (__waitpid)
+weak_alias (__waitpid, waitpid)