Cleaned up code. Added Documentation

Split into multiple files. Added documentation configuration file.
Created autogen.sh, gendoc.sh, and restore.sh to make building and
cleaning code easier.