Migrate to gradle project