You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Most compilers like GCC would take multiple -ldflags arguments, and concatenate them to produce a list of additional arguments to ld.
go build is not doing so, and uses only the last -ldflags. Fortunately it is not completely that bad, and handles -ldflags ""
(an empty argument after -ldflags) as a no-op, so scripting is still possible.
So the proposal is to concatenate multiple gcflags/ldflags. If no objections - would provide PR.
What version of Go are you using (go version)?
$ go version
go version go1.17.1 darwin/amd64
Does this issue reproduce with the latest release?
yes
The text was updated successfully, but these errors were encountered:
Most compilers like GCC would take multiple -ldflags arguments, and concatenate them to produce a list of additional arguments to ld.
go build is not doing so, and uses only the last -ldflags. Fortunately it is not completely that bad, and handles -ldflags ""
(an empty argument after -ldflags) as a no-op, so scripting is still possible.
So the proposal is to concatenate multiple gcflags/ldflags. If no objections - would provide PR.
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
The text was updated successfully, but these errors were encountered: