mirror of
https://github.com/SagerNet/sing-box.git
synced 2026-10-22 12:02:47 +00:00
15 lines
360 B
Go
15 lines
360 B
Go
package build_shared
|
|
|
|
import "strings"
|
|
|
|
func LinkerFlags(version string, debug bool) string {
|
|
flags := []string{
|
|
"-X github.com/sagernet/sing-box/constant.Version=" + version,
|
|
"-X runtime.godebugDefault=multipathtcp=0,tlssha1=1",
|
|
"-checklinkname=0",
|
|
}
|
|
if !debug {
|
|
flags = append(flags, "-s", "-w", "-buildid=")
|
|
}
|
|
return strings.Join(flags, " ")
|
|
}
|