[Android] Improve the illegal character handler in packaging tool.

When the application name includes the illegal character '.', the
packaging tool doesn't handle it and other illegal characters are
handled but no prompt. This fix is to improve the illegal character
handler in the packaging tool and the test case related to illegal
application name is added.

BUG=https://crosswalk-project.org/jira/browse/XWALK-139