SquashFS not compiling due to missing __udivmoddi4 (x86)

Tom Rini trini at konsulko.com
Mon May 2 16:51:40 CEST 2022


On Mon, May 02, 2022 at 12:39:32PM +0200, Sean Nyekjaer wrote:

> Hi,
> 
> I'm trying to build Squashfs for u-boot for x86.
> 
> Looks like we are missing some libgcc helper function.
> 
> ld.bfd: fs/squashfs/sqfs.o: in function `sqfs_read':
> /home/sean/development/siemens/u-boot/fs/squashfs/sqfs.c:1443: undefined reference to `__udivmoddi4'
> ld.bfd: /home/sean/development/siemens/u-boot/fs/squashfs/sqfs.c:1521: undefined reference to `__udivmoddi4'
> 
> I can fix this by adding the function from arch/arc/lib/libgcc2.c to
> arch/x86/lib/div64.c, but I'm not sure it's the right way to do it :)
> 
> Any hints?

That likely means there's some 64 bit math going on which should be
using lldiv or do_div or something like that, instead.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20220502/9cb886cc/attachment.sig>


More information about the U-Boot mailing list