Open szkiba opened 4 days ago
It would be a better user experience if it worked like the go toolkit, i.e. a statically linked binary would be created by default.
@szkiba not sure what you mean here. Could you elaborate?
CopyGoEnv:true
copies the current go env, which includes the CGO_ENABLED.
That is, it does not override the go toolkit's default.
The native builder (
{GoOpts: {CopyGoEnv:true}}
) creates a dynamically linked binary on Linux as if cgo is enabled by default.It would be a better user experience if it worked like the go toolkit, i.e. a statically linked binary would be created by default.