[Buildroot] [PATCH v3 06/10] package/Makefile.in: adjust LDFLAGS for elf2flt

Peter Korsgaard peter at korsgaard.com
Fri Apr 8 12:28:59 UTC 2016


>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni at free-electrons.com> writes:

 > So far, our LDFLAGS for the BR2_BINFMT_FLAT case were only used on
 > Blackfin. However, passing -elf2flt in LDFLAGS is wrong. Indeed,
 > LDFLAGS are not linker flags, but flags passed to the compiler when
 > linking.

 > If you pass -elf2flt to the compiler when linking, it is understood as
 > "-e lf2flt", i.e "the entry point is named lf2flt", which isn't
 > exactly the intention. We in fact need to pass -Wl,-elf2flt in LDFLAGS
 > as well, so that the compiler passes -elf2flt down to the linker.

 > For some reason, this option does not cause an issue with the Blackfin
 > toolchain, but it does with either a Buildroot toolchain for Cortex-M
 > or an OSELAS toolchain for Cortex-M. We have verified that passing
 > -Wl,-elf2flt continues to work with the Blackfin toolchain.

 > Signed-off-by: Thomas Petazzoni <thomas.petazzoni at free-electrons.com>

Committed, thanks.

-- 
Bye, Peter Korsgaard



More information about the buildroot mailing list