mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cgo: Use -fno-eliminate-unused-debug-types when calling gcc to for dwarf stabs.
This keeps debug symbols in for e.g. unreferenced enums. Fixes #479 R=rsc CC=golang-dev, waltermundt https://golang.org/cl/181102
This commit is contained in:
parent
e05b381e79
commit
690fcacdd3
1 changed files with 1 additions and 0 deletions
|
|
@ -229,6 +229,7 @@ func (p *Prog) gccDebug(stdin []byte) (*dwarf.Data, string) {
|
|||
"-Werror", // warnings are errors
|
||||
"-o" + tmp, // write object to tmp
|
||||
"-gdwarf-2", // generate DWARF v2 debugging symbols
|
||||
"-fno-eliminate-unused-debug-types", // gets rid of e.g. untyped enum otherwise
|
||||
"-c", // do not link
|
||||
"-xc", // input language is C
|
||||
"-", // read input from standard input
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue