It has been patched on Gentoo for previous versions, see bug 913110. While edk2-ovmf-202202-lld-textrels.patch got into upstreams, the other patch (edk2-ovmf-202202-binutils-2.41-textrels.patch) is missing. Since that one does not apply cleanly, I've created an updated patch. Reproducible: Always
Created attachment 899664 [details, diff] edk2-ovmf-202405-binutils-2.41-textrels.patch Updated patch solves the issue for me.
Thanks for the patch! Build passed.
Awesome!This fixes build for me on handened with binutils-2.42. Also, with updated path it works for xen-tools (which has same problem with ovmf). Thanks!
+1
I'm confused by this for two reasons. The patch only changes the GCC48 and GCC49 toolchain config, but we use GCC5. We also set these flags in environment variables anyway. I'll double check whether these flags are appearing with my new updated ebuild.
I can't see the flags at all. It seems the environment variables don't do anything. These are not regular build scripts. I now see the patch works because the GCC49 config is included in GCC5. Patch it is then.
(In reply to James Le Cuirot from comment #6) > I can't see the flags at all. It seems the environment variables don't do > anything. These are not regular build scripts. I now see the patch works > because the GCC49 config is included in GCC5. Patch it is then. It is also not clear for me exactly how it happens, but it works for me. It would be good to have a deeper understanding.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=94a911f6b4a29c7187ee9a60a96239a2ee77b869 commit 94a911f6b4a29c7187ee9a60a96239a2ee77b869 Author: James Le Cuirot <chewi@gentoo.org> AuthorDate: 2024-09-25 16:39:52 +0000 Commit: James Le Cuirot <chewi@gentoo.org> CommitDate: 2024-10-10 16:29:33 +0000 sys-firmware/edk2: Apply missing -Werror and hardened patches to 202405 Closes: https://bugs.gentoo.org/937610 Signed-off-by: James Le Cuirot <chewi@gentoo.org> sys-firmware/edk2/edk2-202405.ebuild | 5 ++ .../files/edk2-202408-binutils-2.41-textrels.patch | 13 +++++ sys-firmware/edk2/files/edk2-202408-werror.patch | 56 ++++++++++++++++++++++ 3 files changed, 74 insertions(+)