]>
Commit | Line | Data |
---|---|---|
238af4ba ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_with tests # build without tests | |
4 | ||
199c6f54 ER |
5 | %define gem_name net-scp |
6 | Summary: A pure Ruby implementation of the SCP client protocol | |
7 | Name: ruby-%{gem_name} | |
8 | Version: 1.0.4 | |
9 | Release: 1 | |
10 | License: MIT | |
11 | Group: Development/Languages | |
12 | Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem | |
13 | # Source0-md5: 7fda0eda72b66d99816d516c5fcd4de2 | |
14 | URL: http://net-ssh.rubyforge.org/scp | |
15 | BuildRequires: rpm-rubyprov | |
16 | BuildRequires: rpmbuild(macros) >= 1.656 | |
17 | %if %{with tests} | |
18 | BuildRequires: ruby-minitest | |
19 | BuildRequires: ruby-mocha | |
20 | BuildRequires: ruby-net-ssh | |
238af4ba | 21 | BuildRequires: ruby-rubygems |
199c6f54 ER |
22 | %endif |
23 | Requires: ruby-net-ssh | |
24 | BuildArch: noarch | |
25 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
26 | ||
27 | %description | |
28 | A pure Ruby implementation of the SCP client protocol | |
29 | ||
30 | %package doc | |
31 | Summary: Documentation for %{name} | |
32 | Group: Documentation | |
33 | Requires: %{name} = %{version}-%{release} | |
34 | ||
35 | %description doc | |
36 | Documentation for %{name} | |
37 | ||
38 | %prep | |
39 | %setup -q -n %{gem_name}-%{version} | |
40 | ||
41 | %build | |
42 | %if %{with tests} | |
43 | ruby -Itest test/test_all.rb | |
44 | %endif | |
45 | ||
46 | %install | |
47 | rm -rf $RPM_BUILD_ROOT | |
48 | install -d $RPM_BUILD_ROOT%{ruby_vendorlibdir} | |
49 | cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir} | |
50 | ||
51 | %clean | |
52 | rm -rf $RPM_BUILD_ROOT | |
53 | ||
54 | %files | |
55 | %defattr(644,root,root,755) | |
56 | %doc README.rdoc CHANGELOG.rdoc | |
57 | %dir %{ruby_vendorlibdir}/net | |
58 | %{ruby_vendorlibdir}/net/scp.rb | |
59 | %{ruby_vendorlibdir}/net/scp/ | |
60 | %dir %{ruby_vendorlibdir}/uri | |
61 | %{ruby_vendorlibdir}/uri/open-scp.rb | |
62 | %{ruby_vendorlibdir}/uri/scp.rb | |
63 | ||
64 | %if 0 | |
65 | %files doc | |
66 | %defattr(644,root,root,755) | |
67 | %endif |