[Buildroot] [PATCH] package/tio: fix build with termio redefinition

Thomas Petazzoni thomas.petazzoni at bootlin.com
Fri May 15 21:22:25 UTC 2020


On Mon, 11 May 2020 17:26:02 +0300
Vadym Kochan <vadim4j at gmail.com> wrote:

> Include termbits.h from asm-generic/ which does not have termio
> definition which is already defined by sys/ioctl.h -> ioctl-types.h
> 
> Same approach is also used by flashrom tool.
> 
> Fixes: http://autobuild.buildroot.net/results/076d5f166631450d25f25916381f0bfd6f1d58da
> 
> Signed-off-by: Vadym Kochan <vadim4j at gmail.com>

A similar change was already submitted upstream by Fabrice Fontaine:

  https://github.com/tio/tio/pull/98/commits/7a84120f7bfbe698fa8050953b7a3e7a7dc63ca0

And it was submitted to Buildroot, and it was already rejected. Indeed,
including <asm-generic/...> headers from user-space is bad.

See some discussion in the picocom source code at
https://github.com/npat-efault/picocom/blob/master/termbits2.h#L37 for
more details about this issue.

Unfortunately, it doesn't seem like there is an easy fix available,
short of replicating what picocom did.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com



More information about the buildroot mailing list