This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] PR gdb/21070: Build fix for MIPS with musl libc
- From: Simon Marchi <simon dot marchi at ericsson dot com>
- To: Alexey Neyman <stilor at att dot net>
- Cc: <gdb-patches at sourceware dot org>, Andre McCurdy <armccurdy at gmail dot com>
- Date: Mon, 23 Jan 2017 16:31:00 +0100
- Subject: Re: [PATCH] PR gdb/21070: Build fix for MIPS with musl libc
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=none (sender IP is ) smtp.mailfrom=simon dot marchi at ericsson dot com;
- References: <a0d26238-320e-aa4d-8f85-1fdb2ebd8863@att.net>
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
On 01/21/17 07:12, Alexey Neyman wrote:
Hi,
This issue has been reported in crosstool-ng; the patch is from
OpenEmbedded. Quoting the description from the patch:
[[[[
The MIPS specific header <sgidefs.h> is provided by glibc and uclibc
but not by musl. Regardless of the libc, the kernel headers provide
<asm/sgidefs.h> which provides the same definitions, so use that
instead.
]]]]
I am not the original developer, but the patch appears to be properly
signed-off. I just edited the commit message to conform to submission
guidelines.
Regards,
Alexey.
Hi Alexey and Andre,
This is the sgidefs.h from glibc:
https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/mips/sgidefs.h;hb=HEAD
And this is asm/sgidefs.h from the kernel:
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/mips/include/uapi/asm/sgidefs.h
I wonder what is the history about why the glibc version undoes
everything the kernel version defines. Today they seem very similar.
However, tthere are some defines in the glibc on that are not in the
kernel one. In particular, _ABIO32 is not defined by the kernel but is
used by GDB:
mips-linux-nat.c
456: if (_MIPS_SIM == _ABIO32)
Does it cause a problem?
Simon