-
Notifications
You must be signed in to change notification settings - Fork 31
Closed
Description
golang/sys@6fcdbc0 has removed some "darwin" related code, so projects, which use higher versions of golang.org/x/sys can no longer be built for this platform.
Example:
cat <<EOF > go.mod
module foo
go 1.15
require (
github.com/moby/term v0.0.0-20200611042045-63b9a826fb74
golang.org/x/sys v0.0.0-20200828080924-6fcdbc0bbc04 // indirect
)
EOF
cat <<EOF > main.go
package main
import (
"log"
"os"
"github.com/moby/term"
)
func main() {
fd := os.Stdin.Fd()
if term.IsTerminal(fd) {
ws, err := term.GetWinsize(fd)
if err != nil {
log.Fatalf("term.GetWinsize: %s", err)
}
log.Printf("%d:%d\n", ws.Height, ws.Width)
}
}
EOF
GOOS=darwin go build
Results in:
# github.com/moby/term
../../../go/pkg/mod/github.com/moby/term@v0.0.0-20200611042045-63b9a826fb74/tc.go:13:28: undefined: unix.SYS_IOCTL
../../../go/pkg/mod/github.com/moby/term@v0.0.0-20200611042045-63b9a826fb74/tc.go:18:28: undefined: unix.SYS_IOCTL
../../../go/pkg/mod/github.com/moby/term@v0.0.0-20200611042045-63b9a826fb74/termios_bsd.go:24:31: undefined: unix.SYS_IOCTL
../../../go/pkg/mod/github.com/moby/term@v0.0.0-20200611042045-63b9a826fb74/termios_bsd.go:37:31: undefined: unix.SYS_IOCT
Note: the same now happens for older versions of github.com/docker/docker or github.com/moby/moby, but the latest master already depends on this code here.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels