[PATCH v3 0/3] Fully support standalone Clang/LLVM toolchains
From: Xiang W <hidden>
Date: 2021-07-10 13:18:33
? 2021-07-09???? 15:25 +0100?Jessica Clarke???
On 9 Jul 2021, at 15:23, Xiang W [off-list ref] wrote:quoted
? 2021-07-09???? 14:49 +0100?Jessica Clarke???quoted
On 9 Jul 2021, at 14:46, Xiang W [off-list ref] wrote:quoted
? 2021-07-09???? 05:12 +0100?Jessica Clarke??? I tested these patches. Some bugs reported ld.lld: error: can't create dynamic relocation R_RISCV_32 against symbol: _fw_start in readonly segment; recompile object files with - fPIC or pass '-Wl,-z,notext' to allow text relocations in the outputquoted
quoted
quoted
defined in/home/merle/workspaces/opensbi/build/platform/generic/firmware/ fw_d ynam ic.elf.ld:9quoted
quoted
quoted
referenced by fw_base.S:502(/home/merle/workspaces/opensbi/firmware/fw_base.S:502)quoted
quoted
quoted
/home/merle/workspaces/opensbi/build/platform/generic/firmware/ fw_d ynam ic.o:(.entry+0x3BC)This was reported by Bin. Don?t use a Linux triple for something that?s neither the Linux kernel nor a Linux userspace executable/library. JessLinux triple?That error looks like you built with CROSS_COMPILE=riscv64-linux- or similar. What exactly did you run? Jess
I ran the following command CROSS_COMPILE=riscv64-linux-gnu- make PLATFORM_RISCV_XLEN=32 PLATFORM=generic LLVM=1 The problem is solved after adding .data in base.S Regards? Xiang W