Cleaned up documentation and makefile. Fixed some compile warnings.