Skip to contentSkip to conversation

toolchain: limit musl workaround to kernel headers 3.12+

PATCH In review Baruch Siach 3 participants 5 messages May 19, 2017 – Jun 1, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 toolchain: limit musl workaround to kernel headers 3.12+

The libc-compat.h first appeared in kernel version 3.12. Trying to build a musl toolchain using earlier headers leads to the following failure:

/bin/sed: can't read .../output/host/usr/arm-buildroot-linux-musleabi/sysroot/usr/include/linux/libc-compat.h: No such file or directory package/pkg-generic.mk:266: recipe for target '.../output/build/toolchain/.stamp_staging_installed' failed

Don't apply the sed patch to older headers.

---
 toolchain/toolchain/toolchain.mk | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
toolchain/toolchain/toolchain.mk +3 -1
index e29837357a27..e15ceeb426fa 100644
@@ -21,8 +21,10 @@ TOOLCHAIN_ADD_TOOLCHAIN_DEPENDENCY = NO
 # IFF_DORMANT and IFF_ECHO, add another macro to suppress them in the
 # kernel header, and avoid macro/enum conflict.
 #
+# Kernel version 3.12 introduced the libc-compat.h header.
+#
 # [1] http://www.openwall.com/lists/musl/2015/10/08/2
-ifeq ($(BR2_TOOLCHAIN_USES_MUSL),y)
+ifeq ($(BR2_TOOLCHAIN_USES_MUSL)$(BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_12),yy)
 define TOOLCHAIN_MUSL_KERNEL_HEADERS_COMPATIBILITY_HACK
 	$(SED) 's/^#if defined(__GLIBC__)$$/#if 1/' \
 		$(STAGING_DIR)/usr/include/linux/libc-compat.h
Signature · 1 line
2.11.0
#1 lore raw

[Buildroot] Xorg.conf question ?

Hello everyone,

I tried to startx from newly compiled buildroot,
but
I got "no screens found" error on Qemu.

How can I fix it ?
Regards,

#2 lore raw

[Buildroot] qemu_x86_64_defconfig ==> X11 ?

In reply to Baruch Siach

Hi Everyone,

How can I make X11 server / X windows run based from qemu_x86_64_defconfig ? Thanks

#3 lore raw

PATCH 1/1 toolchain: limit musl workaround to kernel headers 3.12+

In reply to Baruch Siach
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Baruch" == Baruch Siach <[email protected]> writes:

The libc-compat.h first appeared in kernel version 3.12. Trying to build a musl toolchain using earlier headers leads to the following failure:

Quoted 7 lines

/bin/sed: can't read .../output/host/usr/arm-buildroot-linux-musleabi/sysroot/usr/include/linux/libc-compat.h: No such file or directory package/pkg-generic.mk:266: recipe for target '.../output/build/toolchain/.stamp_staging_installed' failed

Don't apply the sed patch to older headers.

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#4 lore raw

PATCH 1/1 toolchain: limit musl workaround to kernel headers 3.12+

In reply to Baruch Siach
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Baruch" == Baruch Siach <[email protected]> writes:

The libc-compat.h first appeared in kernel version 3.12. Trying to build a musl toolchain using earlier headers leads to the following failure:

Quoted 7 lines

/bin/sed: can't read .../output/host/usr/arm-buildroot-linux-musleabi/sysroot/usr/include/linux/libc-compat.h: No such file or directory package/pkg-generic.mk:266: recipe for target '.../output/build/toolchain/.stamp_staging_installed' failed

Don't apply the sed patch to older headers.

Committed to 2017.02.x, thanks.

Signature · 1 line
Bye, Peter Korsgaard