guix_mirror_bot pushed a commit to branch go-team
in repository guix.
commit 2fd0e1058abc815548d529f29dea6ee9cab20b81
Author: Roman Scherer <[email protected]>
AuthorDate: Sun Apr 19 14:13:56 2026 +0200
gnu: go-github-com-bytedance-sonic: Restrict test-subdirs on non-x86-64.
Subpackages internal/jit and internal/native/{avx2,sse} reference
amd64-only symbols, so the default './...' fails to compile on
non-x86-64.
* gnu/packages/golang-xyz.scm (go-github-com-bytedance-sonic)
[arguments]<#:test-subdirs>: Limit to the root package on non-x86-64.
Relates-to: guix/guix!8004
Change-Id: Ie63e1727ee5ed4034a41fba2c12f17395220bd10
Signed-off-by: Sharlatan Hellseher <[email protected]>
---
gnu/packages/golang-xyz.scm | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index 727f89fcc2..536332a3ff 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -4337,7 +4337,16 @@ offerings such as Boost, Better std, Cloud tools.")
(build-system go-build-system)
(arguments
(list
- #:import-path "github.com/bytedance/sonic"))
+ #:import-path "github.com/bytedance/sonic"
+ ;; 'go test ./...' fails to compile on non-x86-64: the
+ ;; tests in internal/jit reference helpers defined only in
+ ;; arch_amd64.go, and the assembly stubs in
+ ;; internal/native/{avx2,sse} import 'sonic/loader', whose
+ ;; internal/abi is amd64-only. The root package itself
+ ;; has arch-guarded fallback code, so keep testing it.
+ #:test-subdirs (if (target-x86-64?)
+ #~(list "...")
+ #~(list ""))))
(native-inputs
(list go-github-com-davecgh-go-spew
go-github-com-stretchr-testify))