arch/riscv: Always build opensbi with GCC
Building with clang is currently broken as /usr/bin/ld.bfd is used rather than the proper crosstoolchain linker. Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Change-Id: Idd8006a26b2c2f9f777fdffe231c3c774320d805 Reviewed-on: https://review.coreboot.org/c/coreboot/+/75397 Reviewed-by: Daniel Maslowski <info@orangecms.org> Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de> Reviewed-by: Elyes Haouas <ehaouas@noos.fr> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
		
				
					committed by
					
						
						Felix Singer
					
				
			
			
				
	
			
			
			
						parent
						
							5c2a2e1bb3
						
					
				
				
					commit
					cf827af370
				
			@@ -178,12 +178,14 @@ OPENSBI_BUILD  := $(abspath $(obj)/3rdparty/opensbi)
 | 
				
			|||||||
OPENSBI_TARGET := $(OPENSBI_BUILD)/platform/$(CONFIG_OPENSBI_PLATFORM)/firmware/fw_dynamic.elf
 | 
					OPENSBI_TARGET := $(OPENSBI_BUILD)/platform/$(CONFIG_OPENSBI_PLATFORM)/firmware/fw_dynamic.elf
 | 
				
			||||||
OPENSBI := $(obj)/opensbi.elf
 | 
					OPENSBI := $(obj)/opensbi.elf
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# TODO: Building with clang has troubles finding the proper linker.
 | 
				
			||||||
 | 
					# Always use GCC for now.
 | 
				
			||||||
$(OPENSBI_TARGET): $(obj)/config.h | $(OPENSBI_SOURCE)
 | 
					$(OPENSBI_TARGET): $(obj)/config.h | $(OPENSBI_SOURCE)
 | 
				
			||||||
	printf "    MAKE       $(subst $(obj)/,,$(@))\n"
 | 
						printf "    MAKE       $(subst $(obj)/,,$(@))\n"
 | 
				
			||||||
	mkdir -p $(OPENSBI_BUILD)
 | 
						mkdir -p $(OPENSBI_BUILD)
 | 
				
			||||||
	$(MAKE) \
 | 
						$(MAKE) \
 | 
				
			||||||
		-C "$(OPENSBI_SOURCE)" \
 | 
							-C "$(OPENSBI_SOURCE)" \
 | 
				
			||||||
		CC="$(CC_ramstage) -fno-builtin" \
 | 
							CC="$(GCC_ramstage) -fno-builtin" \
 | 
				
			||||||
		LD="$(LD_ramstage)" \
 | 
							LD="$(LD_ramstage)" \
 | 
				
			||||||
		OBJCOPY="$(OBJCOPY_ramstage)" \
 | 
							OBJCOPY="$(OBJCOPY_ramstage)" \
 | 
				
			||||||
		AR="$(AR_ramstage)" \
 | 
							AR="$(AR_ramstage)" \
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user