Use Gradle

Allows 1.7 to be compiled without trouble, as well as fixes #17.