[go-nuts] Re: programmatic way to find if application go binary is built with -cover flag ?

2024-05-13 Thread Zxilly Chou
try debug.ReadBuildInfo(), then iterate the pair in the buildinfo.Settings 在2024年5月13日星期一 UTC+8 20:56:51 写道: > Is there a way in go to find whether a go binary is built with -cover flag > ? -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To

[go-nuts] Re: Reproducible builds with CGO

2024-04-26 Thread Zxilly Chou
golang will embed the path of the source file into the binary, also the .gopclntab will contains the path. try use -trimpath and see if there's any change. 在2024年4月27日星期六 UTC+8 01:28:05 写道: > Hi All, > > *Does anybody have experience in how the use of CGO and dynamic linking > may affect the

[go-nuts] Which part of go compiler set the symbol "runtime.text" in the final build?

2024-01-24 Thread Zxilly Chou
Yesterday, I reported an issue on debug/gosym at issues/65232 regarding the difference between the symbol table and gopclntab. A member of the Go team informed me that the start of the .text segment is not always kept the same as 'runtime.text' value. I am curious about how the compiler sets