From 49d1a032da98ac5c61cd42d6e2d3de2145b2f67d Mon Sep 17 00:00:00 2001 From: Guillaume Ballet Date: Thu, 14 Nov 2019 14:42:23 +0100 Subject: [PATCH] build: gather info to investigate why builds fail on ARM (#20281) --- .travis.yml | 2 ++ build/ci.go | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/.travis.yml b/.travis.yml index c992451c4..5366c691b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,6 +47,8 @@ jobs: dist: xenial go: 1.13.x script: + - cat /proc/cpuinfo + - free -h - go run build/ci.go install - go run build/ci.go test -coverage $TEST_PACKAGES diff --git a/build/ci.go b/build/ci.go index ac5c72b6b..55a632d3b 100644 --- a/build/ci.go +++ b/build/ci.go @@ -229,6 +229,9 @@ func doInstall(cmdline []string) { if *arch == "" || *arch == runtime.GOARCH { goinstall := goTool("install", buildFlags(env)...) + if runtime.GOARCH == "arm64" { + goinstall.Args = append(goinstall.Args, "-p", "1") + } goinstall.Args = append(goinstall.Args, "-v") goinstall.Args = append(goinstall.Args, packages...) build.MustRun(goinstall) @@ -241,6 +244,7 @@ func doInstall(cmdline []string) { os.RemoveAll(filepath.Join(path, "pkg", runtime.GOOS+"_arm")) } } + // Seems we are cross compiling, work around forbidden GOBIN goinstall := goToolArch(*arch, *cc, "install", buildFlags(env)...) goinstall.Args = append(goinstall.Args, "-v")