[2509] | 1 | # Generated from pony-1.8.gem by gem2rpm -*- rpm-spec -*- |
---|
| 2 | %global gem_name pony |
---|
| 3 | %global rubyabi 1.9.1 |
---|
| 4 | |
---|
| 5 | Name: rubygem-%{gem_name} |
---|
| 6 | Version: 1.8 |
---|
| 7 | Release: 1%{?dist}.scripts.%{scriptsversion} |
---|
| 8 | Summary: Send email in one command: Pony.mail(:to => 'someone@example.com', :body => 'hello') |
---|
| 9 | Group: Development/Languages |
---|
| 10 | License: MIT |
---|
| 11 | URL: http://github.com/benprew/pony |
---|
| 12 | Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem |
---|
| 13 | Requires: ruby(abi) = %{rubyabi} |
---|
| 14 | Requires: ruby(rubygems) |
---|
| 15 | Requires: rubygem(mail) >= 2.0 |
---|
| 16 | BuildRequires: ruby(abi) = %{rubyabi} |
---|
| 17 | BuildRequires: rubygems-devel |
---|
| 18 | BuildRequires: ruby |
---|
| 19 | BuildArch: noarch |
---|
| 20 | Provides: rubygem(%{gem_name}) = %{version} |
---|
| 21 | |
---|
| 22 | %description |
---|
| 23 | Send email in one command: Pony.mail(:to => 'someone@example.com', :body => |
---|
| 24 | 'hello') |
---|
| 25 | |
---|
| 26 | |
---|
| 27 | %package doc |
---|
| 28 | Summary: Documentation for %{name} |
---|
| 29 | Group: Documentation |
---|
| 30 | Requires: %{name} = %{version}-%{release} |
---|
| 31 | BuildArch: noarch |
---|
| 32 | |
---|
| 33 | %description doc |
---|
| 34 | Documentation for %{name} |
---|
| 35 | |
---|
| 36 | %prep |
---|
| 37 | gem unpack %{SOURCE0} |
---|
| 38 | |
---|
| 39 | %setup -q -D -T -n %{gem_name}-%{version} |
---|
| 40 | |
---|
| 41 | gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec |
---|
| 42 | |
---|
| 43 | %build |
---|
| 44 | mkdir -p .%{gem_dir} |
---|
| 45 | |
---|
| 46 | # Create the gem as gem install only works on a gem file |
---|
| 47 | gem build %{gem_name}.gemspec |
---|
| 48 | |
---|
| 49 | |
---|
| 50 | # gem install installs into a directory. We set that to be a local |
---|
| 51 | # directory so that we can move it into the buildroot in %%install |
---|
| 52 | gem install --local --install-dir ./%{gem_dir} \ |
---|
| 53 | --force --rdoc %{gem_name}-%{version}.gem |
---|
| 54 | |
---|
| 55 | %install |
---|
| 56 | mkdir -p %{buildroot}%{gem_dir} |
---|
| 57 | cp -pa .%{gem_dir}/* \ |
---|
| 58 | %{buildroot}%{gem_dir}/ |
---|
| 59 | rm -f %{buildroot}%{gem_instdir}/{Rakefile,pony.gemspec} |
---|
| 60 | rm -rf %{buildroot}%{gem_instdir}/spec |
---|
| 61 | |
---|
| 62 | |
---|
| 63 | %files |
---|
| 64 | %dir %{gem_instdir} |
---|
| 65 | %{gem_libdir} |
---|
| 66 | %exclude %{gem_cache} |
---|
| 67 | %{gem_spec} |
---|
| 68 | |
---|
| 69 | %files doc |
---|
| 70 | %doc %{gem_docdir} |
---|
| 71 | %doc %{gem_instdir}/README.rdoc |
---|
| 72 | |
---|
| 73 | %changelog |
---|
| 74 | * Sun Mar 09 2014 Benjamin Tidor <btidor@mit.edu> - 1.8-1 |
---|
| 75 | - Initial package |
---|