mirror of
https://github.com/golang/go
synced 2024-11-19 17:14:44 -07:00
cmd/dist: more build fixes
Flush stdout before writing to stderr, to avoid reordering output. Allow amd64 from uname -m (FreeBSD). TBR=golang-dev CC=golang-dev https://golang.org/cl/5629051
This commit is contained in:
parent
68576506d6
commit
650e8de0a5
3
src/cmd/dist/unix.c
vendored
3
src/cmd/dist/unix.c
vendored
@ -470,6 +470,7 @@ fatal(char *msg, ...)
|
||||
{
|
||||
va_list arg;
|
||||
|
||||
fflush(stdout);
|
||||
fprintf(stderr, "go tool dist: ");
|
||||
va_start(arg, msg);
|
||||
vfprintf(stderr, msg, arg);
|
||||
@ -654,7 +655,7 @@ main(int argc, char **argv)
|
||||
if(gohostarch == nil) {
|
||||
if(uname(&u) < 0)
|
||||
fatal("uname: %s", strerror(errno));
|
||||
if(contains(u.machine, "x86_64"))
|
||||
if(contains(u.machine, "x86_64") || contains(u.machine, "amd64"))
|
||||
gohostarch = "amd64";
|
||||
else if(hassuffix(u.machine, "86"))
|
||||
gohostarch = "386";
|
||||
|
Loading…
Reference in New Issue
Block a user