I am trying to compile go 1.8 in Alpine Linux ppc64le (that uses musl) but 
I am getting an issue with the generated go (segfault).

As go 1.4 bootstrap does not have support for ppc64le, the steps I did:
1) Installed go 1.4 in an Alpine Linux x86_64
2) Cross compiled go 1.8 ppc64le in the same x86_64
3) Used the tarball with go cross compiled as a bootstrap to compile go in 
ppc64le.

The problem is that the go generated in step 3) is not working and is 
generating a segfault when trying to use it.
I thought that it could be a problem with go 1.8 generated in step 2), but 
the go is working fine and I was able to compile .go files. I also tried to 
use this go as bootstrap in an Ubuntu ppc64le and worked fine too.


I started to debug the go segfault problem and seems that the "argv" and 
"argc" arguments are not correct in Alpine ppc64le, but looks fine in 
x86_64 (see bellow)

- Alpine ppc64le:
#0  runtime.args (c=-1208014796, v=0x0) at 
/home/alpine/go-1.8/go-repo/go/src/runtime/runtime1.go:64
#1  0x0000000000060ecc in runtime.rt0_go () at 
/home/alpine/go-1.8/go-repo/go/src/runtime/asm_ppc64x.s:70

- Alpine x86_64:
#0  runtime.args (c=1, v=0x73028a53f248) at 
/home/rdutra/go-x86/go/src/runtime/runtime1.go:64
#1  0x0000000000453a19 in runtime.rt0_go () at 
/home/rdutra/go-x86/go/src/runtime/asm_amd64.s:156


Any idea of what could be happening?

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to