This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH roland/waitpid] Fix __waitpid_nocancel link error
- From: Steve Ellcey <sellcey at mips dot com>
- To: Roland McGrath <roland at hack dot frob dot com>
- Cc: "GNU C. Library" <libc-alpha at sourceware dot org>
- Date: Fri, 16 May 2014 14:28:05 -0700
- Subject: Re: [PATCH roland/waitpid] Fix __waitpid_nocancel link error
- Authentication-results: sourceware.org; auth=none
- References: <Pine dot LNX dot 4 dot 64 dot 1405142105400 dot 21615 at digraph dot polyomino dot org dot uk> <1400252942 dot 30618 dot 8 dot camel at ubuntu-sellcey> <20140516182541 dot 5F4852C3A49 at topped-with-meat dot com> <1400272711 dot 30618 dot 15 dot camel at ubuntu-sellcey> <20140516210218 dot 8081E2C3A81 at topped-with-meat dot com>
On Fri, 2014-05-16 at 14:02 -0700, Roland McGrath wrote:
>
> This is unrelated to fork. It is due to my not-cancel.h change.
> I think the following patch will fix it. Can you verify that?
> (You can just use 'git checkout roland/waitpid' if you are otherwise
> using unmodified trunk.)
>
>
> Thanks,
> Roland
>
>
> * sysdeps/unix/sysv/linux/not-cancel.h (waitpid_not_cancel):
> Use wait4 regardless of [__NR_waitpid].
>
> --- a/sysdeps/unix/sysv/linux/not-cancel.h
> +++ b/sysdeps/unix/sysv/linux/not-cancel.h
> @@ -83,13 +83,8 @@ extern int __openat64_nocancel (int fd, const char *fname, int oflag,
> __fcntl_nocancel (fd, cmd, val)
>
> /* Uncancelable waitpid. */
> -#ifdef __NR_waitpid
> -# define waitpid_not_cancel(pid, stat_loc, options) \
> - __waitpid_nocancel (pid, stat_loc, options)
> -#else
> -# define waitpid_not_cancel(pid, stat_loc, options) \
> +#define waitpid_not_cancel(pid, stat_loc, options) \
> INLINE_SYSCALL (wait4, 4, pid, stat_loc, options, NULL)
> -#endif
>
> /* Uncancelable pause. */
> #define pause_not_cancel() \
I applied this patch and my MIPS build worked.
Steve Ellcey
sellcey@mips.com