opt: only use termios if HAVE_SYS_TERMIOS_H is defined