Skip to content

Commit edaf02f

Browse files
committed
fix typo and more specific comment
1 parent fda9367 commit edaf02f

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/cmd/go/internal/work/exec.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2972,9 +2972,8 @@ func (b *Builder) dynimport(a *Action, p *load.Package, objdir, importGo, cgoExe
29722972
ldflags := cgoLDFLAGS
29732973
if (cfg.Goarch == "arm" && cfg.Goos == "linux") || cfg.Goos == "android" {
29742974
if !str.Contains(ldflags, "-no-pie") {
2975-
// if we do'nt see '-no-pie',
2976-
// we add "-pie" keep backward-compatibility
2977-
// (https://golang.org/cl/5989058)
2975+
// we need to use -pie for Linux/ARM to get accurate imported sym (added in https://golang.org/cl/5989058)
2976+
// this seems to be outdated, but we don't want to break existing builds depending on this (Issue 45940)
29782977
ldflags = append(ldflags, "-pie")
29792978
}
29802979
if str.Contains(ldflags, "-pie") && str.Contains(ldflags, "-static") {

0 commit comments

Comments
 (0)