package/pppd: disable for sparc and sparc64 architectures
PATCH 1/1 package/pppd: disable for sparc and sparc64 architectures
pppd fails to build on sparc and sparc64 architectures with a redefinition of 'struct termio' error, with no proper fix or workaround for now. See discussions in [1] and [2] and picocom source code in [3].
[1] http://patchwork.ozlabs.org/project/buildroot/patch/[email protected]/
[2] http://patchwork.ozlabs.org/project/buildroot/patch/[email protected]/
[3] https://github.com/npat-efault/picocom/blob/master/termbits2.h#L37
So let's disable it for now on sparc and sparc64 architectures.
Fixes:
http://autobuild.buildroot.net/results/c0a/c0a9dd410664dec670f90966e12b76e68f9883ee/
--- package/network-manager/Config.in | 1 + package/pppd/Config.in | 8 ++++++++ package/rp-pppoe/Config.in | 1 + 3 files changed, 10 insertions(+)
package/network-manager/Config.in +1 -0
@@ -48,6 +48,7 @@ config BR2_PACKAGE_NETWORK_MANAGER_MODEM_MANAGER config BR2_PACKAGE_NETWORK_MANAGER_PPPD bool "pppd support" + depends on !BR2_sparc64 && !BR2_sparc # pppd select BR2_PACKAGE_PPPD help This option enables support for PPPD daemon
package/pppd/Config.in +8 -0
@@ -1,5 +1,6 @@ config BR2_PACKAGE_PPPD bool "pppd" + depends on !BR2_sparc64 && !BR2_sparc depends on !BR2_STATIC_LIBS depends on BR2_USE_MMU select BR2_PACKAGE_OPENSSL if BR2_TOOLCHAIN_USES_GLIBC
@@ -22,5 +23,12 @@ config BR2_PACKAGE_PPPD_FILTER endif comment "pppd needs a toolchain w/ dynamic library" + depends on !BR2_sparc64 && !BR2_sparc depends on BR2_STATIC_LIBS depends on BR2_USE_MMU + +# pppd is disabled for sparc and sparc64 architectures because it fails +# to build with a redefinition of 'struct termio' error, with no proper +# fix or workaround for now +comment "pppd is disabled for sparc and sparc64 architectures" + depends on BR2_sparc64 || BR2_sparc
package/rp-pppoe/Config.in +1 -0
@@ -4,6 +4,7 @@ comment "rp-pppoe needs a toolchain w/ dynamic library" config BR2_PACKAGE_RP_PPPOE bool "rp-pppoe" + depends on !BR2_sparc64 && !BR2_sparc # pppd depends on !BR2_STATIC_LIBS depends on BR2_USE_MMU # fork() select BR2_PACKAGE_PPPD
Signature · 6 lines
2.39.2 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
package/pppd/Config.in line 3
Quoted 8 lines · On Sun, 15 Oct 2023 22:47:53 +0200 Bernd Kuhls <[email protected]> wrote:
package/pppd/Config.in +1
-0@@ -1,5 +1,6 @@ config BR2_PACKAGE_PPPD bool "pppd" + depends on !BR2_sparc64 && !BR2_sparc
If we wanted to merge that, it should be:
config BR2_PACKAGE_PPPD_ARCH_SUPPORTS
bool default y if !BR2_sparc64 && !BR2_sparc
However, it's never nice to have to do something like this. Has this issue been reported to upstream pppd?
Also, it seems like the ppp package in Debian builds on sparc64, see
https://packages.debian.org/sid/ppp. How do they achieve this? I haven't spotted a particular patch/quirk (but I looked quickly).
In
https://github.com/ppp-project/ppp/blob/master/pppd/termios_linux.h#L14,
the pppd code base is definitely playing with fire. I'm not sure what they are trying to do, but they know that the inclusion of kernel headers will cause some redefinition... Perhaps something to discuss with ppp upstream first.
Best regards,
Thomas
Signature · 7 lines
Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Hello Bernd,
Quoted 13 lines · On Wed, 1 Nov 2023 23:39:31 +0100 Thomas Petazzoni via buildroot…
If we wanted to merge that, it should be:
config
BR2_PACKAGE_PPPD_ARCH_SUPPORTSbool default y if !BR2_sparc64 && !BR2_sparcHowever, it's never nice to have to do something like this. Has this issue been reported to upstream pppd?
Also, it seems like the ppp package in Debian builds on sparc64, see
https://packages.debian.org/sid/ppp. How do they achieve this? I haven't spotted a particular patch/quirk (but I looked quickly).
Quoted 6 lines
In
https://github.com/ppp-project/ppp/blob/master/pppd/termios_linux.h#L14,
the pppd code base is definitely playing with fire. I'm not sure what they are trying to do, but they know that the inclusion of kernel headers will cause some redefinition... Perhaps something to discuss with ppp upstream first.
I finally took some time, narrowed down the issue, and wrote a work-around. The real fix was in fact done very recently in the Linux kernel, but it will only appear in Linux 6.10, so we need a workaround for toolchains that use headers < 6.10.
See my commit at:
https://gitlab.com/buildroot.org/buildroot/-/commit/b162aab7c6da6b45dc5ba9ad30b59b4362e2dc2e
Best regards,
Thomas
Signature · 7 lines
Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot