move ttyname() and ttyname_r() from isatty.c to ttyname.c
add getpass and top Makefile