Convert to Gradle

Renamed main directories to “library” and “sample”, renamed various
Attributes as not to clash with AppCompat v21 attributes.