[Buildroot] [PATCH] andes_ae350_45: Fix build issues of AE350
Yu-Chien Peter Lin
peterlin at andestech.com
Mon Aug 14 02:19:06 UTC 2023
On Sat, Aug 12, 2023 at 02:27:59PM +0200, Thomas Petazzoni wrote:
> On Sat, 12 Aug 2023 14:00:00 +0200
> Kilian Zinnecker <kilian.zinnecker at mail.de> wrote:
>
> > So I think setting BR2_RISCV_ISA_CUSTOM_RVA=y is correct. However, you could
> > try whether it works, if you then completely remove the
> > BR2_TARGET_UBOOT_CUSTOM_MAKEOPTS?
>
> The U-Boot version used by the andes_ae350_45 defconfig indeed includes:
>
> # Newer binutils versions default to ISA spec version 20191213 which moves some
> # instructions from the I extension to the Zicsr and Zifencei extensions.
> toolchain-need-zicsr-zifencei := $(call cc-option-yn, -mabi=$(ABI) -march=$(RISCV_MARCH)_zicsr_zifencei)
> ifeq ($(toolchain-need-zicsr-zifencei),y)
> RISCV_MARCH := $(RISCV_MARCH)_zicsr_zifencei
> endif
>
> So it should already be doing the right thing automatically. However,
> the fact that the defconfig forces its own ARCH_FLAGS=-march=rv64imafdc
> is probably what breaks the build.
>
> So I agree with Kilian here: please try without any:
>
> BR2_TARGET_UBOOT_CUSTOM_MAKEOPTS="ARCH_FLAGS=-march=rv64imafdc"
>
> and see if that helps. However in that case, you might need indeed to
> keep the addition of BR2_RISCV_ISA_CUSTOM_RVA=y as part of the fix:
> please double check that.
>
> Thanks!
>
> Thomas
> --
> Thomas Petazzoni, co-owner and CEO, Bootlin
> Embedded Linux and Kernel engineering and training
> https://bootlin.com
Hi Thomas, Kilian,
Yeah, I should not override the ARCH_FLAGS with BR2_TARGET_UBOOT_CUSTOM_MAKEOPTS.
I've rebuilt it without any problems, so I will remove the configuration and
add a patch to set R2_RISCV_ISA_CUSTOM_RVA.
Thanks for your review!
Best regards,
Peter Lin
More information about the buildroot
mailing list