Skip to content

Commit

Permalink
Adds support for building facter on RHEL7 via spec.
Browse files Browse the repository at this point in the history
  • Loading branch information
dyarnell authored and mckern committed Jan 24, 2014
1 parent 5e3d6f3 commit 1deddfe
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ext/redhat/facter.spec.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Fedora 17 ships with ruby 1.9, which uses vendorlibdir instead
# Fedora 17 ships with ruby 1.9, RHEL 7 with ruby 2.0, which use vendorlibdir instead
# of sitelibdir
%if 0%{?fedora} >= 17
%if 0%{?fedora} >= 17 || 0%{?rhel} >= 7
%global facter_libdir %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["vendorlibdir"]')
%else
%global facter_libdir %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["sitelibdir"]')
Expand Down Expand Up @@ -35,8 +35,8 @@ Requires: virt-what
Requires: ruby >= 1.8.5
BuildRequires: ruby >= 1.8.5

# In Fedora 17 ruby-rdoc is called rubygem-rdoc
%if 0%{?fedora} >= 17
# In Fedora 17+ or RHEL 7+ ruby-rdoc is called rubygem-rdoc
%if 0%{?fedora} >= 17 || 0%{?rhel} >= 7
BuildRequires: rubygem-rdoc
%else
BuildRequires: ruby-rdoc
Expand Down

0 comments on commit 1deddfe

Please sign in to comment.