Add Javadoc generation to Maven, fix a warning

Maven complained about a platform-specific encoding definition.

doc was removed from .gitignore because Maven generates Javadoc
in target/site/apidocs
Add old script, this should be handled by Maven