Initial commit, already contains a lot of changes from FbTerm.