Revert "Remove use of bfd_check_format_matches() which may not always be available depending on bfd version"
Revert "Remove use of bfd_check_format_matches() which may not always be available depending on bfd version"

This reverts commit 9a4ff4a4cf78d8793b695d58cd09ed00e78e8029.

ultraembedded/riscv,ultraembedded/riscv