-1
cd /usr/local/go/src
CGO_ENABLED=0 GOOS=linux GOARCH=arm ./make.bash

# Building C bootstrap tool.
cmd/dist

# Building compilers and Go bootstrap tool for host, darwin/amd64.
lib9
libbio
libmach
misc/pprof
cmd/addr2line
cmd/cov
cmd/nm
cmd/objdump
cmd/pack
cmd/prof
cmd/cc
cmd/gc
cmd/6l
cmd/5l
/usr/local/go/src/cmd/5l/../ld/lib.c:661:9: error: no case matching constant switch condition '53'
[-Werror]
switch(thechar){
.......^~~~~~~
1 error generated.
go tool dist: FAILED: gcc -Wall -Wstrict-prototypes -Wno-sign-compare -Wno-missing-braces -Wno-parentheses -Wno-unknown-pragmas -Wno-switch -Wno-comment -Werror -fno-common -ggdb -pipe -O2 -mmacosx-version-min=10.6 -c -m64 -I /usr/local/go/include -I /usr/local/go/src/cmd/5l -o /usr/local/go/pkg/obj/cmd/5l/lib.o /usr/local/go/src/cmd/5l/../ld/lib.c

CGO_ENABLED=0 GOOS=linux GOARCH=<b>amd64</b> ./make.bash正常です!「腕」だけが正常ではありません。

#/usr/local/go/src/cmd/ld/lib.c コード:

vi cmd/ld/lib.c
661 switch(thechar){
662 case '8':
663 argv[argc++] = "-m32";
664 break;
665 case '6':
666 argv[argc++] = "-m64";
667 break;
668 }
4

1 に答える 1

-1

OSXについてはよくわかりませんが、おそらくコマンドは次のようになるはずです

export CGO_ENABLED=0 ; export GOOS=linux ; export GOARCH=arm ; ./make.bash

代わりは?

于 2013-07-09T09:32:07.480 に答える