diff --git a/.teamcity/settings.kts b/.teamcity/settings.kts index fda747c6..9d12b453 100644 --- a/.teamcity/settings.kts +++ b/.teamcity/settings.kts @@ -46,13 +46,11 @@ val targets = arrayOf( "linux/arm64/tip", "linux/ppc64le/1.21", - "linux/ppc64le/tip", "windows/amd64/1.21", "windows/amd64/tip", "windows/arm64/1.21", - "windows/arm64/tip", "mac/amd64/1.21", "mac/amd64/tip", @@ -231,6 +229,7 @@ class TestBuild(val os: String, val arch: String, version: String, buildId: Abso when (arch) { "386", "amd64" -> equals("teamcity.agent.jvm.os.arch", if (os == "mac") "x86_64" else "amd64") "arm64" -> equals("teamcity.agent.jvm.os.arch", "aarch64") + "ppc64le" -> equals("teamcity.agent.jvm.os.arch", "ppc64le") } when (os) { "linux" -> { diff --git a/_scripts/make.go b/_scripts/make.go index ee75cff6..cd1adc0d 100644 --- a/_scripts/make.go +++ b/_scripts/make.go @@ -398,7 +398,9 @@ func testStandard() { dopie := false switch runtime.GOOS { case "linux": - dopie = true + if runtime.GOARCH != "ppc64le" { + dopie = true + } case "windows": // windows/arm64 always uses pie buildmode, no need to test everything again. // only on Go 1.15 or later, with CGO_ENABLED and gcc found in path @@ -413,6 +415,11 @@ func testStandard() { } } } + case "darwin": + if runtime.GOARCH == "amd64" { + // arm64 can only build in pie mode + dopie = true + } } if dopie { fmt.Println("\nTesting PIE buildmode, default backend") diff --git a/_scripts/test_linux.sh b/_scripts/test_linux.sh index e788ad1b..523456c6 100755 --- a/_scripts/test_linux.sh +++ b/_scripts/test_linux.sh @@ -3,17 +3,21 @@ set -e set -x apt-get -qq update -apt-get install -y dwz wget make git gcc curl jq lsof - -dwz --version +apt-get install -y gcc curl jq lsof version=$1 arch=$2 + +if [ "$arch" != "ppc64le" ]; then + apt-get install -y dwz + dwz --version +fi + function getgo { export GOROOT=/usr/local/go/$1 if [ ! -d "$GOROOT" ]; then - wget -q https://dl.google.com/go/"$1".linux-"${arch}".tar.gz + curl -sO https://dl.google.com/go/"$1".linux-"${arch}".tar.gz mkdir -p /usr/local/go tar -C /usr/local/go -xzf "$1".linux-"${arch}".tar.gz mv -f /usr/local/go/go "$GOROOT" @@ -25,6 +29,7 @@ if [ "$version" = "gotip" ]; then getgo $(curl https://go.dev/VERSION?m=text | head -1) export GOROOT_BOOTSTRAP=$GOROOT export GOROOT=/usr/local/go/go-tip + apt-get install -y git git clone https://go.googlesource.com/go /usr/local/go/go-tip cd /usr/local/go/go-tip/src ./make.bash @@ -44,7 +49,9 @@ GOPATH=$(pwd)/go export GOPATH export PATH=$PATH:$GOROOT/bin:$GOPATH/bin go version -go install honnef.co/go/tools/cmd/staticcheck@2023.1 || true +if [ "$arch" != "ppc64le" ]; then + go install honnef.co/go/tools/cmd/staticcheck@2023.1 || true +fi uname -a echo "$PATH" @@ -68,7 +75,7 @@ if [ "$arch" = "386" ]; then fi set +e -make test +go run _scripts/make.go test x=$? if [ "$version" = "gotip" ]; then exit 0 diff --git a/pkg/proc/proc_test.go b/pkg/proc/proc_test.go index 633752f1..6973e98e 100644 --- a/pkg/proc/proc_test.go +++ b/pkg/proc/proc_test.go @@ -5941,6 +5941,7 @@ func TestStacktraceExtlinkMac(t *testing.T) { // Tests stacktrace for programs built using external linker. // See issue #3194 skipUnlessOn(t, "darwin only", "darwin") + skipOn(t, "broken on darwin/amd64/pie", "darwin", "amd64", "pie") withTestProcess("issue3194", t, func(p *proc.Target, grp *proc.TargetGroup, fixture protest.Fixture) { setFunctionBreakpoint(p, t, "main.main") assertNoError(grp.Continue(), t, "First Continue()")