Initial commit, based on existing work.