mirror of
https://github.com/golang/go
synced 2024-11-23 12:40:11 -07:00
cmd/go: use platform.MustLinkExternal in externalLinkingForced
This is a roll-forward of CL 477395 which was rolled back in CL 477736. The earlier CL failed because we didn't account for the fact that on some targets PIE is the default. That is now fixed. Change-Id: I3e93faa9506033d27040cc9920836f010e05cd26 Reviewed-on: https://go-review.googlesource.com/c/go/+/477919 Reviewed-by: Ian Lance Taylor <iant@google.com> Run-TryBot: Ian Lance Taylor <iant@golang.org> Auto-Submit: Ian Lance Taylor <iant@google.com> Reviewed-by: Bryan Mills <bcmills@google.com> TryBot-Result: Gopher Robot <gobot@golang.org>
This commit is contained in:
parent
bf1814bc9e
commit
6a914ee26f
@ -2627,12 +2627,7 @@ func externalLinkingForced(p *Package) bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Some targets must use external linking even inside GOROOT.
|
// Some targets must use external linking even inside GOROOT.
|
||||||
switch cfg.BuildContext.GOOS {
|
if platform.MustLinkExternal(cfg.BuildContext.GOOS, cfg.BuildContext.GOARCH, false) {
|
||||||
case "android":
|
|
||||||
if cfg.BuildContext.GOARCH != "arm64" {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
case "ios":
|
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user