Added gemspec. Various fixes