elf2flt
elf2flt copied to clipboard
elf2flt: handle binutils >= 2.34
The latest Binutils release (2.34) is not compatible with elf2flt due to a change in bfd_section_* macros. The issue has been reported to the Binutils mailing list but Alan Modra recommend to bundle libbfd library sources into each projects using it [1]. That's because the API is not stable over the time without any backward compatibility guaranties.
On the other hand, the elf2flt tools needs to support modified version of binutils for specific arch/target [2].
Add two tests in the configure script to detect this API change in order to support binutils < 2.34 and binutils >= 2.34.
[1] https://sourceware.org/ml/binutils/2020-02/msg00044.html [2] https://github.com/uclinux-dev/elf2flt/issues/14
Signed-off-by: Romain Naour [email protected]
were you planning on refreshing this ?
This looks to have been sitting here for quite a while now. I have manually resolved the conflict, so it is at least clean and ready to be applied. As far as I can tell Romain addressed all feedback.
tbh, i didn't really notice the updated pushes since the open comments weren't marked resolved, so was waiting for OP to do so. if you think issues are resolved, and you've rebased the work, then let's merge it.
should update the unittest coverage (i.e. uclinux-dev/prebuilts-binutils-libs) to make sure things work & stay working.
Further testing has found at least one problem. This only works if you use the single --with-binutils-build-dir configure form. If you specify each of the --with-libbfd/--with-libiberty/etc configure options (but no --with-binutils-build-dir option) it will fail to detect the version of binutils correctly.
Oh, and the in-tree configure script needs to be regenerated too.
hmm, we should add those scenarios to our CI tests
This pull request updated to fix --with-binutils-build-dir case and the configure script re-generated and applied to main.