Added changelog script.

Moved declarations so that error-handling gotos do not skip them.

Converted int -> size_t where approporiate.

Corrected some typos.
For the old autoconf on Ubuntu Precise
Merge pull request #63 from keithj/devel

Cleaned up some latent errors and added a changelog script