]> git.pld-linux.org Git - packages/gem2rpm.git/blob - gem2rpm.spec
load rubygems
[packages/gem2rpm.git] / gem2rpm.spec
1 Summary:        Generate rpm specfiles from gems
2 Name:           gem2rpm
3 Version:        0.8.1
4 Release:        0.3
5 License:        GPL v2+
6 Group:          Development/Languages
7 Source0:        http://rubygems.org/gems/%{name}-%{version}.gem
8 # Source0-md5:  d3c9416f225ae944fd195e69e122d46e
9 # git clone https://github.com/lutter/gem2rpm.git && cd gem2rpm && git checkout v0.8.1
10 # tar czvf gem2rpm-0.8.1-tests.tgz test/
11 Source1:        %{name}-%{version}-tests.tgz
12 # Source1-md5:  d7d8bc231dc405bbce00f570c89f530e
13 Patch0:         gems.patch
14 URL:            https://github.com/lutter/gem2rpm/
15 BuildRequires:  rpm-rubyprov
16 BuildRequires:  rpmbuild(macros) >= 1.656
17 Requires:       ruby
18 BuildArch:      noarch
19 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21 %description
22 Generate source rpms and rpm spec files from a Ruby Gem. The spec file
23 tries to follow the gem as closely as possible, and be compliant with
24 the Fedora rubygem packaging guidelines
25
26 %package doc
27 Summary:        Documentation for %{name}
28 Group:          Documentation
29 Requires:       %{name} = %{version}-%{release}
30
31 %description doc
32 Documentation for %{name}.
33
34 %prep
35 %setup -q
36 %patch0 -p1
37
38 %build
39 %if %{with tests}
40 testrb -Itest test/
41 %endif
42
43 %install
44 rm -rf $RPM_BUILD_ROOT
45 install -d $RPM_BUILD_ROOT{%{ruby_rubylibdir},%{_bindir}}
46
47 cp -a bin/* $RPM_BUILD_ROOT%{_bindir}
48 cp -a lib/* $RPM_BUILD_ROOT%{ruby_rubylibdir}
49
50 install -d $RPM_BUILD_ROOT%{_datadir}/ruby/templates
51 cp -a templates/* $RPM_BUILD_ROOT%{_datadir}/ruby/templates
52
53 %clean
54 rm -rf $RPM_BUILD_ROOT
55
56 %files
57 %defattr(644,root,root,755)
58 %doc README AUTHORS
59 %attr(755,root,root) %{_bindir}/gem2rpm
60 %{ruby_rubylibdir}/gem2rpm.rb
61 %{ruby_rubylibdir}/gem2rpm
62 %{_datadir}/ruby/templates
63
64 %if 0
65 %files doc
66 %defattr(644,root,root,755)
67 %doc %{gem_docdir}
68 %doc %{gem_instdir}/README
69 %doc %{gem_instdir}/AUTHORS
70 %endif
This page took 0.064003 seconds and 3 git commands to generate.