Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/cpuinfo: don't support ARMv4
@ 2026-10-31 13:45 Thomas Perale via buildroot
  2026-11-01 17:07 ` Thomas Petazzoni via buildroot
  0 siblings, 1 reply; 2+ messages in thread
From: Thomas Perale via buildroot @ 2026-10-31 13:45 UTC (permalink / raw)
  To: buildroot; +Cc: Stefan Hager

Building the package cpuinfo with an ARMv4 architecture would result in
the following error message:

```
/home/thomas/autobuild/instance-0/output-1/host/lib/gcc/arm-buildroot-linux-gnueabi/13.4.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: CMakeFiles/cpuinfo.dir/src/init.c.o: in function `cpuinfo_initialize':
init.c:(.text+0x28): undefined reference to `cpuinfo_arm_linux_init'
/home/thomas/autobuild/instance-0/output-1/host/lib/gcc/arm-buildroot-linux-gnueabi/13.4.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: libcpuinfo.so: hidden symbol `cpuinfo_arm_linux_init' isn't defined
/home/thomas/autobuild/instance-0/output-1/host/lib/gcc/arm-buildroot-linux-gnueabi/13.4.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: final link failed: bad value
```

This can be reproduced with the following defconfig:

```
BR2_arm=y
BR2_fa526=y
BR2_PACKAGE_CPUINFO=y
```

As stated in the README of the upstream project [1] only ARMv5 and later
CPU are supported. This commit then exclude ARMv4 from the supported
architecture.

[1] https://github.com/pytorch/cpuinfo/blob/main/README.md#supported-environments

Fixes: ea1cc1af55 package/cpuinfo: new package
Fixes: https://autobuild.buildroot.org/results/f14/f14e4afacaa61021463c457def1cad3c81d35f29
Signed-off-by: Thomas Perale <thomas.perale@mind.be>
---
 package/cpuinfo/Config.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/cpuinfo/Config.in b/package/cpuinfo/Config.in
index 64477c2bd7..4aecf2e060 100644
--- a/package/cpuinfo/Config.in
+++ b/package/cpuinfo/Config.in
@@ -1,7 +1,7 @@
 config BR2_PACKAGE_CPUINFO_ARCH_SUPPORTS
 	bool
 	default y if BR2_aarch64
-	default y if BR2_arm
+	default y if BR2_arm && !BR2_ARM_CPU_ARMV4
 	default y if BR2_i386
 	default y if BR2_x86_64
 
-- 
2.56.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/cpuinfo: don't support ARMv4
  2026-10-31 13:45 [Buildroot] [PATCH 1/1] package/cpuinfo: don't support ARMv4 Thomas Perale via buildroot
@ 2026-11-01 17:07 ` Thomas Petazzoni via buildroot
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Petazzoni via buildroot @ 2026-11-01 17:07 UTC (permalink / raw)
  To: Thomas Perale; +Cc: buildroot, Stefan Hager

On Sat, Oct 31, 2026 at 02:45:09PM +0100, Thomas Perale via buildroot wrote:
> Building the package cpuinfo with an ARMv4 architecture would result in
> the following error message:
> 
> ```
> /home/thomas/autobuild/instance-0/output-1/host/lib/gcc/arm-buildroot-linux-gnueabi/13.4.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: CMakeFiles/cpuinfo.dir/src/init.c.o: in function `cpuinfo_initialize':
> init.c:(.text+0x28): undefined reference to `cpuinfo_arm_linux_init'
> /home/thomas/autobuild/instance-0/output-1/host/lib/gcc/arm-buildroot-linux-gnueabi/13.4.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: libcpuinfo.so: hidden symbol `cpuinfo_arm_linux_init' isn't defined
> /home/thomas/autobuild/instance-0/output-1/host/lib/gcc/arm-buildroot-linux-gnueabi/13.4.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: final link failed: bad value
> ```
> 
> This can be reproduced with the following defconfig:
> 
> ```
> BR2_arm=y
> BR2_fa526=y
> BR2_PACKAGE_CPUINFO=y
> ```
> 
> As stated in the README of the upstream project [1] only ARMv5 and later
> CPU are supported. This commit then exclude ARMv4 from the supported
> architecture.
> 
> [1] https://github.com/pytorch/cpuinfo/blob/main/README.md#supported-environments
> 
> Fixes: ea1cc1af55 package/cpuinfo: new package
> Fixes: https://autobuild.buildroot.org/results/f14/f14e4afacaa61021463c457def1cad3c81d35f29
> Signed-off-by: Thomas Perale <thomas.perale@mind.be>

Applied to master, thanks!

Best regards,

Thomas Petazzoni
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-11-01 17:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-31 13:45 [Buildroot] [PATCH 1/1] package/cpuinfo: don't support ARMv4 Thomas Perale via buildroot
2026-11-01 17:07 ` Thomas Petazzoni via buildroot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox