Skip to content

Commit

Permalink
Merge #127719
Browse files Browse the repository at this point in the history
127719: Include grunning for s390x. r=rickystewart a=yasiribmcon

PR #95291 excluded grunning from s390x as patched Go runtime is not available. 

Since we can refer go patch from [here](https://github.com/cockroachdb/cockroach/blob/master/build/teamcity/internal/release/build-and-publish-patched-go/diff.patch), we can manually patch go runtime for s390x so that grunning works for s390x.

Hence enabling back this library for s390x.

Co-authored-by: yasiribmcon <[email protected]>
Co-authored-by: yasiribmcon <[email protected]>
  • Loading branch information
3 people committed Jul 30, 2024
2 parents 7cea849 + 0b3a803 commit e8e4cce
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 289 deletions.
287 changes: 6 additions & 281 deletions pkg/util/grunning/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
go_library(
name = "grunning",
srcs = [
"disabled.go",
"enabled.go",
"grunning.go",
],
Expand All @@ -13,285 +12,11 @@ go_library(

go_test(
name = "grunning_test",
srcs = [
"disabled_test.go",
"enabled_test.go",
srcs = ["enabled_test.go"],
deps = [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
deps = select({
"@io_bazel_rules_go//go/platform:aix_ppc64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:android_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:android_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:android_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:android_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:darwin_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:darwin_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:darwin_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:darwin_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:dragonfly_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:freebsd_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:freebsd_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:freebsd_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:freebsd_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:illumos_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:ios_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:ios_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:js_wasm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_mips": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_mips64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_mips64le": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_mipsle": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_ppc64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_ppc64le": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_riscv64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:linux_s390x": [
":grunning",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:netbsd_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:netbsd_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:netbsd_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:netbsd_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:openbsd_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:openbsd_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:openbsd_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:openbsd_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:plan9_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:plan9_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:plan9_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:solaris_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:windows_386": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:windows_amd64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:windows_arm": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"@io_bazel_rules_go//go/platform:windows_arm64": [
":grunning",
"//pkg/testutils/skip",
"//pkg/util/syncutil",
"@com_github_stretchr_testify//require",
],
"//conditions:default": [],
}),
)
4 changes: 2 additions & 2 deletions pkg/util/grunning/disabled.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

// See grunning.Supported() for an explanation behind this build tag.
//
//go:build (linux && s390x) || !bazel
// +build linux,s390x !bazel
//go:build !bazel
// +build !bazel

package grunning

Expand Down
4 changes: 2 additions & 2 deletions pkg/util/grunning/disabled_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

// See grunning.Supported() for an explanation behind this build tag.
//
//go:build (linux && s390x) || !bazel
// +build linux,s390x !bazel
//go:build !bazel
// +build !bazel

package grunning_test

Expand Down
3 changes: 1 addition & 2 deletions pkg/util/grunning/enabled.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@

// See grunning.Supported() for an explanation behind this build tag.
//
//go:build !((linux && s390x) || !bazel)
// +build !linux !s390x
//go:build bazel
// +build bazel

package grunning
Expand Down
3 changes: 1 addition & 2 deletions pkg/util/grunning/enabled_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@

// See grunning.Supported() for an explanation behind this build tag.
//
//go:build !((linux && s390x) || !bazel)
// +build !linux !s390x
//go:build bazel
// +build bazel

package grunning_test
Expand Down

0 comments on commit e8e4cce

Please sign in to comment.