From: Russ Cox Date: Fri, 23 Jan 2015 16:08:32 +0000 (-0500) Subject: cmd/go: on arm, all binaries depend on math X-Git-Tag: go1.5beta1~2266 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=891d344cd0b9c43b6dc89a0920c57442b93326cf;p=gostls13.git cmd/go: on arm, all binaries depend on math Change-Id: I10b781927245a3e9822f9cffe254f226a5b93213 Reviewed-on: https://go-review.googlesource.com/3279 Reviewed-by: Russ Cox --- diff --git a/src/cmd/go/pkg.go b/src/cmd/go/pkg.go index 23154f9120..f9fbe9c452 100644 --- a/src/cmd/go/pkg.go +++ b/src/cmd/go/pkg.go @@ -524,6 +524,10 @@ func (p *Package) load(stk *importStack, bp *build.Package, err error) *Package if buildRace && (!p.Standard || !raceExclude[p.ImportPath]) { importPaths = append(importPaths, "runtime/race") } + // On ARM with GOARM=5, everything depends on math for the link. + if p.ImportPath == "main" && goarch == "arm" { + importPaths = append(importPaths, "math") + } } // Build list of full paths to all Go files in the package,