This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/23404] New: [mips] sys/ioctl.h must be included before sys/socket.h
- From: "syq at debian dot org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Wed, 11 Jul 2018 21:13:07 +0000
- Subject: [Bug libc/23404] New: [mips] sys/ioctl.h must be included before sys/socket.h
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=23404
Bug ID: 23404
Summary: [mips] sys/ioctl.h must be included before
sys/socket.h
Product: glibc
Version: unspecified
Status: NEW
Severity: critical
Priority: P2
Component: libc
Assignee: unassigned at sourceware dot org
Reporter: syq at debian dot org
CC: drepper.fsp at gmail dot com
Target Milestone: ---
This problem is caused by:
https://sourceware.org/bugzilla/show_bug.cgi?id=21267
1. /usr/include/mips64el-linux-gnuabi64/sys/socket.h
Includes
bits/socket.h
2. In bits/socket.h, it detect IOC_IN is not defined, and define
__SYS_SOCKET_H_undef_IOC_IN
First, and then
#include <asm/socket.h>. // it will include asm/sockios.h, then
asm-generic/ioctl.h
Then, undef IOC_IN if __SYS_SOCKET_H_undef_IOC_IN
3. We include, sys/ioctl.h, since the FLAG of __ASM_IOCTL_H is defined in step
2,
So nearly nothing happens here
So, IOC_IN is not defined.
If we don’t include ioctl.h in asm/sockios.h, just like other platforms, it
works then.
It seems that IOC_IN etc are only defined in asm-generic/ioctl.h,
so why namespace conflict?
--
You are receiving this mail because:
You are on the CC list for the bug.