Commit 45d42fdc authored by Elias Naur's avatar Elias Naur

cmd/link/internal/ld: don't link with -no_pie on darwin/arm64

Ever since CL 33301 linking darwin/arm64 excutables has resulted in
warnings like:

ld: warning: -no_pie ignored for arm64

Remove -no_pie on darwin/arm64.

Change-Id: I9f7685351fa8cce29795283e1a24fc7a6753d698
Reviewed-on: https://go-review.googlesource.com/42815
Run-TryBot: Elias Naur <elias.naur@gmail.com>
Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
parent 9058b9ae
......@@ -1050,7 +1050,7 @@ func (l *Link) hostlink() {
argv = append(argv, "-Wl,-headerpad,1144")
if l.DynlinkingGo() {
argv = append(argv, "-Wl,-flat_namespace")
} else {
} else if !SysArch.InFamily(sys.ARM64) {
argv = append(argv, "-Wl,-no_pie")
}
case objabi.Hopenbsd:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment