mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/link: disable mach-o dwarf munging with -w (in addition to -s)
Might as well provide a way around the mach-o munging that doesn't require stripping all symbols. After all, -w does mean no DWARF. For #11887, #19734, and anyone else that needs to disable this code path without losing the symbol table. Change-Id: I254b7539f97fb9211fa90f446264b383e7f3980f Reviewed-on: https://go-review.googlesource.com/38853 Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
371c83b594
commit
23dc3633ca
1 changed files with 1 additions and 1 deletions
|
|
@ -1228,7 +1228,7 @@ func (l *Link) hostlink() {
|
||||||
l.Logf("%s", out)
|
l.Logf("%s", out)
|
||||||
}
|
}
|
||||||
|
|
||||||
if !*FlagS && !debug_s && Headtype == obj.Hdarwin {
|
if !*FlagS && !*FlagW && !debug_s && Headtype == obj.Hdarwin {
|
||||||
// Skip combining dwarf on arm.
|
// Skip combining dwarf on arm.
|
||||||
if !SysArch.InFamily(sys.ARM, sys.ARM64) {
|
if !SysArch.InFamily(sys.ARM, sys.ARM64) {
|
||||||
dsym := filepath.Join(*flagTmpdir, "go.dwarf")
|
dsym := filepath.Join(*flagTmpdir, "go.dwarf")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue