]>
Commit | Line | Data |
---|---|---|
ad9d94ee JR |
1 | %define pkgname erubis |
2 | Summary: Fast, secure, and very extensible implementation of eRuby | |
3 | Name: ruby-%{pkgname} | |
4 | Version: 2.6.5 | |
5 | Release: 1 | |
6 | License: GPL | |
7 | Group: Development/Languages | |
8 | Source0: http://rubygems.org/downloads/%{pkgname}-%{version}.gem | |
9 | # Source0-md5: 071dc576fe9f1c547ef2993e0be942b0 | |
f1d26105 ER |
10 | BuildRequires: rpm-rubyprov |
11 | BuildRequires: rpmbuild(macros) >= 1.656 | |
12 | BuildArch: noarch | |
ad9d94ee JR |
13 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
14 | ||
15 | %description | |
16 | Erubis is a fast, secure, and very extensible implementation of eRuby. | |
ad9d94ee JR |
17 | |
18 | %package rdoc | |
19 | Summary: HTML documentation for %{pkgname} | |
20 | Summary(pl.UTF-8): Dokumentacja w formacie HTML dla %{pkgname} | |
21 | Group: Documentation | |
22 | Requires: ruby >= 1:1.8.7-4 | |
23 | ||
24 | %description rdoc | |
25 | HTML documentation for %{pkgname}. | |
26 | ||
27 | %description rdoc -l pl.UTF-8 | |
28 | Dokumentacja w formacie HTML dla %{pkgname}. | |
29 | ||
30 | %package ri | |
31 | Summary: ri documentation for %{pkgname} | |
32 | Summary(pl.UTF-8): Dokumentacja w formacie ri dla %{pkgname} | |
33 | Group: Documentation | |
34 | Requires: ruby | |
35 | ||
36 | %description ri | |
37 | ri documentation for %{pkgname}. | |
38 | ||
39 | %description ri -l pl.UTF-8 | |
40 | Dokumentacji w formacie ri dla %{pkgname}. | |
41 | ||
42 | %prep | |
f1d26105 | 43 | %setup -q |
ad9d94ee JR |
44 | |
45 | %{__sed} -i -e 's,/usr/bin/env ruby,%{__ruby},' bin/erubis | |
46 | ||
47 | %build | |
48 | rdoc --ri --op ri lib | |
49 | rdoc --op rdoc lib | |
50 | rm -r ri/{ActionView,ERB} | |
51 | rm ri/created.rid | |
f1d26105 | 52 | rm ri/cache.ri |
ad9d94ee JR |
53 | |
54 | %install | |
55 | rm -rf $RPM_BUILD_ROOT | |
56 | install -d $RPM_BUILD_ROOT{%{_bindir},%{ruby_rubylibdir},%{ruby_ridir},%{ruby_rdocdir}} | |
57 | ||
58 | cp -a bin/* $RPM_BUILD_ROOT%{_bindir} | |
59 | cp -a lib/* $RPM_BUILD_ROOT%{ruby_rubylibdir} | |
60 | cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir} | |
61 | cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version} | |
62 | ||
63 | %clean | |
64 | rm -rf $RPM_BUILD_ROOT | |
65 | ||
66 | %files | |
67 | %defattr(644,root,root,755) | |
68 | %doc CHANGES.txt README.txt | |
69 | %attr(755,root,root) %{_bindir}/erubis | |
70 | %{ruby_rubylibdir}/erubis.rb | |
71 | %{ruby_rubylibdir}/erubis | |
72 | ||
73 | %files rdoc | |
74 | %defattr(644,root,root,755) | |
75 | %{ruby_rdocdir}/%{name}-%{version} | |
76 | ||
77 | %files ri | |
78 | %defattr(644,root,root,755) | |
79 | %{ruby_ridir}/Erubis |