Ping^2 Re: Fix bits/socket.h IOC* namespace issues (bug 21267)
Joseph Myers
joseph@codesourcery.com
Tue Apr 18 21:29:00 GMT 2017
On Thu, 6 Apr 2017, Adhemerval Zanella wrote:
> On 05/04/2017 12:56, Joseph Myers wrote:
> > Ping^2. This patch
> > <https://sourceware.org/ml/libc-alpha/2017-03/msg00400.html> is still
> > pending review.
> >
>
> The patch itself looks good. However, I think the __SYS_SOCKET_H_undef*
> macro usage is convoluted and complex, couldn't we just copy the kernel
> definition from asm/socket.h and avoid include it on bits/socket.h?
In principle that might make sense. The issues that would need addressing
are:
* Different definitions for different architecture may well require a
separate header, much like bits/socket_type.h.
* Presumably people need to be able to include the glibc headers together
with the uapi headers, but the kernel headers define these macros
unconditionally, meaning that any difference in the text of the definition
(even keeping the same numerical value) would result in a conflict, and
care would be needed to avoid such conflicts along the lines described at
<https://sourceware.org/glibc/wiki/Synchronizing_Headers>.
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Libc-alpha
mailing list