On Mon, Jul 22, 2019, 6:24 PM Bruce Dubbs via blfs-dev < [email protected]> wrote:
> On 7/22/19 5:48 PM, Ken Moffat via blfs-dev wrote: > > It looks as if any changes for the compile breakage caused by > > removing SIOCGSTAMP (and perhaps other SIOCG* definitions) from > > <sys/socket.h> are being left for upstreams to fix, and perhaps the > > next glibc release will include a fix to pull in the new header. > > > > In the meantime, the seds to define SIOCGSTAMP as 0x8906 seem to do > > the job. I was concerned that they might be fine for x86 but could > > possibly be wrong for other architectures, and we know that people > > sometimes use our instructions e.g. for Pi, but apparently the > > values are not architecture-specific. > > > > Obviously, different files need to be changed to fix different > > programs. But to sprovide a common explanation, could we use a > > standard copymember, something like (omitting the markup) > > > > sed -i 's/SIOCGSTAMP/0x8906/' ... : In linux-5.1 the definition of > > SIOCGSTAMP was moved and is no-longer in <sys/socket.h>. Hard-coding > > its value enables packages which do not know about that change to > > continue to compile with current headers. > > > > And perhaps add a ticket "Fixes for SIOCGSTAMP breakage" to note > > which packages are affected (I know some are already fixed, but > > perhaps use the common explanation). > > > > At this point I don't have a system with 5.2 headers, and I suspect > > I'm a couple of weeks away from an up to date build. > > Another workaround for the 5.2 and later kernels would be to modify > /usr/include/linux/sockios.h > > sed -i '/sockios.h>/a#include asm-generic/sockios.h' \ > /usr/include/linux/sockios.h > > That included file is only 14 lines long: > > /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ > #ifndef __ASM_GENERIC_SOCKIOS_H > #define __ASM_GENERIC_SOCKIOS_H > > /* Socket-level I/O control calls. */ > #define FIOSETOWN 0x8901 > #define SIOCSPGRP 0x8902 > #define FIOGETOWN 0x8903 > #define SIOCGPGRP 0x8904 > #define SIOCATMARK 0x8905 > #define SIOCGSTAMP_OLD 0x8906 /* Get stamp (timeval) */ > #define SIOCGSTAMPNS_OLD 0x8907 /* Get stamp (timespec) */ > > #endif /* __ASM_GENERIC_SOCKIOS_H */ > ======== > > I suspect that would fix things for everyone. It would make things > consistent with 'man 7 socket'. > > -- Bruce > IMO, changing the kernel headers is not a good idea. I think the solution of fixing the affected packages using seds for now is the best approach. So far I've come across Qt, Qtwebengine, and BlueZ. I'm in the process of building a 5.2-based system right now, and had a build of Qt running before I left my house. I think the man page will change soon too because, if I'm not mistaken (on GMail's Mobile App), that package is maintained by the kernel maintainers. I might be wrong there though >
-- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
