// uuidFromGoBuildId hashes the Go build ID and returns a slice of 16 // bytes suitable for use as the payload in a Macho LC_UUID load // command. func uuidFromGoBuildId(buildID string) []byte { … } // machoRewriteUuid copies over the contents of the Macho executable // exef into the output file outexe, and in the process updates the // LC_UUID command to a new value recomputed from the Go build id. func machoRewriteUuid(ctxt *Link, exef *os.File, exem *macho.File, outexe string) error { … }