Skip to content

x/term: Fails to build with golang < 1.12 #42665

@aclindsa

Description

@aclindsa

What version of Go are you using (go version)?

$ go version
go version go1.11.13 linux/amd64

Does this issue reproduce with the latest release?

It fails with the latest release of x/term and an older version of the go compiler, but not with the latest of both.

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/travis/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/travis/gopath"
GOPROXY=""
GORACE=""
GOROOT="/home/travis/.gimme/versions/go1.11.13.linux.amd64"
GOTMPDIR=""
GOTOOLDIR="/home/travis/.gimme/versions/go1.11.13.linux.amd64/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build186938083=/tmp/go-build -gno-record-gcc-switches"

What did you do?

Attempted to build ofxgo on travis using go 1.11.

What did you expect to see?

golang.org/x/term

What did you see instead?

golang.org/x/term
# golang.org/x/term
../../../golang.org/x/term/term_unix_linux.go:9:7: ioctlReadTermios redeclared in this block
	previous declaration at ../../../golang.org/x/term/term_unix_aix.go:9:26
../../../golang.org/x/term/term_unix_linux.go:10:7: ioctlWriteTermios redeclared in this block
	previous declaration at ../../../golang.org/x/term/term_unix_aix.go:10:27

https://travis-ci.com/github/aclindsa/ofxgo/jobs/441671582

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions