This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] PR gdb/21070: Build fix for MIPS with musl libc


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]