View previous topic :: View next topic |
Author |
Message |
lekto Apprentice
Joined: 20 Sep 2014 Posts: 209 Location: Ancient Rome
|
Posted: Mon Oct 31, 2022 7:44 am Post subject: [solved] can't link double-float modules with soft-float |
|
|
Hi, I’m trying to install Gentoo on Lichee RV (RISC-V) using mostly this: https://linux-sunxi.org/Allwinner_Nezha#Manual_build. Unfortunately looks like my sdcard is dying and corrupting lots of files (glibc, ncruses, openssl etc.). I’m trying to install it on new card, but this time on btrfs instead of ext4. When trying to build u-boot with support for btrfs I get this errors:
Code: | riscv64-linux-gnu-ld.bfd: /usr/lib/gcc/riscv64-linux-gnu/11.3.0/libgcc.a(_clzsi2.o): can't link double-float modules with soft-float modules
riscv64-linux-gnu-ld.bfd: failed to merge target specific data of file /usr/lib/gcc/riscv64-linux-gnu/11.3.0/libgcc.a(_clzsi2.o)
riscv64-linux-gnu-ld.bfd: /usr/lib/gcc/riscv64-linux-gnu/11.3.0/libgcc.a(_clz.o): can't link double-float modules with soft-float modules
riscv64-linux-gnu-ld.bfd: failed to merge target specific data of file /usr/lib/gcc/riscv64-linux-gnu/11.3.0/libgcc.a(_clz.o)
make: *** [Makefile:1830: u-boot] Error 1 |
Last edited by lekto on Wed Nov 02, 2022 2:48 pm; edited 1 time in total |
|
Back to top |
|
|
GDH-gentoo Veteran
Joined: 20 Jul 2019 Posts: 1721 Location: South America
|
Posted: Wed Nov 02, 2022 2:01 pm Post subject: |
|
|
Apparently, the linker is complaining about mixing code compiled with -mabi=lp64, with code compiled with -mabi=lp64d. That's not possible. I suppose that the discrepancy is between how GCC was compiled itself (libgcc.a), and how U-Boot is being compiled. _________________
NeddySeagoon wrote: | I'm not a witch, I'm a retired electronics engineer |
Ionen wrote: | As a packager I just don't want things to get messier with weird build systems and multiple toolchains requirements though |
|
|
Back to top |
|
|
lekto Apprentice
Joined: 20 Sep 2014 Posts: 209 Location: Ancient Rome
|
Posted: Wed Nov 02, 2022 2:47 pm Post subject: |
|
|
I think it was bug in fork of u-boot that I was using. I tried to build it natively on Lichee using stage3 lp64 and lp64d and I was always getting this error or other way around. I found somewhere option to force pass letter "d" (in lp64d) to compiler and code build successfully. Unfortunately there were changes in build process and I still can build everything, but it's not working any more. |
|
Back to top |
|
|
GDH-gentoo Veteran
Joined: 20 Jul 2019 Posts: 1721 Location: South America
|
Posted: Wed Nov 02, 2022 3:48 pm Post subject: |
|
|
As far as I can tell, U-Boot's configuration option CONFIG_RISCV_ISA_D ("Standard extension for Double-Precision Floating Point") controls whether the bootloader is compiled with LP64 or LP64D ABI. _________________
NeddySeagoon wrote: | I'm not a witch, I'm a retired electronics engineer |
Ionen wrote: | As a packager I just don't want things to get messier with weird build systems and multiple toolchains requirements though |
|
|
Back to top |
|
|
|