All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] riscv: Start using ldflags-y for 32/64bit LDFLAGS
@ 2020-03-27 13:52 Tom Rini
  2020-03-27 13:52 ` [PATCH 2/3] mips: " Tom Rini
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Tom Rini @ 2020-03-27 13:52 UTC (permalink / raw)
  To: u-boot

To prepare to update our Kbuild logic, start switching some of our cases
of adding different bit/endian linker flags via ldflags-y

Cc: Rick Chen <rick@andestech.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
---
 arch/riscv/config.mk | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/arch/riscv/config.mk b/arch/riscv/config.mk
index 84654eb3ed87..df91a85f677f 100644
--- a/arch/riscv/config.mk
+++ b/arch/riscv/config.mk
@@ -10,16 +10,14 @@
 # Rick Chen, Andes Technology Corporation <rick@andestech.com>
 #
 
-32bit-emul		:= elf32lriscv
-64bit-emul		:= elf64lriscv
+ldflags-$(CONFIG_32BIT) := -m elf32lriscv
+ldflags-$(CONFIG_64BIT) := -m elf64lriscv
 
 ifdef CONFIG_32BIT
-PLATFORM_LDFLAGS	+= -m $(32bit-emul)
 EFI_LDS			:= elf_riscv32_efi.lds
 endif
 
 ifdef CONFIG_64BIT
-PLATFORM_LDFLAGS	+= -m $(64bit-emul)
 EFI_LDS			:= elf_riscv64_efi.lds
 endif
 
@@ -29,6 +27,7 @@ PLATFORM_CPPFLAGS	+= -ffixed-gp -fpic
 PLATFORM_RELFLAGS	+= -fno-common -gdwarf-2 -ffunction-sections \
 			   -fdata-sections
 LDFLAGS_u-boot		+= --gc-sections -static -pie
+PLATFORM_LDFLAGS	+= $(ldflags-y)
 
 EFI_CRT0		:= crt0_riscv_efi.o
 EFI_RELOC		:= reloc_riscv_efi.o
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2020-03-30  3:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-27 13:52 [PATCH 1/3] riscv: Start using ldflags-y for 32/64bit LDFLAGS Tom Rini
2020-03-27 13:52 ` [PATCH 2/3] mips: " Tom Rini
2020-03-27 15:08   ` Daniel Schwierzeck
2020-03-27 15:12     ` Tom Rini
2020-03-27 15:17     ` Tom Rini
2020-03-27 13:52 ` [PATCH 3/3] kconfig / kbuild: Re-sync with Linux 4.19 Tom Rini
     [not found] ` <752D002CFF5D0F4FA35C0100F1D73F3FA46EE197@ATCPCS16.andestech.com>
2020-03-30  3:01   ` [PATCH 1/3] riscv: Start using ldflags-y for 32/64bit LDFLAGS Rick Chen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.