It should be possible to retrieve debug information from internal pclntab table built in executable even after striping it from debug symbols. This table is always present in executable because it used by the runtime package.
What version of Delve are you using (dlv version)?
1.8.0
What version of Go are you using? (go version)?
1.17.5
What operating system and processor architecture are you using?
Linux Fedora 35 Kinoite, AMD64
What did you do?
Strip executable from debug symbols:
go build -ldflags '-s -w' -trimpath -o <name> <file>.go
Run it via Delve:
dlv exec ./<name>
What did you expect to see?
Type 'help' for list of commands.
(dlv)
What did you see instead?
could not launch process: could not open debug info
It should be possible to retrieve debug information from internal pclntab table built in executable even after striping it from debug symbols. This table is always present in executable because it used by the
runtime
package.dlv version
)?go version
)?Strip executable from debug symbols:
Run it via Delve: