|
|
37f8e75 |
# F-17 and above have ruby-1.9.x, and place libs in a different location
|
|
|
4724633 |
# The checks also fail on older releases, due to an older mocha gem, it appears
|
|
|
37f8e75 |
%if 0%{?fedora} >= 17
|
|
|
4724633 |
%global enable_check 1
|
|
|
37f8e75 |
%global facter_libdir %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["vendorlibdir"]')
|
|
|
37f8e75 |
%else
|
|
|
4724633 |
%global enable_check 0
|
|
|
37f8e75 |
%global facter_libdir %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["sitelibdir"]')
|
|
|
37f8e75 |
%endif
|
|
|
37f8e75 |
|
|
|
37f8e75 |
%global ruby_version %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["ruby_version"]')
|
|
|
d73ca20 |
|
|
|
4bf6c00 |
# There is nothing useful in debuginfo, facter is only an arch package to
|
|
|
4bf6c00 |
# allow arch-dependent requires.
|
|
|
4bf6c00 |
%global debug_package %{nil}
|
|
|
4bf6c00 |
|
|
|
d73ca20 |
Name: facter
|
|
|
dc1c3db |
Version: 1.6.5
|
|
|
4bf6c00 |
Release: 5%{?dist}
|
|
|
93f8b33 |
Summary: Command and ruby library for gathering system information
|
|
|
d73ca20 |
|
|
|
d73ca20 |
Group: System Environment/Base
|
|
|
d73ca20 |
License: ASL 2.0
|
|
|
d73ca20 |
URL: http://www.puppetlabs.com/puppet/related-projects/%{name}/
|
|
|
56521c2 |
Source0: http://downloads.puppetlabs.com/%{name}/%{name}-%{version}.tar.gz
|
|
|
56521c2 |
Source1: http://downloads.puppetlabs.com/%{name}/%{name}-%{version}.tar.gz.asc
|
|
|
e9d4214 |
# https://bugzilla.redhat.com/790849
|
|
|
e9d4214 |
Patch0: 0001-Make-ec2-facts-work-on-CentOS-again.patch
|
|
|
d0469a4 |
# https://github.com/puppetlabs/facter/pull/171
|
|
|
d0469a4 |
Patch1: 0001-Preserve-timestamps-when-installing-files.patch
|
|
|
d73ca20 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
d73ca20 |
|
|
|
7203964 |
BuildRequires: ruby >= 1.8.1
|
|
|
016b153 |
BuildRequires: ruby-devel
|
|
|
37f8e75 |
%if %{enable_check}
|
|
|
016b153 |
BuildRequires: net-tools
|
|
|
37f8e75 |
BuildRequires: rubygem(mocha)
|
|
|
37f8e75 |
BuildRequires: rubygem(rspec-core)
|
|
|
37f8e75 |
%endif
|
|
|
37f8e75 |
|
|
|
a900063 |
# dmidecode and pciutils are not available on all arches
|
|
|
a900063 |
%ifarch %ix86 x86_64 ia64
|
|
|
0d728e0 |
Requires: dmidecode
|
|
|
db090e7 |
Requires: pciutils
|
|
|
a900063 |
%endif
|
|
|
a900063 |
Requires: net-tools
|
|
|
37f8e75 |
# Work around the lack of ruby in the default mock buildroot
|
|
|
37f8e75 |
%if "%{ruby_version}"
|
|
|
37f8e75 |
Requires: ruby(abi) = %{ruby_version}
|
|
|
36ba453 |
%endif
|
|
|
7203964 |
Requires: which
|
|
|
60d8a30 |
|
|
|
8bbc9c7 |
%description
|
|
|
93f8b33 |
Facter is a lightweight program that gathers basic node information about the
|
|
|
93f8b33 |
hardware and operating system. Facter is especially useful for retrieving
|
|
|
93f8b33 |
things like operating system names, hardware characteristics, IP addresses, MAC
|
|
|
93f8b33 |
addresses, and SSH keys.
|
|
|
93f8b33 |
|
|
|
93f8b33 |
Facter is extensible and allows gathering of node information that may be
|
|
|
93f8b33 |
custom or site specific. It is easy to extend by including your own custom
|
|
|
93f8b33 |
facts. Facter can also be used to create conditional expressions in Puppet that
|
|
|
93f8b33 |
key off the values returned by facts.
|
|
|
60d8a30 |
|
|
|
60d8a30 |
%prep
|
|
|
60d8a30 |
%setup -q
|
|
|
e9d4214 |
%patch0 -p1
|
|
|
d0469a4 |
%patch1 -p1
|
|
|
60d8a30 |
|
|
|
d73ca20 |
|
|
|
60d8a30 |
%build
|
|
|
d73ca20 |
# Nothing to build
|
|
|
d73ca20 |
|
|
|
60d8a30 |
|
|
|
60d8a30 |
%install
|
|
|
60d8a30 |
rm -rf %{buildroot}
|
|
|
37f8e75 |
ruby install.rb --destdir=%{buildroot} --quick --no-rdoc --sitelibdir=%{facter_libdir}
|
|
|
37f8e75 |
|
|
|
d73ca20 |
|
|
|
60d8a30 |
%clean
|
|
|
60d8a30 |
rm -rf %{buildroot}
|
|
|
60d8a30 |
|
|
|
37f8e75 |
|
|
|
016b153 |
%check
|
|
|
37f8e75 |
%if %{enable_check}
|
|
|
016b153 |
rspec spec
|
|
|
37f8e75 |
%endif
|
|
|
37f8e75 |
|
|
|
60d8a30 |
|
|
|
60d8a30 |
%files
|
|
|
60d8a30 |
%defattr(-,root,root,-)
|
|
|
bdbe815 |
%doc CHANGELOG LICENSE README.md
|
|
|
5bbf9b3 |
%{_bindir}/%{name}
|
|
|
37f8e75 |
%{facter_libdir}/%{name}*
|
|
|
60d8a30 |
|
|
|
60d8a30 |
|
|
|
60d8a30 |
%changelog
|
|
|
4bf6c00 |
* Sun Feb 19 2012 Todd Zullinger <tmz@pobox.com> - 1.6.5-5
|
|
|
4bf6c00 |
- Disable useless debuginfo generation (#795106, thanks to Ville Skyttä)
|
|
|
93f8b33 |
- Update summary and description
|
|
|
bdbe815 |
- Remove INSTALL from %%doc
|
|
|
4bf6c00 |
|
|
|
4724633 |
* Wed Feb 15 2012 Todd Zullinger <tmz@pobox.com> - 1.6.5-4
|
|
|
4724633 |
- Only run rspec checks on Fedora >= 17
|
|
|
4724633 |
|
|
|
37f8e75 |
* Mon Feb 13 2012 Todd Zullinger <tmz@pobox.com> - 1.6.5-3
|
|
|
37f8e75 |
- Make spec file work for EPEL and Fedora
|
|
|
a900063 |
- Drop BuildArch: noarch and make dmidecode/pciutils deps arch-specific
|
|
|
e9d4214 |
- Make ec2 facts work on CentOS again (#790849, thanks to Jeremy Katz)
|
|
|
d0469a4 |
- Preserve timestamps when installing files
|
|
|
37f8e75 |
|
|
|
016b153 |
* Thu Feb 02 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 1.6.5-2
|
|
|
016b153 |
- Rebuilt for Ruby 1.9.3.
|
|
|
016b153 |
|
|
|
dc1c3db |
* Thu Jan 26 2012 Todd Zullinger <tmz@pobox.com> - 1.6.5-1
|
|
|
dc1c3db |
- Update to 1.6.5
|
|
|
db090e7 |
- Require net-tools and pciutils, thanks to Dominic Cleal (#783749)
|
|
|
dc1c3db |
|
|
|
b34253b |
* Thu Jan 05 2012 Todd Zullinger <tmz@pobox.com> - 1.6.4-1
|
|
|
b34253b |
- Update to 1.6.4
|
|
|
0d728e0 |
- Require dmidecode (upstream #11041)
|
|
|
b34253b |
|
|
|
56521c2 |
* Sat Oct 15 2011 Todd Zullinger <tmz@pobox.com> - 1.6.2-1
|
|
|
56521c2 |
- Update to 1.6.2
|
|
|
56521c2 |
- Update source URL
|
|
|
56521c2 |
|
|
|
5011849 |
* Thu Sep 29 2011 Todd Zullinger <tmz@pobox.com> - 1.6.1-1
|
|
|
5011849 |
- Update to 1.6.1
|
|
|
d73ca20 |
- Minor spec file reformatting
|
|
|
5011849 |
|
|
|
6caf3cc |
* Wed Jul 27 2011 Todd Zullinger <tmz@pobox.com> - 1.6.0-2
|
|
|
6caf3cc |
- Update license tag, GPLv2+ -> ASL 2.0
|
|
|
6caf3cc |
|
|
|
5bbf9b3 |
* Thu Jul 14 2011 Todd Zullinger <tmz@pobox.com> - 1.6.0-1
|
|
|
5bbf9b3 |
- Update to 1.6.0
|
|
|
5bbf9b3 |
|
|
|
29c963e |
* Thu May 26 2011 Todd Zullinger <tmz@pobox.com> - 1.5.9-1
|
|
|
29c963e |
- Update to 1.5.9
|
|
|
8a3ff98 |
- Improve Scientific Linux support, courtesy of Orion Poplawski (upstream #7682)
|
|
|
29c963e |
|
|
|
c85c962 |
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.8-2
|
|
|
c85c962 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
|
|
c85c962 |
|
|
|
3a4165f |
* Sat Aug 28 2010 Todd Zullinger <tmz@pobox.com> - 1.5.8-1
|
|
|
3a4165f |
- Update to 1.5.8
|
|
|
3a4165f |
|
|
|
9a06064 |
* Fri Sep 25 2009 Todd Zullinger <tmz@pobox.com> - 1.5.7-1
|
|
|
9a06064 |
- Update to 1.5.7
|
|
|
9a06064 |
- Update #508037 patch from upstream ticket
|
|
|
9a06064 |
|
|
|
b184706 |
* Wed Aug 12 2009 Jeroen van Meeuwen <j.van.meeuwen@ogd.nl> - 1.5.5-3
|
|
|
b184706 |
- Fix #508037 or upstream #2355
|
|
|
b184706 |
|
|
|
aeee2a5 |
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.5-2
|
|
|
aeee2a5 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
|
|
|
aeee2a5 |
|
|
|
a737b88 |
* Fri May 22 2009 Todd Zullinger <tmz@pobox.com> - 1.5.5-1
|
|
|
a737b88 |
- Update to 1.5.5
|
|
|
a737b88 |
- Drop upstreamed libperms patch
|
|
|
a737b88 |
|
|
|
a175f4f |
* Sat Feb 28 2009 Todd Zullinger <tmz@pobox.com> - 1.5.4-1
|
|
|
a175f4f |
- New version
|
|
|
a175f4f |
- Use upstream install script
|
|
|
a175f4f |
|
|
|
8cb7792 |
* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.2-2
|
|
|
8cb7792 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
|
|
8cb7792 |
|
|
|
b78f24f |
* Tue Sep 09 2008 Todd Zullinger <tmz@pobox.com> - 1.5.2-1
|
|
|
b78f24f |
- New version
|
|
|
b78f24f |
- Simplify spec file checking for Fedora and RHEL versions
|
|
|
b78f24f |
|
|
|
15e52d2 |
* Mon Sep 8 2008 David Lutterkort <dlutter@redhat.com> - 1.5.1-1
|
|
|
15e52d2 |
- New version
|
|
|
15e52d2 |
|
|
|
5658ac8 |
* Thu Jul 17 2008 David Lutterkort <dlutter@redhat.com> - 1.5.0-3
|
|
|
5658ac8 |
- Change 'mkdir' in install to 'mkdir -p'
|
|
|
5658ac8 |
|
|
|
8bbc9c7 |
* Thu Jul 17 2008 David Lutterkort <dlutter@redhat.com> - 1.5.0-2
|
|
|
8bbc9c7 |
- Remove files that were listed twice in files section
|
|
|
8bbc9c7 |
|
|
|
8bbc9c7 |
* Mon May 19 2008 James Turnbull <james@lovedthanlosty.net> - 1.5.0-1
|
|
|
8bbc9c7 |
- New version
|
|
|
8bbc9c7 |
- Added util and plist files
|
|
|
8bbc9c7 |
|
|
|
adbd442 |
* Mon Sep 24 2007 David Lutterkort <dlutter@redhat.com> - 1.3.8-1
|
|
|
adbd442 |
- Update license tag
|
|
|
adbd442 |
- Copy all of lib/ into ruby_sitelibdir
|
|
|
adbd442 |
|
|
|
19d0129 |
* Thu Mar 29 2007 David Lutterkort <dlutter@redhat.com> - 1.3.7-1
|
|
|
19d0129 |
- New version
|
|
|
19d0129 |
|
|
|
befe4b0 |
* Fri Jan 19 2007 David Lutterkort <dlutter@redhat.com> - 1.3.6-1
|
|
|
befe4b0 |
- New version
|
|
|
befe4b0 |
|
|
|
36ba453 |
* Thu Jan 18 2007 David Lutterkort <dlutter@redhat.com> - 1.3.5-3
|
|
|
36ba453 |
- require which; facter is very unhappy without it
|
|
|
36ba453 |
|
|
|
36ba453 |
* Mon Nov 20 2006 David Lutterkort <dlutter@redhat.com> - 1.3.5-2
|
|
|
36ba453 |
- Make require ruby(abi) and buildarch: noarch conditional for fedora 5 or
|
|
|
36ba453 |
later to allow building on older fedora releases
|
|
|
36ba453 |
|
|
|
c11f21b |
* Tue Oct 10 2006 David Lutterkort <dlutter@redhat.com> - 1.3.5-1
|
|
|
c11f21b |
- New version
|
|
|
c11f21b |
|
|
|
c11f21b |
* Tue Sep 26 2006 David Lutterkort <dlutter@redhat.com> - 1.3.4-1
|
|
|
c11f21b |
- New version
|
|
|
c11f21b |
|
|
|
f252448 |
* Wed Sep 13 2006 David Lutterkort <dlutter@redhat.com> - 1.3.3-2
|
|
|
f252448 |
- Rebuilt for FC6
|
|
|
f252448 |
|
|
|
60d8a30 |
* Wed Jun 28 2006 David Lutterkort <dlutter@redhat.com> - 1.3.3-1
|
|
|
60d8a30 |
- Rebuilt
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Fri Jun 19 2006 Luke Kanies <luke@madstop.com> - 1.3.0-1
|
|
|
60d8a30 |
- Fixed spec file to work again with the extra memory and processor files.
|
|
|
60d8a30 |
- Require ruby(abi). Build as noarch
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Fri Jun 9 2006 Luke Kanies <luke@madstop.com> - 1.3.0-1
|
|
|
60d8a30 |
- Added memory.rb and processor.rb
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Mon Apr 17 2006 David Lutterkort <dlutter@redhat.com> - 1.1.4-4
|
|
|
60d8a30 |
- Rebuilt with changed upstream tarball
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Tue Mar 21 2006 David Lutterkort <dlutter@redhat.com> - 1.1.4-3
|
|
|
60d8a30 |
- Do not rely on install.rb, it will be deleted upstream
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Mon Mar 13 2006 David Lutterkort <dlutter@redhat.com> - 1.1.4-2
|
|
|
60d8a30 |
- Commented out noarch; requires fix for bz184199
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Mon Mar 6 2006 David Lutterkort <dlutter@redhat.com> - 1.1.4-1
|
|
|
60d8a30 |
- Removed unused macros
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Mon Feb 6 2006 David Lutterkort <dlutter@redhat.com> - 1.1.1-2
|
|
|
60d8a30 |
- Fix BuildRoot. Add dist to release tag
|
|
|
60d8a30 |
|
|
|
60d8a30 |
* Wed Jan 11 2006 David Lutterkort <dlutter@redhat.com> - 1.1.1-1
|
|
|
60d8a30 |
- Initial build.
|