]>
Commit | Line | Data |
---|---|---|
673a33a7 ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_with tests # build without tests | |
4 | ||
6138e7ad JR |
5 | %define pkgname hoe |
6 | Summary: Rake/rubygems helper for project Rakefiles | |
7 | Name: ruby-%{pkgname} | |
8 | Version: 2.5.0 | |
673a33a7 | 9 | Release: 1 |
6138e7ad | 10 | License: MIT/Ruby License |
673a33a7 | 11 | Group: Development/Languages |
6138e7ad JR |
12 | Source0: http://rubygems.org/downloads/%{pkgname}-%{version}.gem |
13 | # Source0-md5: 7afb2f143fbeff68d0bfa46cd1d51623 | |
673a33a7 ER |
14 | URL: http://www.zenspider.com/projects/hoe.html |
15 | BuildRequires: rpm-rubyprov | |
16 | BuildRequires: rpmbuild(macros) >= 1.656 | |
17 | BuildRequires: sed >= 4.0 | |
18 | %if %{with tests} | |
19 | BuildRequires: ruby-minitest >= 5.0 | |
20 | BuildRequires: ruby-minitest < 6 | |
21 | BuildRequires: ruby-rdoc >= 4.0 | |
22 | BuildRequires: ruby-rdoc < 5 | |
23 | %endif | |
24 | Requires: ruby-rubygems >= 1.4 | |
25 | Requires: ruby-rake >= 0.8 | |
26 | Requires: ruby-rake < 11.0 | |
27 | BuildArch: noarch | |
6138e7ad JR |
28 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
29 | ||
6138e7ad | 30 | %description |
e624ce0a JR |
31 | Hoe is a rake/rubygems helper for project Rakefiles. It helps you |
32 | manage and maintain, and release your project and includes a dynamic | |
33 | plug-in system allowing for easy extensibility. Hoe ships with | |
34 | plug-ins for all your usual project tasks including rdoc generation, | |
35 | testing, packaging, and deployment. | |
6138e7ad JR |
36 | |
37 | %package rdoc | |
38 | Summary: Documentation files for %{pkgname} | |
39 | Group: Documentation | |
40 | Requires: ruby >= 1:1.8.7-4 | |
41 | ||
42 | %description rdoc | |
43 | Documentation files for %{pkgname}. | |
44 | ||
6f2e8de4 ER |
45 | %package ri |
46 | Summary: ri documentation for %{pkgname} | |
47 | Summary(pl.UTF-8): Dokumentacja w formacie ri dla %{pkgname} | |
48 | Group: Documentation | |
49 | Requires: ruby | |
50 | ||
51 | %description ri | |
52 | ri documentation for %{pkgname}. | |
53 | ||
6138e7ad | 54 | %prep |
673a33a7 ER |
55 | %setup -q -n %{pkgname}-%{version} |
56 | %{__sed} -i -e '1 s,#!.*ruby,#!%{__ruby},' bin/* | |
6138e7ad JR |
57 | |
58 | %build | |
59 | rdoc --ri --op ri lib | |
60 | rdoc --op rdoc lib | |
673a33a7 | 61 | rm -rf ri/{File,Rake,String,Object} |
6138e7ad | 62 | rm -f ri/created.rid |
673a33a7 | 63 | rm -f ri/cache.ri |
6138e7ad JR |
64 | |
65 | %install | |
66 | rm -rf $RPM_BUILD_ROOT | |
673a33a7 ER |
67 | install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{_bindir},%{ruby_ridir},%{ruby_rdocdir}/%{name}-%{version}} |
68 | cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir} | |
6138e7ad | 69 | cp -a bin/* $RPM_BUILD_ROOT%{_bindir} |
673a33a7 | 70 | |
6138e7ad JR |
71 | cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir} |
72 | cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version} | |
73 | ||
74 | %clean | |
75 | rm -rf $RPM_BUILD_ROOT | |
76 | ||
77 | %files | |
78 | %defattr(644,root,root,755) | |
79 | %doc History.txt README.txt Hoe.pdf | |
673a33a7 ER |
80 | %attr(755,root,root) %{_bindir}/sow |
81 | %{ruby_vendorlibdir}/%{pkgname}.rb | |
82 | %{ruby_vendorlibdir}/%{pkgname} | |
6138e7ad JR |
83 | |
84 | %files rdoc | |
85 | %defattr(644,root,root,755) | |
86 | %{ruby_rdocdir}/%{name}-%{version} | |
6f2e8de4 ER |
87 | |
88 | %files ri | |
89 | %defattr(644,root,root,755) | |
6138e7ad | 90 | %{ruby_ridir}/Hoe |