• Lynn Boger's avatar
    cmd/go, cmd/link: provide meaningful error msg with ext linking on ppc64 · 506d6a32
    Lynn Boger authored
    linux/ppc64 uses the ppc64 v1 ABI which was never fully supported
    by Go. (linux/ppc64le uses the ppc64 v2 ABI and that is fully
    supported).
    
    As a result if the external linker is used to build a program
    on ppc64, there is a either a warning or error message that doesn't
    clearly describe the problem. In the case of a warning,
    a program is created that will most likely not execute since it is not
    built as expected for the ppc64 dynamic linker (ld64.so.1).
    
    To avoid confusion in these cases, error messages are now issued
    if external linker is explicitly used to build the program. Note that most
    buildmodes that require external linking were already flagging linux/ppc64
    as unsupported except for c-archive, which has been added here.
    
    This problem does not occur with gccgo since the ppc64 v1 ABI is
    supported there.
    
    Fixes #25079
    
    Change-Id: I44d77a1eb9df750d499cd432b0ca4a97f0be88b2
    Reviewed-on: https://go-review.googlesource.com/109915Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
    506d6a32
config.go 6.28 KB