You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (go version)?
tip
Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (go env)?
ppc64
Support was never added to golang for the ppc64 v1 ABI, so if files are generated that require the external linker on any ppc64 big endian machine, it will likely fail in some way where it is not always obvious why, and then users are confused.
Seems like golang should be able to provide an error message when an attempt is made to use -linkmode=external with GOARCH=ppc64. I think there are already cases where the use of unsupported linkmodes are flagged. I can make the change it if someone can advise where best it should go.
The text was updated successfully, but these errors were encountered:
laboger
changed the title
link: provide meaningful error message if -linkmodex=external is attempted with GOARCH=ppc64
cmd/link: provide meaningful error message if -linkmodex=external is attempted with GOARCH=ppc64
Apr 25, 2018
laboger
changed the title
cmd/link: provide meaningful error message if -linkmodex=external is attempted with GOARCH=ppc64
cmd/link: provide meaningful error message if -linkmode=external is attempted with GOARCH=ppc64
Apr 25, 2018
This is just a warning, and a dynamic binary is built, but the binary won't run because it hasn't been built according to the ppc64 v1 ABI and the dynamic linker fails:
./hello
Segmentation fault
cgo program:
go build hello_cgo.go
can't load package: package main: build constraints exclude all Go files in /home/boger/gotests
This message is not very useful, I believe it occurs because of this code in go/build/build.go:
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version
)?tip
Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?ppc64
Support was never added to golang for the ppc64 v1 ABI, so if files are generated that require the external linker on any ppc64 big endian machine, it will likely fail in some way where it is not always obvious why, and then users are confused.
Seems like golang should be able to provide an error message when an attempt is made to use -linkmode=external with GOARCH=ppc64. I think there are already cases where the use of unsupported linkmodes are flagged. I can make the change it if someone can advise where best it should go.
The text was updated successfully, but these errors were encountered: