commit:     3033b4048a87b26f18773356a19f77beb9c25d9e
Author:     Sv. Lockal <lockalsash <AT> gmail <DOT> com>
AuthorDate: Sat Jul 19 20:42:37 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Jul 23 02:33:01 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3033b404

dev-libs/xbyak: fixes for FEATURES=test

1. `dev-lang/nasm` is required for tests
2. tests fail to compile on non-multilib
3. tests fail to compile with libc++ (it has no multilib even on multilib 
profile)

Signed-off-by: Sv. Lockal <lockalsash <AT> gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/43075
Closes: https://github.com/gentoo/gentoo/pull/43075
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-libs/xbyak/xbyak-7.28.ebuild | 19 ++++++++++++++++---
 1 file changed, 16 insertions(+), 3 deletions(-)

diff --git a/dev-libs/xbyak/xbyak-7.28.ebuild b/dev-libs/xbyak/xbyak-7.28.ebuild
index 6abe95ceb47e..6670c915b601 100644
--- a/dev-libs/xbyak/xbyak-7.28.ebuild
+++ b/dev-libs/xbyak/xbyak-7.28.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=8
 
-inherit cmake
+inherit cmake multilib toolchain-funcs
 
 DESCRIPTION="JIT assembler for x86(IA-32)/x64(AMD64, x86-64)"
 HOMEPAGE="https://github.com/herumi/xbyak";
@@ -17,9 +17,22 @@ IUSE="test"
 RESTRICT="!test? ( test )"
 
 BDEPEND="
-       test? ( dev-lang/yasm )
+       test? (
+               dev-lang/yasm
+               dev-lang/nasm
+       )
 "
 
+src_prepare() {
+       sed 's/ONLY_64BIT=0/ONLY_64BIT:=0/' -i test/Makefile || die
+       cmake_src_prepare
+}
+
 src_test() {
-       emake -C test test
+       local only_64bit=0
+       if use amd64 && { ! has_multilib_profile || [[ $(tc-get-cxx-stdlib) == 
libc++ ]]; }; then
+               only_64bit=1
+       fi
+
+       emake -C test test ONLY_64BIT=${only_64bit}
 }

Reply via email to