Fix building the release APK with gradle.

In release build all warnings are errors, and lint has some obnoxious warnings.