]>
Commit | Line | Data |
---|---|---|
11f73794 | 1 | %define pkgname mail |
10599c00 | 2 | Summary: A Really Ruby Mail Library |
11f73794 JR |
3 | Name: ruby-%{pkgname} |
4 | Version: 2.1.3 | |
92c79358 | 5 | Release: 5 |
946d6034 | 6 | License: BSD-like |
11f73794 JR |
7 | Source0: http://rubygems.org/downloads/%{pkgname}-%{version}.gem |
8 | # Source0-md5: b9bc3bb5d8ea876b016976f6f1fe5ac4 | |
9 | Patch0: %{name}-vendor.patch | |
56709c5b | 10 | Group: Development/Languages |
11f73794 | 11 | URL: http://github.com/mikel/mail |
10599c00 ER |
12 | BuildRequires: rpm-rubyprov |
13 | BuildRequires: rpmbuild(macros) >= 1.665 | |
1ab954a0 ER |
14 | %if %(locale -a | grep -q '^en_US$'; echo $?) |
15 | BuildRequires: glibc-localedb-all | |
16 | %endif | |
10599c00 | 17 | Requires: ruby-activesupport >= 2.3.4 |
11f73794 | 18 | Requires: ruby-mime-types |
7d963d69 | 19 | Requires: ruby-treetop |
10599c00 | 20 | BuildArch: noarch |
56709c5b ZU |
21 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
22 | ||
56709c5b | 23 | %description |
11f73794 | 24 | A Really Ruby Mail Library. |
56709c5b ZU |
25 | |
26 | %package rdoc | |
11f73794 JR |
27 | Summary: HTML documentation for %{pkgname} |
28 | Summary(pl.UTF-8): Dokumentacja w formacie HTML dla %{pkgname} | |
56709c5b ZU |
29 | Group: Documentation |
30 | Requires: ruby >= 1:1.8.7-4 | |
31 | ||
32 | %description rdoc | |
11f73794 JR |
33 | HTML documentation for %{pkgname}. |
34 | ||
35 | %description rdoc -l pl.UTF-8 | |
36 | Dokumentacja w formacie HTML dla %{pkgname}. | |
37 | ||
38 | %package ri | |
39 | Summary: ri documentation for %{pkgname} | |
40 | Summary(pl.UTF-8): Dokumentacja w formacie ri dla %{pkgname} | |
41 | Group: Documentation | |
42 | Requires: ruby | |
43 | ||
44 | %description ri | |
45 | ri documentation for %{pkgname}. | |
46 | ||
47 | %description ri -l pl.UTF-8 | |
48 | Dokumentacji w formacie ri dla %{pkgname}. | |
56709c5b ZU |
49 | |
50 | %prep | |
10599c00 | 51 | %setup -q -n %{pkgname}-%{version} |
11f73794 JR |
52 | %patch0 -p1 |
53 | ||
54 | rm -r lib/mail/vendor | |
56709c5b ZU |
55 | |
56 | %build | |
1ab954a0 ER |
57 | # UTF8 locale needed for doc generation |
58 | export LC_ALL=en_US.UTF-8 | |
56709c5b ZU |
59 | rdoc --ri --op ri lib |
60 | rdoc --op rdoc lib | |
11f73794 | 61 | rm ri/created.rid |
10599c00 | 62 | rm ri/cache.ri |
56709c5b ZU |
63 | |
64 | %install | |
65 | rm -rf $RPM_BUILD_ROOT | |
10599c00 ER |
66 | install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{ruby_ridir},%{ruby_rdocdir}} |
67 | cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir} | |
56709c5b ZU |
68 | cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir} |
69 | cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version} | |
70 | ||
71 | %clean | |
72 | rm -rf $RPM_BUILD_ROOT | |
73 | ||
74 | %files | |
75 | %defattr(644,root,root,755) | |
11f73794 | 76 | %doc CHANGELOG.rdoc README.rdoc TODO.rdoc |
10599c00 ER |
77 | %{ruby_vendorlibdir}/mail.rb |
78 | %{ruby_vendorlibdir}/mail | |
79 | %{ruby_vendorlibdir}/tasks/* | |
56709c5b ZU |
80 | |
81 | %files rdoc | |
82 | %defattr(644,root,root,755) | |
83 | %{ruby_rdocdir}/%{name}-%{version} | |
11f73794 JR |
84 | |
85 | %files ri | |
86 | %defattr(644,root,root,755) | |
87 | %{ruby_ridir}/Mail |