diff --git a/gnu/packages/golang-build.scm b/gnu/packages/golang-build.scm index af10222e07..010946b832 100644 --- a/gnu/packages/golang-build.scm +++ b/gnu/packages/golang-build.scm @@ -779,10 +779,12 @@ loading algorithms.") (build-system go-build-system) (arguments (list + #:skip-build? #t #:import-path "golang.org/x/net" - #:phases - #~(modify-phases %standard-phases - (delete 'build)))) ; no go files in project's root + #:test-flags + ;; Golang does not support "-race" on ARM, one test fails with error: + ;; ThreadSanitizer: unsupported VMA range. + #~(list #$@(if (target-arm?) '("-skip" "TestRace") '())))) (propagated-inputs (list go-golang-org-x-crypto go-golang-org-x-sys @@ -866,6 +868,15 @@ cancellation for groups of goroutines working on subtasks of a common task (arguments (list #:skip-build? #t + #:test-flags + #~(list #$@(if (target-arm?) + '("-skip" (string-join + (list "TestParseOrigDstAddr/udp4" + "TestIoctlGetEthtoolDrvinfo" + "TestIoctlGetEthtoolTsInfo" + "TestRlimitAs") + "|")) + '())) #:import-path "golang.org/x/sys")) (home-page "https://go.googlesource.com/sys") (synopsis "Go support for low-level system interaction") diff --git a/gnu/packages/golang-check.scm b/gnu/packages/golang-check.scm index 7e21653b69..51af496b64 100644 --- a/gnu/packages/golang-check.scm +++ b/gnu/packages/golang-check.scm @@ -1949,7 +1949,10 @@ execution when a test fails.") "TestStackModeMultipleInvocationInheritance" "TestStackModeMultipleInvocationInheritance2" "TestStackModeMultipleInvocationInheritance3" - "TestWatcher") + "TestWatcher" + #$@(if (target-arm?) + '("TestInfiniteLoopWithTrailingFail") + '())) "|")))) (propagated-inputs (list go-github-com-jtolds-gls diff --git a/gnu/packages/golang-maths.scm b/gnu/packages/golang-maths.scm index b14533c169..f8aa245b0b 100644 --- a/gnu/packages/golang-maths.scm +++ b/gnu/packages/golang-maths.scm @@ -21,6 +21,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system go) #:use-module (guix gexp) + #:use-module (guix utils) #:use-module (guix git-download) #:use-module (guix packages) #:use-module (gnu packages) @@ -299,7 +300,11 @@ format as binary16.") "mathext/..." "num/..." "optimize/..." - "spatial/..." + ;; Tests failing to compile on ARM systems with errors in + ;; goroutines. + #$@(if (target-x86-64?) + '("spatial/...") + '()) "stat/..." "uniti/..."))) (propagated-inputs diff --git a/gnu/packages/golang-web.scm b/gnu/packages/golang-web.scm index 2d77cf6bd3..389dfe624a 100644 --- a/gnu/packages/golang-web.scm +++ b/gnu/packages/golang-web.scm @@ -5366,7 +5366,14 @@ daemon as described in (build-system go-build-system) (arguments (list - #:import-path "github.com/libp2p/go-yamux/v4")) + #:import-path "github.com/libp2p/go-yamux/v4" + #:test-flags + ;; Test fails on ARM with error: [ERR] yamux: Failed to read stream data + ;; on stream 1: receive window exceeded (remain: 262144, recv: + ;; 33554432). + #~(list #$@(if (target-arm?) + '("-skip" "TestSendData_VeryLarge") + '())))) (native-inputs (list go-github-com-stretchr-testify)) (propagated-inputs @@ -5396,8 +5403,9 @@ It is inspired by SPDY but is not interoperable with it.") (base32 "019jj3qwzrbqcgwzri5iwi1vh2cn0ms6k8fx14jlmy856b25yl3y")))) (build-system go-build-system) (arguments - (list - #:import-path "github.com/libp2p/go-yamux/v5")))) + (substitute-keyword-arguments + (package-arguments go-github-com-libp2p-go-yamux-v4) + ((#:import-path _) "github.com/libp2p/go-yamux/v5"))))) (define-public go-github-com-libp2p-zeroconf-v2 (package @@ -5561,19 +5569,22 @@ clients that speak the Gemini protocol.") (arguments (list #:import-path "github.com/marten-seemann/tcp" - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'disable-failing-tests - (lambda* (#:key tests? import-path #:allow-other-keys) - (with-directory-excursion (string-append "src/" import-path) - (substitute* (find-files "." "_test\\.go$") - ;; couldn't initialize from a wrapped conn: unknown - ;; connection type - (("TestWrappedConn") "OffTestWrappedConn") - ;; Get "https://golang.org/robots.txt": dial tcp: lookup - ;; golang.org on [::1]:53: read udp [::1]:56806->[::1]:53: - ;; read: connection refused - (("TestInfo") "OffTestInfo")))))))) + #:test-flags + #~(list "-skip" + (string-join + ;; Test fails with error: couldn't initialize from a wrapped + ;; conn: unknown connection type. + (list "TestWrappedConn" + ;; Get "https://golang.org/robots.txt": dial tcp: lookup + ;; golang.org on [::1]:53: read udp + ;; [::1]:56806->[::1]:53: read: connection refused + "TestInfo" + ;; Test fails on ARM with error: raw-control tcp + ;; 127.0.0.1:49386: getsockopt: protocol not available. + #$@(if (target-arm?) + '("TestConcurrentReadWriteAndInfo") + '())) + "|")))) (native-inputs (list go-golang-org-x-net)) (propagated-inputs @@ -5842,9 +5853,29 @@ types.") (list #:import-path "github.com/mdlayher/netlink" #:test-flags - ;; Test fails to start command "ip": exec: "ip": executable file not - ;; found in $PATH - #~(list "-skip" "TestIntegrationConnSetBuffersSyscallConn"))) + #~(list "-skip" + (string-join + ;; Test fails to start command "ip": exec: "ip": executable + ;; file not found in $PATH + (list "TestIntegrationConnSetBuffersSyscallConn" + #$@(if (target-arm?) + ;; Tests fail on ARM systems with error: failed to + ;; dial netlink: socket: protocol not supported. + '("TestIntegrationConn" + "TestIntegrationConnClosedConn" + "TestIntegrationConnConcurrentClosePreventsReceive" + "TestIntegrationConnConcurrentCloseUnblocksReceive" + "TestIntegrationConnConcurrentOneConn" + "TestIntegrationConnConcurrentSerializeExecute" + "TestIntegrationConnExecuteTimeout" + "TestIntegrationConnExplicitPID" + "TestIntegrationConnReceiveTimeout" + "TestIntegrationConnSendTimeout" + "TestIntegrationConnSetBPF" + "TestIntegrationConnSetBPFEmpty" + "TestIntegrationConnStrict") + '()) + "|"))))) (propagated-inputs (list go-github-com-google-go-cmp go-github-com-josharian-native @@ -5874,11 +5905,21 @@ sockets (AF_NETLINK).") (build-system go-build-system) (arguments (list + #:test-flags + #~(list + ;; One test fails on ARM with error: conn_linux_test.go:120: + ;; skipping, permission denied: failed to unshare network namespace: + ;; operation not permitted + #$@(if (target-arm?) + '("-skip" "TestLinuxBindToDevice") + '())) #:import-path "github.com/mdlayher/socket")) (native-inputs (list go-github-com-google-go-cmp)) (propagated-inputs - (list go-golang-org-x-net go-golang-org-x-sync go-golang-org-x-sys)) + (list go-golang-org-x-net + go-golang-org-x-sync + go-golang-org-x-sys)) (home-page "https://github.com/mdlayher/socket") (synopsis "Low-level network connection type with async I/O and deadline support") (description @@ -6092,16 +6133,20 @@ presenting a small interface.") (arguments (list #:import-path "github.com/mikioh/tcp" - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'disable-failing-tests - (lambda* (#:key tests? import-path #:allow-other-keys) - (with-directory-excursion (string-append "src/" import-path) - (substitute* (find-files "." "_test\\.go$") - ;; Get "https://golang.org/robots.txt": dial tcp: lookup - ;; golang.org on [::1]:53: read udp [::1]:47181->[::1]:53: - ;; read: connection refused. - (("TestInfo") "OffTestInfo")))))))) + #:test-flags + #~(list "-skip" + (string-join + ;; Get "https://golang.org/robots.txt": dial tcp: lookup + ;; golang.org on [::1]:53: read udp [::1]:47181->[::1]:53: + ;; read: connection refused. + (list "TestInfo" + #$@(if (target-arm?) + ;; Test fails on ARM with error: raw-control tcp + ;; 127.0.0.1:58464: getsockopt: protocol not + ;; available. + '("TestConcurrentReadWriteAndInfo") + '())) + "|")))) (native-inputs (list go-golang-org-x-net)) (propagated-inputs @@ -8160,7 +8205,11 @@ ObjectStorage, PHY, etc.).") "TestMsglvlGet" "TestStats" "TestDriverName" - "TestBusInfo") + "TestBusInfo" + #$@(if (target-arm?) + ;; Inappropriate ioctl for device. + '("TestFeatures") + '())) "|")))) (propagated-inputs (list go-golang-org-x-sys)) diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm index 399ead8952..aedbe97864 100644 --- a/gnu/packages/golang-xyz.scm +++ b/gnu/packages/golang-xyz.scm @@ -3186,25 +3186,31 @@ levels that works by wrapping the standard @code{log} library.") (list #:import-path "github.com/cilium/ebpf" #:test-flags - ;; Tests fail with errors: - ;; - neither debugfs nor tracefs are mounted - ;; - no such file or directory - #~(list "-skip" (string-join - (list - "TestNewEvent" - "TestFSType" - "TestEventID" - "TestSanitizePath" - "TestGetTracefsPath" - ;; Tests failing on i686-linux system. - #$@(if (target-x86?) - '("TestAuxvVDSOMemoryAddress/auxv64le.bin" - "TestUnsafeB.*/.*_with_trailing_padding" - "TestUnsafeB.*/.*_with_interspersed_padding" - "TestUnsafeB.*/.*_between_slice_entries" - "TestUnsafeB.*/.*_between_array_entries") - '())) - "|")) + #~(list "-skip" + (string-join + ;; Tests fail with errors: + ;; - neither debugfs nor tracefs are mounted + ;; - no such file or directory + (list "TestNewEvent" + "TestFSType" + "TestEventID" + "TestSanitizePath" + "TestGetTracefsPath" + ;; Tests failing on i686-linux system. + #$@(if (target-x86?) + '("TestAuxvVDSOMemoryAddress/auxv64le.bin" + "TestUnsafeB.*/.*_with_trailing_padding" + "TestUnsafeB.*/.*_with_interspersed_padding" + "TestUnsafeB.*/.*_between_slice_entries" + "TestUnsafeB.*/.*_between_array_entries") + '()) + ;; Tests failing on ARM systems with error: reading vDSO + ;; ELF: read /proc/self/mem: input/output error. + #$@(if (target-arm?) + '("TestVDSOVersion" + "TestCurrentKernelVersion") + '())) + "|")) ;; XXX: 337 tests failed and 664 passed when "..." is preserved, run ;; some of available tests, figure out how to fix the rests. #:test-subdirs @@ -5232,14 +5238,20 @@ program's running, don't expect consistent results between platforms (arguments (list #:import-path "github.com/elastic/gosigar" - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'disable-failing-tests - (lambda* (#:key tests? import-path #:allow-other-keys) - (with-directory-excursion (string-append "src/" import-path) - (substitute* (find-files "." "_test\\.go$") - ;; error: open /etc/mtab: no such file or directory. - (("TestFileSystemList") "OffTestFileSystemList")))))))) + #:test-flags + #~(list "-skip" + (string-join + ;; Test fails with error: open /etc/mtab: no such file or + ;; directory. + (list "TestFileSystemList" + ;; Test fails on ARM with error: inetdiag_test.go:61: + ;; protocol not supported. + #$@(if (target-arm?) + '("TestNetlinkInetDiag" + ;; Expect "qemu-aarch64" to match "go(.exe)?" + "TestProcExe") + '())) + "|")))) (native-inputs (list go-github-com-stretchr-testify)) (propagated-inputs @@ -8994,7 +9006,11 @@ wrapper around @code{crypto/rand}.") (build-system go-build-system) (arguments (list - #:import-path "github.com/jbenet/go-temp-err-catcher")) + #:import-path "github.com/jbenet/go-temp-err-catcher" + #:test-flags + ;; One test fails on ARM with error: tec_test.go:86: time difference is + ;; greater than 0s 71.555µs. + #~(list #$@(if (target-arm?) '("-skip" "TestDoubles") '())))) (home-page "https://github.com/jbenet/go-temp-err-catcher") (synopsis "Error handling helper library") (description "Package @code{temperrcatcher} provides a @code{TempErrCatcher} @@ -9017,7 +9033,22 @@ object, which implements simple error-retrying functionality.") (build-system go-build-system) (arguments (list - #:import-path "github.com/jbenet/goprocess")) + #:import-path "github.com/jbenet/goprocess" + #:test-flags + #~(list "-short" + ;; Tests fail on ARM with error: periodic_test.go:31: time diff + ;; incorrect: 5ms 3.295666ms 15ms. + #$@(if (target-arm?) + '("-skip" (string-join + (list "TestEveryGoSeqParallel" + "TestEverySeq" + "TestTickSeq" + "TestTickSeqNoWait" + "TestTickerGoParallel" + "TestTickerGoSeq" + "TestTickerSeq") + "|")) + '())))) (native-inputs (list go-github-com-jbenet-go-cienv)) (home-page "https://github.com/jbenet/goprocess")