How are you invoking 'configure' and 'make', to enable -flto? Perhaps diffutils can work around the other GCC bugs by looking at the arguments to 'configure' and 'make' and disabling -Wmaybe-uninitialized if you're using -flto.
These are false positives from GCC. I worked around the last one by
installing the attached patch. The others are due to GCC bug 80922
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80922>.
- [bug-diffutils] bug#78019: LTO build fails with diffutils ... Christian Hesse
- [bug-diffutils] bug#78019: bug#78019: LTO build fails... Paul Eggert
- [bug-diffutils] bug#78019: bug#78019: LTO build f... Christian Hesse
- [bug-diffutils] bug#78019: bug#78019: LTO bui... Paul Eggert