]> git.pld-linux.org Git - packages/ruby-ohai.git/blob - ruby-ohai.spec
up to 6.14.0
[packages/ruby-ohai.git] / ruby-ohai.spec
1 %define gemname ohai
2 Summary:        Profiles your system and emits JSON
3 Name:           ruby-%{gemname}
4 Version:        6.14.0
5 Release:        0.1
6 License:        Apache v2.0
7 Group:          Development/Languages
8 Source0:        http://gems.rubyforge.org/gems/%{gemname}-%{version}.gem
9 # Source0-md5:  dd0b8e12ccaf6368362958195c10d25f
10 # Request to include: http://tickets.opscode.com/browse/OHAI-169
11 Source1:        ohai.1
12 URL:            http://docs.opscode.com/ohai.html
13 BuildRequires:  rpm-rubyprov
14 BuildRequires:  rpmbuild(macros) >= 1.656
15 Requires:       ruby-extlib
16 Requires:       ruby-ipaddress
17 Requires:       ruby-json
18 Requires:       ruby-mixlib-cli
19 Requires:       ruby-mixlib-config
20 Requires:       ruby-mixlib-log
21 Requires:       ruby-systemu
22 Requires:       ruby-yajl
23 BuildArch:      noarch
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %description
27 Ohai detects data about your operating system and prints out a JSON
28 data blob. It can be used standalone, but it's primary purpose is to
29 provide node data to Chef.
30
31 %package doc
32 Summary:        Documentation for %{name}
33 Group:          Documentation
34 Requires:       %{name} = %{version}-%{release}
35
36 %description doc
37 This package contains documentation for %{name}.
38
39 %prep
40 %setup -q
41
42 %build
43 %if %{with tests}
44 # Occasionally fails with "undefined method `rfc2822' for nil:NilClass" during
45 # mock. Unsure why - disable for now.
46 sed -i 's^Time.should_receive(:now)^^' spec/ohai/plugins/ohai_time_spec.rb
47 rake spec
48 %endif
49
50 %install
51 rm -rf $RPM_BUILD_ROOT
52 install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{_bindir}}
53 cp -a bin/* $RPM_BUILD_ROOT%{_bindir}
54 cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
55
56 # http://tickets.opscode.com/browse/OHAI-169
57 install -d $RPM_BUILD_ROOT%{_mandir}/man1
58 install -Dp %{SOURCE1} $RPM_BUILD_ROOT%{_mandir}/man1/ohai.1
59
60 %clean
61 rm -rf $RPM_BUILD_ROOT
62
63 %files
64 %defattr(644,root,root,755)
65 %doc README.rdoc
66 %attr(755,root,root) %{_bindir}/ohai
67 %{_mandir}/man1/ohai.1*
68 %{ruby_vendorlibdir}/ohai.rb
69 %{ruby_vendorlibdir}/ohai
70
71 %if 0
72 %files doc
73 %defattr(644,root,root,755)
74 %endif
This page took 0.07855 seconds and 4 git commands to generate.