commit: 5872ad7b37126df3e8897f3db41e3853e6840d99 Author: Christopher Byrne <salah.coronya <AT> gmail <DOT> com> AuthorDate: Mon Feb 7 20:17:58 2022 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Wed Feb 9 11:23:36 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5872ad7b
sys-boot/tboot: Die if tc-is-clang. Requires VLAIS which is gcc-only. Closes: https://bugs.gentoo.org/832020 Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Christopher Byrne <salah.coronya <AT> gmail.com> Closes: https://github.com/gentoo/gentoo/pull/24119 Signed-off-by: Sam James <sam <AT> gentoo.org> sys-boot/tboot/tboot-1.10.3.ebuild | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/sys-boot/tboot/tboot-1.10.3.ebuild b/sys-boot/tboot/tboot-1.10.3.ebuild index cdb682a949ff..4cedba3fabfc 100644 --- a/sys-boot/tboot/tboot-1.10.3.ebuild +++ b/sys-boot/tboot/tboot-1.10.3.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2021 Gentoo Authors +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -28,6 +28,16 @@ PATCHES=( "${FILESDIR}/${PN}-1.10.3-disable-Werror.patch" "${FILESDIR}/${PN}-1.10.3-disable-strip.patch" "${FILESDIR}/${PN}-1.10.3-dont-call-toolchain-directly.patch" ) +pkg_setup() { + if tc-is-clang; then + eerror "tboot is a freestanding application that uses gcc" + eerror "extensions in fundemental ways, include VLAIS" + eerror "(Variable Length Arrays in Structs) and will not" + eerror "compile with clang witout upstream action" + die "Cannot compile with clang. See bug #832020" + fi +} + src_configure() { tc-export AS LD CC CPP AR RANLIB NM OBJCOPY OBJDUMP STRIP