I see that in the latest version of objcopy (GNU objcopy (GNU Binutils) 2.29.1.20171006), I get an error saying "objcopy: architecture ARM unknown"This is working only with the version GNU objcopy (GNU Binutils) 2.21Can you please confirm what are the supported BFD architectures for the -B option in the latest objcopy version.
Working cmd:objcopy.exe -I binary -B ARM -O elf32-littlearm --set-section-flags .data=alloc,readonly,code example.bin example.o
On using the objcopy without -B option, the armlink says its not able to recognise the fileformat. Hence, the usage of -B option is needed.
Hi Christiana,
I downloaded from gnutoolchains.com/.../ for arm toolchain, and -B ARM is working fine now.GNU objcopy (GNU Tools for Arm Embedded Processors 9-2019-q4-major) 2.33.1.20191025
Thanks for the quick tip.
Thanks.