terminal contains a number of utility functions that are currently only implemented for Linux. Darwin uses different named constants for getting and setting the terminal state so this change splits them off as constants and defines them for each arch. R=golang-dev, minux.ma CC=golang-dev https://golang.org/cl/7286043